Live data from Hacker News

LFortran: Modern interactive LLVM-based Fortran compiler

lfortran.org

1–10 of 73 posts

Re: LFortran: Modern interactive LLVM-based Fortran compiler

#3

Is this related to flang? https://github.com/llvm/llvm-project/tree/master/flang/

Not exactly. Development of both started at about the same time, but it was a coincidence. Flang is a standard compiler, whilst LFortran is more geared towards interactive use à la Jupyter, or source-to-source compilation.

Here’s a demo of the Jupyter notebook-like interface: https://mybinder.org/v2/gl/lfortran%2Fweb%2Flfortran-binder/...

Re: LFortran: Modern interactive LLVM-based Fortran compiler

#5

Nice, I want to play with this, but I see on the Development page there is no/limited support for arrays?

Not sure about arrays (I am not involved in the project, I just thought it was cool). It’s still in a very preliminary stage, though, so there certainly are rough edges.

Re: LFortran: Modern interactive LLVM-based Fortran compiler

#8
I use C++ Eigen extensively. I wonder if it feasible to write a C++ programs that hands off blocks of linear algebra code to Fortran subroutines. Eigen does a wonderful job of late binding and lazy evaluation so that something like the following is fairly efficient:

     (L.transpose() * P).diagonal().array().square().mean();
which computes the squared average of column by column dot products between matrices L and P. I assume Fortran, since matrices are native types, does this kind of thing even better.

Aside: Fortran 77 was the first programming language I learned in 1985 and I hated programming for awhile after that. We called it the "F" language. Now that I am a bit older and do a lot of linear algebra coding... I wonder if I would like it now.

Post reply on HN