RFR: 8263670: pmap and pstack in jhsdb do not work on debug server [v2]
Serguei Spitsyn
sspitsyn at openjdk.java.net
Tue Mar 23 02:20:42 UTC 2021
On Thu, 18 Mar 2021 05:17:10 GMT, Yasumasa Suenaga <ysuenaga at openjdk.org> wrote:
>> jhsdb supports pmap (jhsdb jmap) and pstack (jhsdb jstack --mixed), and they work fine if they attach to live process or to coredump, however they do not work on debug server as following:
>>
>> $ jhsdb jmap --connect localhost
>> Attaching to remote server localhost, please wait...
>> Debugger attached successfully.
>> Server compiler detected.
>> JVM version is 11.0.10+9
>> remote configuration is not yet implemented
>>
>> pmap and pstack depend on CDebugger in SA, however it would not be set in case of remote debugger client. We can avoid it if we can delegate the process to debug server.
>
> Yasumasa Suenaga has updated the pull request incrementally with one additional commit since the last revision:
>
> Update testcases
Hi Yasumasa,
The fix looks good. I've added one nit.
Thanks,
Serguei
src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/tools/PMap.java line 81:
> 79: } else {
> 80: if (getDebugeeType() == DEBUGEE_REMOTE) {
> 81: out.print(((RemoteDebuggerClient)dbg).execCommandOnServer("pmap", null));
Nit: Indent is incorrect now.
-------------
Marked as reviewed by sspitsyn (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/3027
More information about the serviceability-dev
mailing list