BZ #20: java.lang.OutOfMemoryError

Status fields:

creation_ts:2006-03-16 02:11
component:jit
version:0.95
rep_platform:i386
op_sys:Linux
bug_status:RESOLVED
resolution:FIXED
reporter:yshi@cs.tcd.ie
Memory Size: 256MB

>>>> spec.benchmarks._201_compress.Main exited with exception:
java.lang.OutOfMemoryError <<<<
java.lang.OutOfMemoryError
   at spec.benchmarks._201_compress.Harness.fill_text_buffer (Harness.java)
   at spec.benchmarks._201_compress.Harness.run_compress (Harness.java)
   at spec.benchmarks._201_compress.Harness.inst_main (Harness.java)
   at spec.benchmarks._201_compress.Main.runBenchmark (Main.java)
   at spec.benchmarks._201_compress.Main.harnessMain (Main.java)
   at spec.harness.ProgramRunner.runOnce (ProgramRunner.java:382)
   at spec.harness.ProgramRunner.runBenchmark2 (ProgramRunner.java:267)
   at spec.harness.ProgramRunner.runBenchmark (ProgramRunner.java:238)
   at spec.harness.ProgramRunner.run (ProgramRunner.java:206)
   at spec.harness.RunProgram.run (RunProgram.java:60)
   at CommandLineRunner.runBenchmark (CommandLineRunner.java:224)
   at CommandLineRunner.main (CommandLineRunner.java:165)

Exception in thread "main" java.lang.NullPointerException
   at SpecApplicationRunner.benchmarkDone (CommandLineRunner.java:256)
   at spec.harness.ProgramRunner.runBenchmark (ProgramRunner.java:240)
   at spec.harness.ProgramRunner.run (ProgramRunner.java:206)
   at spec.harness.RunProgram.run (RunProgram.java:60)
   at CommandLineRunner.runBenchmark (CommandLineRunner.java:224)
   at CommandLineRunner.main (CommandLineRunner.java:165)

Comment #1 by yshi@cs.tcd.ie on 2006-03-16 02:14:56

A computer with 1GB memory runs fine.
A computer with 256MB memory throws the following execption with default
configuraiton

>>>> spec.benchmarks._201_compress.Main exited with exception:
java.lang.OutOfMemoryError <<<<
java.lang.OutOfMemoryError
   at spec.benchmarks._201_compress.Harness.fill_text_buffer (Harness.java)
   at spec.benchmarks._201_compress.Harness.run_compress (Harness.java)
   at spec.benchmarks._201_compress.Harness.inst_main (Harness.java)
   at spec.benchmarks._201_compress.Main.runBenchmark (Main.java)
   at spec.benchmarks._201_compress.Main.harnessMain (Main.java)
   at spec.harness.ProgramRunner.runOnce (ProgramRunner.java:382)
   at spec.harness.ProgramRunner.runBenchmark2 (ProgramRunner.java:267)
   at spec.harness.ProgramRunner.runBenchmark (ProgramRunner.java:238)
   at spec.harness.ProgramRunner.run (ProgramRunner.java:206)
   at spec.harness.RunProgram.run (RunProgram.java:60)
   at CommandLineRunner.runBenchmark (CommandLineRunner.java:224)
   at CommandLineRunner.main (CommandLineRunner.java:165)

Exception in thread "main" java.lang.NullPointerException
   at SpecApplicationRunner.benchmarkDone (CommandLineRunner.java:256)
   at spec.harness.ProgramRunner.runBenchmark (ProgramRunner.java:240)
   at spec.harness.ProgramRunner.run (ProgramRunner.java:206)
   at spec.harness.RunProgram.run (RunProgram.java:60)
   at CommandLineRunner.runBenchmark (CommandLineRunner.java:224)
   at CommandLineRunner.main (CommandLineRunner.java:165)

Comment #2 by twisti@complang.tuwien.ac.at on 2006-03-16 10:23:13

This means, you're using -Xmx256m on that 256MB machine?  Do these two
stacktraces belong together or are these two different ones?

Comment #3 by yshi@cs.tcd.ie on 2006-03-17 00:38:32

The two stack trace are the same.

I talked to Anton. He said this is a known problem with Cacao. Setting -Xmx120m
falg can solve the problem when running JVM98 benchmarks.

Thank you.

Comment #4 by twisti@complang.tuwien.ac.at on 2006-03-17 12:15:35

Hmm, ok.  That means that was interpreter?  Maybe next time you should paste the
commandline too :-)

Comment #5 by yshi@cs.tcd.ie on 2006-03-17 16:23:19

Both JIT and interperter has the same problem if the flag is specified.

Comment #6 by yshi@cs.tcd.ie on 2006-03-17 16:24:35

Sorry about the last comments. It should be:

Both JIT and interpreter have the same problem if the flag is not provided.

Comment #7 by twisti@complang.tuwien.ac.at on 2006-03-17 16:41:40

Very interesting.  This is _213_javac, I suppose.  Is this the same architecture?

Comment #8 by yshi@cs.tcd.ie on 2006-03-18 05:26:23

It is _201_compress.

My laptop (1GB RAM, I686) runs all the benchmarks in JVM98 perfectly without the
-Xmx120m command line flag.

My desktop (256MB RAM, I686) run all the benchmarks well except _201_compress
(Out of memory exception) if the command line flag is not provided. I can run
_201_compress properly on this computer if -Xmx120m is specified.