On Tue, 17 May 2016 23:11:50 +0200 Victor Stinner victor.stinner@gmail.com wrote:
Hi,
I'm still (!) investigating the reasons why the benchmark call_simple (ok, let's be honest: the *micro*benchmark) gets different results for unknown reasons.
Try to define MCACHE_STATS in Objects/typeobject.c and observe the statistics from run to run. It might give some hints.
Regards
Antoine.
2016-05-30 10:14 GMT+02:00 Antoine Pitrou solipsis@pitrou.net:
I'm still (!) investigating the reasons why the benchmark call_simple (ok, let's be honest: the *micro*benchmark) gets different results for unknown reasons.
Try to define MCACHE_STATS in Objects/typeobject.c and observe the statistics from run to run. It might give some hints.
call_simple only uses regular functions, not methods, so the type cache should not have any effect on it. No?
I already noticed that the exact layout of items in globals() dict matters. Depending on the PYTHONHASHSEED, you get or not hash collision, the effect is visible on such microbenchmark.
Victor