File: ifcvt_triangleSameCvtNext.mir

package info (click to toggle)
llvm-toolchain-20 1%3A20.1.6-1~exp1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 2,111,304 kB
  • sloc: cpp: 7,438,677; ansic: 1,393,822; asm: 1,012,926; python: 241,650; f90: 86,635; objc: 75,479; lisp: 42,144; pascal: 17,286; sh: 10,027; ml: 5,082; perl: 4,730; awk: 3,523; makefile: 3,349; javascript: 2,251; xml: 892; fortran: 672
file content (41 lines) | stat: -rw-r--r-- 1,243 bytes parent folder | download | duplicates (23)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
# RUN: llc -mtriple=thumbv7-apple-ios -run-pass=if-converter -verify-machineinstrs %s -o - | FileCheck %s

# 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.

...
---
name:            foo
body:             |
  ; CHECK-LABEL: name: foo
  ; CHECK: bb.0:
  ; CHECK:   successors: %bb.2(0x40000000), %bb.1(0x40000000)
  ; CHECK:   tBcc %bb.2, 1 /* CC::ne */, $cpsr
  ; CHECK: bb.1:
  ; CHECK:   successors: %bb.1(0x80000000)
  ; CHECK:   $sp = tADDspi $sp, 2, 14 /* CC::al */, $noreg
  ; CHECK:   tB %bb.1, 14 /* CC::al */, $noreg
  ; CHECK: bb.2:
  ; CHECK:   successors: %bb.3(0x40000000), %bb.2(0x40000000)
  ; CHECK:   tBcc %bb.3, 0 /* CC::eq */, $cpsr
  ; CHECK:   tB %bb.2, 14 /* CC::al */, $noreg
  ; CHECK: bb.3:
  ; CHECK:   successors: %bb.1(0x80000000)
  ; CHECK:   tBcc %bb.1, 1 /* CC::ne */, $cpsr
  ; CHECK:   tB %bb.1, 14 /* CC::al */, $noreg
  bb.0:
    tBcc %bb.2, 1, $cpsr

  bb.1:
    $sp = tADDspi $sp, 2, 14, _
    tB %bb.1, 14, $noreg

  bb.2:
    tBcc %bb.3, 0, $cpsr
    tB %bb.2, 14, $noreg

  bb.3:
    tBcc %bb.1, 1, $cpsr
    tB %bb.1, 14, $noreg
...