plocher%sally@Sun.COM (John Plocher) (07/15/89)
+---- In gnu.gcc:<75@euteal.ele.tue.nl>, Mart van Stiphout writes: | people keep telling me that gcc generates very fast | code: 30% faster. Can anyone provide me with some benchmarks. +---- Note that Followups are to comp.unix.i386 On the 386 Gnu gcc is better than the standard pcc based compiler provided by ATT, but not much. It *is*, however, the best compiler in its price range :-) As always, errors are my fault, email to me if you find something to complain about. Don't clutter the net with noise postings, please. -John Plocher ----- ---- ----- cut -- here ---- ---- ---- Speed and size Benchmark results for V/386 C compilers Ken Chapin and John Plocher July, 1989 All executables were stripped and mcs -d'd to remove any unneeded "padding" from the sizes. They were timed on a Mylex 386 at 25mhz with 4mb of 32 bit memory with cache run- ning ATT 3.3.2 UNIX. A Weitek 3167 was used for the Weitek tests, software FP emulation in the kernel was used for the other FP tests. The test were run on a relatively quiescent system 3 times; the average of user + system (or dhrystones) time is given here. Tables are in "average" order - the speeds/sizes are averaged for each row, and ranked worst to best. dragon calculates <arg> points in a dragon curve; gauss does a gaussian elimination of a <arg> x <arg> array of random numbers; Bernoulli does mathematical convolutions and mandel generates (but does not display) a VGA sized man- delbrodt pointset. whetstone exercises many floating point operations including the trancendentals and is done with 100 iterations in both single and double(d) precision. e <arg> calculates 'e' to <arg> places; dhrystone is version 1.1 with 250,000 iterations. All compiles were done with optimization enabled. Benchmark code avaliable on request to plocher@sun.com PCC AT&T C 4.1.6 (as shipped with most V/386 systems) (no Weitek support) GNU Gnu gcc 1.35 (from prep.ai.mit.edu, default setup) (no Weitek support) GHS Green Hills C 1.8.3A (from Microport 3.0e SDS package) HI-C MetaWare High C 1.5 (Santa Cruz, CA 408/429-6382) SVS Silicon Valley Software C 2.8 (evaluation copy - distributor unknown) Floating Point Intensive Speed (seconds) Compiler dragon 100000 gauss 100 bernoulli 220 mandel whetstone whetstone(d) GNU 1000.96 434.37 510.82 120m13.24 616.40 562.83 PCC 907.26 318.66 407.89 88m59.75 704.05 601.98 SVS 679.30 312.27 411.85 65m42.34 575.70 534.91 GHS 781.15 371.73 624.46 52m53.84 352.81 315.52 HI-C 541.50 314.53 408.99 57m04.01 282.68 294.53 GNU (w/W) - - - - - - PCC (w/W) - - - - - - SVS (w/W) 5.56 3.98 4.23 15.88 3.58 3.69 GHS (w/W) 6.25 3.63 1.89 15.30 3.46 3.80 HI-C (w/W) 4.38 3.06 1.82 9.80 2.42 3.16 Size (bytes) Compiler dragon gauss bernoulli mandel whetstone GHS 17072 17148 20040 22664 28580 GNU 16696 16684 20064 22924 31332 PCC 16680 16908 19980 22532 32888 SVS 16516 16648 19968 22380 30108 HI-C 16616 16540 19868 18236 26192 GNU (w/W) - - - - - PCC (w/W) - - - - - GHS (w/W) 17388 15456 20112 23100 49596 SVS (w/W) 16940 15212 20160 22852 47616 HI-C (w/W) 16744 16576 19932 18280 44808 Strictly Integer Speed (seconds or dhrystones) Compiler e 2500 dhrystone(nr) dhrystone(r) PCC 3.92 7738 8333 GNU 3.88 8620 same as nr SVS 4.04 10277 same as nr HI-C 3.27 11033 same as nr GHS 3.42 11378 same as nr Size (bytes) Compiler e 2500 dhrystone(nr) dhrystone(r) PCC 20276 15712 15672 SVS 20376 15612 15608 GNU 20268 15544 15544 GHS 16444 15688 15688 HI-C 16244 15468 15476