This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Ignore unused bits in VINTERP encoding
ClosedPublic

Authored by foad on Feb 9 2023, 2:17 AM.

Details

Summary

In the GFX11 VINTERP encoding bits 23, 59 and 60 are unused. Change the
disassembler to ignore these bits.

Diff Detail

Event Timeline

foad created this revision.Feb 9 2023, 2:17 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 9 2023, 2:17 AM
foad requested review of this revision.Feb 9 2023, 2:17 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 9 2023, 2:17 AM
foad added a comment.Feb 9 2023, 2:19 AM

We are not consistent about handling "unused" bits. I'm not even sure what to call them - in the SP3 encoding tables they are just greyed out. But I think the correct behaviour is for the assembler to set them to 0, and the disassembler to ignore them. This is what SP3 seems to do.

dp accepted this revision.Feb 9 2023, 2:30 AM

LGTM.

llvm/test/MC/Disassembler/AMDGPU/gfx11_dasm_vinterp.txt
6

Maybe add a comment describing the purpose of the test?

This revision is now accepted and ready to land.Feb 9 2023, 2:30 AM
This revision was landed with ongoing or failed builds.Feb 9 2023, 2:43 AM
This revision was automatically updated to reflect the committed changes.