[PATCH] D107187: [amdgpu] Add an enhanced conversion from i64 to f32.
Michael Liao via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 3 08:46:36 PDT 2021
hliao added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp:2106
+ } else {
+ auto LZ = B.buildCTLZ_ZERO_UNDEF(S32, Unmerge.getReg(1));
+ auto NotAllZeros =
----------------
foad wrote:
> Can't you buildCTLZ here and let the legalizer worry about how to handle the ZERO case? In particular it would be better to do v_ffbh followed by v_min_u32 with 32, instead of a compare and select.
I reused part of the original code and didn't try whether we support CLTZ without undefined zero behavior. We may try that later.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D107187/new/
https://reviews.llvm.org/D107187
More information about the llvm-commits
mailing list