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

[spv/msl/hlsl-out] support pipeline constant value replacements #4998

Merged
merged 2 commits into from
Feb 12, 2024

Conversation

teoxoy
Copy link
Member

@teoxoy teoxoy commented Jan 5, 2024

Adds support for value replacements of pipeline-overridable constants for our 3 main back-ends.

Tracking meta issue: #4484.

  • File issues to implement override constants in terms of platform features, like SPIR-V's specialization constants. This would let us move SPIR-V generation from pipeline creation time back to module creation time.

@teoxoy teoxoy requested review from a team as code owners January 5, 2024 13:52
@teoxoy teoxoy requested a review from a team January 8, 2024 18:20
@teoxoy teoxoy removed the request for review from a team January 8, 2024 18:21
Copy link
Member

@cwfitzgerald cwfitzgerald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just booping to get out of my review queue :)

Copy link
Member

@jimblandy jimblandy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, this looks good to me.

I have various suggestions. I'll push commits for some of them to teoxoy/wgpu@pipeline-constants...jimblandy:wgpu:pipeline-constants

naga/src/arena.rs Outdated Show resolved Hide resolved
naga/src/back/mod.rs Outdated Show resolved Hide resolved
naga/tests/snapshots.rs Outdated Show resolved Hide resolved
params.pipeline_constants.clone(),
);
if !old.is_empty() {
panic!("Supply pipeline constants via pipeline_constants instead of msl_pipeline.constants!");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In a follow-up, let's try to make the parameters for all the snapshot backends work in the same way.

naga/src/back/pipeline_constants.rs Show resolved Hide resolved
naga/src/back/pipeline_constants.rs Outdated Show resolved Hide resolved
naga/src/arena.rs Outdated Show resolved Hide resolved
@teoxoy teoxoy merged commit 28b79ab into gfx-rs:pipeline-constants Feb 12, 2024
26 checks passed
@teoxoy teoxoy mentioned this pull request Apr 5, 2024
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