X-Git-Url: http://git.vrable.net/?a=blobdiff_plain;f=microbench%2Fmicrobench.py;h=f8b89ea3473a075eedf46e884e1553c5a159b176;hb=81b37a6f03b86bc0d8d3a1eee50c9c0feb51b533;hp=313828abf1450226321aca098f67081dc770e1e8;hpb=c44db7a9d3d32ab3656676c98145c55f32dc8a19;p=bluesky.git diff --git a/microbench/microbench.py b/microbench/microbench.py index 313828a..f8b89ea 100755 --- a/microbench/microbench.py +++ b/microbench/microbench.py @@ -74,6 +74,17 @@ class TestCommands: return [time.time() - start] + def large_read(self): + buf = None + + start = time.time() + fp = open("largefile") + while buf != "": + buf = fp.read(1048576) + fp.close() + + return [time.time() - start] + def shell(self): subprocess.call(['/bin/sh'])