[issue43706] enumerate() instantiation time reducing by using PEP 590 vectorcall

Dong-hee Na report at bugs.python.org
Thu Oct 21 21:59:19 EDT 2021


Dong-hee Na <donghee.na at python.org> added the comment:

@vstinner

I noticed that the msg390083 was based on a non-optimized build.
https://github.com/python/cpython/pull/25154#issuecomment-949061515 ran with the same build option condition.

Here is the PGO + LTO based benchmark.
Still fast.

+-----------------+----------+----------------------+
| Benchmark       | base_opt | vectorcall_opt       |
+=================+==========+======================+
| bench enumerate | 384 ns   | 277 ns: 1.39x faster |
+-----------------+----------+----------------------+

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue43706>
_______________________________________


More information about the Python-bugs-list mailing list