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

Lavapipe causes access violation accessing intersection.world_to_object #6731

Open
Vecvec opened this issue Dec 14, 2024 · 2 comments · May be fixed by #6752
Open

Lavapipe causes access violation accessing intersection.world_to_object #6731

Vecvec opened this issue Dec 14, 2024 · 2 comments · May be fixed by #6752
Labels
api: vulkan Issues with Vulkan area: correctness We're behaving incorrectly feature: raytracing Issues with the Ray Tracing Native Feature type: bug Something isn't working

Comments

@Vecvec
Copy link
Contributor

Vecvec commented Dec 14, 2024

Description
Since I got lavapipe installed I've been testing it with ray-tracing, and it seems that if a section of the intersection struct is accessed that needs a triangle to be hit (not done within the current examples) lavapipe dereferences a null pointer and crashes. I think this is actually our issue, as we gather these members without caring whether we have hit anything or not (this is technically undefined behavior). I think that the best way to deal with this is to emit a function for it for the three different blocks required. I am happy to do this.

Repro steps
add this line to any of the ray cube examples

color  = vec4f(intersection.world_to_object[0].x)

and run with lavapipe

Expected vs observed behavior
it should give an access violation

Platform
latest trunk wgpu w/ change

@cwfitzgerald
Copy link
Member

It would be great to have a (skipped on lavapipe) test for this

@cwfitzgerald cwfitzgerald added type: bug Something isn't working area: correctness We're behaving incorrectly api: vulkan Issues with Vulkan labels Dec 14, 2024
@Vecvec
Copy link
Contributor Author

Vecvec commented Dec 14, 2024

I'm already working on the fix for this, so I am planning to integrate a test.

@cwfitzgerald cwfitzgerald added feature: bindless Issues with Bindless Native Feature feature: raytracing Issues with the Ray Tracing Native Feature and removed feature: bindless Issues with Bindless Native Feature labels Dec 14, 2024
@Vecvec Vecvec linked a pull request Dec 16, 2024 that will close this issue
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: vulkan Issues with Vulkan area: correctness We're behaving incorrectly feature: raytracing Issues with the Ray Tracing Native Feature type: bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants