[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    RFR(L): 8196889: Revamp G1 JMX MemoryPoolMXBean, GarbageCollectorMXBean, and jstat counter definitio
From:       "Hohensee, Paul" <hohensee () amazon ! com>
Date:       2018-07-20 22:37:14
Message-ID: E3D02D84-76D2-48A8-A209-9B777F64551D () amazon ! com
[Download RAW message or body]

[Attachment #2 (text/plain)]

Please review.

Bug: https://bugs.openjdk.java.net/browse/JDK-8196989
CSR: https://bugs.openjdk.java.net/browse/JDK-8196991
Webrev: http://cr.openjdk.java.net/~phh/8196989/webrev.00

This webrev is marked ‘L' because it's a behavioral change (CSR in draft state, may \
I have a review of that too please?) and because the test change fanout is large. The \
actual code changes are ‘M'.

Passes the submit repo, Hotspot tier1, the JFR gc event tests and any other test set \
with ‘gc' or ‘serviceability' in the test directory name. I found it difficult to \
verify the accuracy of the reported values other than manually, since they can vary \
from run to run of the same program. I'd appreciate suggestions for how to go about \
writing accuracy tests.

I set out originally to revamp only the MXBeans, but decided it would be incomplete \
if I didn't include the jstat counters and the output of the GC.heap_info jcmd \
option. I can separate the latter two into their own RFEs, but I find it easier \
understand it all in a single webrev and hope the reviewers will too.

The basic approach is to add the new memory pools and collectors, the new jstat \
counters, and an archive region counter that stands in for an actual archive region \
set. HeapRegionSets are disjoint, so initially I tried to create a first-class \
archive region set (on the same level as the humongous region set), but that idea \
foundered on the fact that there's too much code I don't fully understand that \
depends on archive regions being in the existing old region set. Externally (i.e., in \
the MXBeans and the jstat counters), however, the old region set doesn't include \
archive regions (unless running in legacy mode).

I used CMS's TraceCMSMemoryManagerStats class as the model for \
TraceConcMemoryManagerStats, which latter collects statistics on concurrent cycles. \
There are two STW pauses in each concurrent cycle: they are recorded separately and \
count as two sun.gc.collector.2 events.

The humongous and archive space committed and used values are always identical, hence \
they are always 100% used.

The revised output of jcmd GC.heap_info is in G1CollectedHeap::print_on().
I fixed a typo in src/hotspot/share/gc/g1/g1Policy.hpp by changing the result type of \
young_list_target_length() from size_t to uint, which latter is the type of the \
_young_list_target_length member. I updated the copyright date in \
src/hotspot/share/services/memoryService.hpp to 2018, as I neglected to do so in a \
previous push. Thanks,
Paul


[Attachment #3 (text/html)]

<html xmlns:o="urn:schemas-microsoft-com:office:office" \
xmlns:w="urn:schemas-microsoft-com:office:word" \
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" \
xmlns="http://www.w3.org/TR/REC-html40"> <head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Calibri",sans-serif;}
h2
	{mso-style-priority:9;
	mso-style-link:"Heading 2 Char";
	mso-margin-top-alt:auto;
	margin-right:0in;
	mso-margin-bottom-alt:auto;
	margin-left:0in;
	font-size:18.0pt;
	font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
	{mso-style-priority:99;
	color:#0563C1;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{mso-style-priority:99;
	color:#954F72;
	text-decoration:underline;}
span.EmailStyle17
	{mso-style-type:personal-compose;
	font-family:"Calibri",sans-serif;
	color:windowtext;}
span.Heading2Char
	{mso-style-name:"Heading 2 Char";
	mso-style-priority:9;
	mso-style-link:"Heading 2";
	font-family:"Calibri",sans-serif;
	font-weight:bold;}
.MsoChpDefault
	{mso-style-type:export-only;}
@page WordSection1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
	{page:WordSection1;}
--></style>
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt">Please \
review.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt">Bug: <a \
href="https://bugs.openjdk.java.net/browse/JDK-8196989"> \
https://bugs.openjdk.java.net/browse/JDK-8196989</a><o:p></o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt">CSR: <a \
href="https://bugs.openjdk.java.net/browse/JDK-8196991"> \
https://bugs.openjdk.java.net/browse/JDK-8196991</a><o:p></o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt">Webrev: <a \
href="http://cr.openjdk.java.net/~phh/8196989/webrev.00"> \
http://cr.openjdk.java.net/~phh/8196989/webrev.00</a><o:p></o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt">This webrev is marked ‘L' because \
it's a behavioral change (CSR in draft state, may I have a review of that too \
please?) and because the test change fanout is large. The actual code changes are \
‘M'.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt">Passes the submit repo, Hotspot tier1, the JFR gc event \
tests and any other test set with ‘gc' or ‘serviceability' in the test directory \
name. I found it difficult to verify the accuracy of the reported values  other than \
manually, since they can vary from run to run of the same program. I'd appreciate \
suggestions for how to go about writing accuracy tests.<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt">I set out originally to revamp only \
the MXBeans, but decided it would be incomplete if I didn't include the jstat \
counters and the output of the GC.heap_info jcmd option. I can separate the latter \
two into  their own RFEs, but I find it easier understand it all in a single webrev \
and hope the reviewers will too.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt">The basic approach is to add the new memory pools and \
collectors, the new jstat counters, and an archive region counter that stands in for \
an actual archive region set. HeapRegionSets are disjoint, so initially  I tried to \
create a first-class archive region set (on the same level as the humongous region \
set), but that idea foundered on the fact that there's too much code I don't fully \
understand that depends on archive regions being in the existing old region set.  \
Externally (i.e., in the MXBeans and the jstat counters), however, the old region set \
doesn't include archive regions (unless running in legacy \
mode).<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt">I used CMS's TraceCMSMemoryManagerStats class as the model \
for TraceConcMemoryManagerStats, which latter collects statistics on concurrent \
cycles. There are two STW pauses in each concurrent cycle: they are  recorded \
separately and count as two sun.gc.collector.2 events.<o:p></o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p \
class="MsoNormal"><span style="font-size:11.0pt">The humongous and archive space \
committed and used values are always identical, hence they are always 100% \
used.<o:p></o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt">The revised output of jcmd GC.heap_info is in \
G1CollectedHeap::print_on().<o:p></o:p></span></p> <h2><span \
style="font-size:11.0pt;font-weight:normal">I fixed a typo in \
src/hotspot/share/gc/g1/g1Policy.hpp by changing the result type of \
young_list_target_length() from size_t to uint, which latter is the type of the \
_young_list_target_length member.<o:p></o:p></span></h2> <h2><span \
style="font-size:11.0pt;font-weight:normal">I updated the copyright date in \
src/hotspot/share/services/memoryService.hpp to 2018, as I neglected to do so in a \
previous push.<o:p></o:p></span></h2> <h2><span \
style="font-size:11.0pt;font-weight:normal">Thanks,<o:p></o:p></span></h2> <h2><span \
style="font-size:11.0pt;font-weight:normal">Paul</span><span \
style="font-weight:normal"><o:p></o:p></span></h2> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> <p class="MsoNormal"><span \
style="font-size:11.0pt"><o:p>&nbsp;</o:p></span></p> </div>
</body>
</html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic