-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes for NAG Compiler #5003
Fixes for NAG Compiler #5003
Conversation
As far as I can tell, the redundant addition of LAPACK_FFLAGS dates back to the introduction of CMake support in version 0.2.15, a bit over nine years ago (though I cannot seem to find hpanderson's PR from back then) |
Changes looking good to me (I'm not familiar with the OpenBLAS CMake system, though). Just a quick note on the support of There are some non-standard intrinsic NAG modules that contain POSIX interfaces and, therefore, also support some C system functions ( But changing |
Huh. I have never heard of that |
Hmm. Not sure about the failing checks. The qemu one seems to be Github hiccup, but the Windows one I'm not sure about... |
All good, the Windows one is also unrelated - the free Azure CI uses a variable bunch of older hardware, so long-running build jobs tend to time out when they land on a particularly slow machine |
Sorry I just saw the original ping, so I'm copying the crux of my comment there (#4918 (comment)), basically, I'm not sure the Fortran 2008 compliance requirement is OK for OpenBLAS, so I'd prefer documentation for |
Well, gfortran appears to support this language feature since about version 4.6, so I would expect this to turn into a fight of ancient vendor compilers if anything. My question was more along the lines of if you know a case where it is definitely unsupported. (I assume that the "proper error return" is important enough for the Meson environment that it cannot be solved with the previous kludge of grepping the test logs for a failure phrase) |
If there is a compiler it isn't supported with, the best bet would probably then be to write our own "abort" routine (openblas_abort?) that calls |
guess so, I understand this was your plan b in the first post ? the only drawback from my viewpoint would be that it makes the code deviate more from the Reference-LAPACK original - but as the actual tests are unaffected, that would not make it harder to import any future changes |
Well, I suppose we could work with Reference-LAPACK to update their tests with |
certainly - it is just that there might be less motivation for it, if the change is mostly useful for Meson build support that they don't have |
Closes #5002
As detailed in the above issue, this PR collects changes for the NAG compiler using CMake.
The changes are:
cmake/fc.cmake
. The flags here are mainly from bothMakefile.system
and from Adding NAG Fortran compiler (nagfor) support in the CMake build system. Reference-LAPACK/lapack#686 via @ACSimon33cmake/system.cmake
ctest
CALL ABORT
calls to Fortran StandardERROR STOP
lapack-netlib
(via Adding NAG Fortran compiler (nagfor) support in the CMake build system. Reference-LAPACK/lapack#686 and Fixes for the NAG Fortran compiler Reference-LAPACK/lapack#951, again thanks to @ACSimon33)cmake/lapack.cmake
I'll go a bit more into that last one. Apparently, the line:
was duplicating Fortran flags when
make
was actually run. Now, for most compilers this probably isn't a bad thing, but NAG does not allow some flags to be duplicated:To be extra safe, I only turned that off when building with NAG as I don't want to change behaviors for any other compiler.
I did run
ctest
with NAG and got 100% (see runctest.NAG.log) as well as GCC 14 with my changes. Hopefully the CI will catch more.If you'd like me to run any other tests with NAG (in case
ctest
doesn't cover everything), let me know.Also, as mentioned in #5002 , the use of
ERROR STOP
might break some very old compilers. If so, I believe I could revert back toCALL ABORT
and then write anABORT
external call for NAG.