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
8270803: Reduce CDS API verbosity #4834
Conversation
…reduce-cds-api-verbosity
|
/label remove hotspot |
@iklam |
@iklam |
Webrevs
|
83e878c
to
833bb42
Compare
src/hotspot/share/cds/filemap.cpp
Outdated
MetaspaceShared::max_closed_archive_heap_region, | ||
&num_closed_archive_heap_ranges)) { | ||
HeapShared::set_closed_archive_heap_region_mapped(); | ||
// Map the closed_heap regions, GC does not write into the regions. |
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.
either add '' between heap and regions or replace the "' with space.
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 changed to // Map the closed heap regions: GC does not write into these regions.
I also updated the comment for the open heap regions a few lines below.
@iklam This change now passes all automated pre-integration checks. 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 1 new commit pushed to the
Please see this link for an up-to-date comparison between the source branch of this pull request and the
|
src/hotspot/share/cds/filemap.cpp
Outdated
*heap_mem = regions; | ||
*num = region_num; | ||
*regions_ret = regions; | ||
*num_ret = region_num; |
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.
Instead of num_ret
, I think num_regions
is easier to understand.
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 renamed it to num_regions_ret
to be consistent with regions_ret
: both of them are outgoing parameters. Now their names are also consistent with the globals like closed_heap_regions
and num_closed_heap_regions
.
I also rearranged the parameter order to put the outgoing ones at the end.
Thanks @calvinccheung and @yminqi for the review |
The CDS APIs have some excessively long function/field/enum names. E.g.,
Words such as
archive_heap_
,archive_
,heap_
, ... can be removed when the context is clear:This RFE also fixes inconsistency and grammatical errors in the code:
GrowableArray<MemRegion>* {archive, mem, range}
to refer to the same thing. Change these toGrowableArray<MemRegion>* regions
region
toregions
when appropriateHeapShared::_archive_heap_region_fixed
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/4834/head:pull/4834
$ git checkout pull/4834
Update a local copy of the PR:
$ git checkout pull/4834
$ git pull https://git.openjdk.java.net/jdk pull/4834/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 4834
View PR using the GUI difftool:
$ git pr show -t 4834
Using diff file
Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/4834.diff