RFR: JDK-8260282: Add option to compress heap dumps created by -XX:+HeapDumpOnOutOfMemoryError [v2]
Ralf Schmelter
rschmelter at openjdk.java.net
Mon Jan 25 20:52:06 UTC 2021
On Mon, 25 Jan 2021 19:15:56 GMT, Chris Plummer <cjplummer at openjdk.org> wrote:
>> Ralf Schmelter has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains six additional commits since the last revision:
>>
>> - Merge branch 'master' of https://github.com/openjdk/jdk into JDK-8260282
>> - Fixed maximum supported compression level.
>> - Fixed trailing whitespace.
>> - Merge branch 'master' of https://github.com/openjdk/jdk into JDK-8260282
>> - Change allowed levels. 0 now means disabled.#
>> - Added option to compress the heap dump created by -XX:+HeapDumpOnOutOfMemoryError
>
> src/hotspot/share/runtime/globals.hpp line 561:
>
>> 559: "level of the dump file. 0 (the default) disables gzip " \
>> 560: "compression. Otherwise the level must be between 1 and 10.") \
>> 561: range(0, 10) \
>
> Isn't the range 0-9? Although `HeapDumper::dump()` imposes no upper limit (it seems it should), the `HeapDumpDCMD` sets the upper limit to 9. See `HeapDumpDCmd::execute()`.
You're right. 9 is the maximum compression level supported by zlib. I will update the PR.
-------------
PR: https://git.openjdk.java.net/jdk/pull/2222
More information about the hotspot-runtime-dev
mailing list