1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2# RUN: llc -march=amdgcn -mcpu=tahiti -run-pass=instruction-select -verify-machineinstrs %s -o - | FileCheck %s
3---
4
5name: ptrtoint_s_p3_to_s_s32
6legalized:       true
7regBankSelected: true
8tracksRegLiveness: true
9
10body: |
11  bb.0:
12    liveins: $sgpr0
13
14    ; CHECK-LABEL: name: ptrtoint_s_p3_to_s_s32
15    ; CHECK: liveins: $sgpr0
16    ; CHECK: [[COPY:%[0-9]+]]:sreg_32 = COPY $sgpr0
17    ; CHECK: S_ENDPGM 0, implicit [[COPY]]
18    %0:sgpr(p3) = COPY $sgpr0
19    %1:sgpr(s32) = G_PTRTOINT %0
20    S_ENDPGM 0, implicit %1
21...
22
23---
24
25name: ptrtoint_s_p5_to_s_s32
26legalized:       true
27regBankSelected: true
28tracksRegLiveness: true
29
30body: |
31  bb.0:
32    liveins: $sgpr0
33
34    ; CHECK-LABEL: name: ptrtoint_s_p5_to_s_s32
35    ; CHECK: liveins: $sgpr0
36    ; CHECK: [[COPY:%[0-9]+]]:sreg_32 = COPY $sgpr0
37    ; CHECK: S_ENDPGM 0, implicit [[COPY]]
38    %0:sgpr(p5) = COPY $sgpr0
39    %1:sgpr(s32) = G_PTRTOINT %0
40    S_ENDPGM 0, implicit %1
41...
42
43---
44
45name: ptrtoint_s_p0_to_s_s64
46legalized:       true
47regBankSelected: true
48tracksRegLiveness: true
49
50body: |
51  bb.0:
52    liveins: $sgpr0_sgpr1
53
54    ; CHECK-LABEL: name: ptrtoint_s_p0_to_s_s64
55    ; CHECK: liveins: $sgpr0_sgpr1
56    ; CHECK: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1
57    ; CHECK: S_ENDPGM 0, implicit [[COPY]]
58    %0:sgpr(p0) = COPY $sgpr0_sgpr1
59    %1:sgpr(s64) = G_PTRTOINT %0
60    S_ENDPGM 0, implicit %1
61...
62
63---
64
65name: ptrtoint_s_p1_to_s_s64
66legalized:       true
67regBankSelected: true
68tracksRegLiveness: true
69
70body: |
71  bb.0:
72    liveins: $sgpr0_sgpr1
73
74    ; CHECK-LABEL: name: ptrtoint_s_p1_to_s_s64
75    ; CHECK: liveins: $sgpr0_sgpr1
76    ; CHECK: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1
77    ; CHECK: S_ENDPGM 0, implicit [[COPY]]
78    %0:sgpr(p1) = COPY $sgpr0_sgpr1
79    %1:sgpr(s64) = G_PTRTOINT %0
80    S_ENDPGM 0, implicit %1
81...
82
83---
84
85name: ptrtoint_s_p999_to_s_s64
86legalized:       true
87regBankSelected: true
88tracksRegLiveness: true
89
90body: |
91  bb.0:
92    liveins: $sgpr0_sgpr1
93
94    ; CHECK-LABEL: name: ptrtoint_s_p999_to_s_s64
95    ; CHECK: liveins: $sgpr0_sgpr1
96    ; CHECK: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1
97    ; CHECK: S_ENDPGM 0, implicit [[COPY]]
98    %0:sgpr(p999) = COPY $sgpr0_sgpr1
99    %1:sgpr(s64) = G_PTRTOINT %0
100    S_ENDPGM 0, implicit %1
101...
102