[New-bugs-announce] [issue42673] Optimize round_size for rehashing

Jurjen N.E. Bos report at bugs.python.org
Fri Dec 18 04:35:27 EST 2020

New submission from Jurjen N.E. Bos <jneb at users.sourceforge.net>:

There's a trivial optimization in the round_size in hashtable.c:
a loop is used to compute the lowest power of two >= s,
while this can be done in one step with bit_length.
I am making a pull request for this.

components: Interpreter Core
messages: 383291
nosy: jneb
priority: normal
severity: normal
status: open
title: Optimize round_size for rehashing
type: performance
versions: Python 3.10

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list