Clang: now available from a SVN server near you!

Pawel Worach pawel.worach at gmail.com
Thu Jun 11 17:09:29 UTC 2009


On Tue, Jun 9, 2009 at 12:17, Ed Schouten<ed at 80386.nl> wrote:
> * Pawel Worach <pawel.worach at gmail.com> wrote:
>> So runtime performance is on par with gcc, code size is a bit bigger
>> so there is still room for optimization in LLVM.
>
> I don't agree on the code size. Code size is comparable. I just did a
> quick ls through /bin. There also seem to be a lot of cases where Clang
> generates smaller binaries.
>
> Some time ago the binaries were indeed a lot bigger, but that turned out
> to be a bug in Clang, where a compiler flag had a wrong default value,
> namely the flag that determined whether zero-initialized data had to go
> in BSS or not.

Here are some updated results with llvm/clang r73189.

Compile time and executable size for amd64 LINT (without profiling
because clang does not support it yet):

clang:
314.582u 29.555s 5:44.72 99.8%  14250+2428k 0+0io 481pf+0w

  text            data     bss     dec     hex filename
18034015        3563057 2910192 24507264        175f380 kernel
-rwxr-xr-x  1 root  wheel  27208927 Jun 11 14:34 kernel

gcc:
510.206u 30.260s 8:56.93 100.6% 7032+2414k 0+0io 14pf+0w

  text            data     bss     dec     hex filename
17342564        2623505 2918704 22884773        15d31a5 kernel
-rwxr-xr-x  1 root  wheel  24115620 Jun 11 14:45 kernel

Also an updated ports/benchmarks/libmicro run available here:
http://www.vlakno.cz/~pwo/lm/2009-06-11/lm.html

-- 
Pawel


More information about the freebsd-current mailing list