|
| 1 | +# Feature Highlights |
| 2 | + |
| 3 | +LFortran is in development, there are features that work today, and there are |
| 4 | +features that are being implemented. |
| 5 | + |
| 6 | +## Works today |
| 7 | + |
| 8 | +* **Full Fortran 2018 parser** |
| 9 | + LFortran can parse any Fortran 2018 syntax to AST (Abstract Syntax Tree) |
| 10 | + and format it back as Fortran source code (`lfortran fmt`). |
| 11 | + |
| 12 | +* **Interactive, Jupyter support** |
| 13 | + LFortran can be used as a Jupyter kernel, allowing Python/Julia-style rapid |
| 14 | + prototyping and an exploratory workflow (`conda install jupyter lfortran`). |
| 15 | + It can also be used from the command-line with an interactive prompt |
| 16 | + (REPL). |
| 17 | + |
| 18 | +* **Clean, modular design, usable as a library** |
| 19 | + LFortran is structured around two independent modules, AST (Abstract Syntax |
| 20 | + Tree) and ASR (Abstract Semantic Representation), both of which are |
| 21 | + standalone (completely independent of the rest of LFortran) and users are |
| 22 | + encouraged to use them independently for other applications and build tools |
| 23 | + on top. See the [Design](https://docs.lfortran.org/design/) and |
| 24 | + [Developer Tutorial](https://docs.lfortran.org/developer_tutorial/) documents for |
| 25 | + more details. |
| 26 | + |
| 27 | +* **Create executables** |
| 28 | + It can create executables just like other Fortran compilers. |
| 29 | + |
| 30 | +* **Runs on Linux, Mac, Windows and WebAssembly** |
| 31 | + All four platforms are regularly tested by our CI. |
| 32 | + |
| 33 | +* **Several backends** |
| 34 | + The LLVM can be used to compile to binaries and for interactive usage. The |
| 35 | + C++ backend translates Fortran code to a readable C++ code. The x86 backend |
| 36 | + allows very fast compilation directly to x86 machine code. The WebAssembly |
| 37 | + backend can quickly generate WASM. |
| 38 | + |
| 39 | + |
| 40 | +## Under Development |
| 41 | + |
| 42 | +These features are under development: |
| 43 | + |
| 44 | +* **Full Fortran 2018 support** |
| 45 | + The parser can now parse all of Fortran 2018 syntax to AST. A smaller |
| 46 | + subset can be transformed into ASR and even smaller subset compiled via |
| 47 | + LLVM to machine code. We are now working on extending the subset that |
| 48 | + LFortran can fully compile until we reach full Fortran 2018 support. |
| 49 | + |
| 50 | +* **Support for diverse hardware** |
| 51 | + LLVM makes it possible to run LFortran on diverse hardware and take |
| 52 | + advantage of native Fortran language constructs (such as `do concurrent`) |
| 53 | + on multi-core CPUs and GPUs. |
| 54 | + |
| 55 | +Please vote on issues in our [issue tracker] that you want us to prioritize |
| 56 | +(feel free to create new ones if we are missing anything). |
| 57 | + |
| 58 | + |
| 59 | +[static]: https://nbviewer.jupyter.org/gist/certik/f1d28a486510810d824869ab0c491b1c |
| 60 | +[interactive]: https://mybinder.org/v2/gl/lfortran%2Fweb%2Flfortran-binder/master?filepath=Demo.ipynb |
| 61 | + |
| 62 | +[issue tracker]: https://github.com/lfortran/lfortran/issues |
0 commit comments