Ticket #263 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

JDWP errors cause "old" VMs to crash

Reported by: stephan Owned by:
Priority: critical Milestone: OTDT_1.3.0_M4
Component: debug Version: 1.3.0M3
Keywords: Cc:

Description (last modified by stephan) (diff)

Inspecting various crashes that specifically occurred on MacOS (see OtdtOnMac), it turns out that our debugger may created JDWP requests, that on modern VMs fail with a proper error code, whereas older VMs (1.5) seem to crash (in native code) in these situations.

Thus we should clean-up the debugger to strictly avoid any erroneous requests, rather than hoping to catch resulting exceptions.

Change History

Changed 3 years ago by stephan

  • description modified (diff)

Changed 3 years ago by stephan

r21657 solves a first instance of this issue:

1.5 JVM could not correctly place method entry breakpoint:

  • using a JavaMethodEntryBreakpoint on o.o.Team.finalize() the VM actually placed this breakpoint on j.l.Object.finalize().
  • thus every Object.finalize() incorrectly triggered the TeamBreakpointListener. Somewhere downstream JDIStackFrame.getUnderlyingThisObject() created an illegal JDWP request, causing the JVM to abruptly die, where a 1.6 JVM would gracefully report a JDWP error (not sure what the exact error would be).

Instead of JavaMethodEntryBreakpoint we're now using a JavaMethodBreakpoint with entry==true. I don't see the big difference, but the new version works on 1.5 JVMs (so far tested on Linux-GTK only).

Also pass a valid linenumber (extracted from Team.java by the script genIOOTBreakpoints).

Changed 3 years ago by stephan

  • status changed from new to closed
  • resolution set to fixed
  • milestone changed from OTDT_1.3.0 to OTDT_1.3.0_M4

already r21619 solved a JDWP issue. No further issues known at this time.

Note: See TracTickets for help on using tickets.