Open naromero77 opened 5 years ago
Maybe @d-parks or @gklimowicz have some ideas?
It looks like the same issue. On macOS this is a build time issue as unresolved symbols results in a build error, but on Linux, this is a runtime issue.
Yes, I would agree that it appears to be the same issues. There is a work around which involves commenting out the preprocessor logic. I am not sure what the correct long term solution is.
Yes, this is a known problem with what different compilers predefine as CPP object macros with regards to Intel ISA extensions. I suspect that your compiler is either defining AVX or SSE4_1. The fastest workaround is to disable all the `#ifdef AVXand
#ifdef SSE4_1logic (like prefix the object macros with XXX in the
ifdefs) in
runtime/libpgmath/common/{ceil,dceil,dfloor,floor}.c`
In the meantime, I'll try to find a general solution.
@d-parks @sscalpone Thanks, that was the trick. I will make sure to patch this when I do a PR for the flang Spack package.
I followed the instructions here for building Flang:
https://github.com/flang-compiler/flang/wiki/Building-Flang
particular the OpenMP 4.5 version with the NVidia backend. However, if compile a trivial OpenMP 4.5 program, I receive the following link-time error for a trivial program:
It is very similar to this issue https://github.com/flang-compiler/flang/issues/780
It looks like
libpgmath.so
needs the-lm
from GCC 7.4.0 (default system lib), but adding the appropriate link line-L/lib/x86_64-linux-gnu/
does not resolve the issue.