ATLAS compile error with PGI suite 10.9

Dear All.
I am trying to compile ATLAS 3.8.3 with the PGI compiler suite version version 10.9 but the make command fails.

This is is the configure command I issue:

../configure -C if /opt/pgi/linux86-64/10.9/bin/pgf90 -F if '-fast -Bstatic -tp=x64' -C ic /opt/pgi/linux86-64/10.9/bin/pgcc -F ic "-fast -Bstatic -tp=x64" -b 64 -Si cputhrchk 0 --with-netlib-lapack=/home/zidar/temp/lapack-3.3.0/lapack_LINUX.a --prefix=/home/zidar/temp/atlas-pgi/

The make failes with the following message:

gcc -c -DL2SIZE=4194304 -I/home/zidar/temp/ATLAS/atlas-pgi/include -I/home/zidar/temp/ATLAS/atlas-pgi/..//include -I/home/zidar/temp/ATLAS/atlas-pgi/..//i
nclude/contrib -DAdd_ -DF77_INTEGER=int -DStringSunStyle -DATL_OS_Linux -DATL_ARCH_UNKNOWNx86 -DATL_CPUMHZ=1600 -DATL_SSE3 -DATL_SSE2 -DATL_SSE1 -DATL_USE
64BITS -DATL_GAS_x8664  -DATL_NCPU=16 -O -fomit-frame-pointer -m64 /home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c: In function ‘RunTime’:
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:263: warning: ignoring return value of ‘fscanf’, declared with attribute warn_unused_result
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:264: warning: ignoring return value of ‘fscanf’, declared with attribute warn_unused_result
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:265: warning: ignoring return value of ‘fscanf’, declared with attribute warn_unused_result
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:266: warning: ignoring return value of ‘fscanf’, declared with attribute warn_unused_result
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c: In function ‘main’:
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:351: warning: incompatible implicit declaration of built-in function ‘exit’
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:360: warning: incompatible implicit declaration of built-in function ‘exit’
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:375: warning: incompatible implicit declaration of built-in function ‘exit’
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/masearch.c:442: warning: incompatible implicit declaration of built-in function ‘exit’
gcc -DL2SIZE=4194304 -I/home/zidar/temp/ATLAS/atlas-pgi/include -I/home/zidar/temp/ATLAS/atlas-pgi/..//include -I/home/zidar/temp/ATLAS/atlas-pgi/..//incl
ude/contrib -DAdd_ -DF77_INTEGER=int -DStringSunStyle -DATL_OS_Linux -DATL_ARCH_UNKNOWNx86 -DATL_CPUMHZ=1600 -DATL_SSE3 -DATL_SSE2 -DATL_SSE1 -DATL_USE64B
ITS -DATL_GAS_x8664  -DATL_NCPU=16 -O -fomit-frame-pointer -m64 -o xmasearch masearch.o
./xmasearch s 6 200
make[7]: Entering directory `/home/zidar/temp/ATLAS/atlas-pgi/tune/sysinfo'
gcc -O -fomit-frame-pointer -m64 -fno-tree-loop-optimize -c muladd.c
gcc -O -fomit-frame-pointer -m64 -o xsmuladd muladd.o time.o
time.o: In function `ATL_walltime':
/home/zidar/temp/ATLAS/atlas-pgi/..//tune/sysinfo/ATL_walltime.c:141: undefined reference to `__pgi_unified_version_selector71'

I was able to find the PGI guide to ATLAS (link) yet I was unable to complete any of the steps, because I was unable to generate the xconfig script/binary.

What am I doing wrong?

The output of the configure command is here.

The output of the make command is here.

Compiling LAPACK (done without a problem) and ATLAS is part of a major effor to compile the CPMD package with PGI compiler suite. The compiled binary will be then deployed on the computer cluster thus the “-Bstatic” flag is of prime importance.

Thanks in advance for any help or tip,
Jernej Zidar

Hi Jernej Zidar,

The error here is that linker can’t find the symbol “__pgi_unified_version_selector71” since gcc is being used to link and the PGI C runtime library isn’t being included. Normally I’d recommend adding “-L/opt/pgi/linux86-64/10.9/lib -lpgc” to your link options, but since ATLAS self-tunes for a particular architecture, I think it might be better to simply remove the Unified Binary Flag (-ta=x64). If you need ATLAS for multiple architectures, then it’s best to create individual versions for each architecture.

Note that the build guide you refer to is rather old. The most current version can be found at http://www.pgroup.com/resources/atlas/atlas3932_pgi2010.htm.

Hope this helps,
Mat

Hi, mkcolg.
Yes, the CPMD binary I will (hopefully) generate will be employed on Intel Xeon (53xx, 54xx, 55xx, 56xx) and AMD Opteron (6128) nodes.

Thinking about your advice about creating individual versions og ATLAS:
One major problem is that in our department we have the PGI licence only for one computer so one course of action would be to compile ATLAS/LAPACK on each of the various nodes using GNU compiler and then use PGI to link those ATLAS/LAPACK libraries while compiling the CPMD executable. Please correct me if I’m wrong.

Thank you for the link to the build guide.

Best regards,
Jernej Zidar

Hi Jernej Zidar,

You are more than welcome to use unified binary flag, I just not sure how effective it will be since ATLAS sefl-tunes. Though I would recommend using -tp=nehalem-64,istanbul-64 to target your particular processors instead of the generic -tp=x64. The problem then is getting ATLAS to link with the PGI runtime libraries and put them in the correct place on the link line.

I tired using "-Fa ac “-L/opt/pgi/linux86-64/10.9/lib -lpgc”, but configure puts the library before the object and the error persists. After trying a few things, I gave up a finally just edited the “tune/sysinfo/Makefile” and manually added the library.

xsmuladd : force_build time.o muladd.c
        $(SKC) $(SKCFLAGS) $(SMAFLAGS) -c muladd.c
        $(SKC) $(SKCFLAGS) -o xsmuladd muladd.o time.o -L/opt/pgi/linux86-64/10.9/lib -lpgc
        $(ATLRUN) $(SYSdir) xsmuladd
xdmuladd : force_build time.o muladd.c
        $(DKC) $(DKCFLAGS) $(DMAFLAGS) -c muladd.c
        $(DKC) $(DKCFLAGS) -o xdmuladd muladd.o time.o -L/opt/pgi/linux86-64/10.9/lib -lpgc
        $(ATLRUN) $(SYSdir) xdmuladd

It seemed to build after that. Though, I didn’t let it run to completion since ATLAS takes awhile to tune itself.

  • Mat