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

com/sun/jdi/RedefineAddPrivateMethod.sh fails intermittently

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Subcomponent:
    • Resolved In Build:
      b110
    • CPU:
      x86_64
    • OS:
      solaris_11

      Backports

        Description

        In the 2016-03-01 JDK9-hs-rt nightly, the following test failed:

            com/sun/jdi/RedefineAddPrivateMethod.sh

        Here is a snippet of the .jtr file:

        #section:shell
        ----------messages:(3/144)----------
        command: shell RedefineAddPrivateMethod.sh
        reason: User specified action: run shell RedefineAddPrivateMethod.sh
        elapsed time (seconds): 11.174
        ----------System.out:(26/1641)----------
        --Compiling first version of /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/shtest.java with options: -g
        compiling shtest.java

        --Compiling second version of /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/shtest.java with -g

        --Starting jdb, address=
        Listening at address: sca00csv.us.oracle.com:37763
        --Starting debuggee with args from TESTVMOPTS and/or TESTJAVAOPTS: -Xmixed -server -XX:MaxRAMFraction=8 -XX:+CreateCoredumpOnCrash -XX:ReservedCodeCacheSize=256M -XX:NativeMemoryTracking=detail
        Cmd: /export/local/aurora/CommonData/TEST_JAVA_HOME/bin/java -classpath /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184 -DHANGINGJAVA-7184_DEB -Xmixed -server -XX:MaxRAMFraction=8 -XX:+CreateCoredumpOnCrash -XX:ReservedCodeCacheSize=256M -XX:NativeMemoryTracking=detail -Djtreg.classDir=/export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184 -showversion -agentlib:jdwp=transport=dt_socket,address=37763,server=n,suspend=y shtest
        Set uncaught java.lang.Throwable
        Set deferred uncaught java.lang.Throwable
        Initializing jdb ...

        VM Started: > No frames on the current call stack

        main[1] Deferring breakpoint shtest:3.
        It will be set after the class is loaded.
        main[1] > Unable to set deferred breakpoint shtest:3 : No code at line 3 in shtest

        Stopping due to deferred breakpoint errors.
        "thread=main", java.lang.Class.getDeclaredMethods0(), line=-1 bci=-1

        main[1] main[1] Unable to set breakpoint shtest:3 : No code at line 3 in shtest
        main[1] >
        The application exited
        Input stream closed.
        ----------System.err:(17/842)----------
        ShellScaffold.sh: Version
        --Sending cmd: stop at shtest:3
        --Sending cmd: run
        java version "9-internal"
        Java(TM) SE Runtime Environment (fastdebug build 9-internal+0-2016-03-02-004742.mgronlun.upstream)
        Java HotSpot(TM) 64-Bit Server VM (fastdebug build 9-internal+0-2016-03-02-004742.mgronlun.upstream, mixed mode)

        --Sending cmd: redefine shtest /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/vers2/shtest.class
        --Sending cmd: stop at shtest:3
        --Sending cmd: cont
        --JDB finished: The application exited
        --Finish without sending "quit" command to JDB
        -rw-r--r-- 1 root root 52 Mar 2 04:56 /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/testFailed
        <cleanup:_begin_failFile_contents>
         
        --Fail: main: jdb input stream closed prematurely
        <cleanup:_end_failFile_contents>

        Based on the output above:

        main[1] > Unable to set deferred breakpoint shtest:3 : No code at line 3 in shtest

        it looks like the redefined class was not compiled with the '-g' option.

        Update: however the test output says that the classes were compiled with '-g':

        --Compiling first version of /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/shtest.java with options: -g
        compiling shtest.java

        --Compiling second version of /export/local/aurora/sandbox/results/workDir/classes/0/com/sun/jdi/aa7184/shtest.java with -g


        This test was recently added by JDK-8149743.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  aeriksso Andreas Eriksson (Inactive)
                  Reporter:
                  dcubed Daniel Daugherty
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: