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

Stop naga causing undefined behavior in rayQueryGet*Intersection #6752

Open
wants to merge 8 commits into
base: trunk
Choose a base branch
from

Conversation

Vecvec
Copy link
Contributor

@Vecvec Vecvec commented Dec 16, 2024

Connections
fixes #6731

Description
Naga previously unconditionally called operations that required the ray to hit something. This is undefined behavior according to the spirv raytracing spec. This caused seg-faults on lavapipe. This prevents that by separating the intersection getter into another function with conditional blocks.

Testing
added a test that previously failed (with a seg-fault) that now succeeds

Checklist

  • Run cargo fmt.
  • Run taplo format.
  • Run cargo clippy. If applicable, add:
    • [n/a] --target wasm32-unknown-unknown
    • [n/a] --target wasm32-unknown-emscripten
  • Run cargo xtask test to run tests.
  • Add change to CHANGELOG.md. See simple instructions inside file.

@Vecvec Vecvec requested review from a team as code owners December 16, 2024 05:12
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.

Lavapipe causes access violation accessing intersection.world_to_object
1 participant