[PATCH] D55850: [OpenCL] Allow address spaces as method qualifiers

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 18 12:41:45 PST 2018


Anastasia created this revision.
Anastasia added a reviewer: rjmccall.
Herald added a subscriber: yaxunl.

This patch allows qualifying methods with address spaces and extends some overloading rules to use those qualifiers.

The main use case is to prevent conversions to generic/default address space where it's requested by the programmer. More details can be found in: 
http://lists.llvm.org/pipermail/cfe-dev/2018-December/060470.html

This patch doesn't enable the feature for C++ yet but it can easily be generalized if the overall flow is right.


https://reviews.llvm.org/D55850

Files:
  lib/Parse/ParseDecl.cpp
  lib/Sema/SemaOverload.cpp
  lib/Sema/SemaType.cpp
  test/CodeGenOpenCLCXX/method-overload-address-space.cl
  test/SemaOpenCLCXX/method-overload-address-space.cl

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D55850.178760.patch
Type: text/x-patch
Size: 8938 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20181218/51ec1be8/attachment.bin>


More information about the cfe-commits mailing list