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

Add an IndexUnchecked trait that uses asm! #805

Merged
merged 5 commits into from
Nov 29, 2021

Conversation

expenses
Copy link
Contributor

After #803 it became possible to write asm! functions that index into arrays and RuntimeArrays without bounds checking. This PR exposes these functions as a trait. I decided on index_unchecked* instead of get_unchecked* to avoid the name aliasing. It could still be pretty confusing though.

crates/spirv-std/src/arch.rs Outdated Show resolved Hide resolved
@khyperia
Copy link
Contributor

Also, it'd be nice to not use gpu_only here, because it's not actually gpu_only

@expenses expenses requested a review from khyperia November 25, 2021 11:58
@khyperia khyperia merged commit 9fd3c9e into EmbarkStudios:main Nov 29, 2021
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.

2 participants