[PATCH] D16040: [OpenCL] Refine OpenCLImageAccessAttr to OpenCLAccessAttr
Xiuli PAN via cfe-commits
cfe-commits at lists.llvm.org
Sun Feb 21 22:12:06 PST 2016
pxli168 added inline comments.
================
Comment at: lib/Sema/SemaDeclAttr.cpp:5046
@@ +5045,3 @@
+ if (D->hasAttr<OpenCLAccessAttr>()) {
+ S.Diag(Attr.getLoc(), diag::err_opencl_multiple_access_qualifiers)
+ << D->getSourceRange();
----------------
Anastasia wrote:
> Yes, I think attribute would make more sense.
Already changed to attribute.
================
Comment at: lib/Sema/SemaDeclAttr.cpp:5061
@@ +5060,3 @@
+ if (S.getLangOpts().OpenCLVersion < 200 || DeclTy->isPipeType()) {
+ S.Diag(Attr.getLoc(), diag::err_opencl_invalid_read_write)
+ << PDecl->getType() << DeclTy->isImageType();
----------------
Anastasia wrote:
> Yes, w/o this attribute it would assume default access qualifier i.e. read_only. So I agree to point to the attribute here too.
Already done.
http://reviews.llvm.org/D16040
More information about the cfe-commits
mailing list