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

AArch64: Obsolete UseBarriersForVolatile option

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Approved
    • Icon: P4 P4
    • 15
    • hotspot
    • behavioral
    • minimal
    • Hide
      Internet searches its production usages and found none. Its only usage is an original work-around for a prototype version of a CPU which would also remove it (See https://bugs.openjdk.java.net/browse/JDK-8242469).
      Show
      Internet searches its production usages and found none. Its only usage is an original work-around for a prototype version of a CPU which would also remove it (See https://bugs.openjdk.java.net/browse/JDK-8242469) .
    • add/remove/modify command line option
    • JDK

      Summary

      Obsolete the VM product option UseBarriersForVolatile

      Problem

      Running application with option "-XX:+UseBarriersForVolatile" might have memory consistent issue like what mentioned in https://bugs.openjdk.java.net/browse/JDK-8241137. Besides it adds complexity to the volatile access implementation, and each usage of it needs to take more consideration of the memory consistent and tests. Since ldar/stlr can work well stably for volatile access, and so does ldaxr/stlxr for unsafe atomic operations, we'd better simplify things by removing this flag and the alternative implementation for volatile memory access.

      Solution

      Obsolete the option and remove its usages in hotspot.

      Here is the discussion details about this flag:

      http://mail.openjdk.java.net/pipermail/aarch64-port-dev/2020-March/008679.html

      http://mail.openjdk.java.net/pipermail/aarch64-port-dev/2020-April/008706.html

      Specification

      Running java with option -XX:+/-UseBarriersForVolatile will no longer enable or disable the feature. Instead, it will print the usual obsolete option warning.

            xgong Xiaohong Gong (Inactive)
            xgong Xiaohong Gong (Inactive)
            Ningsheng Jian (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: