[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-serviceability-dev
Subject: =?utf-8?B?UmU6IOetlOWkjTogQ2FsbCBmb3IgZGlzY3Vzc2lvbjogRXh0ZW5kIEpNYXAg?= =?utf-8?B?dG8gc3VwcG9ydCBwY
From: "Hohensee, Paul" <hohensee () amazon ! com>
Date: 2018-11-30 13:48:36
Message-ID: 6C791C63-81E7-42AF-980F-78D799FE322F () amazon ! com
[Download RAW message or body]
[Attachment #2 (text/plain)]
Hi Lin,
This looks interesting and useful, so I filed JBS RFE \
https://bugs.openjdk.java.net/browse/JDK-8214535 to track it, using your summary \
below as the description. This work would fit in with JC's original Atlantis project \
proposal, but not one restricted to doing a thread sanitizer. Maybe we need another \
project for this? Otherwise we'd be passing potentially large patches around.
Thanks,
Paul
From: serviceability-dev <serviceability-dev-bounces@openjdk.java.net> on behalf of \
臧琳 <zanglin5@jd.com>
Date: Tuesday, November 27, 2018 at 6:48 PM
To: "serviceability-dev@openjdk.java.net" <serviceability-dev@openjdk.java.net>
Cc: "discuss@openjdk.java.net" <discuss@openjdk.java.net>
Subject: 答复: Call for discussion: Extend JMap to support parallel and incremental \
heap scanning.
Add serviceability-dev.
Thanks.
________________________________
发件人: 臧琳
发送时间: 2018年11月28日 10:30
收件人: Martijn Verburg
抄送: discuss@openjdk.java.net
主题: Re: Call for discussion: Extend JMap to support parallel and incremental heap \
scanning.
Hi Martijn,
Thanks a lot for you guidance! I will go to serviceability-dev and try to join \
the Atlantis discussion.
Cheers,
Lin
发件人: Martijn Verburg [mailto:martijnverburg@gmail.com]
发送时间: 2018年11月27日 23:18
收件人: 臧琳 <zanglin5@jd.com>
抄送: discuss@openjdk.java.net
主题: Re: Call for discussion: Extend JMap to support parallel and incremental heap \
scanning.
Hi Lin and welcome to OpenJDK!
There's an ongoing thread discussing project Atlantis \
(http://mail.openjdk.java.net/pipermail/discuss/2018-November/004904.html) which I \
think will be looking at potential enhancements like this alongside the \
serviceability group.
In the meantime, I think the serviceability-dev mailing list is the right place to \
start your discussion.
Cheers,
Martijn
On Tue, 27 Nov 2018 at 15:08, 臧琳 <zanglin5@jd.com<mailto:zanglin5@jd.com>> wrote:
Hello,
This is Zang Lin, JVM developer in JD.COM<http://JD.COM>. My department just \
signed OCA and we will try to contribute to OpenJDK. As I am newbie at openJDK, I'd \
like to discuss some of my ideas and ask for suggestions.
Recently I tried to use "jmap -histo" to collect histogram info on a large heap \
at ~200G bytes. it took about 160 seconds, which actually cause our online system \
suffering "non-responsive" issue. In addition, if we stop jmap with "kill", jmap \
exits directly (even the attached JVM still working on heap iteration), leave no help \
info for analysis.
To address the issue above, I proposed following approaches:
1) Extend Jmap to be parallel and incremental, which means Jmap iterates heap in \
parallel and save the intermediate results incrementally during heap scanning \
(controlled by threshold to decide when to dump).
2) Make Jmap to accept arguments that enable/disable parallel and partial heap \
iterating, also make parallel thread number configurable.
3) Make Jmap to dump results to specified file path given by argument, rather than \
output to stdout directly.
A prototype has been made internally with G1 upon JDK 11, and our preliminary \
measurement show that parallel iterate ~200GB heap with 4 threads can save ~30-40 \
seconds, and I am also analyzing the approach to make the time more scaled with \
parallel threads. Moreover, with the implementation of incremental dump, we can get \
usefully partial dump info for analyzing, even when jmap hang for a long time, or get \
killed for some reason.
Several problems were encountered during development. One problem is that it is \
not easy to dynamically allocate some data structures for thread local operations, \
such as KlassInfoTable,which is designed to be StackObj that not allowed to be \
allocated using "new", another problem is that some base classes definition in \
hotspot has to be modified to support parallel operations, such as ObjectClosure etc. \
I am not sure whether these modifications can be acceptable.
Any suggestions/guidance would be much appreciated!
BRs,
Lin
[Attachment #3 (text/html)]
<html xmlns:v="urn:schemas-microsoft-com:vml" \
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)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
{font-family:SimSun;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:"MS Gothic";
panose-1:2 11 6 9 7 2 5 8 2 4;}
@font-face
{font-family:MingLiU;
panose-1:2 2 5 9 0 0 0 0 0 0;}
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:DengXian;
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:"\@MingLiU";
panose-1:2 1 6 9 0 1 1 1 1 1;}
@font-face
{font-family:"\@MS Gothic";
panose-1:2 11 6 9 7 2 5 8 2 4;}
@font-face
{font-family:"\@DengXian";
panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
{font-family:"\@SimSun";
panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal">Hi Lin,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">This looks interesting and useful, so I filed JBS RFE <a \
href="https://bugs.openjdk.java.net/browse/JDK-8214535"> \
https://bugs.openjdk.java.net/browse/JDK-8214535</a> to track it, using your summary \
below as the description. This work would fit in with JC's original Atlantis project \
proposal, but not one restricted to doing a thread sanitizer. Maybe we need another \
project for this? Otherwise we'd be passing potentially large patches \
around.<o:p></o:p></p> <p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Paul<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:12.0pt;color:black">From: \
</span></b><span style="font-size:12.0pt;color:black">serviceability-dev \
<serviceability-dev-bounces@openjdk.java.net> on behalf of </span><span \
style="font-size:12.0pt;font-family:"MS \
Gothic";color:black">臧琳</span><span style="font-size:12.0pt;color:black"> \
<zanglin5@jd.com><br> <b>Date: </b>Tuesday, November 27, 2018 at 6:48 PM<br>
<b>To: </b>"serviceability-dev@openjdk.java.net" \
<serviceability-dev@openjdk.java.net><br> <b>Cc: \
</b>"discuss@openjdk.java.net" <discuss@openjdk.java.net><br> \
<b>Subject: </b></span><span style="font-size:12.0pt;font-family:"MS \
Gothic";color:black">答复</span><span style="font-size:12.0pt;color:black">: \
Call for discussion: Extend JMap to support parallel and incremental heap \
scanning.<o:p></o:p></span></p> </div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div id="divtagdefaultwrapper">
<p><span style="font-size:12.0pt;color:black">Add \
serviceability-dev. <o:p></o:p></span></p> <p><span \
style="font-size:12.0pt;color:black">Thanks.<o:p></o:p></span></p> <p \
class="MsoNormal" style="margin-bottom:12.0pt"><span \
style="font-size:12.0pt;color:black"><o:p> </o:p></span></p> <div>
<div class="MsoNormal" align="center" style="text-align:center"><span \
style="font-size:12.0pt;color:black"> <hr size="2" width="98%" align="center">
</span></div>
<div id="divRplyFwdMsg">
<p class="MsoNormal"><b><span \
style="font-family:MingLiU;color:black">发</span></b><b><span \
style="font-family:"MS Gothic";color:black">件人</span></b><b><span \
style="color:black">:</span></b><span style="color:black"> </span><span \
style="font-family:"MS Gothic";color:black">臧琳</span><span \
style="color:black"><br> </span><b><span \
style="font-family:MingLiU;color:black">发</span></b><b><span \
style="font-family:"MS Gothic";color:black">送</span></b><b><span \
style="font-family:MingLiU;color:black">时间</span></b><b><span \
style="color:black">:</span></b><span style="color:black"> 2018</span><span \
style="font-family:"MS Gothic";color:black">年</span><span \
style="color:black">11</span><span style="font-family:"MS \
Gothic";color:black">月</span><span style="color:black">28</span><span \
style="font-family:"MS Gothic";color:black">日</span><span \
style="color:black"> 10:30<br>
</span><b><span style="font-family:"MS \
Gothic";color:black">收件人</span></b><b><span \
style="color:black">:</span></b><span style="color:black"> Martijn Verburg<br> \
</span><b><span style="font-family:"MS \
Gothic";color:black">抄送</span></b><b><span \
style="color:black">:</span></b><span style="color:black"> \
discuss@openjdk.java.net<br> </span><b><span style="font-family:"MS \
Gothic";color:black">主</span></b><b><span \
style="font-family:MingLiU;color:black">题</span></b><b><span \
style="color:black">:</span></b><span style="color:black"> Re: Call for discussion: \
Extend JMap to support parallel and incremental heap scanning.</span><span \
style="font-size:12.0pt;color:black"> <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span \
style="font-size:12.0pt;color:black"> <o:p></o:p></span></p> </div>
</div>
<div>
<div>
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D">Hi Martijn, \
</span> <span style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p>
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D"> \
Thanks a lot for you guidance! I will go to serviceability-dev and try to join the \
Atlantis discussion.</span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D"> </span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D">Cheers, </span> \
<span style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D">Lin</span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D"> </span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> <p \
style="text-align:justify"><span \
style="font-size:14.0pt;font-family:"Arial",sans-serif;color:#595757"> </span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> <p \
style="text-align:justify"><span \
style="font-size:14.0pt;font-family:"Arial",sans-serif;color:#595757"> </span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:10.5pt;font-family:DengXian;color:#1F497D"> </span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><b><span style="font-family:DengXian;color:black">发件人:</span></b><span \
style="font-family:DengXian;color:black"> Martijn Verburg \
[mailto:martijnverburg@gmail.com] <br>
<b>发送时间:</b> 2018年11月27日 23:18<br>
<b>收件人:</b> 臧琳 <zanglin5@jd.com><br>
<b>抄送:</b> discuss@openjdk.java.net<br>
<b>主题:</b> Re: Call for discussion: Extend JMap to support parallel and \
incremental heap scanning.</span><span \
style="font-size:12.0pt;font-family:SimSun;color:black"><o:p></o:p></span></p> \
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"> <o:p></o:p></span></p>
<div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black">Hi Lin and welcome \
to OpenJDK!<o:p></o:p></span></p> <div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"> <o:p></o:p></span></p>
</div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black">There's an ongoing \
thread discussing project Atlantis (<a \
href="http://mail.openjdk.java.net/pipermail/discuss/2018-November/004904.html">http://mail.openjdk.java.net/pipermail/discuss/2018-November/004904.html</a>)
which I think will be looking at potential enhancements like this alongside the \
serviceability group.<o:p></o:p></span></p> </div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"> <o:p></o:p></span></p>
</div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black">In \
the meantime, I think the serviceability-dev mailing list is the right \
place to start your discussion.<o:p></o:p></span></p> </div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"><br clear="all">
<o:p></o:p></span></p>
<div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black">Cheers,<br>
Martijn<o:p></o:p></span></p>
</div>
</div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"> <o:p></o:p></span></p>
</div>
</div>
</div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black"> <o:p></o:p></span></p>
<div>
<div>
<p><span style="font-size:12.0pt;font-family:SimSun;color:black">On Tue, 27 Nov 2018 \
at 15:08, 臧琳 <<a href="mailto:zanglin5@jd.com">zanglin5@jd.com</a>> \
wrote:<o:p></o:p></span></p> </div>
<blockquote style="border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in \
6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt"> <p \
style="margin-bottom:12.0pt"><span \
style="font-size:12.0pt;font-family:SimSun;color:black"> Hello,<br> <br>
This is Zang Lin, JVM developer in <a href="http://JD.COM" \
target="_blank">JD.COM</a>. My department just signed OCA and we will try to \
contribute to OpenJDK. As I am newbie at openJDK, I'd like to discuss \
some of my ideas and ask for suggestions.<br> <br>
<br>
Recently I tried to use "jmap -histo" to collect histogram \
info on a large heap at ~200G bytes. it took about 160 seconds, which actually \
cause our online system suffering "non-responsive" issue. In \
addition, if we stop jmap with "kill", jmap exits directly (even the \
attached JVM still working on heap iteration), leave no help info for analysis.<br> \
<br> <br>
<br>
To address the issue above, I proposed following approaches:<br>
<br>
1) Extend Jmap to be parallel and incremental, which means Jmap iterates heap in \
parallel and save the intermediate results incrementally during heap scanning \
(controlled by threshold to decide when to dump).<br> <br>
2) Make Jmap to accept arguments that enable/disable parallel and partial heap \
iterating, also make parallel thread number configurable.<br> <br>
3) Make Jmap to dump results to specified file path given by argument, rather than \
output to stdout directly.<br> <br>
<br>
<br>
A prototype has been made internally with G1 upon JDK 11, and our \
preliminary measurement show that parallel iterate ~200GB heap with 4 threads can \
save ~30-40 seconds, and I am also analyzing the approach to make the time more \
scaled with parallel threads. Moreover, with the implementation of incremental \
dump, we can get usefully partial dump info for analyzing, even when jmap hang for a \
long time, or get killed for some reason.<br> <br>
<br>
<br>
Several problems were encountered during development. One problem is \
that it is not easy to dynamically allocate some data structures for thread local \
operations, such as KlassInfoTable,which is designed to be StackObj that not allowed \
to be allocated using "new", another problem is that some base classes \
definition in hotspot has to be modified to support parallel operations, such as \
ObjectClosure etc. I am not sure whether these modifications can be acceptable.<br> \
<br> <br>
<br>
Any suggestions/guidance would be much appreciated!<br>
<br>
<br>
<br>
BRs,<br>
<br>
Lin<br>
<br>
<o:p></o:p></span></p>
</blockquote>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic