Skip to content

Naga shouldn't evaluate overrides unless they're used by the entry point #5885

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

Open
jimblandy opened this issue Jun 26, 2024 · 2 comments · May be fixed by #7652
Open

Naga shouldn't evaluate overrides unless they're used by the entry point #5885

jimblandy opened this issue Jun 26, 2024 · 2 comments · May be fixed by #7652
Assignees
Labels
area: naga back-end Outputs of naga shader conversion naga Shader Translator type: bug Something isn't working

Comments

@jimblandy
Copy link
Member

When generating code for a naga::Module, Naga currently evaluates every override-expression it can, regardless of whether that expression is statically used by the entry point(s) for which we are generating code. The WGSL committee's recent discussions clarified that errors should only be reported from override-expressions that are actually statically used.

@ErichDonGubler
Copy link
Member

Firefox downstream tracking: bug 1953930

@jimblandy
Copy link
Member Author

This is P1 for Firefox because it prevents this WebGPU Sample from running:

https://webgpu.github.io/webgpu-samples/?sample=samplerParameters

@andyleiserson andyleiserson moved this from Todo to In Progress in WebGPU for Firefox Apr 24, 2025
andyleiserson added a commit to andyleiserson/wgpu that referenced this issue Apr 24, 2025
Changes the MSL and HLSL backends to support writing only a single entry
point, and uses them that way in wgpu-hal.

This is working towards a fix for gfx-rs#5885.
andyleiserson added a commit to andyleiserson/wgpu that referenced this issue Apr 29, 2025
Changes the MSL and HLSL backends to support writing only a single entry
point, and uses them that way in wgpu-hal.

This is working towards a fix for gfx-rs#5885.
teoxoy pushed a commit that referenced this issue Apr 30, 2025
Changes the MSL and HLSL backends to support writing only a single entry
point, and uses them that way in wgpu-hal.

This is working towards a fix for #5885.

* Increase the limit in test_stack_size
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: naga back-end Outputs of naga shader conversion naga Shader Translator type: bug Something isn't working
Projects
Status: In Progress
Development

Successfully merging a pull request may close this issue.

3 participants