-
Notifications
You must be signed in to change notification settings - Fork 13
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
JIT compilation updates and compatibility with f90wrap v0.2.14 #315
Conversation
Documentation for this branch can be viewed at https://sites.ecmwf.int/docs/loki/315/index.html |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Look great, and many thanks for grinding this out. Only comment I'd have is that the tempdir
fixture (and possibly similar fixtures used in JIT-based tests) could eventually be moved to a common location (new conftest.py
?) to avoid replication, but that is for another PR, I'd say. GTG from me.
This turned into quite a rabbit hole. Something in the original set of changes seems to have slightly skewed timings in the test execution, presumably due to the increased use of test-local temporary directories. The symptom was then random segfaults when garbage collection was triggered. The subsequent investigation unearthed a few glaring holes in our JIT infrastructure for tests:
I'm afraid, the end result is now a fairly sizeable diff. Sorry! |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #315 +/- ##
==========================================
+ Coverage 95.09% 95.11% +0.01%
==========================================
Files 165 165
Lines 35301 35065 -236
==========================================
- Hits 33571 33351 -220
+ Misses 1730 1714 -16
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed quite a handful of changes in the end... 😭 Many thanks for grinding this through, and many apologies for the JIT issues (how did that ever work? 🤔 In any case, very much appreciated and overall reduction in boilerplate is still very nice!
GTG from me!
The latest release of f90wrap includes module names in the name of generated interface routines (introduced in jameskermode/f90wrap#215). This lets them grow quickly beyond the Fortran length limit of 63 characters for names, and gfortran (not even 13.2) does not allow to lift that limitation.
Therefore, I have shorted the module and routine names in the test base where the character limit was exceeded.
In the process, I also introduced the use of
tempdir
fixtures more widely to ensure clean-up of test files is handled gracefully and the littering of the source directory is reduced.