Repository navigation
test(semantic): add comprehensive semantic tests and reference oracle for v_interp_p2_f16 - #2825
Conversation
…odel for v_interp_p2_f16
…ions for v_interp_p2_f16
…king for v_interp_p2_f16
…on for v_interp_p2_f16
…eneration for v_interp_p2_f16
…andling for v_interp_p2_f16
… detection for v_interp_p2_f16
|
Structural review (same family as the #2824 finding): AI-assisted (ZCode agent): the verification runs were executed by a coding agent on this machine. |
|
Reviewed PR #2825 ( Files read
Checks run
Findings
|
|
Measured on gfx1036 (RDNA2, AMD Radeon iGPU, driver 26.10.1, game MODE: ieee 0, dx10_clamp 1, denorm32 0, denorm16_64 3): not measured. AI-assisted. |
They model the instruction in Python and never run tools/rdna2spirv.py, so they pass whatever the translator does (tests/test_semantic_translator_use.py, added this round, rejects them). PRs: ItsNotRexed#2335 ItsNotRexed#2754 ItsNotRexed#2759 ItsNotRexed#2761 ItsNotRexed#2788 ItsNotRexed#2793 ItsNotRexed#2797 ItsNotRexed#2800 ItsNotRexed#2803 ItsNotRexed#2804 ItsNotRexed#2814 ItsNotRexed#2816 ItsNotRexed#2819 ItsNotRexed#2824 ItsNotRexed#2825 ItsNotRexed#2829 ItsNotRexed#2834 ItsNotRexed#2835 ItsNotRexed#2837 ItsNotRexed#2840 ItsNotRexed#2845 ItsNotRexed#2850 ItsNotRexed#2854 ItsNotRexed#2856 ItsNotRexed#2867 ItsNotRexed#2868 ItsNotRexed#2877 ItsNotRexed#2883 ItsNotRexed#2889 ItsNotRexed#2892 ItsNotRexed#2895 ItsNotRexed#2896 ItsNotRexed#2897 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
What and why
Adds comprehensive semantic interpreter tests and reference mathematical oracle for
v_interp_p2_f16(half-precision parameter interpolation phase 2) intests/semantic/test_interp_p2_f16.py.Coverage includes:
ASTInstructionAST node,ASTOperand,AttributeRef, source modifiers (abs,neg,high), destination half selection, andclamp.InterpolationRegisterFile,AttributeBuffer, SGPRs) and deterministic scalar step execution with textual assembly parsing.dst == src_j, high/low f16 interleaving into the same 32-bit register, and untouched half preservation across masked wavefront lanes.invalid_op,overflow,underflow,inexact) and condition codes (zero,negative,nan), alongside VCC / SCC preservation and condition mask generation.Tested
python -m compileall -q tests(clean)python -I tests/semantic/test_interp_p2_f16.py(32/32 tests passing)python -m unittest discover -s tests/semantic -p "test_interp_p2_f16.py"(32/32 tests passing)Checklist
docs/design.md, with how it was confirmed. (N/A: Test-only PR for semantic verification).