This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Help for compiling PERFECTLY SPECjbb2000 with gcj
- From: Tony Reix <Tony dot Reix at bull dot net>
- To: green at redhat dot com
- Cc: java at gcc dot gnu dot org, Tony dot Reix at frec dot bull dot fr, hans_boehm at hp dot com
- Date: Fri, 29 Aug 2003 16:17:22 +0200
- Subject: Re: Help for compiling PERFECTLY SPECjbb2000 with gcj
{ On Fri, 2003-08-29 at 01:36, Tony Reix wrote:
{ > 2) Using only: -O2 -ffast-math -mfpmath=sse
{ > ----------------------------------------------
{ >
{ > This led to the same "VALIDATION ERROR" messages. So it may be another
{ > problem than FP.
{ >
{ > jc1: attention : SSE instruction set disabled, using 387 arithmetics
{ > cc1: attention : SSE instruction set disabled, using 387 arithmetics
{
{ -mfpmath=sse requires -march=pentium4
OK.
After recompiling SPECjbb2000 with:
# gcj -I/home/reixt/SPECjbb2000/jbb/src --main=spec.jbb.JBBmain \
-o SPECjbb2000.gcj-O2 -g -O2 -march=pentium4 -ffast-math -mfpmath=sse \
.....
I got an Illegal Instruction:
# SPECjbb2000.gcj-O2 -propfile SPECjbb.GCJ331.props
Checking JVM
1st bounds test: OK
Super: Class Super, public=34, protected=33, private=32
Sub: Class Super, public=804, protected=803, private=802
Super: prot=33, priv=32
Sub: prot=111, priv=105
Subclass test OK
1 1 2 3 5 8 13 21 34 55 89 144 233 377 610 987 1597 2584 4181 6765
1 1 2 3 5
22347 Illegal Instruction
Using gdb (5.3), I got:
1 1 2 3 5
Program received signal SIGILL, Illegal instruction.
0x0805ef60 in spec.jbb.validity.LoopBounds2.size() (this=@8159320)
at LoopBounds.java:111
111 v.insertElementAt (new Double (1.0 / n),6);
Current language: auto; currently java
(gdb) where
#0 0x0805ef60 in spec.jbb.validity.LoopBounds2.size() (this=@8159320) at LoopBounds.java:111
#1 0x0805f105 in spec.jbb.validity.LoopBounds.execute() (this=@8159320) at LoopBounds.java:65
#2 0x0805f325 in spec.jbb.validity.LoopBounds.run() () at LoopBounds.java:87
#3 0x0805f92b in spec.jbb.validity.Check.doCheck() () at Check.java:88
#4 0x0808a367 in spec.jbb.JBBmain.main(java.lang.String[]) (args=@80f7fe0) at JBBmain.java:818
#5 0x403a1bef in gnu::gcj::runtime::FirstThread::call_main() (this=@8151f88) at gnu/gcj/runtime/natFirstThread.cc:46
#6 0x40423da8 in gnu.gcj.runtime.FirstThread.run() (this=@8151f88) at gnu/gcj/runtime/FirstThread.java:54
#7 0x403b025c in _Jv_ThreadRun(java::lang::Thread*) (thread=@80c5e90) at java/lang/natThread.cc:285
#8 0x40387a6c in _Jv_RunMain(java::lang::Class*, char const*, int, char const**, bool) (klass=@80c6260, name=null, argc=135602056, argv=@80c5e90, is_jar=false) at prims.cc:1001
#9 0x40387b9d in JvRunMain (klass=@8159270, argc=135631472, argv=@8159270) at prims.cc:1011
#10 0x0804ed01 in main (argc=135631472, argv=@8159270) at /tmp/cciz2pCl.i:11
#11 0x42015574 in __libc_start_main () from /lib/tls/libc.so.6
(gdb) p n
$1 = 5
(gdb) p v
$2 = java.util.Vector@811ee28
So there is a pb with gcj and the following code :
class LoopBounds2 extends LoopBounds{
private int n = 0;
public int size() {
if (n > 4 && n%2 == 1)
v.insertElementAt (new Double (1.0 / n),6);
return v.size() - n++;
}
}