RFR: 8259668: Make SubTasksDone use-once [v3]

Albert Mingkun Yang ayang at openjdk.java.net
Sun Feb 7 09:47:08 UTC 2021


> After JDK-8260574, a instance of `SubTasksDone` is never reused, so part of its APIs could be revised: `clear()` and the code calling it is removed.
> 
> With this patch, `all_tasks_completed` contains only assertion. Kim suggested moving this assertion logic to `~SubTasksDone`, but that could defer the assertion violation. For example, in the case of `G1FullGCMarkTask::work`, there is a significant amount of code running btw the instance when all subtasks are claimed (where `all_tasks_completed` is called in this PR) and `~SubTasksDone`. In the interest of having more precise location where bugs may lie, I have kept `all_tasks_completed` in the original place. More comments on this are welcome.

Albert Mingkun Yang has updated the pull request incrementally with one additional commit since the last revision:

  review

-------------

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/2383/files
  - new: https://git.openjdk.java.net/jdk/pull/2383/files/90add10d..67c399e1

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=2383&range=02
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=2383&range=01-02

  Stats: 32 lines in 4 files changed: 4 ins; 15 del; 13 mod
  Patch: https://git.openjdk.java.net/jdk/pull/2383.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/2383/head:pull/2383

PR: https://git.openjdk.java.net/jdk/pull/2383


More information about the hotspot-dev mailing list