RFR: 8317453: NMT: Performance benchmarks are needed to measure speed and memory [v10]

Johan Sjölen jsjolen at openjdk.org
Tue May 20 08:58:54 UTC 2025


On Wed, 7 May 2025 15:24:13 GMT, Gerard Ziemski <gziemski at openjdk.org> wrote:

>> src/hotspot/share/nmt/memLogRecorder.hpp line 136:
>> 
>>> 134:     address stack[NMT_TrackingStackDepth];
>>> 135:     long int mem_tag;
>>> 136:     long int mem_tag_split;
>> 
>> Use MemTag? Why `long int`?
>
> I think I was more comfortable with explicit types, since they are the struct that gets written to the disk, I wanted to know exactly how they are going to be laid out on a disk to make it easier to parse the data while debugging.
> 
> Can this stay as is?

OK, but if you're laying out the data as is then it'll differ depending on if the recording is done on a little-endian or big-endian machine. I also don't know whether `long int` is a good idea to use here, as it'll compile as a 32-bit int on Windows and a 64-bit int on Linux and Mac (see LLP64 vs LP64). We will not get recordings that you can run on different machines with this scheme.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23786#discussion_r2097410512


More information about the hotspot-dev mailing list