Repository navigation
Conversation
…6 FMA ops on the GPU Add GPU coverage for eight translated RDNA2 f16 instructions with no existing GPU tests: v_pk_fma_f16, v_pk_min_f16, v_pk_max_f16, v_dot2c_f32_f16, v_pack_b32_f16, v_fmac_f16, v_fmamk_f16 and v_fmaak_f16. Exercises OP_SEL/OP_SEL_HI/OP_SEL_HI_2, NEG/NEG_HI, CLAMP, consecutive dot2c accumulation, upper-16-bit literal masking and untouched VDST half preservation across four distinct exact binary16 lane patterns. Assisted-by: Antigravity (Gemini 4 Neon)
Owner
Author
|
Upstream PR xcl-dev#1158 was closed or merged. |
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.
Adds GPU tests for 8 translated RDNA2 f16 instructions that currently have no GPU coverage in
crates/xcl/src/gpu/recomp/tests.rs:v_pk_fma_f16,v_pk_min_f16,v_pk_max_f16,v_dot2c_f32_f16,v_pack_b32_f16,v_fmac_f16,v_fmamk_f16, andv_fmaak_f16.All inputs are exact binary16 values across four distinct edge-case lanes so results are exact across rounding modes and hardware drivers.
What is in it
crates/xcl/src/gpu/recomp/tests.rs:gpu_packed_f16_fma_min_max_dot2c_and_pack: checksv_pk_fma_f16,v_pk_min_f16, andv_pk_max_f16(plain, swappedOP_SEL/OP_SEL_HI/OP_SEL_HI_2,NEG/NEG_HI, andCLAMP), two consecutivev_dot2c_f32_f16accumulations into the samevdst, and all fourOP_SEL[1:0]pairings ofv_pack_b32_f16.gpu_f16_fmac_fmamk_fmaak: checks VOP2v_fmac_f16, VOP3v_fmac_f16(OP_SEL=0b1010,CLAMP=1),v_fmamk_f16, andv_fmaak_f16(verifying upper-16-bit literal masking and preservation of the untouched half ofvdst).Tested
cargo test -p xcl --lib gpu_packed_f16 -- --nocapture: 1 passed, 0 failedcargo test -p xcl --lib gpu_f16_fmac -- --nocapture: 1 passed, 0 failed.\scripts\test.ps1 --skip test_title_runs_and_game_folder_is_untouched --skip test_title_draws_with_a_root_signature_under_the_debug_layer: 741 passed, 0 failed, 41 ignored, 2 filtered outgpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask,gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware(no wave64)python -I scripts/pr_check.py --localon this PR's description and changed files:description okRegression run
crates/xcl/src/gpu/recomp/tests.rs(test-only).Not tested
e2etests (test_title_runs_and_game_folder_is_untouched,test_title_draws_with_a_root_signature_under_the_debug_layer)AI use
emit.rs/tests.rs, wrote both GPU tests and this PR description, and ran the test commands above.Mirror of xcl-dev#1158 (auto-synced, do not edit).