[PATCH] D83665: [OpenCL] Fixed missing address space for templated copy constructor

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 17 10:24:40 PDT 2020


Anastasia added inline comments.


================
Comment at: clang/lib/Sema/SemaTemplateDeduction.cpp:3811
+      if(S.getLangOpts().OpenCL)
+        ArgType = S.deduceOpenCLPointeeAddrSpace(ArgType);
       ArgType = S.Context.getLValueReferenceType(ArgType);
----------------
I feel we can just add an address space explicitly since we are creating the type here for a known use case. However, does Arg actually have an address space? I am just unsure whether we should use generic address space or concrete address space.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D83665





More information about the cfe-commits mailing list