Skip to content

[SPIR-V] Remove dead code and correct Float16 docs#6127

Merged
sudonatalie merged 1 commit intomicrosoft:mainfrom
sudonatalie:float16-docs
Jan 4, 2024
Merged

[SPIR-V] Remove dead code and correct Float16 docs#6127
sudonatalie merged 1 commit intomicrosoft:mainfrom
sudonatalie:float16-docs

Conversation

@sudonatalie
Copy link
Copy Markdown
Collaborator

The docs were out of date stating that the SPV_AMD_gpu_shader_half_float extension was added when half types were used. This is now corrected to show that the Float16 capability is added and no extension.

The remaining code that could have added that extension in certain cases has been dead code since #2503 since none of the instructions checked in that list are ones that are emitted by DXC, so it is removed to clean up.

Evidence that this is dead code:

  1. git grep "InterpolateAt" finds no uses other than those removed here.
  2. All tests still pass when it's removed.
  3. The comments in [spirv] Don't emit extension for using fp16 in GLSLstd450 instructions. #2503 also say they were not able to find a mapping from any HLSL intrinsics to these instructions, which is why no tests were added.

Follow-up from: KhronosGroup/SPIRV-Tools#5519

The docs incorrectly stated that the `SPV_AMD_gpu_shader_half_float`
extension was added when half types were used. This is now corrected to
show that the Float16 capability is added instead.

The remaining code that could have added that extension in certain cases
has been dead code since microsoft#2503 since none of the instructions checked in
that list are ones that are emitted by DXC, so it is removed to clean
up.

Follow up from KhronosGroup/SPIRV-Tools#5519
@sudonatalie sudonatalie enabled auto-merge (squash) January 4, 2024 20:15
@sudonatalie sudonatalie merged commit 1574879 into microsoft:main Jan 4, 2024
@sudonatalie sudonatalie deleted the float16-docs branch January 4, 2024 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants