JDK-2157692 : Test nsk/regression/b6186200 crashed with SIGSEGV
  • Type: Backport
  • Backport of: JDK-6642634
  • Component: hotspot
  • Sub-Component: gc
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2008-01-03
  • Updated: 2021-10-05
  • Resolved: 2011-03-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
hs11 b12Fixed
Description
See parent CR

Comments
SUGGESTED FIX jprt:2008-02-28-224020.ysr.hx11 ================================ Event: putback-to Parent workspace: /net/jano2/export2/hotspot/ws/11/baseline (jano2:/export2/hotspot/ws/11/baseline) Child workspace: /net/prt-archiver.sfbay/data/jprt/archive/2008/02/2008-02-28-224020.ysr.hx11/sourcetree (prt-archiver.sfbay:/data/jprt/archive/2008/02/2008-02-28-224020.ysr.hx11/sourcetree) User: ysr Comment: ------------------------------------------------------------------------------ JPRT Job ID: 2008-02-28-224020.ysr.hx11 JPRT System Used: sfbay JPRT Version Used: Feb 24 2008 - Case of the Mythical Monkeys [fbf782689ce3] Job URL: http://jprt-web.sfbay/archive/2008/02/2008-02-28-224020.ysr.hx11 Job ARCHIVE: /net/prt-archiver.sfbay/data/jprt/archive/2008/02/2008-02-28-224020.ysr.hx11 User: ysr Email: ###@###.### Release: jdk6 Job Source: Teamware: /net/neeraja/export/ysr/hx11/{.} Parent: /net/jano2/export2/hotspot/ws/11/baseline Push Parent: /net/jano2/export2/hotspot/ws/11/baseline File List: {src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp} Command Line: jprt rerun 2008-02-28-224020.ysr.hx11 ------------------------------------------------------------------------------ Fixed 6642634: Test nsk/regression/b6186200 crashed with SIGSEGV This is a verbatim backport to HX11 (6u10), of a fix already in HX12 for a while now. putback comment from hx12: This is a rather old bug and it's not clear why it started showing up recently in testing, except that some timing change may have rendered the bug more easily reproducible. With the right stress options (see below) the crash can be reproduced with older JVM's as well. When direct allocation occurs in the old generation, collected by the CMS collector, concurrent with a CMS cycle, objects must be allocated live (and P-bits used to mark the size of those objects to allow precleaning or sweeping phases to determine the sizes of objects allocated but not yet initialized). This requires the use of specialized allocation paths which were normally used. Except when the allocation failed and the generation had to be expanded to accommodate the allocation. In this case, the correct allocation path was not used, and consequently the object was not allocated live. Depending on when the allocation occurred, this could cause a crash either in a sweeping phase (because the size of an uninitialized block could not be determined) or in a later marking phase (because a reachable block had been reclaimed prematurely). A temporary workaround, as documented in the bug report, is to fix the size of the old generation. Fix Verified: yes Verification Test: nsk/regression/b6186200 with the set of stress options documented in the bug report for greater reproducibility. Reviewed by: jmasa, pbk Approved by: Jim Melvin (P Team) ------------------------------------------------------------------------------ Files: update: src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp Examined files: 1 Contents Summary: 1 update
29-02-2008

EVALUATION jprt:2008-02-28-224020.ysr.hx11
29-02-2008

SUGGESTED FIX See parent CR:- ------- concurrentMarkSweepGeneration.cpp ------- *** /tmp/sccs.7jaaOr Thu Feb 28 14:05:41 2008 --- concurrentMarkSweepGeneration.cpp Thu Feb 28 14:05:21 2008 *************** *** 3124,3135 **** if (GCExpandToAllocateDelayMillis > 0) { os::sleep(Thread::current(), GCExpandToAllocateDelayMillis, false); } ! size_t adj_word_sz = CompactibleFreeListSpace::adjustObjectSize(word_size); ! if (parallel) { ! return cmsSpace()->par_allocate(adj_word_sz); ! } else { ! return cmsSpace()->allocate(adj_word_sz); ! } } // YSR: All of this generation expansion/shrinking stuff is an exact copy of --- 3124,3130 ---- if (GCExpandToAllocateDelayMillis > 0) { os::sleep(Thread::current(), GCExpandToAllocateDelayMillis, false); } ! return have_lock_and_allocate(word_size, tlab); } // YSR: All of this generation expansion/shrinking stuff is an exact copy of
28-02-2008

WORK AROUND See parent CR
28-02-2008

EVALUATION Commit to HX11 -> 6u10.
28-02-2008