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

[REDO] Parallel: Refactor PSCardTable::scavenge_contents_parallel

    XMLWordPrintable

Details

    • gc
    • b12

    Backports

      Description

        `PSCardTable::scavenge_contents_parallel` is ~170 LOC and the its structure/logic is rather hard to follow.

        The original attempt (JDK-8280783) failed because it contained this assert:

        ```
        assert(*dirty_r == clean_card || dirty_r == iter_limit_r, "inv");
        ```

        This assert in the original patch is too strong, `dirty_r` can belong to next stripe (will be cleared/set as part of processing that stripe), but still iterated by current stripe.

        Weaken it to:
        ```
        assert(*dirty_r == clean_card || dirty_r >= clear_limit_r);
        ```

        IOW, the dereference of of `dirty_r` can be a data-race if `dirty_r >= clear_limit_r`.

        Attachments

          Issue Links

            Activity

              People

                ayang Albert Yang
                ayang Albert Yang
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: