Race in macOS os::processor_id()

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P4
    • 14
    • Affects Version/s: None
    • Component/s: hotspot
    • None
    • b25

      In os::processor_id() on macOS, a CAS protects initialization of processor ID number given an APIC id. However, the CAS is not converted properly to a boolean determining whether it succeeded or failed. The implicit boolean conversion is wrong, allowing multiple threads to increment the next processor ID. The result is that we can get IDs that are higher than the number of processors.

            Assignee:
            Erik Ă–sterlund
            Reporter:
            Erik Ă–sterlund
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: