1 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+avx512f -run-pass=regbankselect %s -o - | FileCheck %s --check-prefix=CHECK --check-prefix=FAST
2 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+avx512f -regbankselect-greedy -run-pass=regbankselect %s -o - | FileCheck %s --check-prefix=CHECK --check-prefix=GREEDY
6 define void @test_mul_vec512() {
10 define void @test_add_vec512() {
14 define void @test_sub_vec512() {
18 define <16 x i32> @test_load_v16i32_noalign(<16 x i32>* %p1) {
19 %r = load <16 x i32>, <16 x i32>* %p1, align 1
23 define void @test_store_v16i32_noalign(<16 x i32> %val, <16 x i32>* %p1) {
24 store <16 x i32> %val, <16 x i32>* %p1, align 1
31 # CHECK-LABEL: name: test_mul_vec512
34 regBankSelected: false
36 # CHECK-NEXT: - { id: 0, class: vecr, preferred-register: '' }
37 # CHECK-NEXT: - { id: 1, class: vecr, preferred-register: '' }
44 %0(<16 x s32>) = IMPLICIT_DEF
45 %1(<16 x s32>) = G_MUL %0, %0
51 # CHECK-LABEL: name: test_add_vec512
54 regBankSelected: false
56 # CHECK-NEXT: - { id: 0, class: vecr, preferred-register: '' }
57 # CHECK-NEXT: - { id: 1, class: vecr, preferred-register: '' }
64 %0(<16 x s32>) = IMPLICIT_DEF
65 %1(<16 x s32>) = G_ADD %0, %0
71 # CHECK-LABEL: name: test_sub_vec512
74 regBankSelected: false
76 # CHECK-NEXT: - { id: 0, class: vecr, preferred-register: '' }
77 # CHECK-NEXT: - { id: 1, class: vecr, preferred-register: '' }
84 %0(<16 x s32>) = IMPLICIT_DEF
85 %1(<16 x s32>) = G_SUB %0, %0
90 name: test_load_v16i32_noalign
91 # CHECK-LABEL: name: test_load_v16i32_noalign
94 regBankSelected: false
96 # CHECK-NEXT: - { id: 0, class: gpr, preferred-register: '' }
97 # CHECK-NEXT: - { id: 1, class: vecr, preferred-register: '' }
100 - { id: 1, class: _ }
106 %1(<16 x s32>) = G_LOAD %0(p0) :: (load 64 from %ir.p1, align 1)
107 $zmm0 = COPY %1(<16 x s32>)
108 RET 0, implicit $zmm0
112 name: test_store_v16i32_noalign
113 # CHECK-LABEL: name: test_store_v16i32_noalign
116 regBankSelected: false
118 # CHECK-NEXT: - { id: 0, class: vecr, preferred-register: '' }
119 # CHECK-NEXT: - { id: 1, class: gpr, preferred-register: '' }
121 - { id: 0, class: _ }
122 - { id: 1, class: _ }
127 %0(<16 x s32>) = COPY $zmm0
129 G_STORE %0(<16 x s32>), %1(p0) :: (store 64 into %ir.p1, align 1)