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

Some JFR tests do not accept 'GCLocker Initiated GC' as a valid GC cause

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 18, 19
    • Fix Version/s: 18
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
      gc
    • Resolved In Build:
      b31

      Backports

        Description

        Tests in question:

        jdk/jfr/event/gc/collection/TestGCCauseWithG1ConcurrentMark.java
        jdk/jfr/event/gc/collection/TestGCCauseWithG1FullCollection.java


        Error message:
        GC cause 'GCLocker Initiated GC' not in the valid causes[G1 Preventive Collection, G1 Compaction Pause, G1 Evacuation Pause, System.gc()]: expected true, was false

        The failure superficially resembles the JDK-8268424, though it is not a new GC cause here.

        Sample stack trace:

        ----------System.err:(13/924)----------
        java.lang.RuntimeException: GC cause 'GCLocker Initiated GC' not in the valid causes[G1 Preventive Collection, G1 Compaction Pause, G1 Evacuation Pause, System.gc()]: expected true, was false
        at jdk.test.lib.Asserts.fail(Asserts.java:594)
        at jdk.test.lib.Asserts.assertTrue(Asserts.java:486)
        at jdk.jfr.event.gc.collection.GCGarbageCollectionUtil.test(GCGarbageCollectionUtil.java:98)
        at jdk.jfr.event.gc.collection.TestGCCauseWithG1ConcurrentMark.main(TestGCCauseWithG1ConcurrentMark.java:44)
        at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
        at java.base/java.lang.reflect.Method.invoke(Method.java:577)
        at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
        at java.base/java.lang.Thread.run(Thread.java:833)

        Log:

        Event: jdk.GarbageCollection {
          startTime = 02:06:00.907 (2021-12-13)
          duration = 2.18 ms
          gcId = 19
          name = "G1New"
          cause = "G1 Evacuation Pause"
          sumOfPauses = 2.18 ms
          longestPause = 2.18 ms
        }

        Event: jdk.GarbageCollection {
          startTime = 02:06:00.911 (2021-12-13)
          duration = 2.51 ms
          gcId = 20
          name = "G1New"
          cause = "GCLocker Initiated GC"
          sumOfPauses = 2.51 ms
          longestPause = 2.51 ms
        }

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                fmatte Fairoz Matte
                Reporter:
                enikitin Evgeny Nikitin
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved: