[llvm] [LegalizeDAG] Freeze index when converting insert_elt/insert_subvector to load/store on stack. (PR #86850)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 27 11:48:10 PDT 2024
================
@@ -123,9 +123,10 @@ define void @insert_32xi8_idx(ptr %src, ptr %dst, i8 %in, i32 %idx) nounwind {
; CHECK-NEXT: bstrins.d $sp, $zero, 4, 0
; CHECK-NEXT: xvld $xr0, $a0, 0
; CHECK-NEXT: xvst $xr0, $sp, 0
-; CHECK-NEXT: addi.d $a0, $sp, 0
-; CHECK-NEXT: bstrins.d $a0, $a3, 4, 0
-; CHECK-NEXT: st.b $a2, $a0, 0
+; CHECK-NEXT: bstrpick.d $a0, $a3, 31, 0
+; CHECK-NEXT: addi.d $a3, $sp, 0
+; CHECK-NEXT: bstrins.d $a3, $a0, 4, 0
----------------
topperc wrote:
This could probably be fixed by adding SimplifyDemandedBitsForTargetNode support for bstrins and bstrpick.
https://github.com/llvm/llvm-project/pull/86850
More information about the llvm-commits
mailing list