[llvm] Add matchers m_ExtractSubvector and m_InsertSubvector (PR #120212)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 3 09:49:50 PST 2025


================
@@ -514,6 +514,12 @@ m_InsertElt(const T0_P &Vec, const T1_P &Val, const T2_P &Idx) {
                                             Idx);
 }
 
+template <typename LHS, typename RHS, typename IDX>
+inline TernaryOpc_match<LHS, RHS, IDX>
+m_InsertSubvector(const LHS &L, const RHS &R, const IDX &I) {
+  return TernaryOpc_match<LHS, RHS, IDX>(ISD::INSERT_SUBVECTOR, L, R, I);
+}
----------------
RKSimon wrote:

(pedantic) replace L, R and I with Base, Sub and Idx

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


More information about the llvm-commits mailing list