JDK-8202616 : [Graal] implement missing Unsafe intrinsics
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 10,11
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2018-05-03
  • Updated: 2023-07-21
  • Resolved: 2023-07-21
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11Resolved
Related Reports
Blocks :  
Duplicate :  
Relates :  
Description
   // should be easy to implement as we already have an implementation for int and long
  "jdk/internal/misc/Unsafe.getAndAddByte(Ljava/lang/Object;JB)B",
  "jdk/internal/misc/Unsafe.getAndAddShort(Ljava/lang/Object;JS)S",

  // should be easy to implement as we already have an implementation for int, long, and Object
  "jdk/internal/misc/Unsafe.getAndSetByte(Ljava/lang/Object;JB)B",
  "jdk/internal/misc/Unsafe.getAndSetShort(Ljava/lang/Object;JS)S",
  "jdk/internal/misc/Unsafe.compareAndSetByte(Ljava/lang/Object;JBB)Z",
  "jdk/internal/misc/Unsafe.compareAndSetShort(Ljava/lang/Object;JSS)Z",
                        
  // should be easy to implement as it seems to match the logic that is already
  // implemented in ValueCompareAndSwapNode. On the high-level, we would need
  // something similar to UnsafeCompareAndSwapNode but with a different result type
  "jdk/internal/misc/Unsafe.compareAndExchangeByte(Ljava/lang/Object;JBB)B",
  "jdk/internal/misc/Unsafe.compareAndExchangeInt(Ljava/lang/Object;JII)I",
  "jdk/internal/misc/Unsafe.compareAndExchangeLong(Ljava/lang/Object;JJJ)J",
  "jdk/internal/misc/Unsafe.compareAndExchangeObject(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;",
  "jdk/internal/misc/Unsafe.compareAndExchangeShort(Ljava/lang/Object;JSS)S",