================ @@ -5767,12 +5768,23 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, } else if (Triple.getArch() == llvm::Triple::x86_64) { Ok = llvm::is_contained({"small", "kernel", "medium", "large", "tiny"}, CM); - } else if (Triple.isNVPTX() || Triple.isAMDGPU()) { - // NVPTX/AMDGPU does not care about the code model and will accept + } else if (Triple.isNVPTX()) { + // NVPTX does not care about the code model and will accept // whatever works for the host. Ok = true; + } else if (Triple.isAMDGPU()) { + // AMDGPU does not care about the code model. + Ok = true; + // AMDGPU target ignores CM tiny and kernel. + if (CM == "tiny" || CM == "kernel") { + Skip = true; + D.Diag(diag::warn_ignored_clang_option) + << A->getSpelling() << CM << TripleStr; + } ---------------- arsenm wrote:
This is doing more than adding the test? https://github.com/llvm/llvm-project/pull/71019 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits