Repository navigation
Shaders: honor explicit half input flush in normalized conversions - #3166
Open
andrewpozdnakov7-jpg wants to merge 2 commits into
Open
andrewpozdnakov7-jpg wants to merge 2 commits into
andrewpozdnakov7-jpg wants to merge 2 commits into
Conversation
Contributor
Author
|
Updated to |
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.
V_CVT_NORM_I16_F16andV_CVT_NORM_U16_F16must read half subnormals as zero when MODE[6] disables input denormals. Lyrnc's RDNA2 sweep in #376 measured the distinction for both instructions.Reuse the existing MODE dataflow for statically known
S_DENORM_MODEand literal MODE writes. The analysis runs lazily for shaders that use either conversion. Known flush sites zero the source magnitude below the smallest normal half before scaling. Entry and runtime-unknown modes retain the current behavior.On main, signed conversion of
0x0101in flush mode returns0x0001. On WARP the patch gives0x0000, and all 274 synthetic readbacks passed across both conversions, the four denormal modes, explicit MODE bit writes and agreeing branch paths. All 36 VALU tests, strict shader Clippy and the asset policy passed.AI-assisted with Codex. Please retain the Git author when cherry-picking or rebasing. If folded into another commit, please add
Co-authored-by: andrewpozdnakov7-jpg <andrewpozdnakov7-jpg@users.noreply.github.com>.