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

Remove Thread parameter from VMError::report_and_die

    Details

    • Type: Enhancement
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: tbd
    • Component/s: hotspot
    • Labels:
      None

      Description

      All variants of VMError::report_and_die() have a Thread* parameter, which is assumed to be the current thread - e.g. because reporting code tests this variable for NULL before using ResourceMark.

      Almost all callers pass in Thread::current(). Only exception is the secondary signal handler (VMError::crash_handler()), which passes NULL. Arguably this is an error, in practice it does not matter since for secondary crashes the parameter was ignored anyway.

      Instead of passing in this parameter, it could just as well retrieved at the entrance of VMError::report_and_die(). VMError::report_and_die() could

      but arguably this is wrong too. So it is just easier to

        Attachments

          Activity

            People

            • Assignee:
              stuefe Thomas Stuefe
              Reporter:
              stuefe Thomas Stuefe
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: