• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# RUN: llc -march=amdgcn -mcpu=gfx900 -run-pass si-insert-waitcnts  %s -o - | FileCheck %s
2
3# Ensure we insert waitcnts after any meta instructions at the start of
4# non-kernel functions. Without this, the inserted waitcnts can affect e.g. the
5# PC ranges covered by CFI and debug values.
6
7---
8# CHECK-LABEL: name: skip_implicit_def{{$}}
9# CHECK: IMPLICIT_DEF
10# CHECK: S_WAITCNT
11name: skip_implicit_def
12machineFunctionInfo:
13body: |
14  bb.0:
15    $sgpr0 = IMPLICIT_DEF
16...
17---
18# CHECK-LABEL: name: skip_kill{{$}}
19# CHECK: KILL
20# CHECK: S_WAITCNT
21name: skip_kill
22machineFunctionInfo:
23body: |
24  bb.0:
25    KILL $sgpr0
26...
27---
28# CHECK-LABEL: name: skip_cfi{{$}}
29# CHECK: CFI_INSTRUCTION
30# CHECK: S_WAITCNT
31name: skip_cfi
32machineFunctionInfo:
33body: |
34  bb.0:
35    CFI_INSTRUCTION undefined $sgpr0
36...
37---
38# CHECK-LABEL: name: skip_eh_label{{$}}
39# CHECK: EH_LABEL
40# CHECK: S_WAITCNT
41name: skip_eh_label
42machineFunctionInfo:
43body: |
44  bb.0:
45    EH_LABEL 0
46...
47---
48# CHECK-LABEL: name: skip_gc_label{{$}}
49# CHECK: GC_LABEL
50# CHECK: S_WAITCNT
51name: skip_gc_label
52machineFunctionInfo:
53body: |
54  bb.0:
55    GC_LABEL 0
56...
57---
58# CHECK-LABEL: name: skip_dbg_value{{$}}
59# CHECK: DBG_VALUE
60# CHECK: S_WAITCNT
61name: skip_dbg_value
62machineFunctionInfo:
63body: |
64  bb.0:
65    DBG_VALUE 0
66...
67---
68# CHECK-LABEL: name: skip_dbg_label{{$}}
69# CHECK: DBG_LABEL
70# CHECK: S_WAITCNT
71name: skip_dbg_label
72machineFunctionInfo:
73body: |
74  bb.0:
75    DBG_LABEL 0
76...
77---
78# CHECK-LABEL: name: skip_lifetime_start{{$}}
79# CHECK: LIFETIME_START
80# CHECK: S_WAITCNT
81name: skip_lifetime_start
82machineFunctionInfo:
83body: |
84  bb.0:
85    LIFETIME_START 0
86...
87---
88# CHECK-LABEL: name: skip_lifetime_end{{$}}
89# CHECK: LIFETIME_END
90# CHECK: S_WAITCNT
91name: skip_lifetime_end
92machineFunctionInfo:
93body: |
94  bb.0:
95    LIFETIME_END 0
96...
97