summaryrefslogtreecommitdiffstats
path: root/Doc/reference
diff options
context:
space:
mode:
authorYury Selivanov <yselivanov@sprymix.com>2016-02-11 15:26:27 (GMT)
committerYury Selivanov <yselivanov@sprymix.com>2016-02-11 15:26:27 (GMT)
commite0b23095ee03a11d09f38cbc689307dc5c93afda (patch)
tree4854be21dd4b87937cf03583bd599c1f8d3ddebd /Doc/reference
parent2da89d70fcad24cc266f6919aadd40c0838c4c5f (diff)
downloadcpython-e0b23095ee03a11d09f38cbc689307dc5c93afda.zip
cpython-e0b23095ee03a11d09f38cbc689307dc5c93afda.tar.gz
cpython-e0b23095ee03a11d09f38cbc689307dc5c93afda.tar.bz2
Issues #26289 and #26315: Optimize floor/modulo div for single-digit longs
Microbenchmarks show 2-2.5x improvement. Built-in 'divmod' function is now also ~10% faster. -m timeit -s "x=22331" "x//2;x//-3;x//4;x//5;x//-6;x//7;x//8;x//-99;x//100;" with patch: 0.321 without patch: 0.633 -m timeit -s "x=22331" "x%2;x%3;x%-4;x%5;x%6;x%-7;x%8;x%99;x%-100;" with patch: 0.224 without patch: 0.66 Big thanks to Serhiy Storchaka, Mark Dickinson and Victor Stinner for thorow code reviews and algorithms improvements.
Diffstat (limited to 'Doc/reference')
0 files changed, 0 insertions, 0 deletions