[pypy-svn] r59924 - in pypy/build/benchmem: . benchmark testing
xoraxax at codespeak.net
xoraxax at codespeak.net
Sat Nov 15 11:02:24 CET 2008
Author: xoraxax
Date: Sat Nov 15 11:02:22 2008
New Revision: 59924
Modified:
pypy/build/benchmem/benchmark/appprofiles.py
pypy/build/benchmem/runbench.py
pypy/build/benchmem/testing/test_benchtool.py
Log:
Reduce the number of pystone/richards runs, do more busy waiting, reduce number of cpython_nasty iterations because the function is pretty slow.
Modified: pypy/build/benchmem/benchmark/appprofiles.py
==============================================================================
--- pypy/build/benchmem/benchmark/appprofiles.py (original)
+++ pypy/build/benchmem/benchmark/appprofiles.py Sat Nov 15 11:02:22 2008
@@ -75,7 +75,7 @@
for i in range(iter2):
next = None
- for i in range(iter1):
+ for i in range(iter1/5):
next = B(next)
Modified: pypy/build/benchmem/runbench.py
==============================================================================
--- pypy/build/benchmem/runbench.py (original)
+++ pypy/build/benchmem/runbench.py Sat Nov 15 11:02:22 2008
@@ -120,7 +120,8 @@
popen = Popen(cmds, shell=True, stdout=PIPE,
stderr=PIPE, close_fds=True, env=env)
if popen.wait():
- raise Exception('Error in command ' + cmds)
+ print "ERROR in command " + cmds
+ continue
output_error = popen.stderr.read()
output = popen.stdout.read()
@@ -160,8 +161,8 @@
def run(self):
self.write_benchheader("benchtime")
for name, cmdpostfix, pattern in (
- ('pystone', '-c "import pystone; pystone.main()"', PYSTONE_PATTERN),
- ('richards', '-c "import richards; richards.main(iterations=3)"', RICHARDS_PATTERN),
+ ('pystone', '-c "import pystone; pystone.main(10000)"', PYSTONE_PATTERN),
+ ('richards', '-c "import richards; richards.main(iterations=1)"', RICHARDS_PATTERN),
):
cmd = "%s %s " % (self.executable, cmdpostfix)
times = self.timecommand(cmd, str(benchmarkdir), pattern)
@@ -325,7 +326,7 @@
# because this would give very different results based on
# the system speed. a better solution would be cpu timers
# or ptrace etc.
- for _ in xrange(2**13):
+ for _ in xrange(2**14):
pass
except py.error.ENOENT:
break
Modified: pypy/build/benchmem/testing/test_benchtool.py
==============================================================================
--- pypy/build/benchmem/testing/test_benchtool.py (original)
+++ pypy/build/benchmem/testing/test_benchtool.py Sat Nov 15 11:02:22 2008
@@ -353,7 +353,7 @@
report.CheckpointDetails(resultset).run() # shouldnt do anything
for name, timing in result1.mintimings:
- assert timing['user'] >= 0.5
+ assert timing['user'] >= 0.1
out = runreport("--benchlog %s" %(benchlog,))
assert out.lower().find("timed") != -1
More information about the Pypy-commit
mailing list