[llvm] [AArch64] Add @llvm.experimental.vector.match (PR #101974)

Ricardo Jesus via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 27 08:55:29 PDT 2024


================
@@ -1892,6 +1892,16 @@ def int_experimental_vector_histogram_add : DefaultAttrsIntrinsic<[],
                                LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], // Mask
                              [ IntrArgMemOnly ]>;
 
+// Experimental match
+def int_experimental_vector_match : DefaultAttrsIntrinsic<
+                             [ LLVMScalarOrSameVectorWidth<0, llvm_i1_ty> ],
+                             [ llvm_anyvector_ty,
+                               LLVMMatchType<0>,
+                               LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>,  // Mask
+                               llvm_i32_ty ],  // Segment size
----------------
rj-jesus wrote:

>It's hard to know how we'd generate code for a symbolic value.

Exactly, that was precisely my logic. Unless the hardware supports it, generating code for a symbolic segsize sounds like a hairy problem. I thought we could make it an immediate for now, and later lift the restriction if needed. What do you think?

https://github.com/llvm/llvm-project/pull/101974


More information about the llvm-commits mailing list