[vectorIntrinsics] RFR: Refactor JVM Interface
    Vladimir Ivanov 
    vladimir.x.ivanov at oracle.com
       
    Tue Mar 24 21:07:28 UTC 2020
    
    
  
http://cr.openjdk.java.net/~vlivanov/panama/vector/new_jvm_interface/webrev.00/
(First cleanup pass over the JVM implementation.
The focus is on JVM-JDK interface.)
New JVM interface is minimal and contains intrinsics, well-known 
classes, and opcode declarations. It resides in java.base 
(jdk.internal.vm.vector.VectorSupport) and exports the interface to 
jdk.incubator.vector module.
JVM doesn't need to know about typed vectors anymore: VectorPayload, 
VectorMask, and VectorShuffle are enough to represent all interesting 
cases and provide enough information to the JVM how to handle vector 
classes:
   - VectorPayload class represents vector values which are amenable to 
aggressive box elimination transformation
      * vector on-heap representation remains primitive array-backed;
      * classes which extend VectorPayload should declare 2 static 
fields (VLENGTH and ETYPE) which describe vector on-heap representation 
to the JVM (array length and its element type);
   - VectorShuffle and VectorMask mark vector shuffles and masks for the 
JVM;
   - VectorSpecies and Vector are there to enhance type checking of JVM 
intrinsic usages;
Also, additional refactorings/fixes:
   * merged reinterpret and cast intrinsics into one (convert)
   * refactored rematerialization support
   * don't remove unused VectorBoxAllocate nodes, but replace them with 
safepoints
   * VM vector support is turned off by default, but automatically 
enabled when user adds jdk.incubator.vector incubator module to the graph
   * multiple minor fixes and cleanups along the way
Testing: jdk/incubator/vector tests
Best regards,
Vladimir Ivanov
    
    
More information about the panama-dev
mailing list