This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ping: [PATCH 0/4 V3] GDB Performance testing


On 10/24/2013 04:49 PM, Agovic, Sanimir wrote:
+    def measure(self, func, id):
+        """Measure the operations done by func with a collection of measurements."""
+        for m in self.measurements:
+            m.start(id)
+
+        # Enable GC, force GC and disable GC before running test in order to reduce
+        # the interference from GC.
+        gc.enable()
+        gc.collect()
+        gc.disable()
+
+        func()
+
+        gc.enable()
I`d rather exclude gc cycles completely from the measurements or include gc collection
_after_  you run your perf test. Otherwise the results will depend on the order the perf
tests are run.

Right, we should disable gc before measurements are started and enable
gc again when measurements are stopped.  I'll update the patch.

--
Yao (éå)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]