[cfe-dev] GCC 4.6, LLVM/Clang 2.9, DragonEgg Five-System Benchmarks

John McCall rjmccall at apple.com
Wed Mar 30 02:01:48 PDT 2011


On Mar 30, 2011, at 1:16 AM, Konstantin Tokarev wrote:
> 30.03.2011, 11:26, "Nikola Smiljanic" <popizdeh at gmail.com>:
>> Just stumbled upon this and thought that someone might find it interestinghttp://www.phoronix.com/scan.php?page=article&item=gcc_46_llvm29
> 
> Can anyone explain significant superiority of DragonEgg over Clang is some tests?

Some of the tests are unoptimized compiles, apparently by accident,
which I believe accounts for all the really dramatic differences.  If you're
interested in knowing why the unoptimized speeds vary so much, that's
pretty simple.  DragonEgg's -O0 isn't "really" -O0, because it lowers
starting from a GCC IR that's already undergone SSA transformation,
which means it's already had a number of fundamental data-flow
optimizations applied.  Clang's -O0 code is noticeably worse than GCC's
because, in addition to disabling all IR and machine-level optimization,
we also use cheap-but-terrible instruction selection and register
allocation, whereas (IIRC) GCC uses its normal isel and RA algorithms.

John.



More information about the cfe-dev mailing list