[Jeremy] > I was curious about what the DictCreation microbenchmark in > pybench was slower (about 15%) with 2.1 than with 2.0. I ran > both with profiling enabled (-pg, no -O) and see that insertdict > is a fair bit slower in 2.1. Anyone with dict implementation > expertise want to hazard a guess about this? You don't need to be an expert for this one: just look at the code! There's nothing to it, and not even a comment has changed in insertdict since 2.0. I don't believe the profile. There are plenty of other things to be suspicious about too (e.g., it showed 285 calls to eval_code2 in 2.0, but 998 in 2.1). So you're looking at a buggy profiler, a buggy profiling procedure, or a Cache Mystery (the catch-all excuse for anything that's incomprehensible without HW-level monitoring tools). WRT the latter, try inserting a renamed copy of insertdict before and after the existing one, and make them extern to discourage the compiler+linker from throwing them away. If the slowdown goes away, you're probably looking at an i-cache conflict accident.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4