Message58328
Updates:
* Moved dictobject.c:unicode_eq() to unicodeobject.c:_PyUnicode_Eq()
* Added another optimization step to _PyUnicode_Eq(). The hash is
required later anyway and comparing two hashes is much faster than
memcmp-ing the unicode objects.
if (unicode_hash(a) != unicode_hash(b))
return 0;
* Factored out the ((PyUnicodeObject *) v)->hash optimization into a
function object.c:_PyObject_HashFast() which does the trick for
PyUnicode and PyString. The trick was used a couple of times in
dictobject.c and setobject.c. We may even think about moving the trick
to PyObject_Hash() directly. |
|
| Date |
User |
Action |
Args |
| 2007-12-09 20:51:42 | christian.heimes | set | spambayes_score: 0.0283619 -> 0.0283619 recipients:
+ christian.heimes, gvanrossum, rhettinger |
| 2007-12-09 20:51:42 | christian.heimes | set | spambayes_score: 0.0283619 -> 0.0283619 messageid: <1197233502.08.0.0264421388007.issue1564@psf.upfronthosting.co.za> |
| 2007-12-09 20:51:42 | christian.heimes | link | issue1564 messages |
| 2007-12-09 20:51:41 | christian.heimes | create | |
|