blob: 2d5435196bb9bc8182d876c45530df13066eeff9 [file] [log] [blame] [view]
David Truby413467f2020-04-09 20:12:541# Flang
Steve Scalpone282358f2020-03-27 16:23:322
David Truby413467f2020-04-09 20:12:543Flang is a ground-up implementation of a Fortran front end written in modern
4C++. It started off as the f18 project (https://github.com/flang-compiler/f18)
5with an aim to replace the previous flang project
6(https://github.com/flang-compiler/flang) and address its various deficiencies.
7F18 was subsequently accepted into the LLVM project and rechristened as Flang.
Stephane Chauveau63141a02018-05-03 12:54:538
Sylvestre Ledruf7bd4ef2023-01-06 16:09:219Please note that flang is not ready yet for production usage.
10
Steve Scalponec90ce542019-03-20 06:47:1811## Getting Started
Stephane Chauveau63141a02018-05-03 12:54:5312
sameeran joshieaff2002020-08-18 09:35:5113Read more about flang in the [docs directory](docs).
14Start with the [compiler overview](docs/Overview.md).
psteinfeld1b50ccd2019-02-25 17:39:2715
Steve Scalponec90ce542019-03-20 06:47:1816To better understand Fortran as a language
David Truby413467f2020-04-09 20:12:5417and the specific grammar accepted by flang,
sameeran joshieaff2002020-08-18 09:35:5118read [Fortran For C Programmers](docs/FortranForCProgrammers.md)
Steve Scalponec90ce542019-03-20 06:47:1819and
brett kooncef09587c2020-10-10 20:10:5320flang's specifications of the [Fortran grammar](docs/f2018-grammar.md)
Steve Scalponec90ce542019-03-20 06:47:1821and
brett kooncef09587c2020-10-10 20:10:5322the [OpenMP grammar](docs/OpenMP-4.5-grammar.md).
psteinfeld1b50ccd2019-02-25 17:39:2723
Steve Scalponec90ce542019-03-20 06:47:1824Treatment of language extensions is covered
sameeran joshieaff2002020-08-18 09:35:5125in [this document](docs/Extensions.md).
Steve Scalponec90ce542019-03-20 06:47:1826
27To understand the compilers handling of intrinsics,
sameeran joshieaff2002020-08-18 09:35:5128see the [discussion of intrinsics](docs/Intrinsics.md).
Steve Scalponec90ce542019-03-20 06:47:1829
David Truby413467f2020-04-09 20:12:5430To understand how a flang program communicates with libraries at runtime,
sameeran joshieaff2002020-08-18 09:35:5131see the discussion of [runtime descriptors](docs/RuntimeDescriptor.md).
Steve Scalponec90ce542019-03-20 06:47:1832
33If you're interested in contributing to the compiler,
sameeran joshieaff2002020-08-18 09:35:5134read the [style guide](docs/C++style.md)
Steve Scalponec90ce542019-03-20 06:47:1835and
sameeran joshieaff2002020-08-18 09:35:5136also review [how flang uses modern C++ features](docs/C++17.md).
Stephane Chauveau63141a02018-05-03 12:54:5337
Louis Dionne4ae83bb2022-02-09 17:08:4438If you are interested in writing new documentation, follow
39[LLVM's Markdown style guide](https://github.com/llvm/llvm-project/blob/main/llvm/docs/MarkdownQuickstartTemplate.md).
Sameeran joshibc9cdfa2020-08-24 14:21:4540
Shivam Gupta85057c12023-04-12 06:54:1541Consult the [Getting Started with Flang](docs/GettingStarted.md)
42for information on building and running flang.