[9] RFR(S): 8166046: [TESTBUG] compiler/stringopts/TestStringObjectInitialization.java fails with OOME

Vladimir Kozlov vladimir.kozlov at oracle.com
Mon Sep 19 17:32:05 UTC 2016


Should we scale down compilation threshold too? The test verifies C2 optimization we need to make sure that we still 
catch original JDK-8159244 problem.

Thanks,
Vladimir

On 9/19/16 5:15 AM, Tobias Hartmann wrote:
> Hi,
>
> please review the following patch:
> https://bugs.openjdk.java.net/browse/JDK-8166046
> http://cr.openjdk.java.net/~thartmann/8166046/webrev.00/
>
> The test creates 101 threads that each execute a loop with 10.000 iterations that append to a String another String of size 17. This results in a String of size 101 * 10.000 * 17 = 17.170.000 ( = 35 MB). In the failing cases, the test is executed on 32-bit Windows with -Xcomp and -XX:+DeoptimizeALot which increase memory consumption of the VM due to extensive (re-)compilation, deoptimization and re-allocation. The test fails because there is not enough heap space to hold the String.
>
> I reduced the number of threads to 32+1 and the number of per-thread iterations to 1000. I verified that this fixes the OOMEs on the failing 32-bit Windows machines.
>
> Thanks,
> Tobias
>


More information about the hotspot-compiler-dev mailing list