[cfe-commits] [PATCH] Add -fobjc-direct-class-refs

John McCall rjmccall at apple.com
Tue May 15 10:42:55 PDT 2012

On May 15, 2012, at 9:34 AM, Jonathan Schleifer wrote:
> Am 15.05.2012 um 00:37 schrieb John McCall:
>> I just don't want it to be a command-line option.
> I can think of advantages of having it as a command line option, though:
> If a new runtime emerges, it does not need to patch clang, but instead it can use the -f switches.

If it decides that it's perfectly satisfied with the compiler-emitted structures of some existing runtime, yes.  This feels like a really weird constraint to force on oneself.

> And it also means if a runtime gains a new feature, it does not need to patch clang.

If that new feature happens to be implemented in exactly the same way as some existing runtime, yes.  Please remember that that is not even true for this patch.

The compiler is easy to patch, and when you're distributing your own custom runtime and your own make system, it's easy enough to say "for best performance, please make sure you have X version of the compiler".  I do not want to support an ad hoc runtime specification language in the command-line options.

> What about introducing a new -fobjc-runtime-features=foo,bar,baz with an alias for already known runtimes?

This has exactly the same problems.  The *concept* is flawed, not the spelling.


More information about the cfe-commits mailing list