[PATCH] D31321: [OpenCL] Do not generate "kernel_arg_type_qual" metadata for non-pointer args

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 30 10:33:00 PDT 2017


Anastasia accepted this revision.
Anastasia added a comment.
This revision is now accepted and ready to land.

LGTM!



================
Comment at: test/CodeGenOpenCL/kernel-arg-info.cl:66
 // CHECK: ![[MD13]] = !{!"int*", !"int", !"int", !"float*"}
-// CHECK: ![[MD14]] = !{!"restrict", !"const", !"volatile", !"restrict const"}
 // ARGINFO: ![[MD15]] = !{!"X", !"Y", !"anotherArg", !"Z"}
----------------
echuraev wrote:
> Anastasia wrote:
> > Could we modify the test to check that const and volatile are added for the pointers though?
> Added test case only for volatile pointer because const is checked in the Z argument of foo function.
I think it would still be nice to add an argument with explicit const because the current test doesn't have it explicitly.


https://reviews.llvm.org/D31321





More information about the cfe-commits mailing list