mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 22:40:52 +01:00
[PR #291] rdna2spirv: zero the tfe/lwe status VGPR on image_load and image_load_mip #343
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#343
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/291
Author: @Andretuta
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:old-pr/10022📝 Commits (1)
de87b1ardna2spirv: zero the tfe/lwe status VGPR on image_load and image_load_mip📊 Changes
3 files changed (+113 additions, -10 deletions)
View changed files
📝
docs/design.md(+1 -1)➕
tests/semantic/test_image_load_tfe.py(+95 -0)📝
tools/rdna2spirv.py(+17 -9)📄 Description
Original description (mentions and
#Nreferences are disabled; the numbers refer to the old repository):#8968addedcs_imgload_tfeandcs_imgload_d16_tfeonmain, and both fail on an NVIDIA GeForce RTX 5060 Ti (r32 sint (sint view): 64 bad, texel(5,3) = 2071instead of71) becauseimage_read_typednever wrote0into the trailingtfe/lwestatus VGPR (vdata[data_vgprs]), leaving the seeded0x3e8(1000) value untouched.Claimed in
#9677.Changes
tools/rdna2spirv.py: passstatus=("tfe" in mods or "lwe" in mods)fromimage_load(typed andglccoherent) andimage_load_mip(2D and 3D) intoimage_read_typed, and write0tovdata[data_vgprs]((popcount(dmask) + 1) // 2underd16, elsepopcount(dmask)) viaself.dst(...)so inactive lanes stay preserved.tests/semantic/test_image_load_tfe.py: unit tests coveringtfe,lwe,d16packing (dmask:0x3,0x7),glc, and 2D/3Dimage_load_mip.docs/design.md: document thetfe/lwestatus VGPR rule underTyped image loads.Tested
llvm-mc 21.1.8, Python 3.14.4)python -I scripts/run_gpu_tests.py --build runtime/build --filter imgload: 4/4 passed (cs_imgload,cs_imgload_d16,cs_imgload_tfe,cs_imgload_d16_tfe; 4/4spirv-val) — previously 2/4 (cs_imgload_tfeandcs_imgload_d16_tfefailed with2071)python -m unittest discover -s tests/semantic -p test_image_load_tfe.py: 3/3 passedpython -m unittest discover -s tests/semantic -p test_mem_crash_forms.py: 1/1 passedpython -m unittest discover -s tests/semantic -p test_image_coherent.py: 10/10 passed (1 skipped)python -I tests/test_image_load_typed.py: 23/23 passed (2 skipped)python -m compileall -q make_game.py tools testsandpython -I scripts/check_no_game_data.py ...: passedAI-assisted.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.