[llvm] [AArch64][GlobalISel] Prefer to use Vector Truncate (PR #105692)

Thorsten Schütt via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 22 22:31:14 PDT 2024


================
@@ -1599,6 +1599,13 @@ def insert_vector_elt_oob : GICombineRule<
          [{ return Helper.matchInsertVectorElementOOB(*${root}, ${matchinfo}); }]),
   (apply [{ Helper.applyBuildFn(*${root}, ${matchinfo}); }])>;
 
+// Combine v8i8 (buildvector i8 (trunc(unmerge)), i8 (trunc), i8 (trunc), i8 (trunc), undef, undef, undef, undef)
+def combine_use_vector_truncate : GICombineRule<
+  (defs root:$root, register_matchinfo:$matchinfo),
+  (match (wip_match_opcode G_BUILD_VECTOR):$root,
----------------
tschuett wrote:

Why did you `wip_match_opcode G_BUILD_VECTOR`when there is no build vector in your summary?

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


More information about the llvm-commits mailing list