add missing ptime for benchmark
authorPierre-Marc Fournier <pierre-marc.fournier@polymtl.ca>
Mon, 17 May 2010 16:53:19 +0000 (12:53 -0400)
committerPierre-Marc Fournier <pierre-marc.fournier@polymtl.ca>
Mon, 17 May 2010 16:53:19 +0000 (12:53 -0400)
tests/benchmark/ptime [new file with mode: 0755]

diff --git a/tests/benchmark/ptime b/tests/benchmark/ptime
new file mode 100755 (executable)
index 0000000..8e22c02
--- /dev/null
@@ -0,0 +1,22 @@
+#!/usr/bin/python
+
+import sys
+import time
+import os
+
+def main():
+       args = sys.argv[1:]
+       if len(args) < 1:
+               print "usage: %s COMMAND" % sys.argv[0]
+               sys.exit(1)
+
+       cmd = args[0]
+
+       t1 = time.time()
+       os.system(cmd)
+       1
+       t2 = time.time()
+
+       print (t2-t1)
+
+main()
This page took 0.025092 seconds and 4 git commands to generate.