Apple will use LLVM

Bill Nottingham notting at redhat.com
Thu Feb 16 16:12:06 UTC 2012


Vladimir Makarov (vmakarov at redhat.com) said: 
> >Since I was a bit (intentionally) curt and dismissive in my other
> >response in this thread, I'll add some anecdata here.  I have actually
> >tried building xserver with clang and running the standard set of
> >microbenchmarks.  I found one relevant path where the clang build was
> >~15% faster [1].  Something like 60% of the rest were within ±3%.  For
> >everything else clang was uniformly worse by usually about 5%.
> >
> The another usual mistake when people compare speed of GCC and LLVM
> is to use -O2 for the both compilers.  But the true is that -O1 of
> GCC is -O2 of LLVM with the point of code generation quality.  The
> compiler speed of GCC with -O1 is the same as for LLVM with -O2.
> You can find the latest comparison of LLVM and GCC on
> http://vmakarov.fedorapeople.org/spec/ (see 2011 comparison at the
> bottom of the left frame).

Speaking of potential magic bullets... is there any reason
we don't enable auto-vectorization by default (with -O3, or with the
assorted -f/-m flags?)

- Is it not stable enough?
- Does it not take effect often enough?
- Is it not done generically enough that we would run into instruction set
  problems? (I belive on x86_64 we can assume SSE2. x86 is a mess, obvs.)

Bill


More information about the devel mailing list