JDK-5089864 : 1.4.2_05 crash in hotspot -server compiler PhaseIdealLoop::build_loop_late
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 1.4.2_05
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: solaris_8
  • CPU: generic
  • Submitted: 2004-08-20
  • Updated: 2024-08-26
  • Resolved: 2004-08-20
Related Reports
Duplicate :  
Relates :  
Description
1.4.2_05 crash in hotspot -server compiler

During compilation of method "oracle.sql.NUMBER::toBytes"

Problem also happens with -Xverify:all -XX:-Inline

Problem does not happen with -client

Problem exists in 1.4.2 fcs, 1.4.2__05 and 1.5 beta2.
1.3.1 does not crash.


Production stacktrace:


=>[1] libthread.so.1:__sigprocmask(0x0, 0xe90ff660, 0x0, 0x0, 0x0, 0x0), at 0xff379764 
  [2] libthread.so.1:_resetsig(0xff37bf60, 0x0, 0x0, 0xe9101d70, 0xff38e000, 0x0), at 0xff36e970 
  [3] libthread.so.1:_sigon(0xe9101d70, 0xff395930, 0x6, 0xe90ff734, 0xe9101d70, 0x6), at 0xff36e110 
  [4] libthread.so.1:_thrp_kill(0x0, 0xb, 0x6, 0xff38e000, 0xb, 0xff340448), at 0xff371150 
  [5] libc.so.1:raise(0x6, 0x0, 0x0, 0xffffffff, 0xff3403b4, 0x4), at 0xff2cb9d4 
  [6] libc.so.1:abort(0xff33c004, 0xe90ff888, 0x0, 0xfffffff8, 0x4, 0xe90ff8a9), at 0xff2b58f4 
  [7] libjvm.so:os::abort(0x1, 0xfe5555aa, 0xe90ff938, 0xfe582000, 0xfe5c9944, 0x3ee894), at 0xfe499d98 
  [8] libjvm.so:os::handle_unexpected_exception(0xf5568, 0xb, 0xfe0c980c, 0xe9100678, 0xb, 0x0), at 0xfe4980ac 
  [9] libjvm.so:JVM_handle_solaris_signal(0xfe0c980c, 0xe9100678, 0xe91003c0, 0x3400, 0x3608, 0x0), at 0xfe1d7c6c 
  [10] libthread.so.1:__sighndlr(0xb, 0xe9100678, 0xe91003c0, 0xfe1d731c, 0xe9101e14, 0xe9101e04), at 0xff37b824 
  ---- called from signal handler with signal 11 (SIGSEGV) ------
  [11] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0xed3070), at 0xfe0c980c 
  [12] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0x1200430), at 0xfe0c93b0 
  [13] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0x17aca38), at 0xfe0c93b0 
  [14] libjvm.so:PhaseIdealLoop::PhaseIdealLoop(0xfe5cdc6c, 0x0, 0xe9100984, 0x1, 0x1, 0x1), at 0xfe1bf34c 
  [15] libjvm.so:Compile::Optimize(0xe9101270, 0xfe53526c, 0xe9101184, 0xfe582000, 0x0, 0x0), at 0xfe201248 
  [16] libjvm.so:Compile::Compile(0xfe5350a1, 0x17e6ab4, 0x109a044, 0x165f708, 0xffffffff, 0x1), at 0xfe1ff65c 
  [17] libjvm.so:C2Compiler::compile_method(0x359b0, 0xe9101a8c, 0x0, 0x5a59c0, 0xffffffff, 0x0), at 0xfe1fbe34 
  [18] libjvm.so:CompileBroker::invoke_compiler_on_method(0x655, 0x0, 0xffffffff, 0xfe5c0e70, 0xfe5cdc6c, 0xf5568), at 0xfe1fb5f8 
  [19] libjvm.so:CompileBroker::compiler_thread_loop(0xfe5358a9, 0xfe5c1238, 0xf5568, 0xf5b18, 0x31a08c, 0xfe267ed8), at 0xfe2aae80 
  [20] libjvm.so:JavaThread::run(0xf5568, 0xc, 0x40, 0x0, 0xb, 0xff38e000), at 0xfe267f00 
  [21] libjvm.so:_start(0xf5568, 0xff38f688, 0x1, 0x1, 0xff38e000, 0x0), at 0xfe2643e0 




Assertion in a java_g is:
$ java_g -server -Xbatch -showversion -XX:+PrintCompilation -XX:+CompileTheWorld -Xbootclasspath/p:./oracle.jar -version
.
.
.
 90   b   oracle.sql.NUMBER::tanh (20 bytes)
 91   b   oracle.sql.NUMBER::textToPrecisionNumber (24 bytes)
 92   b   oracle.sql.NUMBER::toBigDecimal (460 bytes)
 93   b   oracle.sql.NUMBER::toBigInteger (440 bytes)
 94   b   oracle.sql.NUMBER::toByte (39 bytes)
 95   b   oracle.sql.NUMBER::toBytes (10 bytes)
 96   b   oracle.sql.NUMBER::toBytes (6 bytes)
 97  !b   oracle.sql.NUMBER::toBytes (83 bytes)
 98   b   oracle.sql.NUMBER::toBytes (1034 bytes)
# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc:  SuppressErrorAt=/loopnode.hpp:487
#
# HotSpot Virtual Machine Error, assertion failure
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Java VM: Java HotSpot(TM) Server VM (1.4.2_05-b04-debug mixed mode)
#
# assert(n != 0, "Bad immediate dominator info.")
#
# Error ID: /export1/jdk142-update/ws/fcs/hotspot/src/share/vm/opto/loopnode.hpp, 487 [ Patched ]
#
# Problematic Thread: prio=5 tid=0x00135cc8 nid=0x8 runnable 
#

Heap at VM Abort:
Heap
 def new generation   total 2112K, used 144K [0xf0c00000, 0xf0e20000, 0xf2150000)
  eden space 2048K,   7% used [0xf0c00000, 0xf0c24380, 0xf0e00000)
  from space 64K,   0% used [0xf0e00000, 0xf0e00000, 0xf0e10000)
  to   space 64K,   0% used [0xf0e10000, 0xf0e10000, 0xf0e20000)
 tenured generation   total 1408K, used 0K [0xf2150000, 0xf22b0000, 0xf4c00000)
   the space 1408K,   0% used [0xf2150000, 0xf2150000, 0xf2150200, 0xf22b0000)
 compacting perm gen  total 16384K, used 1065K [0xf4c00000, 0xf5c00000, 0xf8c00000)
   the space 16384K,   6% used [0xf4c00000, 0xf4d0a410, 0xf4d0a600, 0xf5c00000)
Dumping core....
Abort(coredump)

(Adding the option -XX:SuppressErrorAt=/loopnode.hpp:487 produces the same crash.)


java_g stacktrace: (some line numbers many vary from "standard" java_g)

  [3] abort(0x0, 0xf0b7d818, 0x0, 0xfffffff8, 0x0, 0xf0b7d841), at 0xff2b6c70 
=>[4] os::abort(dump_core = 1), line 1319 in "os_solaris.cpp"
  [5] report_error(is_vm_internal_error = 1, file_name = 0xfee1fb84 "/space/kevinwa/ws/hotspot/src/share/vm/opto/loopnode.hpp", line_no = 450, title = 0xfed7fbbb "assertion failure", format = 0xfed7fbcd "assert(%s, "%s")", ...), line 456 in "debug.cpp"
  [6] report_assertion_failure(code_str = 0xfee1fb79 "d->_idx!=0", file_name = 0xfee1fb84 "/space/kevinwa/ws/hotspot/src/share/vm/opto/loopnode.hpp", line_no = 450, message = 0xfee1fbbd "index zero!"), line 237 in "debug.cpp"
  [7] PhaseIdealLoop::idom_no_update(this = 0xf0b7e74c, d = 0x12e9bc), line 450 in "loopnode.hpp"
  [8] PhaseIdealLoop::idom(this = 0xf0b7e74c, d = 0x12e9bc), line 463 in "loopnode.hpp"
  [9] PhaseIdealLoop::build_loop_late(this = 0xf0b7e74c, n = 0x1eb984, visited = CLASS, worklist = CLASS, verify_me = (nil)), line 2043 in "loopnode.cpp"
  [10] PhaseIdealLoop::build_loop_late(this = 0xf0b7e74c, n = 0x138db4, visited = CLASS, worklist = CLASS, verify_me = (nil)), line 1964 in "loopnode.cpp"
  [11] PhaseIdealLoop::build_loop_late(this = 0xf0b7e74c, n = 0x12e9bc, visited = CLASS, worklist = CLASS, verify_me = (nil)), line 1964 in "loopnode.cpp"
  [12] PhaseIdealLoop::PhaseIdealLoop(this = 0xf0b7e74c, igvn = CLASS, verify_me = (nil), do_split_ifs = 1), line 1120 in "loopnode.cpp"
  [13] Compile::Optimize(this = 0xf0b7f310), line 1364 in "compile.cpp"
  [14] Compile::Compile(this = 0xf0b7f310, ci_env = 0xf0b7fb6c, ci_scope = (nil), target = 0x15959c, osr_bci = -1, subsume_loads = 1, comp_level = 0), line 461 in "compile.cpp"
  [15] C2Compiler::compile_method(this = 0x121720, env = 0xf0b7fb6c, scope = (nil), target = 0x15959c, entry_bci = -1, comp_lev = 0), line 29 in "c2compiler.cpp"
  [16] CompileBroker::invoke_compiler_on_method(task = 0x12e018), line 1577 in "compileBroker.cpp"
  [17] CompileBroker::compiler_thread_loop(), line 1376 in "compileBroker.cpp"
  [18] compiler_thread_entry(thread = 0x126dc8, __the_thread__ = 0x126dc8), line 2422 in "thread.cpp"
  [19] JavaThread::thread_main_inner(this = 0x126dc8), line 1136 in "thread.cpp"
  [20] JavaThread::run(this = 0x126dc8), line 1120 in "thread.cpp"
  [21] _start(data = 0x126dc8), line 732 in "os_solaris.cpp"


Standard 1.4.2_05 java_g core file is attached with showrev -p of source machine.

To reproduce:
============
Save the attached file oracle.jar created with the SA.

Run:
java_g -server -XX:+PrintCompilation -XX:+CompileTheWorld -Xbootclasspath/p:./oracle.jar -version




Comments
WORK AROUND Exclude using a .hotspot_compiler file: exclude oracle/sql/NUMBER toBytes
21-08-2004

PUBLIC COMMENTS 1.4.2_05 crash in hotspot -server compiler During compilation of method "oracle.sql.NUMBER::toBytes" Problem also happens with -Xverify:all -XX:-Inline Problem does not happen with -client Problem exists in 1.4.2 fcs, 1.4.2__05 and 1.5 beta2. 1.3.1 does not crash. Production stacktrace: =>[1] libthread.so.1:__sigprocmask(0x0, 0xe90ff660, 0x0, 0x0, 0x0, 0x0), at 0xff379764 [2] libthread.so.1:_resetsig(0xff37bf60, 0x0, 0x0, 0xe9101d70, 0xff38e000, 0x0), at 0xff36e970 [3] libthread.so.1:_sigon(0xe9101d70, 0xff395930, 0x6, 0xe90ff734, 0xe9101d70, 0x6), at 0xff36e110 [4] libthread.so.1:_thrp_kill(0x0, 0xb, 0x6, 0xff38e000, 0xb, 0xff340448), at 0xff371150 [5] libc.so.1:raise(0x6, 0x0, 0x0, 0xffffffff, 0xff3403b4, 0x4), at 0xff2cb9d4 [6] libc.so.1:abort(0xff33c004, 0xe90ff888, 0x0, 0xfffffff8, 0x4, 0xe90ff8a9), at 0xff2b58f4 [7] libjvm.so:os::abort(0x1, 0xfe5555aa, 0xe90ff938, 0xfe582000, 0xfe5c9944, 0x3ee894), at 0xfe499d98 [8] libjvm.so:os::handle_unexpected_exception(0xf5568, 0xb, 0xfe0c980c, 0xe9100678, 0xb, 0x0), at 0xfe4980ac [9] libjvm.so:JVM_handle_solaris_signal(0xfe0c980c, 0xe9100678, 0xe91003c0, 0x3400, 0x3608, 0x0), at 0xfe1d7c6c [10] libthread.so.1:__sighndlr(0xb, 0xe9100678, 0xe91003c0, 0xfe1d731c, 0xe9101e14, 0xe9101e04), at 0xff37b824 ---- called from signal handler with signal 11 (SIGSEGV) ------ [11] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0xed3070), at 0xfe0c980c [12] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0x1200430), at 0xfe0c93b0 [13] libjvm.so:PhaseIdealLoop::build_loop_late(0xe910093c, 0xe9100890, 0xe9100890, 0xe9100880, 0x0, 0x17aca38), at 0xfe0c93b0 [14] libjvm.so:PhaseIdealLoop::PhaseIdealLoop(0xfe5cdc6c, 0x0, 0xe9100984, 0x1, 0x1, 0x1), at 0xfe1bf34c [15] libjvm.so:Compile::Optimize(0xe9101270, 0xfe53526c, 0xe9101184, 0xfe582000, 0x0, 0x0), at 0xfe201248 [16] libjvm.so:Compile::Compile(0xfe5350a1, 0x17e6ab4, 0x109a044, 0x165f708, 0xffffffff, 0x1), at 0xfe1ff65c [17] libjvm.so:C2Compiler::compile_method(0x359b0, 0xe9101a8c, 0x0, 0x5a59c0, 0xffffffff, 0x0), at 0xfe1fbe34 [18] libjvm.so:CompileBroker::invoke_compiler_on_method(0x655, 0x0, 0xffffffff, 0xfe5c0e70, 0xfe5cdc6c, 0xf5568), at 0xfe1fb5f8 [19] libjvm.so:CompileBroker::compiler_thread_loop(0xfe5358a9, 0xfe5c1238, 0xf5568, 0xf5b18, 0x31a08c, 0xfe267ed8), at 0xfe2aae80 [20] libjvm.so:JavaThread::run(0xf5568, 0xc, 0x40, 0x0, 0xb, 0xff38e000), at 0xfe267f00 [21] libjvm.so:_start(0xf5568, 0xff38f688, 0x1, 0x1, 0xff38e000, 0x0), at 0xfe2643e0
21-08-2004

EVALUATION This bug is a duplicate of an issue found in 5030922, fixed in mustang. The specific fix can be found in the changes to loopopts.cpp in that bug. The webrev can be observed here: file:/net/prt-archiver.sfbay/data/archived_workspaces/main/c2_baseline/2004/20040803135733.azeem.misc/workspace/webrevs/webrev-2004.08.03/index.html ###@###.### 2004-08-20
20-08-2004