Skip to content

gh-118379: Use PyTuple_Pack#118381

Merged
serhiy-storchaka merged 4 commits into
python:mainfrom
nineteendo:use-PyTuple_Pack
Apr 30, 2024
Merged

gh-118379: Use PyTuple_Pack#118381
serhiy-storchaka merged 4 commits into
python:mainfrom
nineteendo:use-PyTuple_Pack

Conversation

@nineteendo
Copy link
Copy Markdown
Contributor

@nineteendo nineteendo commented Apr 29, 2024

@nineteendo
Copy link
Copy Markdown
Contributor Author

Could someone add skip news, thank you?

Copy link
Copy Markdown
Member

@serhiy-storchaka serhiy-storchaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Copy Markdown
Member

@sobolevn sobolevn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is going to be faster. Thank you!

@erlend-aasland erlend-aasland marked this pull request as ready for review April 29, 2024 13:57
@mdboom
Copy link
Copy Markdown
Contributor

mdboom commented Apr 29, 2024

I ran this on our benchmarking infrastructure, and it seems to speed up the telco benchmark (which is the only decimal benchmark in the suite) by about 2%: https://github.com/faster-cpython/benchmarking-public/blob/main/results/bm-20240429-3.13.0a6%2B-59ac30f/bm-20240429-linux-x86_64-nineteendo-use_PyTuple_Pack-3.13.0a6%2B-59ac30f-vs-base.png

Comment thread Modules/itertoolsmodule.c Outdated
@serhiy-storchaka
Copy link
Copy Markdown
Member

If it affects the telco benchmark, and this is not a random fluctuation, there should be possible to create a microbenchmark that shows the tens percents difference.

@serhiy-storchaka serhiy-storchaka merged commit 9a75d56 into python:main Apr 30, 2024
@nineteendo nineteendo deleted the use-PyTuple_Pack branch April 30, 2024 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants