
60
(microcomputers, minicomputers) where Dhrystone is used
most.
There should be, as far as possible, only one C version
of Dhrystone such that results can be compared without
restrictions. In the past, the C versions distributed
by Rick Richardson (Version 1.1) and by Reinhold Weicker
had small (though not significant) differences.
2) As far as it is possible without changes to the
Dhrystone statistics, optimizing compilers should be
revented from removing significant statements.
This C version has been developed in cooperation with
Rick Richardson (Tinton Falls, NJ), it incorporates many
ideas from the "Version 1.1" distributed previously by
him over the UNIX network Usenet.
I also thank Chaim Benedelac (National Semiconductor),
David Ditzel (SUN), Earl Killian and John Mashey (MIPS),
Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley)
for their help with comments on earlier versions of the
benchmark.
Changes: In the initialization part, this version follows mostly
Rick Richardson's version distributed via Usenet, not
the version distributed earlier via floppy disk by
Reinhold Weicker.
As a concession to older compilers, names have been made
unique within the first 8 characters.
Inside the measurement loop, this version follows the
version previously distributed by Reinhold Weicker.
At several places in the benchmark, code has been added,
but within the measurement loop only in branches that
are not executed. The intention is that optimizing
compilers should be prevented from moving code out of
the easurement loop, or from removing code altogether.
Since the statements that are executed within the
measurement loop have NOT been changed, the numbers
defining the "Dhrystone distribution"(distribution of
statements, operand types and locality) still hold.
Except for sophisticated optimizing compilers, execution
times for this version should be the same as for previous
versions.
Since it has proven difficult to subtract the time for
the measurement loop overhead in a correct way, the loop
check has been made a part of the benchmark. This does
have an impact - though a very minor one - on the
distribution statistics which have been updated for this
version.
All changes within the measurement loop are described
and discussed in the companion paper "Rationale for
Dhrystone version 2".
Because of the self-imposed limitation that the order
and distribution of the executed statements should not
be changed, there are still cases where optimizing
compilers may not generate code for some statements. To
a certain degree, this is unavoidable for small
synthetic benchmarks.
Users of the benchmark are advised to check code
listings whether code is generated for all statements of
Dhrystone.