-
Notifications
You must be signed in to change notification settings - Fork 6.2k
8290357: Drop HeapRegion::marked_bytes() #9511
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8290357: Drop HeapRegion::marked_bytes() #9511
Conversation
| void assert_marked_words(HeapRegion* hr) { | ||
| assert((_marked_words * HeapWordSize) == hr->marked_bytes(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This use is for verification/debugging only and has been suggested to remove (the _marked_words member) here during review of the single bitmap change.
|
👋 Welcome back tschatzl! A progress list of the required criteria for merging this PR into |
| total_live_bytes, | ||
| BOOL_TO_STR(selected_for_rebuild), | ||
| live_bytes, | ||
| r->marked_bytes(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At this point (scrubbing start) marked_bytes() contain the amount of marked bytes in the previous marking. This is not particularly interesting to see; live_bytes contains the current marked bytes below tams and is printed.
| } | ||
|
|
||
| void account_failed_region(HeapRegion* r) { | ||
| size_t used_words = r->marked_bytes() / HeapWordSize; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At this point, for evacuation failure regions, marked_bytes() == live_bytes() so it can be replaced without any change.
|
|
||
| bool do_heap_region(HeapRegion* r) { | ||
| if (r->is_old()) { | ||
| size_t prev_live = r->marked_bytes(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not think this has ever been intended (this is the marked bytes below TAMS, not including bytes between TAMS and top()), and for a lower estimate of amount of bytes reclaimed, live_bytes() is as good or better.
| void HeapRegion::note_self_forwarding_removal_start(bool during_concurrent_start, | ||
| bool during_conc_mark) { | ||
| // We always scrub the region to make sure the entire region is | ||
| // parsable after the self-forwarding point removal, and update _marked_bytes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need an update with the comment related to _marked_bytes.
sangheon
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
Just minor nit regarding the remaining comment of _marked_bytes.
|
@tschatzl this pull request can not be integrated into git checkout submit/8290357-remove-marked-bytes
git fetch https://git.openjdk.org/jdk master
git merge FETCH_HEAD
# resolve conflicts and follow the instructions given by git merge
git commit -m "Merge master"
git push |
|
@tschatzl This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 62 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
walulyai
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm!
|
Going to push as commit 4591937.
Your commit was automatically rebased without conflicts. |
Hi all,
please review this removal of the
HeapRegion::_marked_bytesmember that records the bytes marked below tams in the recent mark as it is not really interesting in the removed places. I added comments to give reasons for this removal in the particular places for your review.Testing: jtreg gc/g1, gha
Thanks,
Thomas
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/9511/head:pull/9511$ git checkout pull/9511Update a local copy of the PR:
$ git checkout pull/9511$ git pull https://git.openjdk.org/jdk pull/9511/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 9511View PR using the GUI difftool:
$ git pr show -t 9511Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/9511.diff