United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-6316313 : hotspot terminates at assert during GC in java_g

Details
Type:
Bug
Submit Date:
2005-08-26
Status:
Resolved
Updated Date:
2014-02-27
Project Name:
JDK
Resolved Date:
2006-11-20
Component:
hotspot
OS:
windows_2003
Sub-Component:
compiler
CPU:
x86
Priority:
P4
Resolution:
Fixed
Affected Versions:
5.0u3
Fixed Versions:
1.4.2_14 (b01)

Related Reports
Backport:

Sub Tasks

Description
A customer reproted Hotspot crash at assert function in java_g command during GC.

#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
#  Internal Error (C:/BUILD_AREA/jdk1.5.0_03/hotspot\src\share\vm\memory\genOopClosures.inline.hpp, 69), pid=2908, tid=2280
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_03-b07-debug mixed mode)
#
# Error: assert(!_g->to()->contains(obj),"Scanning field twice?")

CONFIGURATION :
 JRE : 1.4.2_08/5.0u3
 OS  : Windows 2003 server


REPRODUCE :
 Launch the command line.
   java_g -cp .;csmjaxp.jar TEST1 TEST1.xml TEST1.xsd

NOTE:
 Several hours is needed to reproduce.

                                    

Comments
SUGGESTED FIX

Either add another field to Thread which will not change during GC or store eax in a temporary stack slot. The former is the easy way to implement but the later more effecient.
                                     
2006-08-09
EVALUATION

When C1 generate native return code, there is a tiny time window during which GC can kick in and change _vm_result. It happens between where we unbox return result (in eax) and where we checking safepoint there after. This is a long standing bug, not exist in mustang since the rewriring of all the stub routines, but it is in tiger too. Thanks to Tom and Ken for help on this issue.
                                     
2006-08-09



Hardware and Software, Engineered to Work Together