2020-01-02 19:43:37 +08:00
|
|
|
# RUN: llc -mtriple=thumbv7-apple-ios -run-pass=if-converter -verify-machineinstrs %s -o - | FileCheck %s
|
2019-09-26 14:35:55 +08:00
|
|
|
...
|
|
|
|
---
|
|
|
|
name: foo
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2020-01-02 19:43:37 +08:00
|
|
|
tBcc %bb.2, 1, $cpsr
|
2019-09-26 14:35:55 +08:00
|
|
|
|
|
|
|
bb.1:
|
|
|
|
$sp = tADDspi $sp, 2, 14, _
|
2020-01-02 19:43:37 +08:00
|
|
|
tB %bb.1, 14, $noreg
|
2019-09-26 14:35:55 +08:00
|
|
|
|
|
|
|
bb.2:
|
2020-01-02 19:43:37 +08:00
|
|
|
tBcc %bb.3, 0, $cpsr
|
|
|
|
tB %bb.2, 14, $noreg
|
2019-09-26 14:35:55 +08:00
|
|
|
|
|
|
|
bb.3:
|
2020-01-02 19:43:37 +08:00
|
|
|
tBcc %bb.1, 1, $cpsr
|
|
|
|
tB %bb.1, 14, $noreg
|
2019-09-26 14:35:55 +08:00
|
|
|
...
|
|
|
|
|
|
|
|
# Both branches in bb.3 jump to bb.1. IfConversion shouldn't treat this as a
|
|
|
|
# tringle and insert the tADDspi in bb3, but leave it as it is.
|
|
|
|
|
|
|
|
# CHECK: bb.3:
|
|
|
|
# CHECK: successors: %bb.1
|
|
|
|
# CHECK-NOT: tADDspi
|
|
|
|
# CHECK: Bcc %bb.1, 1, $cpsr
|
|
|
|
# CHECK: B %bb.1
|