Why Clang

文鳥 bunchou at googlemail.com
Wed Jun 6 19:11:54 UTC 2012

On Wed, 06 Jun 2012 19:05:59 +0100
Matthew Seaman <matthew at FreeBSD.org> wrote:

> On 06/06/2012 18:28, Thomas D. Dean wrote:
> > Has the discussion on why change to clang been made available?
> Yes, endlessly.  Mostly on lists like freebsd-hackers at ... and at
> various conferences and developer summits.  Check the list archives.
> > I would like to know the reasoning.
> It's simple.  gcc-4.2, which is what the base system compiler is
> derived from is:
>     * fairly old
>     * doesn't perform as well as more recent compilers
>     * doesn't adhere to recently established standards

There's another good reason for clang which nobody mentioned so far:
clear diagnostics. If you ever had to wade through gcc's debug output
and compare several thousand character long template instantiations,
just to find where they differ and then see the clear problem
descriptions that clang produces instead, you'll understand what I
And in combination with libc++, which just arrived on stable, I am
finally able to use all the features of C++11 that I want. Try to use
e.g. std::regex even on g++47, and just see what happens.
Of course, getting rid of GPL is an added benefit ;)
After reading all those complaints, I just had to respond and thank
everyone involved very much for importing clang and libc++. Great job
well done!

Best regards,

More information about the freebsd-questions mailing list