summaryrefslogtreecommitdiff
path: root/benchmarks/bytebench
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2002-01-09 11:24:36 +0000
committerjlam <jlam@pkgsrc.org>2002-01-09 11:24:36 +0000
commitbf18695c94aa75ede108497439be02394765437c (patch)
treed1051dadf4f472609d558e01f4a1b1513263a30a /benchmarks/bytebench
parentc92e35f1bcca634f71e7014db9834a5218cd92e5 (diff)
downloadpkgsrc-bf18695c94aa75ede108497439be02394765437c.tar.gz
Update bytebench to 4.1.0. Pkgsrc changes from the previous package include
moving the state directory for bytebench to /var/benchmarks instead of trying to keep state in ${PREFIX}/share/bytebench. Distribution changes from version 3.6 include: * Double precision Whetstone instead of the old "double" benchmark. * Removal of some obsolete files. * "system" suite adds shell8. * perlbench and poll added as "exhibition" (non-index) benchmarks. * Minor change to fstime.c to fix overflow problems on fast machines. * A lot more operating system-oriented tests into the index. * Many tests rewritten to be more relevant for modern processors. * New baseline: SPARCstation 20-61 with 128 MB RAM, a SPARC Storage Array, and Solaris 2.3
Diffstat (limited to 'benchmarks/bytebench')
-rw-r--r--benchmarks/bytebench/DESCR6
-rw-r--r--benchmarks/bytebench/Makefile34
-rw-r--r--benchmarks/bytebench/PLIST15
-rw-r--r--benchmarks/bytebench/distinfo12
-rw-r--r--benchmarks/bytebench/patches/patch-aa96
-rw-r--r--benchmarks/bytebench/patches/patch-ab40
-rw-r--r--benchmarks/bytebench/patches/patch-ac61
7 files changed, 138 insertions, 126 deletions
diff --git a/benchmarks/bytebench/DESCR b/benchmarks/bytebench/DESCR
index 226b8113473..d5afc9462bb 100644
--- a/benchmarks/bytebench/DESCR
+++ b/benchmarks/bytebench/DESCR
@@ -1,5 +1,5 @@
BYTE's UNIX benchmarking suite is small enough to port easily to any UNIX
system, yet diverse and flexible enough to be useful for a wide spectrum of
-benchmarking requirements. Besides, they're in the public domain, so they can
-be obtained for little, if any, cost. What better reason do you need to use
-them?
+benchmarking requirements. Besides, they're in the public domain, so they
+can be obtained for little, if any, cost. What better reason do you need to
+use them?
diff --git a/benchmarks/bytebench/Makefile b/benchmarks/bytebench/Makefile
index 8dad7bdf80f..5c8ec42b6bf 100644
--- a/benchmarks/bytebench/Makefile
+++ b/benchmarks/bytebench/Makefile
@@ -1,9 +1,10 @@
-# $NetBSD: Makefile,v 1.11 2001/04/09 11:45:36 wiz Exp $
+# $NetBSD: Makefile,v 1.12 2002/01/09 11:24:37 jlam Exp $
-DISTNAME= byte
-PKGNAME= bytebench-3.6
+DISTNAME= unixbench-4.1.0
+PKGNAME= bytebench-4.1.0
CATEGORIES= benchmarks
-MASTER_SITES= ftp://ftp.cdrom.com/pub/unix-c/benchmarks/
+MASTER_SITES= http://www.tux.org/pub/tux/benchmarks/System/unixbench/
+EXTRACT_SUFX= .tgz
MAINTAINER= root@garbled.net
COMMENT= BYTE Magazine's Public Domain benchmark for UNIX
@@ -11,13 +12,20 @@ COMMENT= BYTE Magazine's Public Domain benchmark for UNIX
BENCHMARK_ENV+= BINDIR=${WRKSRC}/pgms
BENCHMARK_ENV+= SCRPDIR=${WRKSRC}/pgms
BENCHMARK_ENV+= RESULTDIR=${WRKSRC}/results
-BENCHMARK_ENV+= TESTDIR=${WRKSRC}/testdir
+BENCHMARK_ENV+= BENCHDIR=${WRKSRC}/testdir
+BENCHMARK_ENV+= TESTDIR=${WRKSRC}/tmp
+
+OWN_DIRS= /var/bytebench
+
+post-extract:
+ ${RM} -f ${WRKSRC}/pgms/select
post-patch:
- ${SED} -e 's|@PREFIX@|${PREFIX}|' ${WRKSRC}/Run >${WRKSRC}/run-byte
+ cd ${WRKSRC}; ${SED} -e "s|@PREFIX@|${PREFIX}|g" Run > run-byte
+ ${CHMOD} +x ${WRKSRC}/run-byte
pre-install:
- ${FIND} ${WRKSRC} -name "*.orig" -exec ${RM} {} \;
+ ${FIND} ${WRKSRC} -name "*.orig" | ${XARGS} ${RM} -f
do-install:
${INSTALL_DATA_DIR} ${PREFIX}/libexec/bytebench
@@ -25,16 +33,20 @@ do-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/bytebench
${INSTALL_DATA} ${WRKSRC}/testdir/* ${PREFIX}/share/bytebench
${INSTALL_DATA_DIR} ${PREFIX}/share/doc/bytebench
- ${INSTALL_DATA} ${WRKSRC}/doc/* ${PREFIX}/share/doc/bytebench
+ ${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/bytebench
${INSTALL_SCRIPT} ${WRKSRC}/run-byte ${PREFIX}/bin
benchmark:
- @if [ `${ID} -u` != 0 ]; then ${ECHO} "This benchmark must be run as root!" ; exit 1 ; fi
- @${SETENV} ${BENCHMARK_ENV} ${WRKSRC}/run-byte \
- | tee ${WRKSRC}/bytebench.out
+ @if [ `${ID} -u` != 0 ]; then \
+ ${ECHO} "This benchmark must be run as root!"; \
+ exit 1; \
+ fi
+ @( cd ${WRKSRC}; ${SETENV} ${BENCHMARK_ENV} ./run-byte \
+ | tee bytebench.out )
results:
@${MKDIR} /tmp/benches/`domainname`
-@${CP} ${WRKSRC}/bytebench.out /tmp/benches/`domainname`/bytebench.`uname`-`uname -m`-`uname -r`.`hostname`
+.include "../../mk/bsd.pkg.install.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/bytebench/PLIST b/benchmarks/bytebench/PLIST
index fa741f5154c..94611a9f607 100644
--- a/benchmarks/bytebench/PLIST
+++ b/benchmarks/bytebench/PLIST
@@ -1,7 +1,6 @@
-@comment $NetBSD: PLIST,v 1.1 2001/10/31 23:45:11 zuntum Exp $
+@comment $NetBSD: PLIST,v 1.2 2002/01/09 11:24:37 jlam Exp $
bin/run-byte
libexec/bytebench/arithoh
-libexec/bytebench/byte.logo
libexec/bytebench/cleanup.sh
libexec/bytebench/context1
libexec/bytebench/dhry2
@@ -10,6 +9,8 @@ libexec/bytebench/double
libexec/bytebench/execl
libexec/bytebench/float
libexec/bytebench/fs.awk
+libexec/bytebench/fsbuffer
+libexec/bytebench/fsdisk
libexec/bytebench/fstime
libexec/bytebench/hanoi
libexec/bytebench/index.awk
@@ -20,7 +21,10 @@ libexec/bytebench/long
libexec/bytebench/looper
libexec/bytebench/loopm.awk
libexec/bytebench/loops.awk
+libexec/bytebench/lps.awk
libexec/bytebench/multi.sh
+libexec/bytebench/mwips.awk
+libexec/bytebench/perlbench
libexec/bytebench/pipe
libexec/bytebench/register
libexec/bytebench/report.awk
@@ -29,11 +33,12 @@ libexec/bytebench/short
libexec/bytebench/spawn
libexec/bytebench/syscall
libexec/bytebench/tst.sh
+libexec/bytebench/unixbench.logo
+libexec/bytebench/whetstone-double
share/bytebench/cctest.c
share/bytebench/dc.dat
share/bytebench/sort.src
-share/doc/bytebench/bench.doc
-share/doc/bytebench/bench3.doc
+share/doc/bytebench/README
@dirrm share/doc/bytebench
-@unexec rm -rf %D/share/bytebench
+@dirrm share/bytebench
@dirrm libexec/bytebench
diff --git a/benchmarks/bytebench/distinfo b/benchmarks/bytebench/distinfo
index c26d85ae475..402b3dcecfd 100644
--- a/benchmarks/bytebench/distinfo
+++ b/benchmarks/bytebench/distinfo
@@ -1,9 +1,9 @@
-$NetBSD: distinfo,v 1.2 2001/04/20 09:13:23 agc Exp $
+$NetBSD: distinfo,v 1.3 2002/01/09 11:24:37 jlam Exp $
-SHA1 (byte.tar.gz) = 6422135370f0e2ba908005d27c7351ef3a89c5b8
-Size (byte.tar.gz) = 45402 bytes
-SHA1 (patch-aa) = 6b2e97cb17fae0cc2f088f9e7819576fea7955ff
-SHA1 (patch-ab) = 4cdd6cbe25018e8643a049aa1034a6e557714bac
-SHA1 (patch-ac) = 83282687132e6a78f2614d418fb336a79ccb58f4
+SHA1 (unixbench-4.1.0.tgz) = 0a43d9cf08869c0f81bde4647be6bcf76c064248
+Size (unixbench-4.1.0.tgz) = 63075 bytes
+SHA1 (patch-aa) = e99170aaa9100486ef4e62387a0795dd4372f157
+SHA1 (patch-ab) = b018ad36a3a72b16bb29e8049a7bfe172888b5b8
+SHA1 (patch-ac) = ebfb09da84c96f8c6f48293c65a74dcf8a43cff5
SHA1 (patch-ad) = 3a1b788d9fa51fc168d59d8c87b1f476df2d5f41
SHA1 (patch-ae) = fbbce3deed7f0421034c1d57b66b1967ad8bddf1
diff --git a/benchmarks/bytebench/patches/patch-aa b/benchmarks/bytebench/patches/patch-aa
index 191fa0dd32b..49a653993e6 100644
--- a/benchmarks/bytebench/patches/patch-aa
+++ b/benchmarks/bytebench/patches/patch-aa
@@ -1,48 +1,32 @@
-$NetBSD: patch-aa,v 1.5 2000/08/04 08:50:17 jlam Exp $
+$NetBSD: patch-aa,v 1.6 2002/01/09 11:24:37 jlam Exp $
---- Run.orig Sat May 13 15:32:15 1995
-+++ Run Fri Aug 4 02:24:27 2000
-@@ -1,6 +1,6 @@
- #! /bin/sh
- #################### set your defaults here ##############
--FLAVOR="" # flavor of UNIX: if not determined by script: SysV or BSD
-+FLAVOR="NetBSD" # flavor of UNIX: if not determined by script: SysV or BSD
- FULL_SUITE="dhry2 dhry2reg arithoh register short int long float double syscall pipe context1 spawn execl fstime C shell dc hanoi"
- ###############################################################################
- # The BYTE UNIX Benchmarks - Release 3
-@@ -50,7 +50,7 @@
- if [ -z "$FLAVOR" ]
- then
- # determine flavor of UNIX from number of lines generated by /bin/tim
-- Fcount=`/bin/time date 2>&1 | wc -l | sed 's/ //g'`
-+ Fcount=`/usr/bin/time date 2>&1 | wc -l | sed 's/ //g'`
- case "$Fcount"
- in
- 2) FLAVOR="BSD";;
-@@ -66,45 +66,39 @@
- else UNAME="hostname"
+--- Run.orig Wed Jul 28 15:04:47 1999
++++ Run
+@@ -87,51 +87,50 @@
+ UNAME="uname -a"
fi
- export FLAVOR
+
-# check that the required files are in the proper places
--if make check
-- then :
-- else make all
+-if make check; then
+- :
+-else
+- make all
-fi
--#
- #
+-
+-
# establish full paths to directories
- PWD=`pwd`
+ _WD=`pwd`
-HOMEDIR=${HOMEDIR-.}
+HOMEDIR=@PREFIX@
cd $HOMEDIR
HOMEDIR=`pwd`
- cd $PWD
+ cd $_WD
-BINDIR=${BINDIR-${HOMEDIR}/pgms}
+BINDIR=${BINDIR-${HOMEDIR}/libexec/bytebench}
cd $BINDIR
BINDIR=`pwd`
- cd $PWD
+ cd $_WD
# let's extend the path to this directory
PATH="${PATH}:${BINDIR}"
@@ -50,38 +34,46 @@ $NetBSD: patch-aa,v 1.5 2000/08/04 08:50:17 jlam Exp $
+SCRPDIR=${SCRPDIR-${HOMEDIR}/libexec/bytebench}
cd $SCRPDIR
SCRPDIR=`pwd`
- cd $PWD
+ cd $_WD
-TMPDIR=${HOMEDIR}/tmp
-+TMPDIR=${RESULTDIR-${HOMEDIR}/share/bytebench}
++TMPDIR=${TMPDIR-/tmp}
cd $TMPDIR
TMPDIR=`pwd`
- cd $PWD
+ cd $_WD
-RESULTDIR=${RESULTDIR-${HOMEDIR}/results}
-+RESULTDIR=${RESULTDIR-${HOMEDIR}/share/bytebench}
++RESULTDIR=${RESULTDIR-/var/bytebench}
cd $RESULTDIR
RESULTDIR=`pwd`
- cd $PWD
+ cd $_WD
TIMEACCUM=${TIMEACCUM-${RESULTDIR}/times}
-TESTDIR=${TESTDIR-${HOMEDIR}/testdir}
-+TESTDIR=${TESTDIR-${HOMEDIR}/share/bytebench}
++BENCHDIR=${BENCHDIR-${HOMEDIR}/share/bytebench}
++cd $BENCHDIR
++BENCHDIR=`pwd`
++cd $_WD
++
++TESTDIR=${TESTDIR-${TMPDIR}/bytebench}
++mkdir -p -m 0700 ${TESTDIR}
++cp ${BENCHDIR}/* ${TESTDIR}
cd $TESTDIR
TESTDIR=`pwd`
- cd $PWD
-@@ -417,11 +411,10 @@
- ############ THE BENCH IS TIMED ##############
- if test "$stdin" = ""
- then # without redirected stdin
-- /bin/time $prog $opt $bgstr 2>>$TMPTIMES >>$stdout
-+ /usr/bin/time $prog $opt $bgstr 2>>$TMPTIMES >>$stdout
- else # with redirected stdin
-- /bin/time $prog $opt $bgstr <$stdin 2>>$TMPTIMES >>$stdout
-+ /usr/bin/time $prog $opt $bgstr <$stdin 2>>$TMPTIMES >>$stdout
- fi
-- /bin/time $benchcmd
- ###############################################
- cd $pwd # move back home
- status=$? # save the result code
+ cd $_WD
+
+-export BINDIR TMPDIR RESULTDIR PATH TESTDIR TIMEACCUM
++export BINDIR TMPDIR RESULTDIR PATH TESTDIR TIMEACCUM BENCHDIR
+ #
+ cat ${BINDIR}/unixbench.logo # display banner
+ rm -f ${TIMEACCUM} # clean out old time accumulation file
+@@ -531,6 +530,8 @@
+ echo "=============================================================="
+ cat $REPORTLOG
+ fi
++
++rm -rf $TESTDIR
+
+ exit 0
+ ########################### Amen ######################
diff --git a/benchmarks/bytebench/patches/patch-ab b/benchmarks/bytebench/patches/patch-ab
index 1b322954a45..d36c8a31386 100644
--- a/benchmarks/bytebench/patches/patch-ab
+++ b/benchmarks/bytebench/patches/patch-ab
@@ -1,22 +1,24 @@
-$NetBSD: patch-ab,v 1.1 1998/09/01 04:07:33 garbled Exp $
---- src/context1.c.orig Mon Aug 31 06:33:46 1998
-+++ src/context1.c Mon Aug 31 20:54:52 1998
-@@ -25,6 +25,9 @@
- #include <stdio.h>
- #include "timeit.c"
- #include <errno.h>
-+#include <sys/types.h>
-+#include <unistd.h>
-+#include <stdlib.h>
+$NetBSD: patch-ab,v 1.2 2002/01/09 11:24:37 jlam Exp $
+
+--- Makefile.orig Wed Jul 28 15:05:02 1999
++++ Makefile
+@@ -31,8 +31,8 @@
+ ID="@(#)Makefile:3.9 -- 5/15/91 19:30:15";
+ SHELL = /bin/sh
+ #HZ = ???? #(read from environment)
+-CFLAGS = -DTIME
+-CC=gcc
++CFLAGS += -DTIME
++#CC=gcc
- unsigned long iter;
+ ## For Linux 486/Pentium, GCC 2.7.x and 2.8.x
+ #OPTON = -O2 -fomit-frame-pointer -fforce-addr -fforce-mem -ffast-math \
+@@ -54,7 +54,7 @@
+ #CFLAGS = -DTIME -std1 -verbose -w0
-@@ -39,7 +42,7 @@
- char *argv[];
- {
- int duration;
-- int check;
-+ unsigned long check;
- int p1[2], p2[2];
+ ## generic gcc CFLAGS. -DTIME must be included
+-CFLAGS = -DTIME -Wall -pedantic -ansi
++CFLAGS += -DTIME -Wall -pedantic -ansi
- if (argc != 2) {
+ # local directories
+ PROGDIR = ./pgms
diff --git a/benchmarks/bytebench/patches/patch-ac b/benchmarks/bytebench/patches/patch-ac
index ee079a45f4c..de3b3969e5a 100644
--- a/benchmarks/bytebench/patches/patch-ac
+++ b/benchmarks/bytebench/patches/patch-ac
@@ -1,23 +1,20 @@
-$NetBSD: patch-ac,v 1.2 2000/01/05 12:23:56 agc Exp $
+$NetBSD: patch-ac,v 1.3 2002/01/09 11:24:37 jlam Exp $
---- src/looper.c.orig Sat May 13 20:32:00 1995
-+++ src/looper.c Wed Jan 5 12:17:10 2000
-@@ -22,6 +22,9 @@
-
- #include <stdio.h>
+--- src/looper.c.orig Wed Jul 28 14:45:08 1999
++++ src/looper.c
+@@ -26,6 +26,7 @@
+ #include <stdlib.h>
+ #include <sys/wait.h>
#include "timeit.c"
-+#include <sys/time.h>
-+#include <sys/wait.h>
+#include <sys/param.h>
unsigned long iter;
char *cmd_argv[28];
-@@ -84,14 +87,30 @@
- perror("Reason");
+@@ -88,12 +89,34 @@
exit(2);
}
-- else
-+ else {
+ else
++ {
/* master */
wait(&status);
- if (status != 0)
@@ -26,25 +23,29 @@ $NetBSD: patch-ac,v 1.2 2000/01/05 12:23:56 agc Exp $
- exit(2);
+#if (defined(NetBSD) && (NetBSD < 199810))
+ /* NetBSD 1.3H and lower have a bug in dc */
-+ if (strcmp(cmd_argv[0],"dc") != 0) {
-+ if (WIFSIGNALED(status)) {
-+ printf("signaled: %d\n",WTERMSIG(status));
-+ exit(2);
-+ }
-+ if (WIFEXITED(status)) {
-+ if (WEXITSTATUS(status) != 0) {
-+ printf("Exit code: %d\n",WEXITSTATUS(status));
-+ exit(2);
-+ }
-+ }
-+ } /* NetBSD 1.3H */
++ if (strcmp(cmd_argv[0],"dc") != 0)
++ {
++ if (WIFSIGNALED(status))
++ {
++ printf("signaled: %d\n",WTERMSIG(status));
++ exit(2);
++ }
++ if (WIFEXITED(status))
++ {
++ if (WEXITSTATUS(status) != 0)
++ {
++ printf("Exit code: %d\n",WEXITSTATUS(status));
++ exit(2);
++ }
++ }
++ } /* NetBSD 1.3H */
+#else
-+ if (status != 0) {
-+ printf("Bad wait status: 0x%x\n", status);
-+ exit(2);
- }
++ if (status != 0)
++ {
++ printf("Bad wait status: 0x%x\n", status);
++ exit(2);
++ }
+#endif
-+ } /* else */
+ }
iter++;
}
- }