Hi Chris, It did compile when I gave that option. But it gives me an error when I try to run the executable on an Intel machine. ----- 1513158 is not prime. Exception handler needed, but not enabled. Recompile program with -enable-correct-eh-support. lli[0x8429bb4] lli[0x8429dc0] /lib/libc.so.6[0x40128c18] /lib/libc.so.6(abort+0x161)[0x40129cb5] [0x403da922] ../../../i386: line 4: 27606 Aborted lli -load=/usr/lib/libm.so $0.bc $* --------------------------------------- I am suspecting that the Makefile is missing quite a few options that should be included. Do you have a list of Makefiles used to compile spec95/spec2000 benchmarks ? That would be of great help. Thanx, -- Vinay S. Belgaumkar
Vinay, On Thu, Apr 01, 2004 at 02:27:53PM -0500, Vinay S. Belgaumkar wrote:> It did compile when I gave that option. But it gives me an error > when I try to run the executable on an Intel machine. > ----- > 1513158 is not prime. > Exception handler needed, but not enabled. Recompile program with > -enable-correct-eh-support.[snip] This error message is from LLVM, not the benchmark. If you are running what you get straight out of llvm-gcc, then correct exception-handling support is not in the executable. If you are running the script that llvm-gcc outputs, the script does not have that switch: `-enable-correct-eh-support' which you need to pass to LLC or LLI for correct code generation.> I am suspecting that the Makefile is missing quite a few options that > should be included. Do you have a list of Makefiles used to compile > spec95/spec2000 benchmarks ? That would be of great help.Sure, these Makefiles are in: llvm/test/Programs/External/SPEC/* -- Misha Brukman :: http://misha.brukman.net :: http://llvm.cs.uiuc.edu
On Thu, 1 Apr 2004, Misha Brukman wrote:> If you are running the script that llvm-gcc outputs, the script does not > have that switch: `-enable-correct-eh-support' which you need to pass to > LLC or LLI for correct code generation.Here's a little more background. When you compile an link a program with llvmgcc, like so: llvmgcc -c x.c -o x.o llvmgcc -c y.c -o y.o llvmgcc x.o y.o -o program The final command actually produces two files "program" and "program.bc". The "program" file is actually a small shell script that executes "program.bc" with the 'lli' tool (the JIT). The problem is that by default, the LLVM code generators do not support exception handling. In order to enable this, you need to pass -enable-correct-eh-support into the code generator. Since you're probably running the program through the generated shell script, just edit the "program" script to add -enable-correct-eh-support to the list of options passed into lli. Please let us know if this makes sense :) -Chris -- http://llvm.cs.uiuc.edu/ http://www.nondot.org/~sabre/Projects/
Vinay S. Belgaumkar wrote:> Hi Chris, > It did compile when I gave that option. But it gives me an error when > I try to run the executable on an Intel machine.First, I should point out that 134.perl from SPEC95 isn't working with code generated by llc at the moment. It appears to work, though, with our Just in Time Compiler. It seems to be a linking issue of some sort. Second, how to run the SPEC benchmarks using our testing framework:> ----- > 1513158 is not prime. > Exception handler needed, but not enabled. Recompile program with > -enable-correct-eh-support. > lli[0x8429bb4] > lli[0x8429dc0] > /lib/libc.so.6[0x40128c18] > /lib/libc.so.6(abort+0x161)[0x40129cb5] > [0x403da922] > ../../../i386: line 4: 27606 Aborted lli > -load=/usr/lib/libm.so $0.bc $* > --------------------------------------- > > I am suspecting that the Makefile is missing quite a few options that > should be included. Do you have a list of Makefiles used to compile > spec95/spec2000 benchmarks ? That would be of great help.Yes, we have a set of Makefiles for compiling the SPEC95 and SPEC2000 benchmarks (at least, the C and C++ benchmarks). The Makefiles are located in llvm/test/Programs/External/SPEC. The easiest way to use them is to use the --enable-spec2000 and --enable-spec95 options of the configure script. For example, our machines have SPEC95 installed in the directory /home/vadve/shared/benchmarks/spec95, so I would use: llvm/configure --enable-spec95=/home/vadve/shared/benchmarks/spec95/benchspec ... to enable testing of SPEC95. Please note that the use of SPEC is disabled unless you specifically enable it. Then, just cd into OBJ_ROOT/llvm/test/Programs/External/SPEC and type "make" to run the SPEC tests. I should also mention that we only support the integer benchmarks of SPEC95 (since the floating point benchmarks are in FORTRAN), and that small modifications were needed to get SPEC95 to compile correctly under Linux with llvm-gcc. SPEC2000, to my knowledge, does not have any of these problems. Having said all of this, not all of the SPEC95 benchmarks work. SPEC2000 is in better health, though, so you may want to use it if you have it. Please let us know if you have any more problems or find anything weird. Thanks, and sorry 134.perl isn't working yet.> > Thanx, > >-- John T. -- ********************************************************************* * John T. Criswell Email: criswell at uiuc.edu * * Research Programmer * * University of Illinois at Urbana-Champaign * * * * "It's today!" said Piglet. "My favorite day," said Pooh. * *********************************************************************