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

Missing local debug information when debugging JEP-330

    XMLWordPrintable

    Details

    • Type: CSR
    • Status: Closed
    • Priority: P3
    • Resolution: Approved
    • Fix Version/s: 17
    • Component/s: tools
    • Labels:
      None
    • Subcomponent:
    • Compatibility Kind:
      behavioral
    • Compatibility Risk:
      minimal
    • Compatibility Risk Description:
      debugging options will be enabled for the class being executed when the use of a debugger is detected
    • Interface Kind:
      Other
    • Scope:
      Implementation

      Description

      Summary

      When compiling code with the source launcher, enable debugging info when debug options are detected.

      Problem

      Currently, the internal compilation of code being run by the source launcher does not include full debug info, because class files are not generated that might subsequentlly be run under a debugger. But a notable special case is when the source launcher itself is being run with a debugger.

      Solution

      Detect the use of a debugger and automatically set the -g option for the internal compilation.

      Specification

      This is just a behavioral change. There is no change required for the user to enable the new behavior.

      The -g option for the internal compilation will be set when the java launcher for JEP-330 is launched with -agentlib:jdwp= or -Xrunjdwp: command line options.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jtulach Jaroslav Tulach
              Reporter:
              jtulach Jaroslav Tulach
              Reviewed By:
              Jan Lahoda
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: