track native memory with JCMD
Use jcmd
to track native memory:
- launch app with the following flag:
-XX:NativeMemoryTracking=detail
- fetch the process PID
- launch
jcmd
:jcmd 202553 VM.native_memory baseline
- to compare the memory allocation with the current
baseline
:jcmd 20553 VM.native_memory summary.diff