[llvm] [Clang][Codegen] fix vector data by modifying VMVN (PR #105913)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 23 18:49:35 PDT 2024


https://github.com/Zhenhang1213 created https://github.com/llvm/llvm-project/pull/105913

None

>From f6eee4704e31ac05c027cad4017af6f8b3846377 Mon Sep 17 00:00:00 2001
From: Austin <zhenhangwang at huawei.com>
Date: Sat, 24 Aug 2024 09:48:20 +0800
Subject: [PATCH] [Clang][Codegen] fix vector data by modifying  VMVN

---
 llvm/lib/Target/ARM/ARMISelLowering.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/lib/Target/ARM/ARMISelLowering.cpp b/llvm/lib/Target/ARM/ARMISelLowering.cpp
index 1e8bb8a495e68b..96e4cbb26a5a7b 100644
--- a/llvm/lib/Target/ARM/ARMISelLowering.cpp
+++ b/llvm/lib/Target/ARM/ARMISelLowering.cpp
@@ -7976,7 +7976,7 @@ SDValue ARMTargetLowering::LowerBUILD_VECTOR(SDValue Op, SelectionDAG &DAG,
           VT, ST->hasMVEIntegerOps() ? MVEVMVNModImm : VMVNModImm);
       if (Val.getNode()) {
         SDValue Vmov = DAG.getNode(ARMISD::VMVNIMM, dl, VmovVT, Val);
-        return DAG.getNode(ISD::BITCAST, dl, VT, Vmov);
+        return DAG.getNode(ARMISD::VECTOR_REG_CAST, dl, VT, Vmov);
       }
 
       // Use vmov.f32 to materialize other v2f32 and v4f32 splats.



More information about the llvm-commits mailing list