TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

LFortran compiles PRIMA

77 pointsby genphy19763 months ago

10 comments

pjmlp2 months ago
Nice milestone.<p>Modern Fortran is no longer the FORTRAN from punch cards, having this compiler push maybe will help folks to write directly blazing performance Fortran code, instead of numerical code in Python.
评论 #43307851 未加载
评论 #43309221 未加载
genphy19762 months ago
For more information about LFortran, see<p>- Wikipedia: <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;LFortran" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;LFortran</a><p>- Homepage: <a href="https:&#x2F;&#x2F;lfortran.org" rel="nofollow">https:&#x2F;&#x2F;lfortran.org</a><p>- GitHub: <a href="https:&#x2F;&#x2F;github.com&#x2F;lfortran&#x2F;lfortran" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;lfortran&#x2F;lfortran</a><p>If you like to play with it, see<p>- LFortran in web browsers using WebAssembly: <a href="https:&#x2F;&#x2F;dev.lfortran.org" rel="nofollow">https:&#x2F;&#x2F;dev.lfortran.org</a><p>- LFortran in Compiler Explorer: <a href="https:&#x2F;&#x2F;godbolt.org&#x2F;z&#x2F;EfWvsY6Kh" rel="nofollow">https:&#x2F;&#x2F;godbolt.org&#x2F;z&#x2F;EfWvsY6Kh</a>
andsoitis2 months ago
LFortran is an alpha-stage modern, interactive LLVM-based Fortran compiler.
评论 #43313892 未加载
quanto2 months ago
&gt; It utilizes a range of Modern Fortran features, including extensive use of optional variables, function pointer passing, and a randomized test driver, among others. Successfully compiling PRIMA requires a compiler with a robust and mature backend, as well as well-developed intermediate passes and a capable parser.<p>I am not getting a full picture here. What&#x27;s challenging about PRIMA code base? Does it use some advanced features that are difficult for a compiler to support? Are the mentioned features in the 2008 standard?<p>What&#x27;s actually impressive is that LFortran in alpha stage is only 2x slower than GFortran, which goes back decades.
评论 #43321069 未加载
actinium2262 months ago
Congrats to Ondřej Čertík and the team working on LFortran, this is a big milestone!
ggraphilia2 months ago
See<p><a href="https:&#x2F;&#x2F;labs.quansight.org&#x2F;blog&#x2F;building-scipy-with-flang" rel="nofollow">https:&#x2F;&#x2F;labs.quansight.org&#x2F;blog&#x2F;building-scipy-with-flang</a><p>which was once discussed on HN at<p><a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=38196412">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=38196412</a>
评论 #43321475 未加载
ggraphilia2 months ago
Discussions on the Fortran Discourse:<p><a href="https:&#x2F;&#x2F;fortran-lang.discourse.group&#x2F;t&#x2F;lfortran-compiles-prima&#x2F;9296" rel="nofollow">https:&#x2F;&#x2F;fortran-lang.discourse.group&#x2F;t&#x2F;lfortran-compiles-pri...</a>
genphy19762 months ago
In case you appreciate LFortran and would like to sponsor its development, see<p>- Become a sponsor to LFortran: <a href="https:&#x2F;&#x2F;github.com&#x2F;sponsors&#x2F;lfortran" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;sponsors&#x2F;lfortran</a><p>- Open Collective: <a href="https:&#x2F;&#x2F;opencollective.com&#x2F;lfortran" rel="nofollow">https:&#x2F;&#x2F;opencollective.com&#x2F;lfortran</a><p>- NumFOCUS: <a href="https:&#x2F;&#x2F;numfocus.org&#x2F;donate-to-lfortran" rel="nofollow">https:&#x2F;&#x2F;numfocus.org&#x2F;donate-to-lfortran</a>
ggraphilia2 months ago
For PRIMA, see<p><a href="https:&#x2F;&#x2F;github.com&#x2F;libprima&#x2F;prima" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;libprima&#x2F;prima</a><p><a href="https:&#x2F;&#x2F;hn.algolia.com&#x2F;?dateRange=all&amp;page=0&amp;prefix=true&amp;query=Prima%20&amp;sort=byPopularity&amp;type=story" rel="nofollow">https:&#x2F;&#x2F;hn.algolia.com&#x2F;?dateRange=all&amp;page=0&amp;prefix=true&amp;que...</a>
genewitch2 months ago
I&#x27;ll have to benchmark a library-less Matmul with LFortran, to compare against flang, C, and python versions.<p>Roughly: 8, 12, 18 units of time, respectively. Python only being twice as slow for the simplest matmul - how much of that is merely the interpreter startup time?