Pipe element type spelling for arg info metadata should follow the same behavior as normal type spelling. We should not return the canonical type.
This patch also removed type handling duplication.
Paths
| Differential D96151
[OpenCL] Fix pipe type printing in arg info metadata ClosedPublic Authored by Anastasia on Feb 5 2021, 9:20 AM.
Details Summary Pipe element type spelling for arg info metadata should follow the same behavior as normal type spelling. We should not return the canonical type. This patch also removed type handling duplication.
Diff Detail
Event TimelineComment Actions This looks like a really good cleanup, in addition to fixing the metadata for pipes. Minor nit: "matadata" -> "metadata" in the description, and there's a StringRef construction that could be sunk.
Comment Actions Nice refactoring & fix! LGTM. I suppose Stuart's comment about moving typeNameRef can be addressed when pushing. This revision is now accepted and ready to land.Feb 8 2021, 1:44 AM Closed by commit rGecc8ac3f081b: [OpenCL] Fix pipe type printing in arg info metadata (authored by Anastasia). · Explain WhyFeb 8 2021, 8:05 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 322114 clang/lib/CodeGen/CodeGenModule.cpp
clang/test/CodeGenOpenCL/kernel-arg-info.cl
|
Would it be better to sink this into the if (Ty.isCanonical()) block?