[PowerPC] Fix eq/ne comparison of v2i64 pre-Power8
authorNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Mon, 24 Jan 2022 19:19:20 +0000 (13:19 -0600)
committerNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Wed, 26 Jan 2022 14:59:08 +0000 (08:59 -0600)
commit0c56bc92e4b9cf949f431d1c9e11e9b509ef6dbd
treef5159ae74a7383c86dca91fb0149bedf29f7054b
parentdc441d776f9f8c3bbde4e234c606abffe7d5a95e
[PowerPC] Fix eq/ne comparison of v2i64 pre-Power8

In commit 1674d9b6b2da, I fixed the bug where we didn't consider
both words of the result of the comparison. However, the logic
needs to be different for eq and ne.
Namely for eq, we need both words of the doubleword to equal so it
is an AND. OTOH for ne, we need either word to be unequal so it
is an OR.
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
llvm/test/CodeGen/PowerPC/vec-icmpeq-v2i64-p7.ll
llvm/test/CodeGen/PowerPC/vector-popcnt-128-ult-ugt.ll
llvm/test/CodeGen/PowerPC/vsx.ll