2018-06-22 07:38:20 +08:00
|
|
|
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
|
2020-03-16 04:58:26 +08:00
|
|
|
# RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=hawaii -run-pass=instruction-select -verify-machineinstrs -o - %s | FileCheck -check-prefixes=GCN %s
|
2018-06-22 07:38:20 +08:00
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s32_sgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s32_sgpr
|
2019-10-19 02:26:37 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:sreg_32 = IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:sgpr(s32) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
2018-06-22 07:38:20 +08:00
|
|
|
---
|
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_s32_vgpr
|
2018-06-22 07:38:20 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_s32_vgpr
|
2018-06-22 07:38:20 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:vgpr_32 = IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:vgpr(s32) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
2018-06-25 23:42:12 +08:00
|
|
|
...
|
2019-06-25 00:24:03 +08:00
|
|
|
|
2018-06-25 23:42:12 +08:00
|
|
|
---
|
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_s64_sgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_s64_sgpr
|
2020-01-13 06:10:18 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:sreg_64 = IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:sgpr(s64) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
|
2018-06-25 23:42:12 +08:00
|
|
|
---
|
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_s64_vgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s64_vgpr
|
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_64 = IMPLICIT_DEF
|
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:vgpr(s64) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
|
2018-06-25 23:42:12 +08:00
|
|
|
---
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_p0_sgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
2018-06-25 23:42:12 +08:00
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_p0_sgpr
|
2020-01-13 06:10:18 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:sreg_64 = IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:sgpr(p0) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
|
|
|
|
---
|
|
|
|
name: implicit_def_p0_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_p0_vgpr
|
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_64 = IMPLICIT_DEF
|
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
2018-06-25 23:42:12 +08:00
|
|
|
%0:vgpr(p0) = G_IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
S_ENDPGM 0, implicit %0
|
2018-06-25 23:42:12 +08:00
|
|
|
...
|
|
|
|
|
|
|
|
---
|
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_p1_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_p1_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_64 = IMPLICIT_DEF
|
|
|
|
; GCN: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4, implicit $exec
|
2021-02-09 08:36:10 +08:00
|
|
|
; GCN: FLAT_STORE_DWORD [[DEF]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store 4, addrspace 1)
|
2018-06-25 23:42:12 +08:00
|
|
|
%0:vgpr(p1) = G_IMPLICIT_DEF
|
2019-02-05 07:29:31 +08:00
|
|
|
%1:vgpr(s32) = G_CONSTANT i32 4
|
2019-01-27 23:57:23 +08:00
|
|
|
G_STORE %1, %0 :: (store 4, addrspace 1)
|
2018-06-22 07:38:20 +08:00
|
|
|
...
|
2019-06-25 00:24:03 +08:00
|
|
|
|
2018-06-22 07:38:20 +08:00
|
|
|
---
|
2018-06-25 23:42:12 +08:00
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_p3_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_p3_vgpr
|
2019-07-17 02:42:53 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_64 = IMPLICIT_DEF
|
|
|
|
; GCN: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4, implicit $exec
|
2019-10-02 00:35:06 +08:00
|
|
|
; GCN: $m0 = S_MOV_B32 -1
|
2021-02-09 08:36:10 +08:00
|
|
|
; GCN: FLAT_STORE_DWORD [[DEF]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store 4, addrspace 1)
|
2018-06-25 23:42:12 +08:00
|
|
|
%0:vgpr(p3) = G_IMPLICIT_DEF
|
2019-02-05 07:29:31 +08:00
|
|
|
%1:vgpr(s32) = G_CONSTANT i32 4
|
2019-01-27 23:57:23 +08:00
|
|
|
G_STORE %1, %0 :: (store 4, addrspace 1)
|
2018-06-25 23:42:12 +08:00
|
|
|
...
|
2019-06-25 00:24:03 +08:00
|
|
|
|
2018-06-25 23:42:12 +08:00
|
|
|
---
|
|
|
|
|
2019-06-25 00:24:03 +08:00
|
|
|
name: implicit_def_p4_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN-LABEL: name: implicit_def_p4_vgpr
|
2018-06-25 23:42:12 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_64 = IMPLICIT_DEF
|
|
|
|
; GCN: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4, implicit $exec
|
2021-02-09 08:36:10 +08:00
|
|
|
; GCN: FLAT_STORE_DWORD [[DEF]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store 4, addrspace 1)
|
2018-06-25 23:42:12 +08:00
|
|
|
%0:vgpr(p4) = G_IMPLICIT_DEF
|
2019-02-05 07:29:31 +08:00
|
|
|
%1:vgpr(s32) = G_CONSTANT i32 4
|
2019-01-27 23:57:23 +08:00
|
|
|
G_STORE %1, %0 :: (store 4, addrspace 1)
|
2018-06-25 23:42:12 +08:00
|
|
|
...
|
2019-06-25 00:24:03 +08:00
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s1_vgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s1_vgpr
|
|
|
|
; GCN: [[DEF:%[0-9]+]]:vgpr_32 = IMPLICIT_DEF
|
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:vgpr(s1) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s1_sgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s1_sgpr
|
2019-10-19 02:26:37 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:sreg_32 = IMPLICIT_DEF
|
2019-06-25 00:24:03 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:sgpr(s1) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s1_vcc
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s1_vcc
|
|
|
|
; GCN: [[DEF:%[0-9]+]]:sreg_64_xexec = IMPLICIT_DEF
|
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:vcc(s1) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
2019-10-02 00:35:06 +08:00
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s1024_sgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s1024_sgpr
|
2020-04-22 18:08:08 +08:00
|
|
|
; GCN: [[DEF:%[0-9]+]]:sgpr_1024 = IMPLICIT_DEF
|
2019-10-02 00:35:06 +08:00
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:sgpr(s1024) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|
|
|
|
---
|
|
|
|
|
|
|
|
name: implicit_def_s1024_vgpr
|
|
|
|
legalized: true
|
|
|
|
regBankSelected: true
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
; GCN-LABEL: name: implicit_def_s1024_vgpr
|
|
|
|
; GCN: [[DEF:%[0-9]+]]:vreg_1024 = IMPLICIT_DEF
|
|
|
|
; GCN: S_ENDPGM 0, implicit [[DEF]]
|
|
|
|
%0:vgpr(s1024) = G_IMPLICIT_DEF
|
|
|
|
S_ENDPGM 0, implicit %0
|
|
|
|
...
|