June 15, 2010
This post: http://www.realworldtech.com/forums/index.cfm?action=detail&id=110745&threadid=110549&roomid=2

...has made me realize that it would be very good for D if we had some good D-vs-C++ *compilation* benchmarks. Something template-heavy, and preferably real-world. Or maybe something specifically meta-programming-heavy that has four versions:

- C++ template metaprogramming without precompiled headers
- C++ template metaprogramming with precompiled headers
- D2 template metaprogramming
- D2 CTFE (while falling back on templates, of course, for anything that
can't be done in CTFE).

And, of course, have results for:

- DMD
- LDC (or maybe not, it's still D1-only, isn't it?)
- GDC, if it's gotten good enough yet (don't know, haven't been following
it)
- DMC (for apples-to-apples with DMD)
- GCC (to demonstrate a typical case, since GCC is so popular)
- GCC using the Gold linker (since it's the new poster boy for speedy C++
linking)
- LLVM's C++ compiler (I assume it has one, right?).

And, obviously, do a "clean" between each run...erm...I mean, between each compile.

Could be helpful for demonstrating things like just how much faster D compiles, and how with D it doesn't really matter if templates are slower than not using templates, and, of course, for sanity-checking all of our beliefs about D compilation speed.

Also would probably be good to read and heed the advice in here: http://www.zedshaw.com/essays/programmer_stats.html  ("Programmers Need To Learn Statistics Or I Will Kill Them All" <-- I love the article's name :) )

I don't have time to attempt this. Plus I'd have no idea what project to look for on the C++ side, and I'm completely out of practice on C++. Any takers?

-------------------------------
Not sent from an iPhone.


June 15, 2010
"Nick Sabalausky" <a@a.a> wrote in message news:hv8d7c$2e5f$1@digitalmars.com...
> This post: http://www.realworldtech.com/forums/index.cfm?action=detail&id=110745&threadid=110549&roomid=2
>
> ...has made me realize that it would be very good for D if we had some good D-vs-C++ *compilation* benchmarks. Something template-heavy, and preferably real-world. Or maybe something specifically meta-programming-heavy that has four versions:
>

Come to think of it, another good benchmark to have (not really a compilation benchmark this time, though) would be D (with and without FastCGI) vs PHP. Adam already posted some encouraging ad-hoc results, but a real benchmark would be a great thing to have. Would probably be difficult to design/run though. But if the overhead from using PHP really does rival or surpass the overhead from using plain vanilla CGI, then a reliable benchmark could clear up the long-held misconceptions about CGI, and give anyone who's server allows custom CGI an extra reason to go from PHP to D.


June 15, 2010
"Nick Sabalausky" <a@a.a> wrote in message news:hv8eoc$2gie$1@digitalmars.com...
> Adam already posted some encouraging ad-hoc results

s/ad-hoc/anecdotal/


June 15, 2010
Nick Sabalausky wrote:
> - LLVM's C++ compiler (I assume it has one, right?).
> 
	Not really. For the time being, it uses the gcc front-end (although
there are plans to add full C++ support to clang).

		Jerome
-- 
mailto:jeberger@free.fr
http://jeberger.free.fr
Jabber: jeberger@jabber.fr



June 15, 2010
Nick Sabalausky:
> ...has made me realize that it would be very good for D if we had some good D-vs-C++ *compilation* benchmarks. Something template-heavy, and preferably real-world. Or maybe something specifically meta-programming-heavy that has four versions:

See my point #7 here: http://www.digitalmars.com/webnews/newsgroups.php?art_group=digitalmars.D&article_id=111075 Of the program in point #3 you can compare both compilation time and runtime.

Bye,
bearophile
Top | Discussion index | About this forum | D home