This revision was automatically updated to reflect the committed changes.
Closed by commit rG523775f96742: [OpenCL] Allow pointer-to-pointer kernel args
beyond CL 1.2 (authored by svenvh).
Changed prior to commit:
https://reviews.llvm.org/D92091?vs=308075&id=308607#toc
Repository:
rG LLVM Gi
svenvh added inline comments.
Comment at: clang/test/SemaOpenCL/invalid-kernel-parameters.cl:13
kernel void no_ptrptr(global int * global *i) { }
+kernel void no_ptrptrptr(global int * global * global *i) { }
Anastasia wrote:
> Btw this was missing in the orig
Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.
LGTM! Thanks!
The testing can be improved before committing!
Comment at: clang/lib/Sema/SemaDecl.cpp:8638
// array, this recursive call only happens once.
re
svenvh added inline comments.
Comment at: clang/lib/Sema/SemaDecl.cpp:8638
// array, this recursive call only happens once.
return getOpenCLKernelParameterType(S, QualType(UnderlyingTy, 0));
}
Anastasia wrote:
> Btw I am surprised that we recurse to
svenvh updated this revision to Diff 308075.
svenvh added a comment.
Recursively call `getOpenCLKernelParameterType` to check address spaces.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D92091/new/
https://reviews.llvm.org/D92091
Files:
clang/l
Anastasia added inline comments.
Comment at: clang/lib/Sema/SemaDecl.cpp:8638
// array, this recursive call only happens once.
return getOpenCLKernelParameterType(S, QualType(UnderlyingTy, 0));
}
Btw I am surprised that we recurse to check the underl
svenvh created this revision.
svenvh added a reviewer: Anastasia.
Herald added a subscriber: yaxunl.
Herald added a project: clang.
svenvh requested review of this revision.
The restriction on pointer-to-pointer kernel arguments has been
relaxed in OpenCL 2.0. Apply the same address space restric