[spirv] Don't emit extension for using fp16 in GLSLstd450 instructions.#2503
Merged
ehsannas merged 1 commit intomicrosoft:masterfrom Oct 8, 2019
Merged
[spirv] Don't emit extension for using fp16 in GLSLstd450 instructions.#2503ehsannas merged 1 commit intomicrosoft:masterfrom
ehsannas merged 1 commit intomicrosoft:masterfrom
Conversation
With the exception of interpolation instructions. New revision of SPIR-V Extended Instructions for GLSL allows fp16 except for interpolation instructions. See: https://www.khronos.org/registry/spir-v/specs/1.0/GLSL.std.450.html Fixes microsoft#2500.
jaebaek
reviewed
Oct 8, 2019
Collaborator
jaebaek
left a comment
There was a problem hiding this comment.
LGTM but I think adding an example for interpolate operation would make it more complete. Was it already added?
Contributor
Author
|
I wasn't able to find any hlsl intrinsic that would map to the extended instruction set's interpolate instructions. |
jaebaek
approved these changes
Oct 8, 2019
sudonatalie
added a commit
to sudonatalie/DirectXShaderCompiler
that referenced
this pull request
Jan 4, 2024
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
added a commit
to sudonatalie/DirectXShaderCompiler
that referenced
this pull request
Jan 4, 2024
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
added a commit
that referenced
this pull request
Jan 4, 2024
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 #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
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With the exception of interpolation instructions.
New revision of SPIR-V Extended Instructions for GLSL allows fp16
except for interpolation instructions.
See: https://www.khronos.org/registry/spir-v/specs/1.0/GLSL.std.450.html
Fixes #2500.