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

Externally effectively weak referenced non-humongous object was not deleted after YOUNG_GC

    Details

    • Type: Bug
    • Status: Open
    • Priority: P3
    • Resolution: Unresolved
    • Affects Version/s: 9
    • Fix Version/s: 10
    • Component/s: hotspot
    • Subcomponent:
      gc

      Description

      java.lang.RuntimeException: Externally effectively weak referenced non-humongous object was not deleted after YOUNG_GC (assert failed: [Ljava.lang.Object;@131e9c6 == null)
      at jdk.test.lib.Asserts.error(Asserts.java:447)
      at jdk.test.lib.Asserts.assertTrue(Asserts.java:374)
      at jdk.test.lib.Asserts.assertEquals(Asserts.java:169)
      at jdk.test.lib.Asserts.assertNull(Asserts.java:313)
      at gc.g1.humongousObjects.objectGraphTest.GC.lambda$getCaseCheck$0(GC.java:115)
      at gc.g1.humongousObjects.objectGraphTest.GC$Checker.accept(GC.java:194)
      at gc.g1.humongousObjects.objectGraphTest.GC$Checker.accept(GC.java:156)
      at java.util.HashMap$KeySpliterator.forEachRemaining(java.base@9-internal/HashMap.java:1600)
      at java.util.stream.ReferencePipeline$Head.forEach(java.base@9-internal/ReferencePipeline.java:591)
      at gc.g1.humongousObjects.objectGraphTest.TestObjectGraphAfterGC.checkResults(TestObjectGraphAfterGC.java:222)
      at gc.g1.humongousObjects.objectGraphTest.TestObjectGraphAfterGC.doTesting(TestObjectGraphAfterGC.java:140)
      at gc.g1.humongousObjects.objectGraphTest.TestObjectGraphAfterGC.lambda$main$0(TestObjectGraphAfterGC.java:106)
      at java.util.Spliterators$ArraySpliterator.forEachRemaining(java.base@9-internal/Spliterators.java:948)
      at java.util.stream.ReferencePipeline$Head.forEach(java.base@9-internal/ReferencePipeline.java:591)
      at gc.g1.humongousObjects.objectGraphTest.TestObjectGraphAfterGC.main(TestObjectGraphAfterGC.java:102)
      at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(java.base@9-internal/Native Method)
      at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(java.base@9-internal/NativeMethodAccessorImpl.java:62)
      at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(java.base@9-internal/DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(java.base@9-internal/Method.java:531)
      at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:110)
      at java.lang.Thread.run(java.base@9-internal/Thread.java:843)

        Activity

        Hide
        jmasa Jon Masamitsu (Inactive) added a comment -
        This is a new test, right? Just added recently?
        Show
        jmasa Jon Masamitsu (Inactive) added a comment - This is a new test, right? Just added recently?
        Hide
        jwilhelm Jesper Wilhelmsson added a comment -
        I'm not sure exactly where in the GC log the test assumes that something resides in the young gen, but there are several concurrent cycles in the log so anything can happen there I guess.
        Show
        jwilhelm Jesper Wilhelmsson added a comment - I'm not sure exactly where in the GC log the test assumes that something resides in the young gen, but there are several concurrent cycles in the log so anything can happen there I guess.
        Hide
        kzhaldyb Kirill Zhaldybin (Inactive) added a comment -
        The test logic is the following:
        1. allocate an object graph (non humongous nodes are allocated in young gen, humongous ones - in old gen). The test stores weak or soft references to each node, the only strong reference to graph is a reference to first node.
        2. make the object graph strongly unreachable (the only strong ref to first node is nulled).
        3. young gc.
        4. check that weakly reachable non-humongous nodes which were not referenced by humongous nodes and therefore should be collected are actually collected.

        Non-humongous nodes nodes were not promoted to old gen because they don't have much time for it - they were allocated and then young gc was called.
        Show
        kzhaldyb Kirill Zhaldybin (Inactive) added a comment - The test logic is the following: 1. allocate an object graph (non humongous nodes are allocated in young gen, humongous ones - in old gen). The test stores weak or soft references to each node, the only strong reference to graph is a reference to first node. 2. make the object graph strongly unreachable (the only strong ref to first node is nulled). 3. young gc. 4. check that weakly reachable non-humongous nodes which were not referenced by humongous nodes and therefore should be collected are actually collected. Non-humongous nodes nodes were not promoted to old gen because they don't have much time for it - they were allocated and then young gc was called.
        Hide
        kzhaldyb Kirill Zhaldybin (Inactive) added a comment -
        Despite there are no indications that it was test issue but I still found some issues in the test which could cause such a failure.
        So I am consider this as a test bug and I want to fix it in 9
        Show
        kzhaldyb Kirill Zhaldybin (Inactive) added a comment - Despite there are no indications that it was test issue but I still found some issues in the test which could cause such a failure. So I am consider this as a test bug and I want to fix it in 9

          People

          • Assignee:
            Unassigned
            Reporter:
            jprovino Joseph Provino (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

            • Created:
              Updated: