Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-119053: Implement the fast path for list.__getitem__#119112

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
corona10 merged 8 commits intopython:mainfromcorona10:gh-119053
May 21, 2024

Conversation

corona10
Copy link
Member

@corona10corona10 commentedMay 17, 2024
edited by bedevere-appbot
Loading

@corona10corona10 changed the titlegh-119053: Implement the fast path for list.__getitem__[WIP] gh-119053: Implement the fast path for list.__getitem__May 17, 2024
@corona10corona10 changed the title[WIP] gh-119053: Implement the fast path for list.__getitem__gh-119053: Implement the fast path for list.__getitem__May 17, 2024
@corona10corona10 marked this pull request as ready for reviewMay 17, 2024 06:48
@corona10corona10 requested a review frommpageMay 18, 2024 10:16
Copy link
Contributor

@mpagempage left a comment
edited
Loading

Choose a reason for hiding this comment

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

This looks good to me. I noticed that we perform a validity check on the index several times now:

  1. Inlist_item
  2. Inlist_get_item_ref
  3. Inlist_item_impl (if we end up taking the slow path)

While this doesn't affect correctness, I think it would make sense to refactor the code to eliminate the redundant checks given how performance sensitive this code is. That could be tackled in a separate PR, though.

@colesburycolesbury added needs backport to 3.13bugs and security fixes labelsMay 20, 2024
@corona10corona10 merged commitab4263a intopython:mainMay 21, 2024
@miss-islington-app
Copy link

Thanks@corona10 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@corona10corona10 deleted the gh-119053 branchMay 21, 2024 13:49
miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestMay 21, 2024
…gh-119112)(cherry picked from commitab4263a)Co-authored-by: Donghee Na <donghee.na@python.org>
@bedevere-app
Copy link

GH-119309 is a backport of this pull request to the3.13 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.13bugs and security fixes labelMay 21, 2024
corona10 added a commit that referenced this pull requestMay 21, 2024
…9112) (gh-119309)gh-119053: Implement the fast path for list.__getitem__ (gh-119112)(cherry picked from commitab4263a)Co-authored-by: Donghee Na <donghee.na@python.org>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@mpagempagempage approved these changes

@colesburycolesburycolesbury approved these changes

Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@corona10@mpage@colesbury

[8]ページ先頭

©2009-2025 Movatter.jp