Name mangle BLAS and LAPACK routines #10
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is mainly here so I don't forget. The change here is because of an issue that @agstub and @bena-nasa found when trying to debug issues with integrating ISSM into GEOS.
When @agstub was trying to run, he kept crashing. It was found with a debugger that it was crashing in a
ddotcall from WW3, which he was not running. It turns out WW3 has some BLAS and LAPACK calls in bare subroutines. So, once GEOS was all linked up, instead of using the BLAS/LAPACKddotcall from MKL (or petsc or wherever ISSM expected it), it got it from WW3.Just so @agstub could keep working, I made this name-mangled version of 7.14 so he could proceed. All I did was add a
ww3_prefix to the BLAS/LAPACK routines I could see.As @tclune said in a meeting, the right way for this to be done is probably to put the WW3 dupes in a module not as bare subroutines. Then, we'd just need to tell WW3 to use that module when it needs them.
That said, while this update allows @agstub to run, I'm not sure if I've now broken WW3 runs of GEOS. @atrayano says he knows how to run and of course @adarmenov does as well. Maybe this could be tested so we at least know nothing broke.
NOTE: This is still an issue upstream in WW3. I wonder if I should make an issue there?