diff options
author | Erlend E. Aasland <erlend@python.org> | 2024-04-12 07:40:55 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-12 07:40:55 (GMT) |
commit | deb921f85173a194afb4386553d85c3f99767ca1 (patch) | |
tree | c5f32d62bf1ad727f25f6e8b084876c32d8a96e2 /Misc | |
parent | 49fc1414b52b31f6ad0408775d160ec0559c33bb (diff) | |
download | cpython-deb921f85173a194afb4386553d85c3f99767ca1.zip cpython-deb921f85173a194afb4386553d85c3f99767ca1.tar.gz cpython-deb921f85173a194afb4386553d85c3f99767ca1.tar.bz2 |
gh-117431: Adapt bytes and bytearray .find() and friends to Argument Clinic (#117502)
This change gives a significant speedup, as the METH_FASTCALL calling
convention is now used. The following bytes and bytearray methods are adapted:
- count()
- find()
- index()
- rfind()
- rindex()
Co-authored-by: Inada Naoki <songofacandy@gmail.com>
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/NEWS.d/next/Core and Builtins/2024-04-12-09-09-11.gh-issue-117431.lxFEeJ.rst | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Core and Builtins/2024-04-12-09-09-11.gh-issue-117431.lxFEeJ.rst b/Misc/NEWS.d/next/Core and Builtins/2024-04-12-09-09-11.gh-issue-117431.lxFEeJ.rst new file mode 100644 index 0000000..0d94389 --- /dev/null +++ b/Misc/NEWS.d/next/Core and Builtins/2024-04-12-09-09-11.gh-issue-117431.lxFEeJ.rst @@ -0,0 +1,9 @@ +Improve the performance of the following :class:`bytes` and +:class:`bytearray` methods by adapting them to the :c:macro:`METH_FASTCALL` +calling convention: + +* :meth:`!count` +* :meth:`!find` +* :meth:`!index` +* :meth:`!rfind` +* :meth:`!rindex` |