hi
Trying to produce a pure serial implementation choosing 0 here
0) the standard serial implementation ?
it seems to always produce a parallel openmp code so any serial program linked to the lib has to be compiled using -fopenmp
libsharp is by default compiled using .fopenmp I tried to force a serial implementation of that (my idea was to have a serial library as a prerequisite and then produce a serial library) , but it appears that the fopenp flag is still there
I am using gfortran
GNU Fortran (Debian 10.2.1-6) 10.2.1 20210110
and gcc
gcc (Debian 10.2.1-6) 10.2.1 20210110
Anonymous
Hmm, looks like the "configure" call to libsharp (line 611 in hpxconfig_functions.sh) should get an additional "--disable-openmp" in the serial case. Not sure how to achieve this though ...
I didn't dig through the issue but:
when I compile the f90 library there is -fopenmp in the gfortran compiler flags (and so any pure serial program to be linked to libhealpix has to be compiled with -fopenmp).
I guessed that it may depend from the fact that the prerequisite libsharp was compiled with -fopenmp (so forcing an openmp flag to any library depending on libsharp) but that was not the case
Hi,
if you want to compile a 'serial' HEALPix free of openmp, you will have to set by hand various flags.
If you are under bash or similar, you could try
SHARP_COPT='-O3 -ffast-math -march=native' F_PARAL=0 CXXFLAGS='-O3' ./configure --auto=f90,cxxwhich will remove openmp from libsharp and Healpix/F90, but maybe not from Healpix/C++
Thanks Eric!