Skip to content

gh-146261: JIT: protect against function version changes#146300

Merged
Fidget-Spinner merged 7 commits intopython:mainfrom
Fidget-Spinner:fix_func_version_changes
Apr 12, 2026
Merged

gh-146261: JIT: protect against function version changes#146300
Fidget-Spinner merged 7 commits intopython:mainfrom
Fidget-Spinner:fix_func_version_changes

Conversation

@Fidget-Spinner
Copy link
Copy Markdown
Member

@Fidget-Spinner Fidget-Spinner commented Mar 22, 2026

This PR reverts the func_version symbol changes by using the fact that we have recorded values and _CHECK_FUNCTION_VERSION guards --- if we simply keep those around and not eliminate them, our function versions are guaranteed to be correct for all following _PUSH_FRAME if we invalidate dependencies properly in the function version changes.

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
@Fidget-Spinner
Copy link
Copy Markdown
Member Author

@markshannon does this bugfix look okay to you? The reason we need this is that __code__ can be swapped out for functions. If you think it's okay, I can merge.

@Fidget-Spinner Fidget-Spinner merged commit 6f7bb29 into python:main Apr 12, 2026
69 checks passed
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.

3 participants