================
@@ -576,21 +576,38 @@ class ParsedAttr final
}
}
- /// If this is an OpenCL address space attribute, returns its SYCL
- /// representation in LangAS, otherwise returns default address space.
+ /// If this is a SYCL address space attribute, returns its SYCL
+ /// representation in LangAS.
LangAS asSYCLLangAS() const {
- switch (getKind()) {
- case ParsedAttr::AT_OpenCLGlobalAddressSpace:
+ switch (getParsedKind()) {
+ case ParsedAttr::AT_SYCLGlobalAddressSpace:
return LangAS::sycl_global;
+ // TODO: OpenCLGlobalDeviceAddressSpace, OpenCLGlobalHostAddressSpace,
+ // sycl_global_device, and sycl_global_host will be removed after
+ // deprecation.
+ //
https://discourse.llvm.org/t/rfc-remove-opencl-global-device-and-opencl-global-host-address-space-attributes/90677
case ParsedAttr::AT_OpenCLGlobalDeviceAddressSpace:
return LangAS::sycl_global_device;
case ParsedAttr::AT_OpenCLGlobalHostAddressSpace:
return LangAS::sycl_global_host;
----------------
elizabethandrews wrote:
I would rather not do this. We would break existing code with no way of fixing
wherever the attributes are used now. IMO we should wait for the deprecation
behavior to be over before forcing users to remove the attributes from their
code base because we changed behavior.
https://github.com/llvm/llvm-project/pull/200849
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits