[PATCH] D134550: [Clang] Make Clang driver suggest '-Xclang' for CC1 options passed to the driver
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 26 14:37:49 PDT 2022
aaron.ballman added a comment.
In D134550#3813285 <https://reviews.llvm.org/D134550#3813285>, @jyknight wrote:
> In D134550#3813269 <https://reviews.llvm.org/D134550#3813269>, @aaron.ballman wrote:
>
>> Alternatively, perhaps those experimental options should be exposed from the driver instead of being a cc1-only flag?
>
> IMO: yes. If we want end-users to use a particular flag, we should expose it as a Driver flag. If we want to reserve the right to change or delete it, putting "experimental" in the name conveys that -- significantly more than telling users to spell the flag `-Xclang -foo` does.
Agreed, I think we should expose those flags via Driver with a sufficiently clear name rather than leave them in cc1.
> There's a real underlying problem here that the name `-Xclang` seems like "clang-specific flag" not "unstable internal API don't depend on me" -- to everyone who is not a Clang Driver developer...
Yeah, that's an excellent point! Perhaps we want to consider renaming that to something like `-X clang-internal-option` or something along those lines?
In D134550#3813523 <https://reviews.llvm.org/D134550#3813523>, @ychen wrote:
> Drive by thoughts: keyed this on assertion/debug build?
That's an interesting idea because it means the functionality is unlikely to get out to users in practice but folks working on Clang get some extra help.
In terms of this patch -- is there sentiment to revert (even temporarily while we discuss)?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134550/new/
https://reviews.llvm.org/D134550
More information about the cfe-commits
mailing list