[clang] [llvm] [AArch64] Implement STNP/LDNP intrinsics (PR #238416)

Kieran B via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 10 02:11:35 PST 2026


================
@@ -4877,6 +4890,19 @@ defm STNPD : StorePairNoAlloc<0b01, 1, FPR64Op, simm7s8, "stnp">;
 defm STNPQ : StorePairNoAlloc<0b10, 1, FPR128Op, simm7s16, "stnp">;
 }
 
+multiclass STNPQStoreIntrinsic<ValueType VecTy> {
+    def : Pat<(int_aarch64_neon_vstnq_x2 (VecTy FPR128:$Rt1), (VecTy FPR128:$Rt2), GPR64sp:$Rn),
+              (STNPQi FPR128:$Rt1, FPR128:$Rt2, GPR64sp:$Rn, 0)>;
+}
+defm : STNPQStoreIntrinsic<v16i8>;
+defm : STNPQStoreIntrinsic<v8i16>;
+defm : STNPQStoreIntrinsic<v4i32>;
+defm : STNPQStoreIntrinsic<v2i64>;
+defm : STNPQStoreIntrinsic<v8f16>;
+defm : STNPQStoreIntrinsic<v8bf16>;
+defm : STNPQStoreIntrinsic<v4f32>;
+defm : STNPQStoreIntrinsic<v2f64>;
----------------
kieroxide wrote:

I have added the loops but I think keeping them separate makes sense as the store is in the store section of the file and vice verse :+1: 

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


More information about the cfe-commits mailing list