================ @@ -633,6 +633,17 @@ void amdgpu::Linker::ConstructJob(Compilation &C, const JobAction &JA, else if (Args.hasArg(options::OPT_mcpu_EQ)) CmdArgs.push_back(Args.MakeArgString( "-plugin-opt=mcpu=" + Args.getLastArgValue(options::OPT_mcpu_EQ))); + + // If the user's toolchain has the 'include/amdgcn-amd-amdhsa/` path, we + // assume it supports the standard C libraries for the GPU and include them. + bool HasLibC = getToolChain().getStdlibIncludePath().has_value(); ---------------- yxsamliu wrote:
maybe refactor as a member of ToolChain::addOffloadLibCArgs https://github.com/llvm/llvm-project/pull/98170 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits