summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
diff options
context:
space:
mode:
authorNicolai Haehnle <nhaehnle@gmail.com>2018-04-01 17:09:07 +0000
committerNicolai Haehnle <nhaehnle@gmail.com>2018-04-01 17:09:07 +0000
commit5d0d30304c5f2305d8458625e5e46db6cc7f0a06 (patch)
tree76d3d56a5a058a69dc9a7d3bd2a2d827cff5e45e /llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
parent398c0b6701209c2c7fc980463c21456db2114971 (diff)
downloadbcm5719-llvm-5d0d30304c5f2305d8458625e5e46db6cc7f0a06.tar.gz
bcm5719-llvm-5d0d30304c5f2305d8458625e5e46db6cc7f0a06.zip
AMDGPU: Make getTgtMemIntrinsic table-driven for resource-based intrinsics
Summary: Avoids having to list all intrinsics manually. This is in preparation for the new dimension-aware image intrinsics, which I'd rather not have to list here by hand. Change-Id: If7ced04998397ef68c4cb8f7de66b5050fb767e5 Reviewers: arsenm, rampitec, b-sumner Subscribers: kzhuravl, wdng, mgorny, yaxunl, dstuttard, tpr, llvm-commits, t-tye Differential Revision: https://reviews.llvm.org/D44937 llvm-svn: 328938
Diffstat (limited to 'llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h')
-rw-r--r--llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h b/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
index 74e14ef8fbd..8f75b424798 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
+++ b/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
@@ -53,6 +53,17 @@ public:
static bool isUniformMMO(const MachineMemOperand *MMO);
};
+
+namespace AMDGPU {
+
+struct RsrcIntrinsic {
+ unsigned Intr;
+ uint8_t RsrcArg;
+ bool IsImage;
+};
+const RsrcIntrinsic *lookupRsrcIntrinsicByIntr(unsigned Intr);
+
+} // end AMDGPU namespace
} // End llvm namespace
#endif
OpenPOWER on IntegriCloud