FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-126910: Verify that JIT stencils preserve frame pointer by Fidget-Spinner · Pull Request #146524 · python/cpython · GitHub

/ cpython Public

gh-126910: Verify that JIT stencils preserve frame pointer - #146524

Merged
Fidget-Spinner merged 11 commits into
python:mainfrom
Fidget-Spinner:fp_verifier
Mar 27, 2026
Merged

gh-126910: Verify that JIT stencils preserve frame pointer#146524
Fidget-Spinner merged 11 commits into
python:mainfrom
Fidget-Spinner:fp_verifier

Conversation

Fidget-Spinner commented Mar 27, 2026
edited
Loading

Copy link
Copy Markdown
Member

This PR introduces a lightweight assembly verifier that the JIT does not clobber the frame pointer.

I verified that without #146521 , this will fail JIT compilation on x86-64. Will use CI to test AArch64.

This is expected to fail JIT CI until that PR lands.

diegorusso left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM, thanks!

Fidget-Spinner commented Mar 27, 2026
edited
Loading

Copy link
Copy Markdown
Member Author

Alright! Confirmed all platforms that currently support frame pointers (x64 and AArch64) fail, so this means it does work!

Copy link
Copy Markdown
Member Author

Just an FYI: discussed with Mark on 26 Mar UK time that we should just remove the clever tricks to get the frame address and use a simple approximate one.

Fidget-Spinner commented Mar 27, 2026
edited
Loading

Copy link
Copy Markdown
Member Author

Had to partially revert some of #146521 because the current recursion limit/stack overflow detection is working strangely after that with the JIT. Brandt's suggestion to just whack a Py_NO_INLINE on the function work. Good thing we have the verifier now so that we don't use one of the other recursion check functions and inadvertently introduce this again into the JIT.

Fidget-Spinner merged commit 1384f02 into python:main Mar 27, 2026
83 checks passed
Fidget-Spinner deleted the fp_verifier branch March 27, 2026 19:39
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

2 participants


Back | FazBrowse Home | New Git URL