[jdk8u-dev] RFR: 8067941: [TESTBUG] Fix tests for OS with 64K page size. [v2]

Andrew John Hughes andrew at openjdk.org
Fri Aug 26 15:23:08 UTC 2022


On Thu, 30 Jun 2022 03:36:49 GMT, Dongbo He <dongbohe at openjdk.org> wrote:

>> Hi,
>> 
>> I would like to backport this patch to fix tests for OS with 64K page size.
>> Patch does not apply cleanly: 
>> JDK-8062854[1] move StackOverflowBug.java and Test8009761.java to corresponding subfolders.
>> Test8009761.java context is different because JDK-8021775[2] and JDK-8011397[3] doesn't in jdk8u.
>> Change to TestGCLogMessages.java is excluded because it was added in JDK-8027962[4].
>> Chnage to WBStackSize.java is excluded because JDK-8032970[5] does not exist in 8.
>> 
>> I changed Xss in StackOverflowBug.java, Test8009761.java, TestRecursiveReplacedException.java, 
>> StackOverflowGuardPagesOff.java, TestStackBangMonitorOwned.java and TestStackBangRbp.java from
>> 392k to 512k according to JDK-8159335[6], because JDK-8173339[7] changed StackShadowPages to 20, xss needs at least 456k.
>> 
>> Testing: Performed full jtreg test aarch64-linux-gnu platforms with 64k page size.
>> Checked that StackOverflowBug.java, Test8009761.java, TestRecursiveReplacedException.java,
>> StackOverflowGuardPagesOff.java, TestStackBangMonitorOwned.java, TestStackBangRbp.java,
>> TestHumongousAllocInitialMark.java, TestCMSHeapSizeFlags.java, TestG1HeapSizeFlags.java,
>> TestParallelHeapSizeFlags.java, TestSerialHeapSizeFlags.java fails without the patch
>> and passes with the patch on Aarch64 with 64K page size.
>> 
>> 
>> [1] https://bugs.openjdk.java.net/browse/JDK-8062854
>> [2] https://bugs.openjdk.java.net/browse/JDK-8021775
>> [3] https://bugs.openjdk.java.net/browse/JDK-8011397
>> [4] https://bugs.openjdk.java.net/browse/JDK-8027962
>> [5] https://bugs.openjdk.java.net/browse/JDK-8032970
>> [6] https://bugs.openjdk.java.net/browse/JDK-8159335
>> [7] https://bugs.openjdk.java.net/browse/JDK-8173339
>
> Dongbo He 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 two additional commits since the last revision:
> 
>  - Merge branch '8173339' into 8067941
>  - Backport 8e2df5f543522866e7c27ff95ea6fb6458393682

Changes make sense to me, given the bump to AArch64 stack sizes in JDK-8173339

I assume this doesn't affect other architectures, as we don't have JDK-8159335 which bumped the stack sizes on ppc64?

8u now:
~~~
$ grep -r 'StackShadowPages' hotspot/|grep pd_global
hotspot/src/cpu/aarch64/vm/globals_aarch64.hpp:define_pd_global(intx, StackShadowPages, 20 DEBUG_ONLY(+5));
hotspot/src/cpu/sparc/vm/globals_sparc.hpp:define_pd_global(intx, StackShadowPages, 10 DEBUG_ONLY(+1));
hotspot/src/cpu/sparc/vm/globals_sparc.hpp:define_pd_global(intx, StackShadowPages, 3 DEBUG_ONLY(+1));
hotspot/src/cpu/x86/vm/globals_x86.hpp:define_pd_global(intx, StackShadowPages, NOT_WIN64(20) WIN64_ONLY(6) DEBUG_ONLY(+2));
hotspot/src/cpu/x86/vm/globals_x86.hpp:define_pd_global(intx, StackShadowPages, 4 DEBUG_ONLY(+5));
hotspot/src/cpu/zero/vm/globals_zero.hpp:define_pd_global(intx,  StackShadowPages,     5 LP64_ONLY(+1) DEBUG_ONLY(+3));
hotspot/src/os_cpu/aix_ppc/vm/globals_aix_ppc.hpp:define_pd_global(intx, StackShadowPages,         6 DEBUG_ONLY(+2));
hotspot/src/os_cpu/linux_ppc/vm/globals_linux_ppc.hpp:define_pd_global(intx, StackShadowPages,         6 DEBUG_ONLY(+2));
~~~

11u now:
~~~
$ grep -r 'define DEFAULT_STACK_SHADOW_PAGES' ../jdk11u-dev/src/hotspot
../jdk11u-dev/src/hotspot/cpu/x86/globals_x86.hpp:#define DEFAULT_STACK_SHADOW_PAGES (NOT_WIN64(20) WIN64_ONLY(7) DEBUG_ONLY(+2))
../jdk11u-dev/src/hotspot/cpu/x86/globals_x86.hpp:#define DEFAULT_STACK_SHADOW_PAGES (4 DEBUG_ONLY(+5))
../jdk11u-dev/src/hotspot/cpu/aarch64/globals_aarch64.hpp:#define DEFAULT_STACK_SHADOW_PAGES (20 DEBUG_ONLY(+5))
../jdk11u-dev/src/hotspot/cpu/arm/globals_arm.hpp:#define DEFAULT_STACK_SHADOW_PAGES (5 DEBUG_ONLY(+1))
../jdk11u-dev/src/hotspot/cpu/ppc/globals_ppc.hpp:#define DEFAULT_STACK_SHADOW_PAGES (20 DEBUG_ONLY(+2))
../jdk11u-dev/src/hotspot/cpu/s390/globals_s390.hpp:#define DEFAULT_STACK_SHADOW_PAGES   (20 DEBUG_ONLY(+4))
../jdk11u-dev/src/hotspot/cpu/sparc/globals_sparc.hpp:#define DEFAULT_STACK_SHADOW_PAGES (20 DEBUG_ONLY(+2))
../jdk11u-dev/src/hotspot/cpu/zero/globals_zero.hpp:#define DEFAULT_STACK_SHADOW_PAGES (5 LP64_ONLY(+1) DEBUG_ONLY(+3))
~~~

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

Marked as reviewed by andrew (Reviewer).

PR: https://git.openjdk.org/jdk8u-dev/pull/71


More information about the jdk8u-dev mailing list