This is an archive of the discontinued LLVM Phabricator instance.

[OpenCL][NFC] Unify ZeroToOCL* cast types
ClosedPublic

Authored by AlexeySachkov on Sep 28 2018, 8:09 AM.

Diff Detail

Repository
rC Clang

Event Timeline

AlexeySachkov created this revision.Sep 28 2018, 8:09 AM

This is an initial version. I guess there are some other enums related to CK_ZeroToOCL* which also can be merged.

Also, I'm not sure that CK_ZeroToOCLOpaqueType is a good name. Thoughts?

Anastasia added inline comments.Oct 2 2018, 10:14 AM
lib/Sema/SemaInit.cpp
5275–5277

Let's remove OpenCLVersion check here because we reject queue_t during parsing if cl-std!=CL2.0.

5279

I guess this one can't be generalized?

Applied comments from Anastasia. Updated patch with more code unified

AlexeySachkov marked an inline comment as done.Oct 10 2018, 1:26 AM
AlexeySachkov added inline comments.
lib/Sema/SemaInit.cpp
5279

Actually, it is generalized now

Anastasia accepted this revision.Oct 19 2018, 10:24 AM

LGTM! Thanks!

This revision is now accepted and ready to land.Oct 19 2018, 10:24 AM

Rebase to the ToT

This revision was automatically updated to reflect the committed changes.