[PATCH] D31210: [AMDGPU] Switch address space mapping by triple environment
Tony Tye via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Mar 24 17:16:17 PDT 2017
t-tye accepted this revision.
t-tye added a comment.
This revision is now accepted and ready to land.
Just a couple of suggestions, otherwise:
LGTM
================
Comment at: lib/Basic/Targets.cpp:2015
-static const unsigned AMDGPUAddrSpaceMap[] = {
- 1, // opencl_global
- 3, // opencl_local
- 2, // opencl_constant
- 4, // opencl_generic
- 1, // cuda_device
- 2, // cuda_constant
- 3 // cuda_shared
+static LangAS::Map AMDGPUPrivateIsZeroMap = {
+ 1, // opencl_global
----------------
Is there a reason this is no longer const?
================
Comment at: lib/Basic/Targets.cpp:2024
+};
+static LangAS::Map AMDGPUGenericIsZeroMap = {
+ 1, // opencl_global
----------------
Same as above.
================
Comment at: lib/Basic/Targets.cpp:2357
+
+ AddrSpace AS;
};
----------------
Could this be const since it is not changed after construction?
https://reviews.llvm.org/D31210
More information about the cfe-commits
mailing list