-
Notifications
You must be signed in to change notification settings - Fork 728
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Accelerate Unsafe CAS Intrinsics on Power and X
Adds support for the following recognized methods: CompareAndExchangeObject //JDK11 CompareAndExchangeReference //JDK17,21 CompareAndExchangeInt //JDK11,17,21 CompareAndExchangeLong //JDK11,17,21 Similar to their CompareAndSet counterparts, the JIT acceleration does not support CAE on static fields so the createUnsafeCASCallDiamond function was updated to also work on the CAE methods. The accelerated CAE code was built on top of the existing accelerated CAS support on both Power and X. Removed recognized CAS enums from isUnsafePut. They are not Unsafe put methods and these cases could not be triggered. Even before my changes, setting TR_UseOldCompareAndSwapObject and TR_DisableCASInlining would cause a crash on x. It doesn't really make sense to set both at the same time but I fixed it anyways since it was quick. VMwrtbarWithoutStoreEvaluator is used for several different opcdes include arraycopy, ArrayStoreCHK, writeBarrier and Unsafe CAS calls. This is only used for the Unsafe CAS calls that store an object. To differtiate Unsafe CAS calls from the other cases, there is a check for the node being an icall. This check is no longer valid with the introduction of support for compareAndExchangeReference. The node in this case is an acall. This changes the check to a generic call check. There is also a check for the call being to a recognized method. This check now checks for specific recognized methods which are: sun_misc_Unsafe_compareAndSwapObject_jlObjectJjlObjectjlObject_Z jdk_internal_misc_Unsafe_compareAndExchangeObject jdk_internal_misc_Unsafe_compareAndExchangeReference Signed-off-by: jimmyk <[email protected]>
- Loading branch information
Showing
6 changed files
with
405 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.