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

AArch64: CompareAndExchange intrinsics clobber address register

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b150
    • CPU:
      aarch64
    • OS:
      generic

      Description

      the various compareAndExchange intrinsics in aarch64.ad potentially clobber the address register:

      ;; cmpxchg {
                0x0000007f88b5919c: ldxr w0, [x0]
                0x0000007f88b591a0: cmp w0, w2
                0x0000007f88b591a4: b.ne 0x0000007f88b591b0
                0x0000007f88b591a8: stlxr w8, w3, [x0]
                0x0000007f88b591ac: cbnz w8, 0x0000007f88b5919c
               ;; } cmpxchg

      This is very bad because it's subsequently used (within the same instruction) for the store-exclusive. It results in occasional segfaults.

        Attachments

          Activity

            People

            • Assignee:
              rkennke Roman Kennke
              Reporter:
              rkennke Roman Kennke
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: