JDK-6629727 : assertion in set_trap_state() in methodDataOop.hpp is too strong.
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: hs12
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2007-11-14
  • Updated: 2011-03-08
  • Resolved: 2011-03-08
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.
JDK 6 JDK 7 Other
6u14Fixed 7Fixed hs13Fixed
Description
In methodDataOop.hpp

  void set_trap_state(int new_state) {
    assert(ProfileTraps, "used only under +ProfileTraps");
    uint old_flags = (_header._struct._flags & flag_mask);
    _header._struct._flags = (new_state << trap_shift) | old_flags;
    assert(trap_state() == new_state, "sanity");
  } 

the assertion

assert(trap_state() == new_state, "sanity");

can fail if the trap state is being set simultaneously by another
thread.

Comments
EVALUATION The assertion is too strong and should be removed.
2007-11-14