sac2c issueshttps://gitlab.sac-home.org/sac-group/sac2c/-/issues2017-11-19T20:22:21Zhttps://gitlab.sac-home.org/sac-group/sac2c/-/issues/1104Problems trying to use icc with -dophm2017-11-19T20:22:21ZRobert BerneckyProblems trying to use icc with -dophm| | |
| --- | --- |
| Bugzilla Link | [901](http://bugs.sac-home.org/show_bug.cgi?id=901) |
| Created on | Jan 13, 2012 17:36 |
| Version | svn |
| OS | Linux |
| Architecture | PC |
## Extended Description
<pre>This is likely a simp...| | |
| --- | --- |
| Bugzilla Link | [901](http://bugs.sac-home.org/show_bug.cgi?id=901) |
| Created on | Jan 13, 2012 17:36 |
| Version | svn |
| OS | Linux |
| Architecture | PC |
## Extended Description
<pre>This is likely a simple problem in configuration,
but I am unable to use the Intel icc compiler with sac2c.
Here's what I have:
sac2c foo.sac -target intelcc_rbe
Several problems, actually:
P1;
sac2c -h
describes -target as looking at $SACBASE/runtime/sac2crc.
This does not exist. What does exist are:
$SAC2CBASE/sac2crc
and
$SAC2CBASE/setup/sac2crc
It is not obvious which of these I should edit, nor does
the compiler tell you which one it was looking at if you
do something like: sac2c -target NoSuchTarget
P2: I get this if I compile with what looks like a simple
variant of -target intelcc:
ipo: remark #11001: performing single-file optimizations
ipo: remark #11006: generating object file /tmp/ipo_icc3yenGL.o
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/libc.a(malloc.o): In function `free':
(.text+0x5180): multiple definition of `free'
/home/sac/sac2c/lib//libsacphm.seq.a(malloc.p.seq.o):/home/sac/sac2c/src/libsacphm/compat/malloc.c:212: first defined here
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/libc.a(malloc.o): In function `malloc':
(.text+0x4bb0): multiple definition of `malloc'
/home/sac/sac2c/lib//libsacphm.seq.a(malloc.p.seq.o):/home/sac/sac2c/src/libsacphm/compat/malloc.c:80: first defined here
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/libc.a(malloc.o): In function `realloc':
(.text+0x5250): multiple definition of `realloc'
/home/sac/sac2c/lib//libsacphm.seq.a(malloc.p.seq.o):/home/sac/sac2c/src/libsacphm/compat/malloc.c:288: first defined here
ABORT: System failed to execute shell command
ABORT: icc -shared-intel -xsse4.2 -fast -msse3 -simd -ipo -opt-prefetch
ABORT: -ldl -lpthread -I$SAC2CBASE/include/ -L$SAC2CBASE/lib/
ABORT: -L/tmp/SAC_NJvA1x -o intel.out intel.out.c -L. -Wl,-rpath,.
ABORT: -L/home/sac/sac2c/lib -Wl,-rpath,/home/sac/sac2c/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/structures/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/structures/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/numerical/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/numerical/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/numerical/blas/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/numerical/blas/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/unibench/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/unibench/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/auxiliary/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/auxiliary/lib
ABORT: -L/home/sac/sac/BASE/stdlib/modules/mutc/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/modules/mutc/lib
ABORT: -L/home/sac/sac/BASE/stdlib/world/mutc/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/world/mutc/lib
ABORT: -L/home/sac/sac/BASE/stdlib/world/system/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/world/system/lib
ABORT: -L/home/sac/sac/BASE/stdlib/world/stdio/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/world/stdio/lib
ABORT: -L/home/sac/sac/BASE/stdlib/world/stdio/dislin/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/world/stdio/dislin/lib
ABORT: -L/home/sac/sac/BASE/stdlib/world/stdio/gnuplot/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/world/stdio/gnuplot/lib
ABORT: -L/home/sac/sac/BASE/stdlib/classes/random/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/classes/random/lib
ABORT: -L/home/sac/sac/BASE/stdlib/classes/auxiliary/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/classes/auxiliary/lib
ABORT: -L/home/sac/sac/BASE/stdlib/utrace/lib
ABORT: -Wl,-rpath,/home/sac/sac/BASE/stdlib/utrace/lib -L. -Wl,-rpath,.
ABORT: -L/usr/local/dislin -Wl,-rpath,/usr/local/dislin -L/opt/local/lib
ABORT: -Wl,-rpath,/opt/local/lib -lStdIOMod -lBinFileMod -lFibreIOMod
ABORT: -lListIOMod -lComplexIOMod -lColor8IOMod -lGreyIOMod -lArrayIOMod
ABORT: -lScalarIOMod -lStringArrayMod -lRuntimeErrorMod -lIOresourcesMod
ABORT: -lArrayFormatMod -lStructuresMod -lBitsMod -lComplexMod -lListMod
ABORT: -lColor8Mod -lGreyMod -lFileMod -lTermFileMod -lTerminalMod
ABORT: -lFileSystemMod -lArrayMod -lMathArrayMod -lComplexArrayTransformMod
ABORT: -lComplexArrayArithMod -lArrayTransformMod -lSysErrMod -lWorldMod
ABORT: -lStringMod -lConstantsMod -lArrayArithMod -lComplexScalarArithMod
ABORT: -lComplexArrayBasicsMod -lComplexBasicsMod -lBoolMod -lCharMod
ABORT: -lArrayBasicsMod -lMathMod -lm -lScalarArithMod -lsacpreludeMod
ABORT: -lsacphm.seq -lsac.seq -pthread -ldl
ABORT: with exit code 1
If I compile with -nophm, this goes away, but performance is dismal.
The presence of "gcc" in the above suggests that I am not getting the
correct libc, but it's not clear from looking at sac2crc (either of
them) how I should fix this.
My entry for intelcc_rbe looks like this:
target intelcc_rbe::intelcc:
>
> CCFLAGS += " -fast -msse3 -simd -ipo -opt-prefetch"
It seems odd that intelcc (directly above this entry) works,
but that my entry does not.
Suggestions welcome.</pre>BugZillaBugZilla