diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:02:28 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:02:28 +0000 |
commit | 7442d6faa2719e4e7d33a7021c406c5a4facd74d (patch) | |
tree | c72b9241553fc9966179aba84f90f17bfa9235c3 /include/clang/Basic/AddressSpaces.h | |
parent | b52119637f743680a99710ce5fdb6646da2772af (diff) | |
download | src-7442d6faa2719e4e7d33a7021c406c5a4facd74d.tar.gz src-7442d6faa2719e4e7d33a7021c406c5a4facd74d.zip |
Vendor import of clang trunk r300422:vendor/clang/clang-trunk-r300422
Notes
Notes:
svn path=/vendor/clang/dist/; revision=317019
svn path=/vendor/clang/clang-trunk-r300422/; revision=317020; tag=vendor/clang/clang-trunk-r300422
Diffstat (limited to 'include/clang/Basic/AddressSpaces.h')
-rw-r--r-- | include/clang/Basic/AddressSpaces.h | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/include/clang/Basic/AddressSpaces.h b/include/clang/Basic/AddressSpaces.h index 63df61bedbc6..0ec5aafd64b6 100644 --- a/include/clang/Basic/AddressSpaces.h +++ b/include/clang/Basic/AddressSpaces.h @@ -20,24 +20,32 @@ namespace clang { namespace LangAS { -/// \brief Defines the set of possible language-specific address spaces. +/// \brief Defines the address space values used by the address space qualifier +/// of QualType. /// -/// This uses a high starting offset so as not to conflict with any address -/// space used by a target. enum ID { - Offset = 0x7FFF00, - - opencl_global = Offset, + // The default value 0 is the value used in QualType for the the situation + // where there is no address space qualifier. For most languages, this also + // corresponds to the situation where there is no address space qualifier in + // the source code, except for OpenCL, where the address space value 0 in + // QualType represents private address space in OpenCL source code. + Default = 0, + + // OpenCL specific address spaces. + opencl_global, opencl_local, opencl_constant, opencl_generic, + // CUDA specific address spaces. cuda_device, cuda_constant, cuda_shared, - Last, - Count = Last-Offset + // This denotes the count of language-specific address spaces and also + // the offset added to the target-specific address spaces, which are usually + // specified by address space attributes __attribute__(address_space(n))). + Count }; /// The type of a lookup table which maps from language-specific address spaces |