Fix: AMReX w/ OpenMP and Ignore FFTW OMP#4941
Conversation
|
What about the call to |
|
Okay this is confusing. Could you summarize what we are trying to support? AMReX may be built with or without OMP. FFTW on the system may or may not support threading. If it does support threading, it may or may not be OMP. In all the combinations, we do we do? |
|
Oh yes, |
In #4861 we decided it might be ok to default to require that FFTW supports threading if AMReX is build with OpenMP support, because other behavior is confusing for users. I now found a corner case on conda-forge and in a CI runner where I cannot have, temporarily (I hope), FFTW with OpenMP nor threads. To now build I am forced to either disable all FFT support or all OpenMP support of AMReX. In CMake, I had anticipated this a bit in the past by adding an opt-in |
7624dc4 to
c50ece1
Compare
In some corner cases, we sometimes work around broken FFTW installs. In those, we build with OpenMP but set FFTW OpenMP requirements to off explicitly. This enables this work-around.
c50ece1 to
932a04d
Compare
Summary
In some corner cases, we sometimes work around broken FFTW installs: for some (temporary) reason we cannot have any threading in FFTW, neither with OpenMP nor threads.
In those cases, when we still want to thread the rest of AMReX with OpenMP, we can set our AMReX transitive FFTW OpenMP requirements explicitly off, e.g., via CMake
-DAMReX_FFTW_IGNORE_OMP=ON. But this is not yet implemented consistently and since #4861 exposes undefined FFTW symbols when used.This enables this work-around.
AMReX_Config.HAdditional background
#4861 (comment)
Checklist
The proposed changes: