Re:A Modern Fortran Scientific Programming Ecosystem
by adgjlsfhk1 on Friday October 14, 2022 @12:28AM
(#33199629)
Most of the old Fortran code isn't that great. To the extent it's optimized, it's optimized for PDP era hardware where memory was fast, floating point was slow, fma didn't exist, vectorization didn't exist, computers weren't fast enough to do tedious symbolic math to find better routines, and they weren't fast enough to test hundreds of millions of inputs to ensure correctness and accuracy. The datastructures, algorithms and tuning and testing were never great, and are worse on modern computers. For a simple example of how much of a difference this can make, look at https://github.com/JuliaMath/Bessels.jl which is often 10x faster than AMOS (the old reliable Fortran code).
[ Parent
| on HN ]
Re:A Modern Fortran Scientific Programming Ecosystem
by cannam on Friday October 14, 2022 @05:19AM
(#33201326)
I idly wonder how these compare to the arbitrary-precision implementations I worked on for REDUCE, exactly 30 years ago as it happens (https://github.com/reduce-algebra/reduce-algebra/blob/master...) - in its unusual Lisp-based but largely procedural language.
The citations in the Julia source file are certainly newer - Abramowitz and Stegun was basically all I had.
I think the REDUCE functions were considered quite fast (for higher precision) at the time, but it was certainly true that they weren't tested as thoroughly as would be the norm now.
Re:A Modern Fortran Scientific Programming Ecosystem
by adgjlsfhk1 on Friday October 14, 2022 @08:03AM
(#33202393)
bessels.jl only does fixed precision (most of the effort has been in Float64 and float32) currently, so it's not fully comparable. if you want to see state of the art arbitrary precision, check out ARB which has quite good implementations (they're what we test against to check accuracy)
Re:A Modern Fortran Scientific Programming Ecosystem
by TheRealKing on Sunday October 16, 2022 @10:53PM
(#33229418)
"often 10X faster" is just plain exaggeration looking at it positively, and plain falsehood spread by the for-profit JuliaComputing, looking at it realistically. The statement does not even reflect the numbers posted on the project's page, which has, by the way, nothing to do with Fortran directly.