summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgarbled <garbled>1998-12-26 15:59:54 +0000
committergarbled <garbled>1998-12-26 15:59:54 +0000
commit069601cc6968f844d963e20f6639ba6fd74b640c (patch)
tree6958f25a4817a66619dea1a60f9498023655b3f2
parent12f648cc39d932c1a94b5579dcb006fea47ac42f (diff)
downloadpkgsrc-069601cc6968f844d963e20f6639ba6fd74b640c.tar.gz
Fix all the benchmark targets so they work properly, and work with the
package uninstalled, with the exceptionof lmbench. Make non-batch targets for all the benchmarks, and create a results target which places all the results in /tmp for easier collection.
-rw-r--r--benchmarks/Makefile4
-rw-r--r--benchmarks/benchfft/Makefile17
-rw-r--r--benchmarks/benchfft/files/setup.answers16
-rw-r--r--benchmarks/bonnie/Makefile8
-rw-r--r--benchmarks/bytebench/Makefile8
-rw-r--r--benchmarks/dhrystone/Makefile10
-rw-r--r--benchmarks/fib/Makefile8
-rw-r--r--benchmarks/flops/Makefile8
-rw-r--r--benchmarks/hbench/Makefile15
-rw-r--r--benchmarks/hbench/files/setup.answers10
-rw-r--r--benchmarks/heapsort/Makefile8
-rw-r--r--benchmarks/hint/Makefile8
-rw-r--r--benchmarks/iozone/Makefile8
-rw-r--r--benchmarks/linpack/Makefile11
-rw-r--r--benchmarks/lmbench/Makefile18
-rw-r--r--benchmarks/lmbench/files/setup.answers9
-rw-r--r--benchmarks/nsieve/Makefile8
-rw-r--r--benchmarks/paranoia/Makefile8
-rw-r--r--benchmarks/whetstone/Makefile8
19 files changed, 147 insertions, 43 deletions
diff --git a/benchmarks/Makefile b/benchmarks/Makefile
index e85dbf17dab..ee613ecafce 100644
--- a/benchmarks/Makefile
+++ b/benchmarks/Makefile
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.12 1998/12/06 01:25:08 hubertf Exp $
+# $NetBSD: Makefile,v 1.13 1998/12/26 15:59:56 garbled Exp $
# FreeBSD Id: Makefile,v 1.4 1997/02/16 13:32:59 andreas Exp
#
-PKG_MISC_TARGETS?= benchmark
+PKG_MISC_TARGETS?= benchmark results
SUBDIR += benchfft
SUBDIR += bonnie
diff --git a/benchmarks/benchfft/Makefile b/benchmarks/benchfft/Makefile
index 1be6e338a1e..9a9f9b3563d 100644
--- a/benchmarks/benchfft/Makefile
+++ b/benchmarks/benchfft/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 1998/12/03 01:27:04 hubertf Exp $
+# $NetBSD: Makefile,v 1.3 1998/12/26 15:59:55 garbled Exp $
DISTNAME= benchfft-2.0
CATEGORIES= benchmarks math
@@ -27,12 +27,21 @@ do-install:
benchmark:
.if defined(BATCH)
- @${ECHO} "*** This benchmark may only be run in non-batch mode" ; \
- exit 1
+ @${ECHO} "*** This benchmark should be run in non-batch mode"
+ @${SED} -e 's|bench-fft|./bench|g' <${WRKSRC}/submit-script> ${WRKSRC}/run_bench
+ @chmod 755 ${WRKSRC}/run_bench
+ @${SED} -e 's|@machine@|'`uname -m`'|' \
+ ${FILESDIR}/setup.answers | (cd ${WRKSRC} ; ./run_bench)
.else
- @${WRKSRC}/submit-script
+ @${SED} -e 's|bench-fft|./bench|g' <${WRKSRC}/submit-script> ${WRKSRC}/run_bench
+ @chmod 755 ${WRKSRC}/run_bench
+ @(cd ${WRKSRC} ; ./run_bench)
@${ECHO} ${PKGNAME} results:
${CAT} submit.txt
.endif
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/submit.txt /tmp/benches/`domainname`/fft.`uname`-`uname -m`-`uname -r`.`hostname`
+
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/benchfft/files/setup.answers b/benchmarks/benchfft/files/setup.answers
new file mode 100644
index 00000000000..3ea6c331eca
--- /dev/null
+++ b/benchmarks/benchfft/files/setup.answers
@@ -0,0 +1,16 @@
+pkg run
+n
+n
+NetBSD
+NetBSD
+@machine@
+@machine@
+100
+64
+0
+NetBSD
+gcc
+y
+f77
+y
+Do not submit this form
diff --git a/benchmarks/bonnie/Makefile b/benchmarks/bonnie/Makefile
index 05638ba8319..c05ca742df7 100644
--- a/benchmarks/bonnie/Makefile
+++ b/benchmarks/bonnie/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.11 1998/09/24 09:20:08 agc Exp $
+# $NetBSD: Makefile,v 1.12 1998/12/26 15:59:55 garbled Exp $
# FreeBSD Id: Makefile,v 1.5 1997/11/26 23:09:14 jseger Exp
#
@@ -23,6 +23,10 @@ post-extract:
${MV} ${WRKSRC}/Bonnie.c ${WRKSRC}/bonnie.c
benchmark:
- @(cd ${WRKSRC}; ./bonnie)
+ @(cd ${WRKSRC}; ./bonnie | tee bonnie.out)
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/bonnie.out /tmp/benches/`domainname`/bonnie.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/bytebench/Makefile b/benchmarks/bytebench/Makefile
index 85296a80b6e..ff9f579910c 100644
--- a/benchmarks/bytebench/Makefile
+++ b/benchmarks/bytebench/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 1998/12/03 01:27:05 hubertf Exp $
+# $NetBSD: Makefile,v 1.4 1998/12/26 15:59:55 garbled Exp $
DISTNAME= byte
PKGNAME= bytebench-3.6
@@ -20,6 +20,10 @@ do-install:
benchmark:
@if [ `id -u` != 0 ]; then echo "This benchmark must be run as root!" ; exit 1 ; fi
- @${WRKSRC}/run-byte
+ @${WRKSRC}/run-byte | tee ${WRKSRC}/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.mk"
diff --git a/benchmarks/dhrystone/Makefile b/benchmarks/dhrystone/Makefile
index d4e1a080381..74daa74a499 100644
--- a/benchmarks/dhrystone/Makefile
+++ b/benchmarks/dhrystone/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 1998/09/24 09:23:32 agc Exp $
+# $NetBSD: Makefile,v 1.3 1998/12/26 15:59:55 garbled Exp $
DISTNAME= dhry2.1
PKGNAME= dhrystone-2.1
@@ -18,7 +18,11 @@ do-install:
${INSTALL_MAN} ${WRKSRC}/Rationale ${PREFIX}/share/doc/dhrystone
benchmark:
- -${ECHO} 1000000 | ${WRKSRC}/dry2
- -${ECHO} 1000000 | ${WRKSRC}/dry2reg
+ -@${ECHO} 5000000 | ${WRKSRC}/dry2 | tee ${WRKSRC}/dry.out
+ -@${ECHO} 5000000 | ${WRKSRC}/dry2reg | tee -a ${WRKSRC}/dry.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/dry.out /tmp/benches/`domainname`/dhrystone.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/fib/Makefile b/benchmarks/fib/Makefile
index 06c97aa0251..34937ecbcd3 100644
--- a/benchmarks/fib/Makefile
+++ b/benchmarks/fib/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1.1.1 1998/10/22 05:55:46 garbled Exp $
+# $NetBSD: Makefile,v 1.2 1998/12/26 15:59:55 garbled Exp $
DISTNAME= fib.c
PKGNAME= fib-980203
@@ -21,6 +21,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/fib ${PREFIX}/bin
benchmark:
- -@${WRKSRC}/fib
+ -@${WRKSRC}/fib | tee ${WRKSRC}/fib.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/fib.out /tmp/benches/`domainname`/fib.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/flops/Makefile b/benchmarks/flops/Makefile
index 94bbee02669..d22e567a456 100644
--- a/benchmarks/flops/Makefile
+++ b/benchmarks/flops/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1.1.1 1998/10/22 05:26:33 garbled Exp $
+# $NetBSD: Makefile,v 1.2 1998/12/26 15:59:55 garbled Exp $
DISTNAME= flops
PKGNAME= flops-2.0
@@ -25,6 +25,10 @@ do-install:
${INSTALL_DATA} ${WRKSRC}/flops.doc ${PREFIX}/share/doc/flops
benchmark:
- -@${WRKSRC}/flops
+ -@${WRKSRC}/flops | tee ${WRKSRC}/flops.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/flops.out /tmp/benches/`domainname`/flops.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/hbench/Makefile b/benchmarks/hbench/Makefile
index 2bbdf40830a..9c184a044ad 100644
--- a/benchmarks/hbench/Makefile
+++ b/benchmarks/hbench/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.6 1998/12/03 01:27:05 hubertf Exp $
+# $NetBSD: Makefile,v 1.7 1998/12/26 15:59:55 garbled Exp $
DISTNAME= hbench-OS-1.0
PKGNAME= hbench-1.0
@@ -42,10 +42,21 @@ do-install:
benchmark:
@if [ `id -u` != 0 ]; then echo "This benchmark must be run as root!" ; exit 1 ; fi
- @cd ${WRKSRC}; \
+ cd ${WRKSRC}; \
+ ${MKDIR} conf; \
+ ${MKDIR} results; \
${SED} -e 's|@pwd@|'`/bin/pwd`'|g' \
-e 's|@hostname@|'`/bin/hostname -s`'|g' \
+ -e 's|@wrksrc@|'`/bin/pwd`'|g' \
${FILESDIR}/setup.answers | ${MAKE} setup; \
+ ${MV} conf/`/bin/hostname -s`.run conf/foo ; \
+ ${SED} -e 's|#PLAINBINDIR=${HBENCHROOT}|PLAINBINDIR='`/bin/pwd`'|' \
+ < conf/foo > conf/`/bin/hostname -s`.run ; \
${MAKE} run
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cd ${WRKSRC} ; \
+ tar -cf /tmp/benches/`domainname`/hbench.`uname`-`uname -m`-`uname -r`.`hostname`.tar results conf
+
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/hbench/files/setup.answers b/benchmarks/hbench/files/setup.answers
index c75216c739d..c5294b9826b 100644
--- a/benchmarks/hbench/files/setup.answers
+++ b/benchmarks/hbench/files/setup.answers
@@ -3,13 +3,11 @@
+@wrksrc@/conf/full.test
+@wrksrc@/XXX
+@wrksrc@
-
-
-
-
-
+@pwd@/results
@pwd@/conf/@hostname@.run
-
diff --git a/benchmarks/heapsort/Makefile b/benchmarks/heapsort/Makefile
index 312b82e2118..55d2f77efc9 100644
--- a/benchmarks/heapsort/Makefile
+++ b/benchmarks/heapsort/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1.1.1 1998/10/22 06:07:24 garbled Exp $
+# $NetBSD: Makefile,v 1.2 1998/12/26 15:59:56 garbled Exp $
DISTNAME= heapsort.c
PKGNAME= heapsort-1.0
@@ -21,6 +21,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/heapsort ${PREFIX}/bin
benchmark:
- -@${WRKSRC}/heapsort
+ -@${WRKSRC}/heapsort | tee ${WRKSRC}/heapsort.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/heapsort.out /tmp/benches/`domainname`/heapsort.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/hint/Makefile b/benchmarks/hint/Makefile
index 968a96ed77b..938d250dfad 100644
--- a/benchmarks/hint/Makefile
+++ b/benchmarks/hint/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 1998/12/03 01:27:05 hubertf Exp $
+# $NetBSD: Makefile,v 1.4 1998/12/26 15:59:56 garbled Exp $
#
# New ports collection makefile for: hint
# Version required: 12 June 1998 (no version stamp)
@@ -26,6 +26,10 @@ do-install:
${INSTALL_MAN} ${WRKSRC}/hint.1 ${PREFIX}/man/man1
benchmark:
- cd ${WRKSRC} ; mkdir -p data ; ./DOUBLE
+ cd ${WRKSRC} ; mkdir -p data ; ./DOUBLE | tee hint.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/hint.out /tmp/benches/`domainname`/hint.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/iozone/Makefile b/benchmarks/iozone/Makefile
index 5d8a7e858af..957a2020aab 100644
--- a/benchmarks/iozone/Makefile
+++ b/benchmarks/iozone/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.4 1998/09/24 09:20:08 agc Exp $
+# $NetBSD: Makefile,v 1.5 1998/12/26 15:59:56 garbled Exp $
DISTNAME= iozone
PKGNAME= iozone-1.14b
@@ -17,6 +17,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/iozone ${PREFIX}/bin
benchmark:
- @(cd ${WRKSRC}; ./iozone)
+ @(cd ${WRKSRC}; ./iozone 100 | tee iozone.out)
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/iozone.out /tmp/benches/`domainname`/iozone.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/linpack/Makefile b/benchmarks/linpack/Makefile
index 70a6f35b84d..08ea9f0fc47 100644
--- a/benchmarks/linpack/Makefile
+++ b/benchmarks/linpack/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 1998/09/23 17:00:35 agc Exp $
+# $NetBSD: Makefile,v 1.3 1998/12/26 15:59:56 garbled Exp $
DISTNAME= linpackc
PKGNAME= linpack-940225
@@ -23,7 +23,12 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/linpacks ${PREFIX}/bin
benchmark:
- -@${WRKSRC}/linpacks
- -@${WRKSRC}/linpackd
+ -@${WRKSRC}/linpacks | tee ${WRKSRC}/linpacks.out
+ -@${WRKSRC}/linpackd | tee ${WRKSRC}/linpackd.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/linpacks.out /tmp/benches/`domainname`/linpacks.`uname`-`uname -m`-`uname -r`.`hostname`
+ -@cp ${WRKSRC}/linpackd.out /tmp/benches/`domainname`/linpackd.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/lmbench/Makefile b/benchmarks/lmbench/Makefile
index 63f4c314856..f443872a125 100644
--- a/benchmarks/lmbench/Makefile
+++ b/benchmarks/lmbench/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 1998/12/03 01:27:05 hubertf Exp $
+# $NetBSD: Makefile,v 1.4 1998/12/26 15:59:56 garbled Exp $
DISTNAME= lmbench-2alpha11
PKGNAME= lmbench-2.11a
@@ -31,12 +31,24 @@ do-install:
.include "../../mk/bsd.prefs.mk"
benchmark:
+.if exists(${PREFIX}/bin/lmbench/hello)
.if defined(BATCH)
- @${ECHO} "*** This benchmark may only be run in non-batch mode" ; \
- exit 1
+ @${ECHO} "*** This benchmark should only be run in non-batch mode" ; \
+ if [ `id -u` != 0 ]; then echo "This benchmark must be run as root!" ; exit 1 ; fi ; \
+ @${SED} -e 's|@wrksrc@|${WRKSRC}|' < ${FILESDIR}/setup.answers | \
+ (cd ${WRKSRC}/src; ${GMAKE} results)
.else
@if [ `id -u` != 0 ]; then echo "This benchmark must be run as root!" ; exit 1 ; fi
@cd ${WRKSRC}/src; ${GMAKE} results
.endif
+.else
+ @${ECHO} "*** This benchmark must be installed to run" ; \
+ exit 1
+.endif
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cd ${PREFIX}/share/lmbench ; \
+ tar -cf /tmp/benches/`domainname`/lmbench.`uname`-`uname -m`-`uname -r`.`hostname`.tar results
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/lmbench/files/setup.answers b/benchmarks/lmbench/files/setup.answers
new file mode 100644
index 00000000000..2cdb830ff6b
--- /dev/null
+++ b/benchmarks/lmbench/files/setup.answers
@@ -0,0 +1,9 @@
+
+
+
+
+
+@wrksrc@
+
+
+no
diff --git a/benchmarks/nsieve/Makefile b/benchmarks/nsieve/Makefile
index a771248e9ea..bf1c80e88f8 100644
--- a/benchmarks/nsieve/Makefile
+++ b/benchmarks/nsieve/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1.1.1 1998/10/22 06:23:09 garbled Exp $
+# $NetBSD: Makefile,v 1.2 1998/12/26 15:59:56 garbled Exp $
DISTNAME= nsieve.c
PKGNAME= nsieve-1.2b
@@ -21,6 +21,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/nsieve ${PREFIX}/bin
benchmark:
- -@${WRKSRC}/nsieve
+ -@${WRKSRC}/nsieve | tee ${WRKSRC}/nsieve.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/nsieve.out /tmp/benches/`domainname`/nsieve.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/paranoia/Makefile b/benchmarks/paranoia/Makefile
index 13df3a5f167..6d4ca51af9b 100644
--- a/benchmarks/paranoia/Makefile
+++ b/benchmarks/paranoia/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 1998/09/24 09:08:16 agc Exp $
+# $NetBSD: Makefile,v 1.4 1998/12/26 15:59:56 garbled Exp $
DISTNAME= paranoia
PKGNAME= paranoia-960101
@@ -20,6 +20,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/paranoia ${PREFIX}/bin
benchmark:
- @(cd ${WRKSRC}; ./paranoia < ${FILESDIR}/paranoia.run)
+ @(cd ${WRKSRC}; ./paranoia < ${FILESDIR}/paranoia.run | tee paranoia.out)
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/paranoia.out /tmp/benches/`domainname`/paranoia.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"
diff --git a/benchmarks/whetstone/Makefile b/benchmarks/whetstone/Makefile
index 09d23950db2..2db02dd1ef6 100644
--- a/benchmarks/whetstone/Makefile
+++ b/benchmarks/whetstone/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 1998/09/24 09:19:10 agc Exp $
+# $NetBSD: Makefile,v 1.4 1998/12/26 15:59:56 garbled Exp $
DISTNAME= whetstone
PKGNAME= whetstone-1.2
@@ -20,6 +20,10 @@ do-install:
${INSTALL_PROGRAM} ${WRKSRC}/whetstone ${PREFIX}/bin
benchmark:
- @${WRKSRC}/whetstone
+ @${WRKSRC}/whetstone 80000 | tee ${WRKSRC}/whetstone.out
+
+results:
+ -@${MKDIR} /tmp/benches/`domainname`
+ -@cp ${WRKSRC}/whetstone.out /tmp/benches/`domainname`/whetstone.`uname`-`uname -m`-`uname -r`.`hostname`
.include "../../mk/bsd.pkg.mk"