-
Enhancement
-
Resolution: Fixed
-
P4
-
repo-panama
-
generic
-
generic
Some of the VectorAPIs were inconsistent with their intrinsic declarations, and some of the type arguments were not precise enough as well. E.g.,
The return type of "unaryOp" should be a subtype of "Vector" instead of an all-purpose "Object" [1][2].
The imprecise declarations and type arguments would not effect the correctness but bring bad readability and make the code hard to maintain. This patch is a cleanup for those mismatched declarations of VectorAPIs.
[1]https://github.com/openjdk/panama-vector/blob/vectorIntrinsics%2Bmask/src/java.base/share/classes/jdk/internal/vm/vector/VectorSupport.java#L269
[2] https://github.com/openjdk/panama-vector/blob/vectorIntrinsics%2Bmask/src/hotspot/share/classfile/vmIntrinsics.hpp#L812
Ref: https://github.com/openjdk/panama-vector/pull/97#discussion_r672672011
The return type of "unaryOp" should be a subtype of "Vector" instead of an all-purpose "Object" [1][2].
The imprecise declarations and type arguments would not effect the correctness but bring bad readability and make the code hard to maintain. This patch is a cleanup for those mismatched declarations of VectorAPIs.
[1]https://github.com/openjdk/panama-vector/blob/vectorIntrinsics%2Bmask/src/java.base/share/classes/jdk/internal/vm/vector/VectorSupport.java#L269
[2] https://github.com/openjdk/panama-vector/blob/vectorIntrinsics%2Bmask/src/hotspot/share/classfile/vmIntrinsics.hpp#L812
Ref: https://github.com/openjdk/panama-vector/pull/97#discussion_r672672011