arsenm added inline comments.
================ Comment at: lib/CodeGen/CGCUDANV.cpp:205 + auto *Aux = CGM.getContext().getAuxTargetInfo(); + if (Aux && Aux->getTriple().getArch() == llvm::Triple::amdgcn) { + auto *ArgTy = Arg->getType()->getPointerElementType(); ---------------- yaxunl wrote: > arsenm wrote: > > Checking the specific target seems wrong. Shouldn't you just need to check > > if the value is byval or not? > This is in the host code gen for the kernel stub function, where the struct > argument is always by val for x86_64. We cannot use that to differentiate > between nvptx and amdgcn. No, you need to see what the lowering behavior is for the argument type in the device's calling convention CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55067/new/ https://reviews.llvm.org/D55067 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits