RFR: 8245446: vmTestbase/nsk/jvmti/RedefineClasses/StressRedefine/TestDescription.java crash intermittently

Leonid Mesnik lmesnik at openjdk.java.net
Tue Dec 8 21:21:38 UTC 2020


On Tue, 8 Dec 2020 09:53:36 GMT, Serguei Spitsyn <sspitsyn at openjdk.org> wrote:

> The StressRedefine.java (base for redefine stress tests) defines 3 important constants:
>     private static int staticMethodCallersNumber = 10;
>     private static int nonstaticMethodCallersNumber = 10;
>     private static int redefiningThreadsNumber = 40;
> 
> The 1st is number of threads to call a static method from constantly redefined class.
> The 2nd is number of threads to call am instance method from constantly redefined class.
> The 3rd is number of threads to redefine the target class.
> The redefiningThreadsNumber=40 is unreasonably big for the StressRedefine test, and there is no chance with -Xcomp  for one of the methods above to get resolved without a class redefinition. So, after 100 of non-successfull attempts we hit the guarantee in the open/src/hotspot/share/interpreter/interpreterRuntime.cpp:879
>   guarantee((retry_count++ < 100)) failed: Could not resolve to latest version of redefined method 
> To avoid it, the test StressRedefine/TestDescription.java is tweaked to have redefiningThreadsNumber=4.
> 
> The test StressRedefineWithoutBytecodeCorruption is worse as it fails even with redefiningThreadsNumber=1. So, a require is added to exclude the test with the -Xcomp flag.

looks good.

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

Marked as reviewed by lmesnik (Committer).

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


More information about the serviceability-dev mailing list