[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-hotspot-runtime-dev
Subject:    Re: RFR: 8290482: Update JNI Specification of DestroyJavaVM for better alignment with JLS, JVMS, and
From:       David Holmes <dholmes () openjdk ! org>
Date:       2022-09-27 23:46:15
Message-ID: TGc8WDnb4FDB6zNgjsouj9SM1CYk8_7rlEoEmpZF3fg=.5fa04872-0da5-4f0b-9289-9b829947e7c1 () github ! com
[Download RAW message or body]

On Tue, 20 Sep 2022 10:37:41 GMT, David Holmes <dholmes@openjdk.org> wrote:

> > This update is primarily about changes to the JNI Invocation API specification, \
> > mainly in relation to `DestroyJavaVM`. The motivation for the changes is to align \
> > with changes being made to the JLS, JVMS and `java.lang.Runtime`, specifications \
> > in relation to VM termination - ref: 
> > JDK-8290196 12.8: Clarify the definition of program exit
> > https://bugs.openjdk.org/browse/JDK-8290196
> > 
> > JDK-8290388 5.7: Clarify the definition of JVM termination
> > https://bugs.openjdk.org/browse/JDK-8290388
> > 
> > JDK-8290036 Define and specify Runtime shutdown sequence
> > https://bugs.openjdk.org/browse/JDK-8290036
> > 
> > Mostly these are just non-normative changes to the JNI spec prose but there are \
> > two actual specification changes: 
> > 1.  The fact it is an error to detach a thread with active Java frames was only \
> > mentioned in the overview section, not in the actual `DetachCurrentThread` \
> > specification. (Just an oversight - the VM already checked this) 
> > 2.  We need to make it an error to call `DestroyJavaVM` from an attached thread \
> > with active Java frames (as this can't work for the same reason we disallow \
> > `DetachCurrentThread`). This requires an implementation change in Hotspot. 
> > Issue 2 covers the code change, and regression test, in this PR.
> > 
> > In addition the specification changes can be seen here:
> > 
> > - specdiff: http://cr.openjdk.java.net/~dholmes/8290482/8290482-jni-spec/diff.html
> >                 
> > - original: http://cr.openjdk.java.net/~dholmes/8290482/8290482-jni-spec/jni-invocation-original.html
> >                 
> > - new: http://cr.openjdk.java.net/~dholmes/8290482/8290482-jni-spec/jni-invocation-new.html
> >  
> > The specification itself is not open but comments on the spec changes are welcome \
> > - though please see the JBS issue and CSR request first. The revised wording has \
> > already been extensively reviewed/negotiated between Alex Buckley, Stuart Marks \
> > and myself, so any change must either be a glaring error/problem or else a \
> > trivial adjustment. 
> > Thank you.
> 
> David Holmes has updated the pull request incrementally with one additional commit \
> since the last revision: 
> Fix JniVersion test

CSR is now approved.

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

PR: https://git.openjdk.org/jdk/pull/10352


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic