Skip to content
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

Using --enable-threads reverts the compiler to xlc_r on OpenPOWER #149

Open
RemiLacroix-IDRIS opened this issue Jul 24, 2018 · 2 comments
Open

Comments

@RemiLacroix-IDRIS
Copy link

Hello,

I'm noticing something odd when trying to compile FFTW 3.3.8 on OpenPOWER using PGI 18.5.

If I use the --enable-threads option when calling the configure script, the PGI compiler seems to be replaced by XLC.

Here are the relevant environment variables that are set before calling the configure script:

CPP=/opt/pgi/linuxpower/18.5/bin/pgcc -E
F90=/opt/pgi/linuxpower/18.5/bin/pgf90
F77=/opt/pgi/linuxpower/18.5/bin/pgfortran
CXX=/opt/pgi/linuxpower/18.5/bin/pgc++
FC=/opt/pgi/linuxpower/18.5/bin/pgfortran
CC=/opt/pgi/linuxpower/18.5/bin/pgcc

Here is the configuration log for ./configure: config.log, note that FFTW_CC is defined as "/opt/pgi/linuxpower/18.5/bin/pgcc -Masmkeyword -O3".

Now check the configuration log for ./configure --enable-threads: config_threads.log, note that FFTW_CC is now defined as "xlc_r -O3" and that for some reasons the script is looking for xlc_r:

configure:21902: checking for xlc_r
configure:21918: found /usr/bin/xlc_r
configure:21929: result: xlc_r

Is this a bug in the configuration script?

@stevengj
Copy link
Contributor

That's do to this rule:

fftw3/m4/acx_pthread.m4

Lines 222 to 227 in d59abda

# More AIX lossage: must compile with xlc_r or cc_r
if test x"$GCC" != xyes; then
AC_CHECK_PROGS(PTHREAD_CC, xlc_r cc_r, ${CC})
else
PTHREAD_CC=$CC
fi
… this may be obsolete, as at the time it was written we were testing on ancient AIX versions.

A workaround is to configure with PTHREAD_CC=$CC

@RemiLacroix-IDRIS
Copy link
Author

A workaround is to configure with PTHREAD_CC=$CC

That did the trick, maybe this rule should be somewhat relaxed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants