RFR: 8258584: java/util/HexFormat/HexFormatTest.java fails on x86_32 [v2]

Roger Riggs rriggs at openjdk.java.net
Mon Dec 21 15:36:55 UTC 2020


On Sat, 19 Dec 2020 09:45:09 GMT, Jie Fu <jiefu at openjdk.org> wrote:

>> Hi all,
>> 
>> java/util/HexFormat/HexFormatTest.java fails on x86_32 due to '-Xmx4G'.
>> The reason is that -Xmx4G is invalid maximum heap size for 32-bit platforms.
>> The current implementation only supports maximum 3800M on 32-bit systems [1].
>> 
>> I've tried to reduce the -Xmx size, but it still fails even with -Xmx2G.
>> So this test seems to be brittle on 32-bit platforms since 2G is already larger than 3800M/2=1900M.
>> The fix just skips the test for 32-bit systems.
>> 
>> Thanks.
>> Best regards,
>> Jie
>> 
>> [1] https://github.com/openjdk/jdk/blob/master/src/hotspot/os/posix/os_posix.cpp#L567
>
> Jie Fu has updated the pull request incrementally with two additional commits since the last revision:
> 
>  - Ignore OOME for testOOME
>  - Revert the change

Completely ignoring the exception will leave no trace that the test was skipped or why.
Please retain the printing of the memory limits and instead of rethrowing the oome add:
 new SkipException("Insufficient Memory to test OOME");```
(It will need an import of org.testng.SkipException).
Throwing SkipException will flag the test as being skipped in the Jtreg summary.

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

Changes requested by rriggs (Reviewer).

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


More information about the core-libs-dev mailing list