RFR: 8313306: More sensible memory reservation logging [v12]

Martin Doerr mdoerr at openjdk.org
Tue Feb 20 17:19:56 UTC 2024


On Thu, 15 Feb 2024 14:18:17 GMT, Sonia Zaldana Calles <szaldana at openjdk.org> wrote:

>> This PR implements more specialized logs for virtual memory APIs in the “os” namespace. It uses “os” and “map” as log tags using unified JVM logging as introduced in JEP 158 (https://openjdk.org/jeps/158). 
>> 
>> As far as testing is concerned, I have added a regression test to verify the logging is working accordingly.
>
> Sonia Zaldana Calles has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Making functions one lines and refactoring assert

Do you need more than the System.err output?

 stdout: [[0.002s][debug][os,map] Reserved [0x00007fffb1960000 - 0x00007fffb1970000), (65536 bytes)
[0.002s][debug][os,map] Committed [0x00007fffb1960000 - 0x00007fffb1970000), (65536 bytes)
[0.004s][debug][os,map] Committed [0x00007fffaec10000 - 0x00007fffaec40000), (196608 bytes)
[0.005s][debug][os,map] Reserved [0x00007fff90a40000 - 0x00007fff9fa40000), (251658240 bytes)
[0.005s][debug][os,map] Committed [0x00007fff97e00000 - 0x00007fff98000000), (2097152 bytes)
[0.005s][debug][os,map] Reserved [0x00007fffae2c0000 - 0x00007fffae2e0000), (131072 bytes)
[0.005s][debug][os,map] Committed [0x00007fffae2c0000 - 0x00007fffae2d0000), (65536 bytes)
[0.005s][debug][os,map] Committed [0x00007fff90a40000 - 0x00007fff90c40000), (2097152 bytes)
[0.005s][debug][os,map] Reserved [0x00007fffae1d0000 - 0x00007fffae2c0000), (983040 bytes)
[0.005s][debug][os,map] Committed [0x00007fffae1d0000 - 0x00007fffae1e0000), (65536 bytes)
[0.006s][debug][os,map] Committed [0x00007fff98670000 - 0x00007fff98870000), (2097152 bytes)
[0.006s][debug][os,map] Reserved [0x00007fffae0e0000 - 0x00007fffae1d0000), (983040 bytes)
[0.006s][debug][os,map] Committed [0x00007fffae0e0000 - 0x00007fffae0f0000), (65536 bytes)
[0.019s][debug][os,map] Reserved [0x00000000fe000000 - 0x0000000100000000), (33554432 bytes)
[0.019s][debug][os,map] Reserved [0x00007fffaeba0000 - 0x00007fffaebb0000), (65536 bytes)
[0.019s][debug][os,map] Reserved [0x00007fffac0f0000 - 0x00007fffac100000), (65536 bytes)
[0.019s][debug][os,map] Reserved [0x00007fffac070000 - 0x00007fffac0f0000), (524288 bytes)
[0.019s][debug][os,map] Reserved [0x00007fffac060000 - 0x00007fffac070000), (65536 bytes)
[0.020s][debug][os,map] Reserved [0x00007fff8d640000 - 0x00007fff8f640000), (33554432 bytes)
[0.020s][debug][os,map] Committed [0x00007fff8d640000 - 0x00007fff8f640000), (33554432 bytes)
[0.035s][debug][os,map] Reserved [0x0000000800000000 - 0x0000000841000000), (1090519040 bytes)
[0.035s][debug][os,map] Released [0x0000000800000000 - 0x0000000841000000), (1090519040 bytes)
[0.035s][debug][os,map] reserve_between (range [0x0000000100000000-0x0001000000000000), size 0x41000000, alignment 0x100000000, randomize: 1)
[0.035s][trace][os,map] before reserve, 32 Points: 40 32120 1814 30964 2929 30001 3184 29643 4112 27899 5148 26897 6884 26456 7802 24834 8193 23633 9418 23061 10247 22165 11949 20547 12790 19711 14147 18647 14746 17802 15828 17381 
[0.035s][trace][os,map] result: 0x0000002900000000 range [0x0000000100000000-0x0001000000000000), size 0x41000000, alignment 0x100000000, randomize: 1
[0.035s][debug][os,map] successfully attached at 0x0000002900000000
[0.155s][debug][os,map] Committed [0x0000002901040000 - 0x0000002901050000), (65536 bytes)
[0.155s][debug][os,map] Reserved [0x00007fff6c000000 - 0x00007fff70000000), (67108864 bytes)
[0.155s][debug][os,map] Committed [0x00007fff6c000000 - 0x00007fff6c010000), (65536 bytes)
[0.194s][debug][os,map] Committed [0x00007fff7db40000 - 0x00007fff7db70000), (196608 bytes)
[0.195s][debug][os,map] Committed [0x00007fff7d940000 - 0x00007fff7d970000), (196608 bytes)
[0.196s][debug][os,map] Committed [0x00007fff7d740000 - 0x00007fff7d770000), (196608 bytes)
[0.196s][debug][os,map] Committed [0x00007fff7d540000 - 0x00007fff7d570000), (196608 bytes)
[0.196s][debug][os,map] Committed [0x00007fff7d340000 - 0x00007fff7d370000), (196608 bytes)
[0.196s][debug][os,map] Committed [0x00007fff7cf40000 - 0x00007fff7cf70000), (196608 bytes)
[0.197s][debug][os,map] Committed [0x00007fff7cb40000 - 0x00007fff7cb70000), (196608 bytes)
[0.234s][debug][os,map] Committed [0x00007fff7c940000 - 0x00007fff7c970000), (196608 bytes)
[0.245s][debug][os,map] Committed [0x00007fff6c010000 - 0x00007fff6c020000), (65536 bytes)
[0.246s][debug][os,map] Committed [0x00007fff7c740000 - 0x00007fff7c770000), (196608 bytes)
[0.252s][debug][os,map] Committed [0x00007fff6c400000 - 0x00007fff6c410000), (65536 bytes)
[0.252s][debug][os,map] Committed [0x0000002901000000 - 0x0000002901010000), (65536 bytes)
Tester execution...
[0.263s][debug][os,map] Committed [0x00007fff6c020000 - 0x00007fff6c030000), (65536 bytes)
[0.338s][debug][os,map] Committed [0x00007fff6c030000 - 0x00007fff6c040000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff7c340000 - 0x00007fff7c370000), (196608 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98000000 - 0x00007fff98010000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98010000 - 0x00007fff98020000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98020000 - 0x00007fff98030000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98030000 - 0x00007fff98040000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98040000 - 0x00007fff98050000), (65536 bytes)
[0.351s][debug][os,map] Committed [0x00007fff98050000 - 0x00007fff98060000), (65536 bytes)
[0.362s][debug][os,map] Committed [0x00007fff98060000 - 0x00007fff98070000), (65536 bytes)
[0.370s][debug][os,map] Reserved [0x00007fff7c330000 - 0x00007fff7c340000), (65536 bytes)
];

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

PR Comment: https://git.openjdk.org/jdk/pull/17356#issuecomment-1954681078


More information about the hotspot-runtime-dev mailing list