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

Refactor native stack printing from vmError.cpp to debug.cpp to make it available in gdb as well

    Details

    • Type: Enhancement
    • Status: Closed
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b34
    • Verification:
      Not verified

      Backports

        Description

        In the hs_err files we have a nice mixed stack trace which contains both, Java and native frames.
        It would be nice if we could make this functionality available from within gdb during debugging sessions.

        This can be easily achieved by refactoring the corresponding code from VMError::report() in vmError.cpp into it own method in debug.cpp.

        With another helper function which creates a frame object, we can then get a mixed stack trace in gdb as follows:

        Linux/amd64
        call pns(make_frame($sp, $rbp, $pc))

        Linux/i586
        call pns(make_frame($sp, $ebp, $pc))

        Linux/ppc64
        call pns(make_frame($sp, $pc))

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  simonis Volker Simonis
                  Reporter:
                  simonis Volker Simonis
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: