[AArch64][SelectionDAG] Eliminates redundant zero-extension for 32-bit popcount
authorzhongyunde <zhongyunde@huawei.com>
Mon, 9 Jan 2023 08:04:49 +0000 (16:04 +0800)
committerzhongyunde <zhongyunde@huawei.com>
Mon, 9 Jan 2023 08:08:16 +0000 (16:08 +0800)
commit9e83333445715e737ea78e42e082c99c8ebcb7df
tree83e53d0131fc9afe6b6cfe4f721b9b60265c2738
parent15692e7487b3a96edfe5409c84480ac21d01d768
[AArch64][SelectionDAG] Eliminates redundant zero-extension for 32-bit popcount

Fix https://github.com/llvm/llvm-project/issues/59597.
mov w8, w0 + fmov d0, x8 ==> fmov s0, w0

Reviewed By: dmgreen, efriedma

Differential Revision: https://reviews.llvm.org/D140649
llvm/lib/Target/AArch64/AArch64InstrInfo.td
llvm/test/CodeGen/AArch64/arm64-popcnt.ll