Skip to content

Remove integer variants of SampleCmp #5564

@pow2clk

Description

@pow2clk

Description
When adding integer sampling support in Shader Model 6.7, SampleCmp, SampleCmpLevelZero, and SampleCmpLevel were given support for integer resources in spite of the fact that the spec limits filter modes to non-comparison variants.

Steps to Reproduce

The existing test includes integer overloads for these builtins: https://github.com/microsoft/DirectXShaderCompiler/blob/main/tools/clang/test/HLSLFileCheck/hlsl/objects/Texture/sampleInteger.hlsl

Just compiling it with the RUN arguments -T ps_6_7 and -DTYPE=uint (or any integer) will show a successful compile

Actual Behavior
DXIL with sampleCmp called on integer resources is generated. It should fail as it does with 6.6

Environment

  • DXC version : 1.8 - 1.8.0.3959
  • Host Operating System win11

Metadata

Metadata

Assignees

Labels

bugBug, regression, crashsm6.8Shader Model 6.8

Type

No type

Projects

Status

Done

Status

Triaged

Relationships

None yet

Development

No branches or pull requests

Issue actions