[PATCH] D74697: AMDGPU/GlobalISel: Select v2s32->v2s16 G_TRUNC
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 17 05:48:56 PST 2020
arsenm marked an inline comment as done.
arsenm added inline comments.
================
Comment at: llvm/test/CodeGen/AMDGPU/GlobalISel/trunc.ll:95
+; GFX8-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
+; GFX8-NEXT: v_mov_b32_sdwa v0, v1 dst_sel:WORD_1 dst_unused:UNUSED_PRESERVE src0_sel:WORD_0
+; GFX8-NEXT: s_setpc_b64 s[30:31]
----------------
foad wrote:
> Could also do this with a single v_perm instruction, but I don't know if there's any reason to prefer it (e.g. are there any processors that have v_perm but don't have sdwa?).
That would require materializing the constant in a register, so it would be 2 instructions, and 16 bytes, vs 1 8 byte instruction
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74697/new/
https://reviews.llvm.org/D74697
More information about the llvm-commits
mailing list