diff --git a/share/qtcreator/debugger/cdbbridge.py b/share/qtcreator/debugger/cdbbridge.py index b5fc683cbae..7fdd057bb11 100644 --- a/share/qtcreator/debugger/cdbbridge.py +++ b/share/qtcreator/debugger/cdbbridge.py @@ -7,6 +7,7 @@ import sys import cdbext import re import threading +import time from utils import TypeCode sys.path.insert(1, os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))) @@ -443,6 +444,7 @@ class Dumper(DumperBase): self.put('{name="%s",value="",type="",numchild="0"},' % msg) def fetchVariables(self, args): + start_time = time.perf_counter() self.resetStats() (ok, res) = self.tryFetchInterpreterVariables(args) if ok: @@ -476,6 +478,8 @@ class Dumper(DumperBase): self.put(',qtnamespace="%s"' % self.qtNamespaceToReport) self.qtNamespaceToReport = None + runtime = time.perf_counter() - start_time + self.put(',runtime="%s"' % runtime) self.reportResult(''.join(self.output), args) self.output = []