RFR: 8254799: runtime/ErrorHandling/TestHeapDumpOnOutOfMemoryError.java fails with release VMs

Yumin Qi minqi at openjdk.java.net
Thu Oct 15 00:36:13 UTC 2020


On Thu, 15 Oct 2020 00:16:38 GMT, David Holmes <dholmes at openjdk.org> wrote:

>> runtime/ErrorHandling/TestHeapDumpOnOutOfMemoryError.java and
>> runtime/ErrorHandling/TestHeapDumpOnOutOfMemoryErrorInMetaspace.java fail with release VMs due to VerifyDependencies is
>> develop and is available only in debug version of VM.
>> -XX:+IgnoreUnrecognizedVMOptions is added to fix it.
>
> Looks good and trivial.
> Thanks for fixing.
> 
> David

> _Mailing list message from [David Holmes](mailto:david.holmes at oracle.com) on
> [hotspot-runtime-dev](mailto:hotspot-runtime-dev at openjdk.java.net):_
> Hi Yumin,
> 
> On 15/10/2020 10:16 am, Yumin Qi wrote:
> 
> > On Wed, 14 Oct 2020 23:45:52 GMT, Jie Fu <jiefu at openjdk.org> wrote:
> > > runtime/ErrorHandling/TestHeapDumpOnOutOfMemoryError.java and
> > > runtime/ErrorHandling/TestHeapDumpOnOutOfMemoryErrorInMetaspace.java fail with release VMs due to VerifyDependencies is
> > > develop and is available only in debug version of VM.
> > > -XX:+IgnoreUnrecognizedVMOptions is added to fix it.
> > 
> > 
> > For test using debug version, please use "@requires vm.debug" in test.
> 
> I disagree with that approach. The test is run for any release and this
> is exec'ing the JVM directly so not controlled by an @test directive
> directly. You would have to have two versions of the Java code to run on
> release or debug VMs.
> 
> What Jie has done seems the best solution to me - a logical equivalent of
> 
> DEBUG_ONLY(-XX:-VerifyDependencies)
> 
> Cheers,
> David

The original fix has problem, don't know how it went through test! Disabling this flag is to reduce run time in debug.
I am OK with the workaround though it looks strange.

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

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


More information about the hotspot-runtime-dev mailing list