www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Re: Updated D Benchmarks

Robert Clipsham:
 This looks like the way to go for the benchmarks. When I've added all 
 the tests people have sent me and added a reference C++ result I will 
 put the results file under revision control with the rest of the source 
 code and set up a script to generate graphs to show results over time.

I have sent you an email with several benchmarks. In the meantime I have seen this tiny C++ Global Illumination in 99 lines: http://kevinbeason.com/smallpt/ There are other scenes available too: http://kevinbeason.com/smallpt/extraScenes.txt It's not meant to be fast, so surely there are ways to write much faster C++ code. But it's short enough, and the results are nice enough (even if slow) that it may be translated to D, for comparison. To run it with my MinGW I've had to add: inline double erand48() { return rand() / (double)RAND_MAX; } and replace erand48(...) with erand48(). The MinGW I use is based on GCC 4.3.1 but I have not used OpenMP, it's used in this code to essentially divide the running time by the number of available cores. Bye, bearophile
Mar 16 2009