[PATCH] D80932: [SYCL] Make default address space a superset of OpenCL address spaces.

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 2 08:14:13 PDT 2020


Anastasia added a comment.

Why?

Default address space is normally an address space of automatic storage i.e. `private` in OpenCL. If you look at the address space map of targets most of them map default and private address spaces to the same value. Converting between private and other named address space is not allowed in OpenCL see section 6.5. I don't believe this change is doing anything legitimate.

Can you explain what you are trying to achieve with this?



================
Comment at: clang/test/SemaOpenCLCXX/address-space-lambda.cl:34
   priv2();
-  auto priv3 = []() __global {}; //expected-note{{candidate function not viable: 'this' object is in address space '__private', but method expects object in address space '__global'}} //expected-note{{conversion candidate of type 'void (*)()'}}
-  priv3(); //expected-error{{no matching function for call to object of type}}
----------------
Here we are testing expected behavior. I believe we already had a discussion about this.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D80932/new/

https://reviews.llvm.org/D80932





More information about the cfe-commits mailing list