Skip to content
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

[CHERI] Fix issue where tag_get was being CSE'd across free calls. #70

Merged
merged 1 commit into from
Jan 8, 2025

Conversation

resistor
Copy link
Collaborator

Fix for #38

@davidchisnall
Copy link

Seems to have introduced a lot of test failures?

@resistor
Copy link
Collaborator Author

@davidchisnall Interested in your thoughts on the code quality regressions this introduces. Modeling get_tag as a memory read guarantees that we don't CSE it across calls, but also kills CSE in a lot of other safe scenarios.

@resistor resistor marked this pull request as ready for review December 16, 2024 00:25
@davidchisnall
Copy link

I think we probably want to introduce two builtins, one that is and one that isn’t doing temporal checks. They’re independent so using both won’t be CSE’d.

A lot of of uses know that they can’t be deallocated and so are fine to use the non-temporal one, as long as they don’t use it before they’ve done the thing that guarantees that the object is not free. We can also maybe do some clever things later like rewrite the temporal one to non-temporal if we know that a capability has store-local permission.

@resistor
Copy link
Collaborator Author

@davidchisnall PTAL

@davidchisnall
Copy link

LGTM, @nwf ?

@nwf
Copy link
Member

nwf commented Jan 7, 2025

Seems sensible to me, though I cannot do much more than nod along to the LLVM changes.

@resistor resistor enabled auto-merge (rebase) January 8, 2025 07:30
@resistor resistor merged commit e2c599d into CHERIoT-Platform:cheriot Jan 8, 2025
1 check passed
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