changeset 51591:ecf4b959fa74

perf: start recording total time after warming The warming might be costly and this should not affect the "time profile" of the actual collection.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Sun, 14 Apr 2024 02:41:36 +0200
parents a6bdd2e6f7cb
children 24844407fa0d
files contrib/perf.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/perf.py	Sun Apr 14 02:40:15 2024 +0200
+++ b/contrib/perf.py	Sun Apr 14 02:41:36 2024 +0200
@@ -563,7 +563,6 @@
 ):
     gc.collect()
     results = []
-    begin = util.timer()
     count = 0
     if profiler is None:
         profiler = lambda: NOOPCTX
@@ -572,6 +571,7 @@
             setup()
         with context():
             func()
+    begin = util.timer()
     keepgoing = True
     while keepgoing:
         if count in profiled_runs: