mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
A hybrid of and-masking and a conditional-set-to-zero produce even faster search loop.
This commit is contained in:
parent
bd9b200b87
commit
ed741d4ff0
1 changed files with 2 additions and 1 deletions
|
@ -671,7 +671,8 @@ set_pop(PySetObject *so)
|
|||
|
||||
while ((entry = &so->table[i])->key == NULL || entry->key==dummy) {
|
||||
i++;
|
||||
i &= so->mask;
|
||||
if (i > so->mask)
|
||||
i = 0;
|
||||
}
|
||||
key = entry->key;
|
||||
entry->key = dummy;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue