Tal Einat <taleinat+pyt...@gmail.com> added the comment:

After spending quite a while setting up my dev machine for (hopefully) reliable 
benchmarking, I can say with a high level of certainty that the latest PR 
(GH-22904, commit fe9e9d9c1f1c5f98c797d19e2214d1413701f6de) runs stringbench.py 
significantly faster than the master branch (commit 
fb5db7ec58624cab0797b4050735be865d380823). See attached results.

I've also run the zipf-distributed random string benchmarks provided by Dennis, 
with a slight addition of `random.seed(1)` in the do_timings function. Those 
show significant, consistent improvements on needles of length over 100, but 
not on shorter needles. The results are also found in the attached file.


My conclusion is that the current two-way implementation is certainly better 
for needles of length over 100, but for shorter needles the situation is still 
unclear.


System details:
Dell XPS 9560
Intel i7-7700HQ
Ubuntu 20.04

Steps taken to prepare system for performance tuning:
* Enable CPU isolation for two physical cores
* Disable Intel p-state driver
* Disable turbo-boost
* Run `pyperf system tune`
* Run benchmarks with CPU pinning

----------
nosy: +taleinat
Added file: 
https://bugs.python.org/file49545/twoway-benchmark-results-2020-10-28.txt

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue41972>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to