[Python-checkins] gh-104717: Add comment about manual loop unrolling (gh-104718)

corona10 webhook-mailer at python.org
Sun May 21 08:08:35 EDT 2023


https://github.com/python/cpython/commit/b9fcfa60244da85d8847a05e8d5e75d0a6694f90
commit: b9fcfa60244da85d8847a05e8d5e75d0a6694f90
branch: main
author: Dong-hee Na <donghee.na at python.org>
committer: corona10 <donghee.na92 at gmail.com>
date: 2023-05-21T21:08:28+09:00
summary:

gh-104717: Add comment about manual loop unrolling (gh-104718)

files:
M Objects/dictobject.c

diff --git a/Objects/dictobject.c b/Objects/dictobject.c
index 7436c113f37c..254cd9ad2f9b 100644
--- a/Objects/dictobject.c
+++ b/Objects/dictobject.c
@@ -944,6 +944,7 @@ unicodekeys_lookup_unicode(PyDictKeysObject* dk, PyObject *key, Py_hash_t hash)
         }
         perturb >>= PERTURB_SHIFT;
         i = mask & (i*5 + perturb + 1);
+        // Manual loop unrolling
         ix = dictkeys_get_index(dk, i);
         if (ix >= 0) {
             PyDictUnicodeEntry *ep = &ep0[ix];



More information about the Python-checkins mailing list