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

Shenandoah get_barrier_strength should accept all shapes of (Weak)CAS reference barriers

    Details

    • Subcomponent:
      gc
    • Resolved In Build:
      b18

      Description

      I have multiple test failures while running jcstress on current jdk/jdk. All of them seem to point to the same thing:

      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (/home/shade/trunks/jdk-jdk/src/hotspot/share/gc/shenandoah/c2/shenandoahSupport.cpp:3248), pid=27815, tid=27831
      # Error: ShouldNotReachHere()

      This is not fatal for product builds, as it would default to STRONG barrier, but it breaks fastdebug testing with superfluous failures.

      Reproduces easily with:

      $ jdk-jdk/build/linux-x86_64-server-fastdebug/images/jdk/bin/java -jar jcstress-latest.jar --jvmArgs "-XX:+UnlockExperimentalVMOptions -XX:+UseShenandoahGC" -t varHandles -m quick

      The failing nodes are either WeakCompareAndSwapN or CompareAndExchangeN:

               1912 === 1949 1947 1913 1030 1032 [[ 1909 1911 1953 ]] !orig=1034 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetAcquire @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetAcquireString::actor2 @ bci:8 WeakCompareAndSetAcquireString_jcstress::actor2 @ bci:80
               1921 WeakCompareAndSwapN === 1960 1958 1922 1034 1036 [[ 1918 1920 1964 ]] !orig=1038 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSet @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetString::actor1 @ bci:8 WeakCompareAndSetString_jcstress::actor1 @ bci:80
               1921 WeakCompareAndSwapN === 1960 1958 1922 1034 1036 [[ 1918 1920 1964 ]] !orig=1038 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSet @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetString::actor1 @ bci:8 WeakCompareAndSetString_jcstress::actor1 @ bci:80
               1901 WeakCompareAndSwapN === 1938 1936 1902 1029 1031 [[ 1898 1900 ]] !orig=1033 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetPlain @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetPlainString::actor2 @ bci:8 WeakCompareAndSetPlainString_jcstress::actor2 @ bci:80
               1756 WeakCompareAndSwapN === 1790 1788 1757 894 896 [[ 1753 1755 ]] !orig=898 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetRelease @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetReleaseString::actor1 @ bci:8 WeakCompareAndSetReleaseString_jcstress::actor1 @ bci:80
               1911 WeakCompareAndSwapN === 1950 1948 1912 1034 1036 [[ 1908 1910 ]] !orig=1038 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetRelease @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetReleaseString::actor1 @ bci:8 WeakCompareAndSetReleaseString_jcstress::actor1 @ bci:80
               3373 WeakCompareAndSwapN === 3405 3403 3374 884 886 [[ 3370 3372 ]] !orig=888 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetPlain @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetPlainString::actor1 @ bci:8 WeakCompareAndSetPlainString_jcstress::actor1 @ bci:80
               1039 CompareAndExchangeN === 1028 1029 1022 1035 1037 [[ 1040 1041 1047 ]] !jvms: VarHandleReferences$FieldInstanceReadWrite::compareAndExchange @ bci:34 VarHandleGuards::guard_LLL_L @ bci:37 CompareAndExchangeString::actor1 @ bci:8 CompareAndExchangeString_jcstress::actor1 @ bci:80
               893 CompareAndExchangeN === 882 883 880 889 891 [[ 894 895 901 ]] !jvms: VarHandleReferences$FieldInstanceReadWrite::compareAndExchangeAcquire @ bci:34 VarHandleGuards::guard_LLL_L @ bci:37 CompareAndExchangeAcquireString::actor2 @ bci:8 CompareAndExchangeAcquireString_jcstress::actor2 @ bci:80
               2102 WeakCompareAndSwapN === 2139 2137 2103 1030 1032 [[ 2099 2101 2143 ]] !orig=1034 !jvms: VarHandleReferences$FieldInstanceReadWrite::weakCompareAndSetAcquire @ bci:34 VarHandleGuards::guard_LLL_Z @ bci:37 WeakCompareAndSetAcquireString::actor1 @ bci:8 WeakCompareAndSetAcquireString_jcstress::actor1 @ bci:80
               1039 CompareAndExchangeN === 1028 1029 1022 1035 1037 [[ 1040 1041 ]] !jvms: VarHandleReferences$FieldInstanceReadWrite::compareAndExchangeRelease @ bci:34 VarHandleGuards::guard_LLL_L @ bci:37 CompareAndExchangeReleaseString::actor1 @ bci:8 CompareAndExchangeReleaseString_jcstress::actor1 @ bci:80

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                shade Aleksey Shipilev
                Reporter:
                shade Aleksey Shipilev
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: