Diag(clang::diag::err_drv_missing_argument) << A->getSpelling() << 1; Args.eraseArg(options::OPT__SLASH_o); } } handleArguments 这个函数都是对参数的一些额外处理,主要看生效的部分. 这个里面主要是增加了 -dumpdir a-.(这里也就是为何最终的output为a.out) if (FinalPhase == phases::Link...
I am interpreting your statement as suggesting we should do something like the following? const Arg *A = Args.getLastArg(options::OPT_fuse_ld_EQ); if (A->getValue() == "lld-link") { D.Diag(diag::err_drv_unsupported_option_argument) << A->getSpelling() << A->getValue(); } ...
empty()) { Diag(clang::diag::err_drv_no_input_files); return; } Arg *FinalPhaseArg; phases::ID FinalPhase = getFinalPhase(Args, &FinalPhaseArg); 这里有一个很关键的函数,叫做getFinalPhase,即我们最后会走到哪一个Phase. 我们跳进去看。 // -{E,EP,P,M,MM} only run the preprocessor...
Available add-ons Advanced Security Enterprise-grade security features GitHub Copilot Enterprise-grade AI features Premium Support Enterprise-grade 24/7 support Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Provide feedback We read every piece of ...
+ D.Diag(diag::err_drv_unsupported_opt_for_target) + << "-fxray-shared" << Triple.str(); + } + + unsigned PICLvl = std::get<1>(tools::ParsePICArgs(TC, Args)); + if (!PICLvl) { + D.Diag(diag::err_opt_not_valid_without_opt) << "-fxray-shared" ...
void Driver::BuildActions(Compilation &C, DerivedArgList &Args, const InputList &Inputs, ActionList &Actions) const { llvm::PrettyStackTraceString CrashInfo("Building compilation actions"); if (!SuppressMissingInputWarning && Inputs.empty()) { Diag(clang::diag::err_drv_no_input_files); retu...
void Driver::BuildActions(Compilation &C, DerivedArgList &Args, const InputList &Inputs, ActionList &Actions) const { llvm::PrettyStackTraceString CrashInfo("Building compilation actions"); if (!SuppressMissingInputWarning && Inputs.empty()) { Diag(clang::diag::err_drv_no_input_files); retu...
D.Diag(diag::err_drv_argument_not_allowed_with) << Desc << Triple.str(); } I think a good solution would be to print -mexecute-only (or -mpure-code) as the reason for the incompatibility if it was passed to the compiler driver, and print the target triple otherwise. Sign up...
() == types::TY_LLVM_BC) { - C.getDriver().Diag(diag::err_drv_no_linker_llvm_support) - << getToolChain().getTripleString(); - continue; - } - - // The 'nvlink' application performs RDC-mode linking when given a '.o' - // file and device linking when given a '.cubin...
namespaceoptions{/// Flags specifically for clang options. Must not overlap with/// llvm::opt::DriverFlag.enumClangFlags{DriverOption=(1<<4),LinkerInput=(1<<5),NoArgumentUnused=(1<<6),Unsupported=(1<<7),CoreOption=(1<<8),CLOption=(1<<9),CC1Option=(1<<10),CC1AsOption=(1<<11...