[cfe-dev] PCRE compiles fines and passes the test suite :)

Steve Naroff snaroff at apple.com
Thu Jan 31 08:22:52 PST 2008


On Jan 31, 2008, at 7:37 AM, Nuno Lopes wrote:

>>> ---
>>> compiler   | compile+link time | test suite run time | binary size
>>> gcc 4.1    |      17s          |       1.9s          |    43KB
>>> clang+llvm |    1m 13s         |       1.4s          |    188KB
>>> ---
>>>
>>> Although llvm is much slower at compiling (the linking part seems  
>>> to  be
>>> really slow due to the -O2 optimizations), the binary produced is  
>>> much
>>> faster :)
>>>
>>
>> This doesn't makes sense to me. Are you using an optimized "release"
>> version of clang?
>
> no, it was a debug build. With a release build of llvm, it takes  
> only 10
> seconds to build pcre! It's even faster than gcc 4.1 :)
> Of course this could still be better because of the overhead of the  
> ccc
> script.
>

Much better...:-) I'd be surprised if ccc is introducing much  
overhead. The best way to know is to measure. If you are running on  
Mac OS X, Shark is a wonderful performance analysis tool to tell us  
exactly where the overhead is.

>
>>> P.S.2.: why isn't LLVM deployed to replace gcc? isn't it capable  
>>> to  act
>>> as a
>>> drop-in replacement for gcc with the gcc front-end (for now)?
>
> Noone tackle this question.. My question is for real: can llvm  
> already be
> used as a drop-in replacement of gcc or not? e.g. can I already  
> rebuild my
> gentoo system (including the kernel) with llvm? :)
>

Chris is in the best position to answer your question (which is why I  
didn't respond to it).

>
> Nuno
>
> P.S.: the clang build is currently broken because of a commit to  
> LLVM's
> ADT/StringMap.h.
>

Good catch! Hopefully this will be fixed soon...

snaroff

> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev




More information about the cfe-dev mailing list