Thanks to visit codestin.com
Credit goes to github.com

Skip to content

YJIT: Allow dev_nodebug to disasm release-mode code #11198

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 18, 2024

Conversation

k0kubun
Copy link
Member

@k0kubun k0kubun commented Jul 18, 2024

  • Add runtime_assertions feature to the cargo config
    • To check the quality of the generated code that would run in the release mode, I sometimes want to see the disasm of generated code without runtime assertions like "set stack canary".
    • Having this feature (separately from cfg!(debug_assertions)) allows --enable-yjit=dev_nodebug to disasm code without runtime assertions while enabling other compile-time assertions.
  • Drop stats feature from cargo
    • This is no longer used. All stats implemented in YJIT's code are available in the release mode as well. I still left --enable-yjit=stats for the YJIT_STATS macro in C code.

@matzbot matzbot requested a review from a team July 18, 2024 17:44
Copy link
Member

@XrXr XrXr left a comment

Choose a reason for hiding this comment

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

This is nice. There seems to be a few codegen decisions still made with debug_assertions that probably should be changed, though. git grep debug_assertions

@XrXr
Copy link
Member

XrXr commented Jul 18, 2024

I'm gonna push a commit onto this PR that removes one of the places that codegens using debug_assertions still, hopefully you don't mind.

This reverts commit f05ad37.
The stray canary issue should have been solved by
def7023, alleviating this codegen
accommodation.
@k0kubun
Copy link
Member Author

k0kubun commented Jul 18, 2024

Yes please!

@k0kubun k0kubun merged commit 2de8b5b into ruby:master Jul 18, 2024
106 checks passed
@k0kubun k0kubun deleted the yjit-nodebug branch July 18, 2024 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants