[clang] [clang][Driver] Allow -fuse-lld=lld-link when lto is enabled on *windows-msvc targets (PR #113966)

Max Winkler via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 28 22:19:36 PDT 2024


MaxEW707 wrote:

> Windows should use `-fuse-ld=lld` as well, not `-fuse-ld=lld-link`

Is `-fuse-ld=lld-link` intended to be an allowable option?

Right now we don't issue any error if a user passes in `lld-link`.

I am interpreting your statement as suggesting we should do something like 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();
}
```

https://github.com/llvm/llvm-project/pull/113966


More information about the cfe-commits mailing list