summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2016-01-04 20:23:10 +0000
committerTom Stellard <thomas.stellard@amd.com>2016-01-04 20:23:10 +0000
commit3da5672755d3aa9ca7e0ae7db36d8142911a1b3e (patch)
tree0bdf87344901aa59bc593776dbb02dafbc0b09fc
parent58999d9253aa7312d2bd150aeb00ab859151e22d (diff)
downloadbcm5719-llvm-3da5672755d3aa9ca7e0ae7db36d8142911a1b3e.tar.gz
bcm5719-llvm-3da5672755d3aa9ca7e0ae7db36d8142911a1b3e.zip
AMDGPU/SI: Move VI SMEM pattern back into VIInstructions.td
Summary: This was accidently moved to CIInstructions.td in r256282 Reviewers: cfang, arsenm Subscribers: arsenm, llvm-commits Differential Revision: http://reviews.llvm.org/D15763 llvm-svn: 256775
-rw-r--r--llvm/lib/Target/AMDGPU/CIInstructions.td6
-rw-r--r--llvm/lib/Target/AMDGPU/VIInstructions.td9
2 files changed, 9 insertions, 6 deletions
diff --git a/llvm/lib/Target/AMDGPU/CIInstructions.td b/llvm/lib/Target/AMDGPU/CIInstructions.td
index 88a090d3df3..b8409a913d1 100644
--- a/llvm/lib/Target/AMDGPU/CIInstructions.td
+++ b/llvm/lib/Target/AMDGPU/CIInstructions.td
@@ -329,12 +329,6 @@ def useFlatForGlobal : Predicate <
let Predicates = [useFlatForGlobal] in {
-// 1. Offset as 20bit DWORD immediate
-def : Pat <
- (SIload_constant v4i32:$sbase, IMM20bit:$offset),
- (S_BUFFER_LOAD_DWORD_IMM $sbase, (as_i32imm $offset))
->;
-
// Patterns for global loads with no offset
class FlatLoadPat <FLAT inst, SDPatternOperator node, ValueType vt> : Pat <
(vt (node i64:$addr)),
diff --git a/llvm/lib/Target/AMDGPU/VIInstructions.td b/llvm/lib/Target/AMDGPU/VIInstructions.td
index 20a026a822e..1a7801c92bd 100644
--- a/llvm/lib/Target/AMDGPU/VIInstructions.td
+++ b/llvm/lib/Target/AMDGPU/VIInstructions.td
@@ -101,3 +101,12 @@ def S_DCACHE_WB_VOL : SMEM_Inval <0x23,
} // End SIAssemblerPredicate = DisableInst, SubtargetPredicate = isVI
+let Predicates = [isVI] in {
+
+// 1. Offset as 20bit DWORD immediate
+def : Pat <
+ (SIload_constant v4i32:$sbase, IMM20bit:$offset),
+ (S_BUFFER_LOAD_DWORD_IMM $sbase, (as_i32imm $offset))
+>;
+
+} // End Predicates = [isVI]
OpenPOWER on IntegriCloud