Skip to content

Commit

Permalink
[ARM] GlobalISel: Test default banks for load results. NFC.
Browse files Browse the repository at this point in the history
Check that all scalars are loaded into the GPR by default.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293883 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
rovka committed Feb 2, 2017
1 parent 178f518 commit 10282bd
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions test/CodeGen/ARM/GlobalISel/arm-regbankselect.mir
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
define void @test_add_s16() { ret void }
define void @test_add_s8() { ret void }
define void @test_add_s1() { ret void }

define void @test_loads() { ret void }
...
---
name: test_add_s32
Expand Down Expand Up @@ -109,3 +111,33 @@ body: |
BX_RET 14, _, implicit %r0
...
---
name: test_loads
# CHECK-LABEL: name: test_loads
legalized: true
regBankSelected: false
selected: false
# CHECK: registers:
# CHECK: - { id: 0, class: gprb }
# CHECK: - { id: 1, class: gprb }
# CHECK: - { id: 2, class: gprb }
# CHECK: - { id: 3, class: gprb }
# CHECK: - { id: 4, class: gprb }

registers:
- { id: 0, class: _ }
- { id: 1, class: _ }
- { id: 2, class: _ }
- { id: 3, class: _ }
- { id: 4, class: _ }
body: |
bb.0:
liveins: %r0
%0(p0) = COPY %r0
%1(s32) = G_LOAD %0
%2(s16) = G_LOAD %0
%3(s8) = G_LOAD %0
%4(s1) = G_LOAD %0
BX_RET 14, _, implicit %r0
...

0 comments on commit 10282bd

Please sign in to comment.