Author inada.naoki
Recipients inada.naoki, pitrou, rhettinger, scoder, serhiy.storchaka, vstinner
Date 2017-09-05.06:20:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1504592450.19.0.519434047877.issue31336@psf.upfronthosting.co.za>
In-reply-to
Content
There is special internal API in dictobject.c
_PyDict_LoadGlobal(PyDictObject *globals, PyDictObject *builtins, PyObject *key)

Maybe, we can have special API like that
_PyDict_LookupMro(PyObject *mro, PyObject *key);

BTW, method cache in _PyType_Lookup is not good for initializing type.
It always mishit.  And all specialized method is cached even if it isn't used anymore.

Stefan, would you benchmark these ideas?
History
Date User Action Args
2017-09-05 06:20:50inada.naokisetrecipients: + inada.naoki, rhettinger, pitrou, scoder, vstinner, serhiy.storchaka
2017-09-05 06:20:50inada.naokisetmessageid: <1504592450.19.0.519434047877.issue31336@psf.upfronthosting.co.za>
2017-09-05 06:20:50inada.naokilinkissue31336 messages
2017-09-05 06:20:49inada.naokicreate