When running new test TestNestedRelockAtDeopt.java from JDK-8324174 with default flags, it exits early with OOM exception thrown:
> java -Xmx128m TestNestedRelockAtDeopt
OOM caught in test1
Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "main"
It is incorrect since the test should catch all OOM exception:
> java -Xmx128m -Xint TestNestedRelockAtDeopt
OOM caught in test1
OOM caught in test2
OOM caught in test3
OOM caught in test4
OOM could be thrown during deoptimization when scalarized object is re-allocated and re-locked. But we should handle such case gracefully after fix JDK-6898462.
Other JDK releases may be also affected but without JDK-8324174 fix it is hard to tell.