walton%DEImos.Caltech.Edu@Hamlet.Caltech.Edu (03/18/86)
From: walton%DEImos.Caltech.Edu@Hamlet.Caltech.Edu I downloaded this from CompuServe's AmigaForum last night, and I was sure the net would be interested. Based on this, I ordered Aztec C this morning. Manx is giving a $100 discount from the $299 developers' and $499 commercial package if you've already purchased Lattice C-- just give them the serial number of your Lattice package when you order. The developers' package includes compiler, assembler, overlay linker, full library interface to AmigaDOS and Intuition, and other goodies. The commercial package adds source to make, diff, grep, and z (a vi-like editor), a symbolic debugger, and a program to translate ALINK format object files into Aztec linker format (in case you don't have source). Steve Walton Caltech Solar Astronomy swalton@caltch.bitnet walton%deimos@hamlet.caltech.edu UUCP: ? -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Benchmarks for Aztec C versus Lattice C by: Rick Schaeffer March 9, 1986 Well, I finally got my Aztec C compiler!! Of course, the first thing I did was run a whole series of benchmarks to compare it with my Lattice C compiler. Since there's been so much interest in Lattice vs Aztec, I ran all the benchmarks I could get my hands on and made up the below table for anyone else who is interested. The rules under which the benchmarks were run were as follows: First, I used the default selections of both compilers as far as compile time options go since I wanted to compare "apples to apples" as much as possible. The Aztec compiler comes set up to take advantage of ram disk during compiles, so I used the "cc2" program with Lattice (which I've modified to, likewise, take advantage of ram disk for temporary files). The Aztec compiler automatically runs all passes of it's compiler...cc2 does the same thing...except it costs time to load cc2 itself, so I ran cc2 from ram disk...again attempting to compare apples to apples. Compile and link times were timed with a stopwatch and time was measured from hitting return after typing the command line to seeing the CLI prompt after the compile completed. Run time was obtained by calls to the Amiga Dos "Current_Time" function. Source for all of the programs, except the Dhrystone program, were obtained from the November, 1985 issue of Byte magazine. Source for the Dhrystone was obtained from the Compuserve Amiga Forum database. The large comment header was removed from the Dhrystone program...other than that the programs were entered VERBATIM as published in byte except for the timing routines (which were for the Macintosh)...I modified these to work with the Amiga. The Aztec compiler, by default, generates code that uses 16 bit integers, and the Lattice compiler uses 32 bit integers. However, the Aztec compiler has a compile-time switch that causes it to use 32 bit integers and there is a set of 32 bit libraries supplied with which to link such a program. Therefore, I ran the benchmarks twice for the Aztec compiler...once with the default of 16 bit integers, and again with the 32 bit option and libraries selected. All timings are in seconds and hundredths except the run time for the Dhrystone benchmark, which is in Dhrystones per second. I did not include timings for compile and link of the register variables versions of the benchmarks. They were insignificantly different from the times shown...which are for the non-register versions. Benchmark Results Frame Intmath Pointer Qsort Sieve Float Fib Dhrystone ------------------------------------------------------------------------ Compile Aztec(16) 21.44 26.58 23.29 27.07 24.70 26.07 23.67 36.26 Lattice 44.16 61.42 45.00 70.74 76.60 48.03 45.49 68.46 Aztec(32) 23.48 26.19 23.96 26.78 26.01 25.23 23.74 35.14 Link Aztec(16) 33.95 33.47 33.97 43.79 39.11 38.92 31.52 42.64 Lattice 112.34 109.79 111.73 112.00 116.49 114.34 115.35 112.64 Aztec(32) 35.52 30.64 33.64 41.86 40.49 38.42 32.99 39.47 Executable Module Size (No register variables) Aztec(16) 5012 5532 4996 9504 13432 5428 5124 6488 Lattice 13470 14108 13712 18224 22216 14336 13876 16040 Aztec(32) 5212 5772 5196 9684 13640 5628 5328 6812 Executable Module Size (With register variables) Aztec(16) 5012 5252 4988 9448 13380 N/A N/A 6328 Lattice 13744 14088 13704 18204 22184 N/A N/A 15996 Aztec(32) 5208 5488 5184 9628 13588 N/A N/A 6644 Run Time (No register variables) <Dhrystone in Dhrystones/second> Aztec(16) 0.00 4.34 19.77 55.23 4.80 15.90 19.55 1000 Lattice 0.10 21.77 16.85 56.40 5.96 118.32 22.70 454 Aztec(32) 0.10 9.82 19.88 61.55 5.87 15.90 22.59 704 Run Time (With register variables) <Dhrystone in Dhrystones/second> Aztec(16) 0.00 2.70 10.54 42.00 2.68 N/A N/A 1041 Lattice 0.00 21.40 10.53 44.60 3.98 N/A N/A 462 Aztec(32) 0.00 7.38 10.51 42.95 3.28 N/A N/A 769 A couple of notes about these timings: First, the run times are shown to the hundredth of a second....but I doubt the accuracy of the Amiga's clock at that resolution. I AM confident, however, that the timings are accurate to the tenth of a second. Second, the Aztec compiler supports and uses the Motorola Fast Floating Point library (FFP), whereas the Lattice compiler uses Lattice's own IEEE compatible floating point library. The Lattice compiler can be linked with the FFP libraries, but it doesn't use them by default...you have to do the function calls yourself. That is the reason there is such a LARGE difference in the floating point benchmark for run time. It is my understanding that the FFP library will be supported by the Lattice compiler in a future release. The Lattice compiler version I used for these benchmarks was 3.02. I understand that Lattice is now shipping version 3.03 but I have not as yet received my upgrade (this is being written on 3/9/86). The Aztec version used for the benchmarks was 3.20a. Rick Schaeffer E. 13611 26th Ave Spokane, Wa. 99216 Compuserve ID - 70120,174 Bix ID - ricks. Steve Walton ARPA: walton%deimos@hamlet.caltech.edu Caltech Solar Astronomy BITNET:swalton@caltech.bitnet Physics DECNET: DEIMOS::WALTON UUCP: your guess is as good as mine...