Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Languages aren't optimized, compilers are

Actually, specific pieces of code get optimized, and compilers that can "undo" optimizations put in to the source code by hand are so rare I daresay they don't exist.



The intel compiler is considered to generate runtimes that runs about twice as fast as runtimes from gfortran. Haven't seen any recent tests of CLANG/LLVM yet. The statement that compilers, not languages, are optimized generally holds true for Fortran.


"Considered" maybe, but not measured in practice. Of course you need equivalent optimizations to generate similar code -- Intel even defaults to incorrect optimizations. GCC is also substantially more reliable in my experience watching users who insist on using Intel on HPC systems without actually measuring anything.

Of course compilers are relevant, but Fortran has long presented optimization possibilities that aren't typically available in other languages, like not passing by reference.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: