================ @@ -199,15 +214,31 @@ RValue CodeGenFunction::EmitAMDGPUDevicePrintfCallExpr(const CallExpr *E) { } llvm::Value *Arg = A.getRValue(*this).getScalarVal(); + if (isString(A.getType().getTypePtr()) && CGM.getLangOpts().OpenCL) ---------------- ssahasra wrote:
The typecast can be inserted later when the arguments are actually processed. At that point, we already know which args are strings because we have parsed the format string. https://github.com/llvm/llvm-project/pull/72556 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits