2017-10-19 07:18:12 +08:00
|
|
|
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
|
2018-05-06 05:19:59 +08:00
|
|
|
# RUN: llc -mtriple=amdgcn-mesa-mesa3d -mcpu=fiji -O0 -run-pass=legalizer %s -o - | FileCheck %s
|
AMDGPU/GlobalISel: Mark 32-bit integer constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33115
llvm-svn: 302919
2017-05-13 00:46:46 +08:00
|
|
|
|
|
|
|
---
|
2018-02-27 01:20:43 +08:00
|
|
|
name: test_constant_i32
|
AMDGPU/GlobalISel: Mark 32-bit integer constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33115
llvm-svn: 302919
2017-05-13 00:46:46 +08:00
|
|
|
body: |
|
2018-02-27 01:20:43 +08:00
|
|
|
bb.0:
|
AMDGPU/GlobalISel: Mark 32-bit integer constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33115
llvm-svn: 302919
2017-05-13 00:46:46 +08:00
|
|
|
|
2018-02-27 01:20:43 +08:00
|
|
|
; CHECK-LABEL: name: test_constant_i32
|
2017-10-25 02:04:54 +08:00
|
|
|
; CHECK: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 5
|
2018-03-17 23:17:48 +08:00
|
|
|
; CHECK: $vgpr0 = COPY [[C]](s32)
|
|
|
|
%0:_(s32) = G_CONSTANT i32 5
|
|
|
|
$vgpr0 = COPY %0
|
AMDGPU/GlobalISel: Mark 32-bit integer constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33115
llvm-svn: 302919
2017-05-13 00:46:46 +08:00
|
|
|
...
|
2018-02-27 01:20:43 +08:00
|
|
|
---
|
|
|
|
name: test_constant_i64
|
|
|
|
body: |
|
|
|
|
bb.0:
|
AMDGPU/GlobalISel: Mark 32-bit float constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33212
llvm-svn: 304003
2017-05-27 00:40:03 +08:00
|
|
|
|
2018-02-27 01:20:43 +08:00
|
|
|
; CHECK-LABEL: name: test_constant_i64
|
2018-03-17 23:17:48 +08:00
|
|
|
; CHECK: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 5
|
|
|
|
; CHECK: $vgpr0_vgpr1 = COPY [[C]](s64)
|
|
|
|
%0:_(s64) = G_CONSTANT i64 5
|
|
|
|
$vgpr0_vgpr1 = COPY %0
|
|
|
|
|
2018-02-27 01:20:43 +08:00
|
|
|
...
|
AMDGPU/GlobalISel: Mark 32-bit float constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33212
llvm-svn: 304003
2017-05-27 00:40:03 +08:00
|
|
|
---
|
2018-02-27 01:20:43 +08:00
|
|
|
name: test_fconstant_f32
|
AMDGPU/GlobalISel: Mark 32-bit float constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33212
llvm-svn: 304003
2017-05-27 00:40:03 +08:00
|
|
|
body: |
|
2018-02-27 01:20:43 +08:00
|
|
|
bb.0:
|
AMDGPU/GlobalISel: Mark 32-bit float constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33212
llvm-svn: 304003
2017-05-27 00:40:03 +08:00
|
|
|
|
2018-02-27 01:20:43 +08:00
|
|
|
; CHECK-LABEL: name: test_fconstant_f32
|
2017-10-25 02:04:54 +08:00
|
|
|
; CHECK: [[C:%[0-9]+]]:_(s32) = G_FCONSTANT float 1.000000e+00
|
2018-02-27 01:20:43 +08:00
|
|
|
; CHECK: $vgpr0 = COPY [[C]](s32)
|
2018-03-17 23:17:48 +08:00
|
|
|
%0:_(s32) = G_FCONSTANT float 1.0
|
2018-02-01 06:04:26 +08:00
|
|
|
$vgpr0 = COPY %0
|
AMDGPU/GlobalISel: Mark 32-bit float constants as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D33212
llvm-svn: 304003
2017-05-27 00:40:03 +08:00
|
|
|
...
|
2018-02-27 01:20:43 +08:00
|
|
|
---
|
|
|
|
name: test_fconstant_f64
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
|
|
|
|
; CHECK-LABEL: name: test_fconstant_f64
|
|
|
|
; CHECK: [[C:%[0-9]+]]:_(s64) = G_FCONSTANT double 1.000000e+00
|
|
|
|
; CHECK: $vgpr0_vgpr1 = COPY [[C]](s64)
|
2018-03-17 23:17:48 +08:00
|
|
|
%0:_(s64) = G_FCONSTANT double 1.0
|
2018-02-27 01:20:43 +08:00
|
|
|
$vgpr0_vgpr1 = COPY %0
|
2018-03-17 23:17:48 +08:00
|
|
|
...
|
|
|
|
|
|
|
|
---
|
|
|
|
name: test_constant_1
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
|
|
|
|
; CHECK-LABEL: name: test_constant_1
|
|
|
|
; CHECK: [[C:%[0-9]+]]:_(s1) = G_CONSTANT i1 false
|
|
|
|
; CHECK: S_ENDPGM implicit [[C]](s1)
|
|
|
|
%1:_(s1) = G_CONSTANT i1 0
|
|
|
|
S_ENDPGM implicit %1
|
2018-02-27 01:20:43 +08:00
|
|
|
...
|