RFR: 8257234 : Add gz option to SA jmap to write a gzipped heap dump [v7]
Lin Zang
lzang at openjdk.java.net
Fri Jan 22 07:10:11 UTC 2021
On Tue, 19 Jan 2021 21:35:16 GMT, Chris Plummer <cjplummer at openjdk.org> wrote:
>> Lin Zang has updated the pull request incrementally with one additional commit since the last revision:
>>
>> fix issue of setting gz option with no value
>
> src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java line 475:
>
>> 473: if (!useSegmentedHeapDump) {
>> 474: // Fill in final length
>> 475: fillInHeapRecordLength();
>
> It's unclear to me why this code is now conditional on not using a segmented heap dump.
Hi Chris,
Thanks for review. The original implementation of heap dump (when not using segments) is to treat all HPROF_HEAP_DUMP section as a whole segment and fill the size after the data are ready to be flush.
As specified at link: http://hg.openjdk.java.net/jdk6/jdk6/jdk/raw-file/tip/src/share/demo/jvmti/hprof/manual.html#mozTocId848088 .
so here if it is not segmented heap dump, it still need call fillInHeapRecordLength() to fill the size slot before data flush.
-------------
PR: https://git.openjdk.java.net/jdk/pull/1712
More information about the serviceability-dev
mailing list