RFR: JDK-8318636: Add jcmd to print annotated process memory map [v6]

Johan Sjölen jsjolen at openjdk.org
Wed Nov 1 10:12:06 UTC 2023


On Wed, 1 Nov 2023 09:52:24 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

>> src/hotspot/share/nmt/memMapPrinter.cpp line 99:
>> 
>>> 97:   }
>>> 98: 
>>> 99:   bool add(const void* from, const void* to, MEMFLAGS f) {
>> 
>> Please mention that we're `add`ing in sorted order, that is that `forall R \in _ranges: R.to <= from` holds.
>
> I wasn't sure about that. Do we always? Are NMT regions guaranteed to be sorted? (Dimly remember cases where that weren't so)

It's always sorted in some way, we save the linked lists in some different sorting orders for baselining, but in the `VirtualMemoryTracker` they're guaranteed to be sorted by address.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/16301#discussion_r1378609954


More information about the serviceability-dev mailing list