RFR: 8266807: Windows os_windows-gtest broken for UseLargePages [v3]

Albert Mingkun Yang ayang at openjdk.java.net
Fri May 28 12:56:08 UTC 2021


On Fri, 28 May 2021 12:46:29 GMT, Stefan Johansson <sjohanss at openjdk.org> wrote:

>> Please review this change to fix the large page testing on Windows.
>> 
>> **Summary**
>> The comparisons in the test check for reservations `!= NULL` and consider that a failed reservation, that is incorrect. This leads to the test never really doing anything. When `UseLargePages` is false, the test is skipped and when true and the user is configured with lock permissions (needed to use large pages), the test is skipped after the first allocation (since it is wrongly seen as a failure).
>> 
>> When a user doesn't have permissions to lock memory, the JVM will turn off large pages so this will be the same as running with `-UseLargePages`. 
>> 
>> The test has been changed to skip testing if the first large page reservation fail, similar to what was intended before. After that the rest of the reservations are expected to pass, apart from the reservation trying to reserve in an already existing reservation.
>> 
>> **Testing**
>> Manual testing on a Windows host with and without large pages enabled. Also tested through mach5.
>
> Stefan Johansson has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Albert review. Harden test to not allow failure for request address

Preexisting: there are two early returns (`!UseLargePages` and `result == NULL`), which could make the test pass without testing anything. I think this is problematic and should be addressed.

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

Marked as reviewed by ayang (Committer).

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


More information about the hotspot-runtime-dev mailing list