1; RUN: llc < %s -mtriple aarch64 -mcpu=falkor -disable-post-ra | FileCheck %s 2 3; Check that strided load tag collisions are avoided on Falkor. 4 5; CHECK-LABEL: hwpf1: 6; CHECK: ldp {{w[0-9]+}}, {{w[0-9]+}}, [x[[BASE:[0-9]+]], #-16] 7; CHECK: mov x[[BASE2:[0-9]+]], x[[BASE]] 8; CHECK: ldp {{w[0-9]+}}, {{w[0-9]+}}, [x[[BASE2]], #-8] 9; CHECK: ldp {{w[0-9]+}}, {{w[0-9]+}}, [x[[BASE3:[0-9]+]]] 10; CHECK: mov x[[BASE4:[0-9]+]], x[[BASE3]] 11; CHECK: ldp {{w[0-9]+}}, {{w[0-9]+}}, [x[[BASE4]], #8] 12 13define void @hwpf1(i32* %p, i32* %sp, i32* %sp2, i32* %sp3, i32* %sp4) { 14entry: 15 br label %loop 16 17loop: 18 %iv = phi i32 [ 0, %entry ], [ %inc, %loop ] 19 20 %gep = getelementptr inbounds i32, i32* %p, i32 %iv 21 %load1 = load i32, i32* %gep 22 23 %gep2 = getelementptr inbounds i32, i32* %gep, i32 1 24 %load2 = load i32, i32* %gep2 25 26 %add = add i32 %load1, %load2 27 %storegep = getelementptr inbounds i32, i32* %sp, i32 %iv 28 store i32 %add, i32* %storegep 29 30 %gep3 = getelementptr inbounds i32, i32* %gep, i32 2 31 %load3 = load i32, i32* %gep3 32 33 %gep4 = getelementptr inbounds i32, i32* %gep, i32 3 34 %load4 = load i32, i32* %gep4 35 36 %add2 = add i32 %load3, %load4 37 %storegep2 = getelementptr inbounds i32, i32* %sp2, i32 %iv 38 store i32 %add2, i32* %storegep2 39 40 %gep5 = getelementptr inbounds i32, i32* %gep, i32 4 41 %load5 = load i32, i32* %gep5 42 43 %gep6 = getelementptr inbounds i32, i32* %gep, i32 5 44 %load6 = load i32, i32* %gep6 45 46 %add3 = add i32 %load5, %load6 47 %storegep3 = getelementptr inbounds i32, i32* %sp3, i32 %iv 48 store i32 %add3, i32* %storegep3 49 50 %gep7 = getelementptr inbounds i32, i32* %gep, i32 6 51 %load7 = load i32, i32* %gep7 52 53 %gep8 = getelementptr inbounds i32, i32* %gep, i32 7 54 %load8 = load i32, i32* %gep8 55 56 %add4 = add i32 %load7, %load8 57 %storegep4 = getelementptr inbounds i32, i32* %sp4, i32 %iv 58 store i32 %add4, i32* %storegep4 59 60 %inc = add i32 %iv, 8 61 %exitcnd = icmp uge i32 %inc, 1024 62 br i1 %exitcnd, label %exit, label %loop 63 64exit: 65 ret void 66} 67 68