1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2# RUN: llc -run-pass arm-mve-vpt %s -o - | FileCheck %s
3
4--- |
5  target datalayout = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
6  target triple = "thumbv8.1m.main-none-none-eabi"
7
8  define arm_aapcs_vfpcc <4 x float> @vpt_preuse(<4 x float> %inactive1, <4 x float> %a, <4 x float> %b, i16 zeroext %p1, i16 zeroext %p2) #0 {
9  entry:
10    ;
11    ; Intentionally left blank, see the MIR sequence below.
12    ;
13    ret <4 x float> %inactive1
14  }
15
16  attributes #0 = { "target-features"="+armv8.1-m.main,+hwdiv,+mve.fp,+ras,+thumb-mode" }
17
18...
19---
20name:            vpt_preuse
21alignment:       4
22exposesReturnsTwice: false
23legalized:       false
24regBankSelected: false
25selected:        false
26failedISel:      false
27tracksRegLiveness: true
28hasWinCFI:       false
29registers:       []
30liveins:
31  - { reg: '$q0', virtual-reg: '' }
32  - { reg: '$q1', virtual-reg: '' }
33  - { reg: '$q2', virtual-reg: '' }
34  - { reg: '$q5', virtual-reg: '' }
35  - { reg: '$r0', virtual-reg: '' }
36  - { reg: '$r1', virtual-reg: '' }
37frameInfo:
38  isFrameAddressTaken: false
39  isReturnAddressTaken: false
40  hasStackMap:     false
41  hasPatchPoint:   false
42  stackSize:       0
43  offsetAdjustment: 0
44  maxAlignment:    0
45  adjustsStack:    false
46  hasCalls:        false
47  stackProtector:  ''
48  maxCallFrameSize: 0
49  cvBytesOfCalleeSavedRegisters: 0
50  hasOpaqueSPAdjustment: false
51  hasVAStart:      false
52  hasMustTailInVarArgFunc: false
53  localFrameSize:  0
54  savePoint:       ''
55  restorePoint:    ''
56fixedStack:      []
57stack:           []
58constants:       []
59body:             |
60  bb.0:
61  liveins: $lr, $q0, $q1, $q2, $q3, $q4, $q5, $r0, $r1, $r2, $r7, $r8, $r9, $r10, $r11, $r12
62
63
64    ; CHECK-LABEL: name: vpt_preuse
65    ; CHECK: successors: %bb.0(0x80000000)
66    ; CHECK: liveins: $lr, $q0, $q1, $q2, $q3, $q4, $q5, $r0, $r1, $r2, $r7, $r8, $r9, $r10, $r11, $r12
67    ; CHECK: renamable $vpr = MVE_VCMPu32 renamable $q1, renamable $q5, 2, 0, $noreg
68    ; CHECK: renamable $r4 = t2ADDrr renamable $r2, renamable $r10, 14 /* CC::al */, $noreg, $noreg
69    ; CHECK: VSTR_P0_off renamable $vpr, $sp, 0, 14 /* CC::al */, $noreg
70    ; CHECK: BUNDLE implicit-def $q6, implicit-def $d12, implicit-def $s24, implicit-def $s25, implicit-def $d13, implicit-def $s26, implicit-def $s27, implicit $vpr, implicit killed $r4 {
71    ; CHECK:   MVE_VPST 8, implicit $vpr
72    ; CHECK:   renamable $q6 = MVE_VLDRBU32 killed renamable $r4, 0, 1, renamable $vpr
73    ; CHECK: }
74    ; CHECK: t2LoopEnd renamable $lr, %bb.0, implicit-def dead $cpsr
75    ; CHECK: t2B %bb.0, 14 /* CC::al */, $noreg
76  renamable $vpr = MVE_VCMPu32 renamable $q1, renamable $q5, 2, 0, $noreg
77  renamable $r4 = t2ADDrr renamable $r2, renamable $r10, 14, $noreg, $noreg
78  VSTR_P0_off renamable $vpr, $sp, 0, 14, $noreg
79  renamable $q6 = MVE_VLDRBU32 killed renamable $r4, 0, 1, renamable $vpr
80  t2LoopEnd renamable $lr, %bb.0, implicit-def dead $cpsr
81  t2B %bb.0, 14, $noreg
82
83...
84