1; Test that this test case does not abort after the folding of load -> add -> 2; store into an alsi. This folding is suppose to not happen as it would 3; introduce a loop in the DAG. 4; 5; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 -disable-basicaa -consthoist-gep | FileCheck %s 6 7@g_295 = external dso_local unnamed_addr global i32, align 4 8@g_672 = external dso_local unnamed_addr global i64, align 8 9@g_1484 = external dso_local global <{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, align 2 10 11define void @fun() { 12; CHECK-LABEL: fun: 13 14bb: 15 br label %bb1 16 17bb1: ; preds = %bb1, %bb 18 store i32 2, i32* getelementptr inbounds (<{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, <{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>* @g_1484, i64 0, i32 2, i32 16) 19 %tmp = icmp slt i32 undef, 3 20 br i1 %tmp, label %bb1, label %bb2 21 22bb2: ; preds = %bb1 23 %tmp3 = load i32, i32* getelementptr inbounds (<{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>, <{ i8, i64, { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, [2 x i8], i8, i8, i8, i8, i8, i8, i8, i8, i32, i8, i8, i8 }, i32 }>* @g_1484, i64 0, i32 2, i32 28) 24 %tmp4 = load i64, i64* @g_672 25 %tmp5 = add i64 %tmp4, 1 26 store i64 %tmp5, i64* @g_672 27 %tmp6 = icmp eq i64 %tmp5, 0 28 %tmp7 = zext i1 %tmp6 to i32 29 %tmp8 = icmp ult i32 %tmp3, %tmp7 30 %tmp9 = zext i1 %tmp8 to i32 31 store i32 %tmp9, i32* @g_295 32 ret void 33} 34 35