osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Python-Dev] PEP 575, 576, 579 and 580


> > > 5. It should speed up CPython for the standard benchmark suite.
...
> >
> > I don't think point 5 is a goal here either, as the problem isn't that
> > these calling optimisations don't exist, it's that they don't
> > currently have a public API that third party projects can access (the
> > most recent METH_FASTCALL thread covers that pretty well).
>
> Agreed.  The goal is not to speed up CPython but to bring third-party
> extensions up to speed (both literally and figuratively).
>

For clarify, main goal is not just only 3rd party extension faster.
Publicate some private APIs is enough for it.

Goals of these PEP 576 (GitHub version) and 580 is making
custom callable type (especially method-like object) faster.

Because most functions and methods are defined with PyMethodDef
and m_methods / tp_methods, these PEPs are not needed for them.

I think main motivation of these PEPs are modern Python usages:
Jupyter notebook + Cython.

Unlike extension module writer, we shouldn't expect user knows
difference between C and Python.  That's why Cython want emulate
normal Python function/methods as possible.

Regards,

-- 
INADA Naoki  <songofacandy at gmail.com>