JDK-6945394 : J2SE Hotspot Compiler crashes while compiling a specific method
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 6u16
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: linux_ubuntu
  • CPU: x86
  • Submitted: 2010-04-20
  • Updated: 2011-02-16
  • Resolved: 2010-04-20
Related Reports
Duplicate :  
Description
FULL PRODUCT VERSION :
java version "1.6.0_10"
Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
Java HotSpot(TM) 64-Bit Server VM (build 11.0-b15, mixed mode)

FULL OS VERSION :
Ubuntu 8.10 64 Bit Server (2.6.27-7-server)

EXTRA RELEVANT SYSTEM CONFIGURATION :
The bug was reported by multiple users and appears to occur on many different systems:
http://sourceforge.net/projects/opennlp/forums/forum/9943/topic/3217841
http://sourceforge.net/projects/opennlp/forums/forum/9942/topic/3107134 (this guy says bug was already reported to sun)
http://sourceforge.net/tracker/?func=detail&aid=2793972&group_id=3368&atid=103368

The bug also occurs on a second system my macbook (http://en.wikipedia.org/wiki/MacBook, its the early 2006 model)
running Ubuntu 9.10 32 Bit (2.6.31-20-generic),
java -version
java version "1.6.0_16"
Java(TM) SE Runtime Environment (build 1.6.0_16-b01)
Java HotSpot(TM) Server VM (build 14.2-b01, mixed mode)
On this system the bug only occurs when run in server mode or without server mode option (is that the default?!),
if run with the -client option the bug does not occur.

A DESCRIPTION OF THE PROBLEM :
The bug seems to occur when a method of the OpenNLP (http://opennlp.sourceforge.net) is compiled by the hotspot compiler. On my test system and always crashes the Java VM.

THE PROBLEM WAS REPRODUCIBLE WITH -Xint FLAG: No

THE PROBLEM WAS REPRODUCIBLE WITH -server FLAG: Yes

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
I could not isolate the issue exactly, sorry for this, but I found a simple way for you to reproduce it:

1. Download opennlp-tools-1.4.3 from this link:
http://sourceforge.net/projects/opennlp/files/OpenNLP%20Tools/1.4.3/opennlp-tools-1.4.3.tgz/download

2. Unpack the tar file
3. Compile everything with ant (default target)
4. Run this command:
java -cp lib/maxent-2.5.2.jar:lib/trove.jar:output/opennlp-tools-1.4.3.jar opennlp.tools.sentdetect.SentenceDetectorME -lang english -encoding ISO-8859-1 hs_err_pid5063.log test.bin

In case the hs_err_pid5063.log file does not crash it in your test setup just try a large text file, which contains text separated by a new line.

EXPECTED VERSUS ACTUAL BEHAVIOR :
The VM should not crash and execute the program as specified.

ERROR MESSAGES/STACK TRACES THAT OCCUR :
Attached seperatly

REPRODUCIBILITY :
This bug can be reproduced always.

---------- BEGIN SOURCE ----------
I could not isolate the issue, please do the steps described above. If no progress can be made without a concrete sample, please notify me so I can spent more time on isolating the problem.
---------- END SOURCE ----------

CUSTOMER SUBMITTED WORKAROUND :
It was reported that changing a few lines in opennlp.tools.sentdetect.DefaultSDContextGenerator.previousSpaceIndex fixes the issue. In case of 32 Bit system the -client options fixes the issue, and -Xint also solves the issue. I also heard (but did not verify) that compiling with a newer source level than 1.4 also fixes the issue.

Comments
EVALUATION This is a duplicate of 6855164 which is fixed in 6u18. Make sure to read the release notes for that release.
20-04-2010

EVALUATION This is a duplicate of 6855164 which is fixed in 6u18 and later.
20-04-2010