United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7026700 regression in 6u24-rev-b23: Crash in C2 compiler in PhaseIdealLoop::build_loop_late_post
JDK-7026700 : regression in 6u24-rev-b23: Crash in C2 compiler in PhaseIdealLoop::build_loop_late_post

Details
Type:
Bug
Submit Date:
2011-03-11
Status:
Closed
Updated Date:
2014-06-03
Project Name:
JDK
Resolved Date:
2011-06-28
Component:
hotspot
OS:
linux_ubuntu,solaris_10
Sub-Component:
compiler
CPU:
x86,sparc
Priority:
P3
Resolution:
Won't Fix
Affected Versions:
6u24-rev,6u25
Fixed Versions:
6-pool

Related Reports
Backport:
Backport:
Relates:
Relates:
Relates:

Sub Tasks

Description
C2 compiler crashes in PhaseIdealLoop::build_loop_late_post
This is reproducible easily and quickly after customer application launches.

V  [libjvm.so+0x6ea4d8] [0x6e988c]'void PhaseIdealLoop::build_loop_late_post(Node*)'+0xc4c
V  [libjvm.so+0x6e9838] [0x6e95c4]'void PhaseIdealLoop::build_loop_late(VectorSet&,Node_List&,Node_Stack&)'+0x274
V  [libjvm.so+0x6e785c] [0x6e7098]'void PhaseIdealLoop::build_and_optimize(bool,bool)'+0x7c4
V  [libjvm.so+0x1d93f4] [0x1d907c]'void Compile::Optimize()'+0x378
V  [libjvm.so+0x428b5c] [0x427db8]'Compile::Compile(ciEnv*,C2Compiler*,ciMethod*,int,bool,bool)'+0xda4
V  [libjvm.so+0x1d3cf4] [0x1d3c4c]'void C2Compiler::compile_method(ciEnv*,ciMethod*,int)'+0xa8
V  [libjvm.so+0x1d4bd8] [0x1d417c]'void CompileBroker::invoke_compiler_on_method(CompileTask*)'+0xa5c
V  [libjvm.so+0x247e34] [0x2475d4]'void CompileBroker::compiler_thread_loop()'+0x860
V  [libjvm.so+0x858590] [0x858540]'void JavaThread::thread_main_inner()'+0x50
V  [libjvm.so+0x77d890] [0x77d738]'java_start'+0x158

for details see the attached error log and corefile

                                    

Comments
WORK AROUND

-XX:-DoEscapeAnalysis
                                     
2011-03-11
EVALUATION

On 07/04/2011 20:45, Tom Rodriguez wrote:
So I managed to reproduce it with replay and it's an EA bug.  It seems to be connected to their use of the  -XX:-ReduceFieldZeroing flag.  If you don't turn that off the bug doesn't occur.  I decided to run CTW with that flag and got a couple failures so we can reproduce it outside of replay.

/java/re/jdk/1.7.0/latest/binaries/solaris-amd64/fastdebug/bin/java -server -XX:-ReduceFieldZeroing -Xss4m -verify -XX:-ShowMessageBoxOnError -XX:+CompileTheWorld -XX:CompileTheWorldStartAt=1090 -Xbootclasspath/p:/net/sqenfs-1.sfbay/export1/comp/vm/testbase/CompileTheWorld/jarfiles/Dynamo4.1.0.jar -XX:CompileTheWorldStopAt=109

crashes with the idom problem.  I debugged it a bit this morning and I think that the problem is that we're not actually eliminating some loads from the eliminated object because the phi structures is complex.  I notice that LoadNode::split_through_phi will sometimes give up if it doesn't appear profitable.  Doesn't that code always have to do a split?  Otherwise it can give up on eliminating a load.  I modified it to always do the split by ignoring the wins count and skipping the early when cnt == 3 and that seems to fix the bug.

As far as the customer goes if they drop the -XX:-ReduceFieldZeroing flag they should be fine.  Why are they running with -XX:+ReduceFieldZeroing -XX:+ReduceInitialCardMarks -XX:-ReduceBulkZeroing.  There were some bugs with those flags and CMS but they are fixed by now I think.
                                     
2011-04-07
EVALUATION

Confirmed there's no problem when removing ReduceFieldZeroing.
They had previously been asked to remove that as it was a workaround from 
a previous case, but hadn't done so until presented with this analysis!
                                     
2011-04-19
EVALUATION

http://hg.openjdk.java.net/jdk7/hotspot-comp/hotspot/rev/66b0e2371912
                                     
2011-04-21
EVALUATION

http://hg.openjdk.java.net/jdk7/hotspot-rt/hotspot/rev/66b0e2371912
                                     
2011-05-05
WORK AROUND

Also, remove -XX:-ReduceFieldZeroing
                                     
2011-06-28
EVALUATION

No action required in JDK6 right now, workaround in place.  Future JDK 6 updates will inherit the fix via hotspot express.  Closing the 6-pool entry as will not fix, nothing required.
                                     
2011-06-28



Hardware and Software, Engineered to Work Together