[PATCH] D71365: expand printf when compiling HIP to AMDGPU

Sameer Sahasrabuddhe via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 7 23:11:31 PST 2020


sameerds added a comment.

In D71365#1807872 <https://reviews.llvm.org/D71365#1807872>, @b-sumner wrote:

> Should this be looking forward to also handling OpenCL, which does require vector support?


Sure. The implementation is general enough that we can point at the two places in AMDGPUEmitPrintf.cpp that need to be enhanced for OpenCL:

1. processArg() should recognize a vector argument and transmit its elements to the host correctly.
2. locateCStrings() should deal with all the additional OpenCL specifiers (like vectors and half data-types) as needed.

Then depending on the input language, Clang codegen can indicate whether to support these extensions or emit an error.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D71365/new/

https://reviews.llvm.org/D71365





More information about the cfe-commits mailing list