[jdk18] RFR: 8278489: Preserve result in native wrapper with +UseHeavyMonitors
David Holmes
dholmes at openjdk.java.net
Mon Dec 13 22:50:26 UTC 2021
On Mon, 13 Dec 2021 20:54:55 GMT, Roman Kennke <rkennke at openjdk.org> wrote:
> Testing observed a few failures after JDK-8276901. The reason for the failures is in the native-wrappers, in the +UseHeavyMonitors paths, we don't preserve the result register after the native call.
>
> Testing:
> - [x] java/awt/color, sun/java2d/cmm tests (x86_32, x86_64 x -UseHeavyMonitors, +UseHeavyMonitors)
> - [ ] tier1 (x86_32, x86_64 x -UseHeavyMonitors, +UseHeavyMonitors)
Not a review as not my area but saw some nits with the adjusted code.
David
src/hotspot/cpu/x86/sharedRuntime_x86_32.cpp line 1867:
> 1865: }
> 1866:
> 1867: // Must save rax, if if it is live now because cmpxchg must use it
Existing typo: if if
src/hotspot/cpu/x86/sharedRuntime_x86_32.cpp line 1870:
> 1868: if (ret_type != T_FLOAT && ret_type != T_DOUBLE && ret_type != T_VOID) {
> 1869: save_native_result(masm, ret_type, stack_slots);
> 1870: }
Indentation looks wrong
src/hotspot/cpu/x86/sharedRuntime_x86_64.cpp line 2069:
> 2067: }
> 2068:
> 2069: // Must save rax if if it is live now because cmpxchg must use it
existing typo: if if
-------------
PR: https://git.openjdk.java.net/jdk18/pull/16
More information about the hotspot-compiler-dev
mailing list