-
Notifications
You must be signed in to change notification settings - Fork 167
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
Workarounds for NAG #108
Comments
NAG 7.0 just released does support submodules. I'll get it installed on our machines tonight or tomorrow. Regarding the need for an explicit include, something is not right in the |
I've put in PR #109 that fixes the issue of not finding compiled .mod files |
Yes NAG 7.0 was the first to support |
With the latest master (dc7e49b) and NAG 7.0, there are three warnings:
For now we can ignore those. Then there is an error:
I think this has to do with how NAG names submodules and how cmake finds them (or not in this case). |
That NAG 7.0 error may be a bug in cmake. Similar errors happenes with other compilers until CMake fixed the bugs. The NAG 7.0 warnings are due to NAG not being in Fortran 2018 syntax mode. I didn't look if nag 7.0 has a command line option to enable Fortran 2018 syntax. |
|
The "copying" thing that cmake is complaining about had me confused. But it looks like it copies the .mod files (that are created where we want them) into the Intel, for example, calls their compiled submodule file I think CMake just needs to be taught how NAG behaves; 7.0 is the first version with support for submodules. |
Yes that NAG file naming scheme for submodules is completely different than any other compiler so I would say there's a very high chance that CMake needs to update itself. |
I'm checking the latest CMake now to be sure it's no different than 3.14. If it doesn't work I'll submit an issue to the cmake project. |
I submitted the cmake issue. If they don't act on it quickly, I'd bet it is easy to fix and submit a PR ourselves. But I'll leave it at that for now. |
Well the kitware folks were very quick and helpful to point out where changes needed to be made, but labeled the issue "not a priority for us, but you're welcome to submit a PR". So I've gone ahead and done that. Update: Looks like it will be in 3.16.3 due out around 1/23. |
https://blog.kitware.com/cmake-3-16-3-available-for-download/ |
@zbeekman will be pleased that I am happy to recommend CMake 3.16.3 for stdlib. ;) |
haha, well if we need it we need it. But, for the record I wasn't advocating for the latest cmake (unnecessarily...) just for a version I knew to be reliable. |
NAG could require CMake 3.16.3 like: if(CMAKE_Fortran_COMPILER_ID STREQUAL NAG)
cmake_policy(VERSION 3.16.3)
endif() while allowing other compilers to use older CMake |
I can report a successful build with NAG 7.0 and CMake 3.16 after a minimal patch diff --git a/src/stdlib_bitsets.fypp b/src/stdlib_bitsets.fypp
index ad52517..f1f204d 100644
--- a/src/stdlib_bitsets.fypp
+++ b/src/stdlib_bitsets.fypp
@@ -2006,7 +2006,7 @@ module stdlib_bitsets
end interface operator(<=)
- interface error_handler
+ interface
module subroutine error_handler( message, error, status, &
module, procedure )
character(*), intent(in) :: message
@@ -2015,7 +2015,7 @@ module stdlib_bitsets
character(*), intent(in), optional :: module
character(*), intent(in), optional :: procedure
end subroutine error_handler
- end interface error_handler
+ end interface
contains
Unfortunately the tests still fail
Test log: LastTest.log.gz |
I can report a successful build with NAG 7.0 (Build 7061) and CMake 3.18.3 without any patch. (git 089f325) But some tests still fail.
Without
|
@sakamoti thank you for testing it! Yes, we need to fix it. |
This is a bug in the NAG compiler with UDDTIO (see #354 (comment)). Haven't reported it yet because I currently don't have a license and therefore cannot open support requests. |
I contacted NAG support around June 2021 with a similar error regarding UDDTIO chunk etc. I haven't checked to see if it is exactly the same as this issue (#354), but I think one of the compiler bugs related to UDTIO is resolved. (The compiler version at the time was nagfor7049) Now (nagfor7061), stop in test_string_derivedtype_io.f90, line 27.
The return value of The return value of chunk |
NAG 7.2 just released with full Fortran 2018 support: https://support.nag.com/nagware/np/r72_doc/relnotes.html |
For NAG 6.2 and the latest master (f300f4a):
-I
manually:Everything then builds and tests pass (including quadruple precision).
The text was updated successfully, but these errors were encountered: