The native thread cannot directly reference the Access object, so the entire native thread is a GC security Zone (GC safe region), and the native thread can continue execution when the GC occurs.
However, once the native thread invokes the VM interface, the native thread needs to switch state and switch to non-GC security.
For example, invoking the Java JNI interface, the native thread first attempts to switch to the runable state. When switching, check whether the GC has occurred. If it is already in GC, wait for GC to finish, if there is no GC, successfully switched to runable state, blocking GC.
When the call ends, the native thread switches back from the runable state to the native state, returning to the GC security point.
So the native thread (non-VM interface call state) does not respond to the GC and is not blocked by the GC.
The native thread enters the VM interface call, blocking each other from the GC.
GC Note--native thread