[PATCH] D23086: [OpenCL] Generate concrete struct type for ndrange_t
Anastasia Stulova via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 15 10:21:54 PDT 2016
Anastasia added a comment.
In https://reviews.llvm.org/D23086#514279, @yaxunl wrote:
> How about we decide if a type is ndrange_t type based on their canonical types. If the canonical type of type X is the same as the canonical type of ndrange_t type, then type X is treated as ndrange_t type. Is this reasonable?
I am not sure I understand entirely what you mean?
Following the earlier suggestion from David, I think we can just create a struct type internally and then typedef it to ndrange_t, we can use buildImplicitRecord and addImplicitTypedef methods I believe. The latter one has already been used for other OpenCL types.
We will have to switch to string comparisons to identify this type in SemaChecking.cpp and CGBuiltins.cpp for handling the enqueue_kernel call.
Repository:
rL LLVM
https://reviews.llvm.org/D23086
More information about the cfe-commits
mailing list