Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4460093

AccessWatchpointEvent causes target VM to crash at interpreterRuntime.cpp,960

XMLWordPrintable

    • beta2
    • generic
    • generic
    • Verified



      Name: egR10015 Date: 05/17/2001



      HotSpot 1.4.0beta-b64 fails to pass the following tests

      nsk/jdi/EventRequestManager/deleteEventRequest/delevtreq001
      nsk/jdi/EventRequestManager/deleteEventRequests/delevtreqs001

      from testbase_nsk on all platforms. The target VM crashes
      with the error ID 494E54455250524554455232554E54494D450E43505003C0
      (interpreterRuntime.cpp, 960) when a requested AccessWatchpointEvent
      occurs.

      The test delevtreq001 mentioned above checks that the JDI method
      EventRequestManager.deleteEventRequest()
      properly disables and removes an event request. The test consists of
      two parts: a debugger (please see the source file delevtreq001.java)
      and a debuggee (the source file delevtreq001t.java). The debugger
      creates several AccessWatchpointRequests for notification when
      the contents of a field are accessed in the debuggee, and then it
      verifies that appropriate events are generated by the target VM.
      After that the debugger removes one request by deleteEventRequest() call.
      Finally, the test checks that the event corresponding to the deleted
      request, are not generated by the target VM any more. But when
      the debuggee performes the very first access to the first testing field
      (the byte field "byteFld"), its VM crashes with the error mentioned above.
      I've observed the following. The crash never happens when the debuggee
      accesses the fields of integer only type. Note also that HS 1.3.1-b24
      successfully passes the test.

      To reproduce the bug run with HS1.4

      sh doit.sh $JAVA_HOME

      in
      /net/sqesvr.eng/export/vsn/GammaBase/Bugs/<this bug number>

      and wait one minute for the target VM crash

      --------------- output on Solsparc with HS 1.4.0-b64 -----------------
      $ sh doit.sh ~/hotspot/jdk1.4/solsparc
      java version "1.4.0-beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta-b64)
      Java HotSpot(TM) Client VM (build 1.4.0-beta-b64, mixed mode)
      binder> Listening for a pipe connection to port: 7000
      binder> Binding to pipe socket
      binder> Listening to pipe server socket
      binder> VirtualMachineManager: version 1.4
      binder> FindingConnector: default
      binder> LaunchingConnector:
      binder> name: com.sun.jdi.CommandLineLaunch
      binder> description: Launches target using Sun Java VM command line and attaches to it
      binder> transport: dt_socket
      binder> Connector arguments:
      binder> home=/export/ld54/java/dest/jdk1.4.0beta-b64/solsparc
      binder> vmexec=java
      binder> options= -classpath ".:share/classes:/home/eug/hotspot/jdk1.4/solsparc/lib/tools.jar"
      binder> main=delevtreq001t "-verbose" "-waittime=1"
      binder> quote="
      binder> suspend=true
      binder> Launch debugee
      test.pipe> Waiting for pipe connection
      debugee.err> debugee.pipe> Making pipe connection to socket: localhost:7000
      debugee.err> Debuggee: sending the command: ready
      Creating AccessWatchpointRequest for the debuggee's field:
      byte byteFld
      Creating AccessWatchpointRequest for the debuggee's field:
      short shortFld
      Creating AccessWatchpointRequest for the debuggee's field:
      int intFld
      handleEvent: following JDI event occured: VMStartEvent in thread main

      a) Getting all requested AccessWatchpointEvents...

      1) Sending the command "run1" to a debuggee
      debugee.err> Debuggee: received the command: run1
      debugee.out> #
      debugee.out> # HotSpot Virtual Machine Error, Internal Error
      debugee.out> # Please report this error at
      debugee.out> # http://java.sun.com/cgi-bin/bugreport.cgi
      debugee.out> #
      debugee.out> # Error ID: 494E54455250524554455232554E54494D450E43505003C0 01
      debugee.out> #
      debugee.out> # Problematic Thread: prio=5 tid=0x298e0 nid=0x1 runnable
      debugee.out> #
      handleEvent: following JDI event occured: VMDisconnectEvent
      Notification about the AccessWatchpointEvent #0 received,
      or time has elapsed
      # ERROR: TEST FAILURE: debuggee's reply is empty
      test.pipe> Closing pipe socket
      binder> Closing pipe server socket
      exit code = 97
      ----------------------------------------------------------------------

      --------------- output on Solsparc with HS 1.3.1-b24 -----------------
      $ sh doit.sh ~/hotspot/jdk1.3.1/solsparc
      java version "1.3.1"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1-b24)
      Java HotSpot(TM) Client VM (build 1.3.1-b24, mixed mode)
      binder> Listening for a pipe connection to port: 7000
      binder> Binding to pipe socket
      binder> Listening to pipe server socket
      binder> VirtualMachineManager: version 1.3
      binder> FindingConnector: default
      binder> LaunchingConnector:
      binder> name: com.sun.jdi.CommandLineLaunch
      binder> description: Launches target using Sun Java VM command line and attaches to it
      binder> transport: dt_socket
      binder> Connector arguments:
      binder> home=/export/ld54/java/dest/jdk1.3.1-b24/solsparc
      binder> vmexec=java
      binder> options= -classpath ".:share/classes:/home/eug/hotspot/jdk1.3.1/solsparc/lib/tools.jar"
      binder> main=delevtreq001t "-verbose" "-waittime=1"
      binder> quote="
      binder> suspend=true
      binder> Launch debugee
      test.pipe> Waiting for pipe connection
      debugee.err> debugee.pipe> Making pipe connection to socket: localhost:7000
      debugee.err> Debuggee: sending the command: ready
      Creating AccessWatchpointRequest for the debuggee's field:
      byte byteFld
      Creating AccessWatchpointRequest for the debuggee's field:
      short shortFld
      Creating AccessWatchpointRequest for the debuggee's field:
      int intFld
      handleEvent: following JDI event occured: VMStartEvent in thread main

      a) Getting all requested AccessWatchpointEvents...

      1) Sending the command "run1" to a debuggee
      debugee.err> Debuggee: received the command: run1
      handleEvent: following JDI event occured: ###@###.###(java.lang.String[])+71 in thread
      main
      handleEvent: AccessWatchpointEvent for the debuggee's field #0:
      byte byteFld
      handleEvent: notifying about the received event #0
      Notification about the AccessWatchpointEvent #0 received,
      or time has elapsed
      debugee.err> Debuggee: access to the field "byteFld" is done
      debugee.err> Debuggee: sending the command: ready
      Debuggee's reply received: ready
      Got expected AccessWatchpointEvent for the following debuggee's field:
      byte byteFld

      2) Sending the command "run2" to a debuggee
      debugee.err> Debuggee: received the command: run2
      handleEvent: following JDI event occured: ###@###.###(java.lang.String[])+98 in thread
      main
      handleEvent: AccessWatchpointEvent for the debuggee's field #1:
      short shortFld
      handleEvent: notifying about the received event #1
      Notification about the AccessWatchpointEvent #1 received,
      or time has elapsed
      Debuggee's reply received: ready
      Got expected AccessWatchpointEvent for the following debuggee's field:
      short shortFld

      3) Sending the command "run3" to a debuggee
      handleEvent: following JDI event occured: ###@###.###(java.lang.String[])+126 in thread
      main
      handleEvent: AccessWatchpointEvent for the debuggee's field #2:
      int intFld
      handleEvent: notifying about the received event #2
      Notification about the AccessWatchpointEvent #2 received,
      or time has elapsed
      debugee.err> Debuggee: access to the field "shortFld" is done
      debugee.err> Debuggee: sending the command: ready
      debugee.err> Debuggee: received the command: run3
      Debuggee's reply received: ready
      Got expected AccessWatchpointEvent for the following debuggee's field:
      int intFld

      b) Getting AccessWatchpointEvents without request #1...

      Removing AccessWatchpointRequest #1 for the debuggee's field:
      short shortFld
      debugee.err> Debuggee: access to the field "intFld" is done
      debugee.err> Debuggee: sending the command: ready

      1) Sending the command "run1" to a debuggee
      debugee.err> Debuggee: received the command: run1
      handleEvent: following JDI event occured: ###@###.###(java.lang.String[])+71 in thread
      main
      handleEvent: AccessWatchpointEvent for the debuggee's field #0:
      byte byteFld
      handleEvent: notifying about the received event #0
      Notification about the AccessWatchpointEvent #0 received,
      or time has elapsed
      Debuggee's reply received: ready
      Got expected AccessWatchpointEvent for the following debuggee's field:
      byte byteFld

      2) Sending the command "run2" to a debuggee
      debugee.err> Debuggee: access to the field "byteFld" is done
      debugee.err> Debuggee: sending the command: ready
      debugee.err> Debuggee: received the command: run2
      debugee.err> Debuggee: access to the field "shortFld" is done
      debugee.err> Debuggee: sending the command: ready
      Notification about the AccessWatchpointEvent #1 received,
      or time has elapsed
      Debuggee's reply received: ready

      TEST PASSED: no event for the deleted AccessWatchpointRequest #1

      3) Sending the command "run3" to a debuggee
      handleEvent: following JDI event occured: ###@###.###(java.lang.String[])+126 in thread
      main
      handleEvent: AccessWatchpointEvent for the debuggee's field #2:
      int intFld
      handleEvent: notifying about the received event #2
      Notification about the AccessWatchpointEvent #2 received,
      or time has elapsed
      debugee.err> Debuggee: received the command: run3
      Debuggee's reply received: ready
      Got expected AccessWatchpointEvent for the following debuggee's field:
      int intFld
      handleEvent: following JDI event occured: VMDeathEvent
      debugee.err> Debuggee: access to the field "intFld" is done
      debugee.err> Debuggee: sending the command: ready
      debugee.err> Debuggee: received the command: quit
      debugee.err> Debuggee: exiting
      handleEvent: following JDI event occured: VMDisconnectEvent
      test.pipe> Closing pipe socket
      binder> Closing pipe server socket
      exit code = 95
      ----------------------------------------------------------------------

      ======================================================================

      Name: egR10015 Date: 05/22/2001


      The bug also affects the following test from testbase_nsk:

      nsk/jdi/EventRequestManager/createAccessWatchpointRequest/craccwtchpreq001

      ======================================================================

            mchung Mandy Chung (Inactive)
            eugsunw Eug Eug (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: