1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -start-before=if-converter -stop-after=if-converter -o - %s \
3 # RUN: -verify-machineinstrs | FileCheck %s
5 ; ModuleID = 'reduced.ll'
6 source_filename = "reduced.ll"
7 target datalayout = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
8 target triple = "armv4t-unknown-linux-gnueabi"
10 define void @tusb1210_chg_det_work(i1 %tobool.not) {
12 br i1 %tobool.not, label %if.else, label %if.then
14 if.then: ; preds = %entry
15 callbr void asm sideeffect ".word b, ${1:l}, ${0:c}\0A\09", "i,!i"(ptr null)
16 to label %if.end [label %if.end.sink.split]
18 if.else: ; preds = %entry
19 callbr void asm sideeffect ".word b, ${1:l}, ${0:c}\0A\09", "i,!i"(ptr null)
20 to label %if.end [label %if.end.sink.split]
22 if.end.sink.split: ; preds = %if.else, %if.then
23 %.sink = phi i32 [ 1, %if.then ], [ 0, %if.else ]
24 store i32 %.sink, ptr null, align 4
27 if.end: ; preds = %if.end.sink.split, %if.else, %if.then
33 name: tusb1210_chg_det_work
35 exposesReturnsTwice: false
37 regBankSelected: false
40 tracksRegLiveness: true
43 callsUnwindInit: false
48 failsVerification: false
49 tracksDebugUserValues: true
52 - { reg: '$r0', virtual-reg: '' }
54 isFrameAddressTaken: false
55 isReturnAddressTaken: false
66 cvBytesOfCalleeSavedRegisters: 0
67 hasOpaqueSPAdjustment: false
69 hasMustTailInVarArgFunc: false
77 debugValueSubstitutions: []
79 machineFunctionInfo: {}
81 ; CHECK-LABEL: name: tusb1210_chg_det_work
83 ; CHECK-NEXT: successors: %bb.1(0x80000000), %bb.2(0x80000000)
84 ; CHECK-NEXT: liveins: $r0
86 ; CHECK-NEXT: TSTri killed renamable $r0, 1, 14 /* CC::al */, $noreg, implicit-def $cpsr
87 ; CHECK-NEXT: renamable $r0 = MOVi 0, 1 /* CC::ne */, $cpsr, $noreg
88 ; CHECK-NEXT: renamable $r0 = MOVi 1, 0 /* CC::eq */, killed $cpsr, $noreg, implicit killed $r0
89 ; CHECK-NEXT: INLINEASM_BR &".word b, ${1:l}, ${0:c}\0A\09", 9 /* sideeffect mayload attdialect */, 13 /* imm */, 0, 13 /* imm */, %bb.1
92 ; CHECK-NEXT: bb.1.if.end.sink.split (machine-block-address-taken, inlineasm-br-indirect-target):
93 ; CHECK-NEXT: successors: %bb.2(0x80000000)
94 ; CHECK-NEXT: liveins: $r0
96 ; CHECK-NEXT: renamable $r1 = MOVi 0, 14 /* CC::al */, $noreg, $noreg
97 ; CHECK-NEXT: STRi12 killed renamable $r0, killed renamable $r1, 0, 14 /* CC::al */, $noreg :: (store (s32) into `ptr null`)
99 ; CHECK-NEXT: bb.2.if.end:
100 ; CHECK-NEXT: BX_RET 14 /* CC::al */, $noreg
102 successors: %bb.4(0x40000000), %bb.1(0x40000000)
105 TSTri killed renamable $r0, 1, 14 /* CC::al */, $noreg, implicit-def $cpsr
106 Bcc %bb.4, 1 /* CC::ne */, killed $cpsr
109 successors: %bb.3(0x80000000), %bb.2(0x00000000)
111 renamable $r0 = MOVi 1, 14 /* CC::al */, $noreg, $noreg
112 INLINEASM_BR &".word b, ${1:l}, ${0:c}\0A\09", 9 /* sideeffect mayload attdialect */, 13 /* imm */, 0, 13 /* imm */, %bb.2
115 bb.2.if.end.sink.split (machine-block-address-taken, inlineasm-br-indirect-target):
116 successors: %bb.3(0x80000000)
119 renamable $r1 = MOVi 0, 14 /* CC::al */, $noreg, $noreg
120 STRi12 killed renamable $r0, killed renamable $r1, 0, 14 /* CC::al */, $noreg :: (store (s32) into `ptr null`)
123 BX_RET 14 /* CC::al */, $noreg
126 successors: %bb.3(0x80000000), %bb.2(0x00000000)
128 renamable $r0 = MOVi 0, 14 /* CC::al */, $noreg, $noreg
129 INLINEASM_BR &".word b, ${1:l}, ${0:c}\0A\09", 9 /* sideeffect mayload attdialect */, 13 /* imm */, 0, 13 /* imm */, %bb.2