This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Set MemoryVT for truncstores in tblgen.
ClosedPublic

Authored by abinavpp on Jan 20 2022, 2:19 AM.

Details

Summary

GlobalISelEmitter was skipping these patterns when its predicates were
checked. This patch should allow us to select d16_hi stores in
GlobalISel.

Diff Detail

Event Timeline

abinavpp created this revision.Jan 20 2022, 2:19 AM
abinavpp requested review of this revision.Jan 20 2022, 2:19 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 20 2022, 2:19 AM
foad accepted this revision.Jan 20 2022, 2:46 AM

LGTM. It would be nice to improve the codegen as noted inline but I'm not sure how to implement that.

llvm/test/CodeGen/AMDGPU/GlobalISel/load-unaligned.ll
268

Now the only use of v5 is in v_lshrrev_b16 v1, 8, v5 below, so we really ought to fold that somehow.

This revision is now accepted and ready to land.Jan 20 2022, 2:46 AM
This revision was automatically updated to reflect the committed changes.