[issue16389] re._compiled_typed's lru_cache causes significant degradation of the mako_v2 bench

Serhiy Storchaka report at bugs.python.org
Tue Nov 6 17:46:02 CET 2012


Serhiy Storchaka added the comment:

> I think the lru_cache should be kept if possible (i.e. I'm -0.5 on your patch).

This patch is only to show the upper level to which should be sought.  I tried to optimize lru_cache(), but got only 15%.  I'm afraid that serious optimization is impossible 
without rewriting lru_cache() on C.

>   2) avoid using it for regular expressions compiled with re.compile;

I do not see how it can significantly affect performance.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16389>
_______________________________________


More information about the Python-bugs-list mailing list