24 lines · plain
1; RUN: llc -mtriple=thumb-eabi -mcpu=arm1156t2-s -mattr=+thumb2 %s -o - | FileCheck %s2; If-conversion defeats the purpose of this test, which is to check CBZ3; generation, so use memory barrier instruction to make sure it doesn't4; happen and we get actual branches.5 6define i32 @t1(i32 %a, i32 %b, i32 %c) {7; CHECK-LABEL: t1:8; CHECK: cbz9 %tmp2 = icmp eq i32 %a, 010 br i1 %tmp2, label %cond_false, label %cond_true11 12cond_true:13 fence seq_cst14 %tmp5 = add i32 %b, 115 %tmp6 = and i32 %tmp5, %c16 ret i32 %tmp617 18cond_false:19 fence seq_cst20 %tmp7 = add i32 %b, -121 %tmp8 = xor i32 %tmp7, %c22 ret i32 %tmp823}24