rnk added a comment.

In D64458#1577435 <https://reviews.llvm.org/D64458#1577435>, @pcc wrote:

> Do we really need to support clang-cl syntax here? Can't the user of 
> -fthinlto-index= use the regular clang driver?


I think it depends on how many compiler flags we have to pass to backend 
compilation actions. I don't have a good sense of how many of those actually 
matter. Some flags affect the object file and are not encoded in bitcode, like 
-ffunction-sections. It's potentially onerous for a build system to have to 
work out for itself that `cl -O2` implicitly enables `-Gy`, which is the MSVC 
spelling of `-ffunction-sections`, so therefore we need this other set of 
backend action flags. It seems nicer to for the build system to just take the 
first stage command line and re-run it with a new input and this new flag.

If we want to make the behavior consistent, I would say we should port this new 
-x ir behavior over to clang so it's the same as clang-cl.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D64458/new/

https://reviews.llvm.org/D64458



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to