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

[SPIRV-V] Implement Shader Model 6.8 Expanded Comparison Sampling #6854

Merged

Conversation

cassiebeckley
Copy link
Collaborator

Compile SampleCmpBias using OpImage*SampleDrefImplicitLod and SampleCmpGrad using OpImage*SampleDrefExplicitLod.

The existing handlers for CalculateLevelOfDetail and CalculateLevelOfDetailUnclamped work for the
SamplerComparisonSampler overload, so no new code is needed other than tests.

@cassiebeckley cassiebeckley requested a review from a team as a code owner August 8, 2024 16:30
Copy link
Collaborator

@s-perron s-perron left a comment

Choose a reason for hiding this comment

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

Looks good. I like the amount of new tests. I think the code could be cleaned up a bit. I made comments in the cmp-bias function. I believe the same goes for the cmp-grad function.

tools/clang/lib/SPIRV/SpirvEmitter.cpp Outdated Show resolved Hide resolved
tools/clang/lib/SPIRV/SpirvEmitter.cpp Outdated Show resolved Hide resolved
@cassiebeckley cassiebeckley force-pushed the 6_8-expanded-comparison-sampling branch from e4c7422 to 9de329f Compare August 15, 2024 19:11
@cassiebeckley cassiebeckley enabled auto-merge (squash) August 15, 2024 19:15
@s-perron s-perron self-requested a review August 22, 2024 15:38
Copy link
Collaborator

@s-perron s-perron left a comment

Choose a reason for hiding this comment

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

LGTM, I just wonder why the optional argument parsing is more general than I expect. I could have the optional arguments understanding wrong.

@s-perron
Copy link
Collaborator

s-perron commented Sep 9, 2024

@cassiebeckley Can you rebase the PR and push it again? For some reason the tests are not running.

Compile `SampleCmpBias` using `OpImage*SampleDrefImplicitLod` and
`SampleCmpGrad` using `OpImage*SampleDrefExplicitLod`.

The existing handlers for `CalculateLevelOfDetail` and
`CalculateLevelOfDetailUnclamped` work for the
`SamplerComparisonSampler` overload, so no new code is needed other than
tests.
@cassiebeckley cassiebeckley force-pushed the 6_8-expanded-comparison-sampling branch from f6443c3 to 318db25 Compare September 9, 2024 17:28
@cassiebeckley cassiebeckley merged commit ca2e67d into microsoft:main Sep 9, 2024
12 checks passed
@cassiebeckley cassiebeckley deleted the 6_8-expanded-comparison-sampling branch September 9, 2024 19:01
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