This revision was automatically updated to reflect the committed changes.
yaxunl marked an inline comment as done.
Closed by commit rL266111: PR19957: [OpenCL] Incorrectly accepts implicit
address space conversion with… (authored by yaxunl).
Changed prior to commit:
Anastasia added a comment.
In http://reviews.llvm.org/D17412#391351, @Matt wrote:
> In http://reviews.llvm.org/D17412#391322, @Anastasia wrote:
>
> > Cool, thanks! I think we should commit this ASAP.
> >
> > @Xiuli/@Matt, do you have any more comments here?
>
>
> Hi! I think that "Matt" for this
pxli168 accepted this revision.
pxli168 added a comment.
LGTM!
Thanks!
http://reviews.llvm.org/D17412
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Matt added a comment.
In http://reviews.llvm.org/D17412#391322, @Anastasia wrote:
> Cool, thanks! I think we should commit this ASAP.
>
> @Xiuli/@Matt, do you have any more comments here?
Hi! I think that "Matt" for this one would be @arsenm :-)
http://reviews.llvm.org/D17412
Anastasia added a subscriber: Matt.
Anastasia added a comment.
Cool, thanks! I think we should commit this ASAP.
@Xiuli/@Matt, do you have any more comments here?
http://reviews.llvm.org/D17412
___
cfe-commits mailing list
yaxunl marked 2 inline comments as done.
Comment at: test/CodeGenOpenCL/address-spaces-conversions.cl:1
@@ -1,2 +1,2 @@
// RUN: %clang_cc1 %s -triple x86_64-unknown-linux-gnu -O0
-ffake-address-space-map -cl-std=CL2.0 -emit-llvm -o - | FileCheck %s
Anastasia
yaxunl updated this revision to Diff 52080.
yaxunl marked 3 inline comments as done.
yaxunl added a comment.
Add back a blank line deleted by accident.
Add OpenCL to a comment.
http://reviews.llvm.org/D17412
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/AST/ASTContext.cpp
Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.
LGTM, please correct two small issues commented here!
Comment at: lib/Sema/SemaExpr.cpp:169
@@ -168,4 +168,3 @@
break;
-
bool Warn =
yaxunl updated this revision to Diff 52073.
yaxunl marked 6 inline comments as done.
yaxunl added a comment.
Revised by Anastasia's comments.
Added comments to code for cases 1a-c and 2a-c.
Added codegen test for missing cases of 1a-b and 2a-b.
Rename variables in sema test.
yaxunl added inline comments.
Comment at: test/SemaOpenCL/address-spaces-conversions-cl2.0.cl:276
@@ +275,3 @@
+ constant char *arg_const_ch;
+ var_void_const = 0 ? var_cond : arg_const_ch;
+#ifndef CONSTANT
Anastasia wrote:
> btw, what happens if we assign
yaxunl marked 6 inline comments as done.
Comment at: lib/AST/ASTContext.cpp:7613
@@ +7612,3 @@
+if (getLangOpts().OpenCL) {
+ if (LHS.getUnqualifiedType() != RHS.getUnqualifiedType() ||
+ LQuals.getCVRQualifiers() != RQuals.getCVRQualifiers())
Anastasia added a comment.
LG, apart from small comments mentioned here.
Comment at: lib/AST/ASTContext.cpp:7613
@@ +7612,3 @@
+if (getLangOpts().OpenCL) {
+ if (LHS.getUnqualifiedType() != RHS.getUnqualifiedType() ||
+ LQuals.getCVRQualifiers() !=
yaxunl removed rL LLVM as the repository for this revision.
yaxunl updated this revision to Diff 51460.
yaxunl marked 13 inline comments as done.
yaxunl added a comment.
Added comments. Revised test.
http://reviews.llvm.org/D17412
Files:
include/clang/Basic/DiagnosticSemaKinds.td
pxli168 added inline comments.
Comment at: lib/AST/ASTContext.cpp:7613
@@ +7612,3 @@
+if (getLangOpts().OpenCL) {
+ if (LHS.getUnqualifiedType() != RHS.getUnqualifiedType() ||
+ LQuals.getCVRQualifiers() != RQuals.getCVRQualifiers())
Anastasia
pxli168 added a comment.
The logic is still to complex and I hope it can be optimized.
Comment at: lib/Sema/SemaExpr.cpp:6222-6227
@@ -6188,1 +6221,8 @@
+auto ResultAddrSpace = ResultTy.getQualifiers().getAddressSpace();
+LHSCastKind = lhQual.getAddressSpace() ==
yaxunl added inline comments.
Comment at: lib/AST/ASTContext.cpp:7605
@@ -7604,3 +7604,3 @@
// If two types are identical, they are compatible.
if (LHSCan == RHSCan)
return LHS;
Anastasia wrote:
> I feel like the AS check should be lifted here instead,
yaxunl updated this revision to Diff 49232.
yaxunl marked 7 inline comments as done.
yaxunl added a comment.
Revised as Anastasis suggested.
Modified mergeTypes() for un-handled case.
Separate sema tests for condition operator to a new file.
Repository:
rL LLVM
Anastasia added a comment.
I think we are not covering all the possible cases with tests now! May be we
could also create a separate cl file since it becomes quite large.
Comment at: lib/AST/ASTContext.cpp:7605
@@ -7604,3 +7604,3 @@
// If two types are identical, they are
yaxunl marked 2 inline comments as done.
Comment at: lib/Sema/SemaExpr.cpp:6194-6203
@@ +6193,12 @@
+
+ incompatTy = S.Context.getPointerType(
+ S.Context.getAddrSpaceQualType(S.Context.VoidTy, ResultAddrSpace));
+ LHS = S.ImpCastExprToType(LHS.get(),
pxli168 added inline comments.
Comment at: lib/Sema/SemaExpr.cpp:6194-6203
@@ +6193,12 @@
+
+ incompatTy = S.Context.getPointerType(
+ S.Context.getAddrSpaceQualType(S.Context.VoidTy, ResultAddrSpace));
+ LHS = S.ImpCastExprToType(LHS.get(), incompatTy,
+
yaxunl updated the summary for this revision.
yaxunl removed a reviewer: pekka.jaaskelainen.
yaxunl added a subscriber: pekka.jaaskelainen.
yaxunl set the repository for this revision to rL LLVM.
yaxunl updated this revision to Diff 48967.
yaxunl marked 5 inline comments as done.
yaxunl added a
21 matches
Mail list logo