[Open64-devel] Compiler fails because of an undefined symbol
Brought to you by:
ributzka,
suneeljain
From: Marc Gonzalez-S. <mar...@in...> - 2003-10-08 11:57:21
|
Hello all, I run native ORC 2.1 on an Itanium 1 (I installed the binary distribution). I wrote a naive matrix multiply program (see attached file) so I could see the result of the LNO phase. I intended to use whirl2c on the optimized intermediate representation. However, when I set preopt and lno to ON, and wopt and cg to OFF, the compiler fails: $ orcc -keep -PHASE:p=on:l=on:w=off:c=off matrix.c be(1519): unaligned access to 0x6000000000028a9c, ip=0x20000000001c5c00 be(1519): unaligned access to 0x60000000000290dc, ip=0x20000000001c5bb0 /orc-2.1/usr//lib/gcc-lib/ia64-orc-linux/2.1/be: error while loading shared libraries: /orc-2.1/usr//lib/gcc-lib/ia64-orc-linux/2.1/lno.so: undefined symbol: TI_RES_COUNT_Alloc orcc INTERNAL ERROR: /opt/orc/orc-2.1/usr//lib/gcc-lib/ia64-orc-linux/2.1/be returned non-zero status 127 $ ls -l -rw-r--r-- 1 acohen coca 13504 Oct 8 13:07 matrix.B -rw-r--r-- 1 acohen coca 4194304 Oct 8 13:07 matrix.N -rw-r--r-- 1 acohen coca 476 Oct 8 13:03 matrix.c -rw-r--r-- 1 acohen coca 521 Oct 8 13:07 matrix.i whirl2c works with matrix.B but not with matrix.N and, as far as I can tell, matrix.B is generated before LNO. $ whirl2c matrix.B whirl2c_be(1521): unaligned access to 0x600000000002765c, ip=0x20000000001c5c00 whirl2c_be(1521): unaligned access to 0x6000000000027c9c, ip=0x20000000001c5bb0 /orc-2.1/usr/lib/gcc-lib/ia64-orc-linux/2.1/whirl2c translates matrix.B into matrix.w2c.h and matrix.w2c.c, based on source matrix.c $ whirl2c matrix.N whirl2c_be(1530): unaligned access to 0x600000000002765c, ip=0x20000000001c5c00 whirl2c_be(1530): unaligned access to 0x6000000000027c9c, ip=0x20000000001c5bb0 "matrix.c": Error: Can't open intermediate compiler file (matrix.N): Success I found references to TI_RES_COUNT_Alloc inside cg.so, lno.so and orc_intel.so (apparently it is defined in cg.so). cg.so: 00000000000a1470 g F .text 0000000000000130 TI_RES_COUNT_Alloc lno.so: 0000000000000000 *UND* 0000000000000000 TI_RES_COUNT_Alloc orc_intel.so: 0000000000000000 F *UND* 0000000000000130 TI_RES_COUNT_Alloc If I include the code generation phase, then the error message disappears, but matrix.N is not generated. $ orcc -keep -PHASE:p=on:l=on:w=off:c=on matrix.c be(1699): unaligned access to 0x600000000002fdfc, ip=0x20000000001c5c00 be(1699): unaligned access to 0x600000000003043c, ip=0x20000000001c5bb0 be(1699): unaligned access to 0x6000000000088f2e, ip=0x20000000011015a0 be(1699): unaligned access to 0x6000000000088f5b, ip=0x2000000001101341 $ ls -l -rwxr-xr-x 1 acohen coca 15412 Oct 8 13:24 a.out -rw-r--r-- 1 acohen coca 13504 Oct 8 13:24 matrix.B -rw-r--r-- 1 acohen coca 476 Oct 8 13:03 matrix.c -rw-r--r-- 1 acohen coca 521 Oct 8 13:24 matrix.i -rw-r--r-- 1 acohen coca 4416 Oct 8 13:24 matrix.o -rw-r--r-- 1 acohen coca 13481 Oct 8 13:24 matrix.s What is the problem? Regards, Marc Gonzalez-Sigler |