RFR: 8265393: VM crashes if both -XX:+RecordDynamicDumpInfo and -XX:SharedArchiveFile options are specified [v3]

Yumin Qi minqi at openjdk.java.net
Thu Apr 22 18:44:54 UTC 2021


> Hi, Please review
>   1) When the two flags -XX:+RecordDynamicDumpInfo and -XX:SharedArchiveFile used,  in
>      Arguments::init_shared_archive_paths() :
>           if (DynamicDumpSharedSpaces) {
>             if (os::same_files(SharedArchiveFile, ArchiveClassesAtExit)) {
>                ...
>   ArchiveClassesAtExit is NULL.
>   C++ does not have a defined behavior of strcmp with strings of NULL. Posix version of os::same_files(const char* file1, const char* file2) calls strcmp without checking input args. This should be same as it is treated on Windows.
>   2) JCmdTest.java is fat and possible to cause test timeout. Split JCmdTest.java into two separate Tests: JCmdTestStaticDump.java and JCmdTestDynamicDump.java.
>   3) Add a test to check run with -XX:+RecordDynamicDumpInfo and -XX:SharedArchiveFile in JCmdTestDynamicDump.java
>        The test does not use utility to create jvm process  since it will take testing envs into process, but the way in the test using LingeredApp does not take envs.
> 
>   Tests: tier1,tier2,tier3,tier4
> 
> Thanks
> Yumin

Yumin Qi has updated the pull request incrementally with one additional commit since the last revision:

  Remove extra imports, fix nits to review comments

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/3599/files
  - new: https://git.openjdk.java.net/jdk/pull/3599/files/ae4b3690..489134c4

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=3599&range=02
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=3599&range=01-02

  Stats: 47 lines in 3 files changed: 7 ins; 36 del; 4 mod
  Patch: https://git.openjdk.java.net/jdk/pull/3599.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/3599/head:pull/3599

PR: https://git.openjdk.java.net/jdk/pull/3599


More information about the hotspot-dev mailing list