[Hexagon] Pattern match a CTZ loop into a call to countTrailingZeros.

No functional change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233192 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Benjamin Kramer 2015-03-25 15:36:57 +00:00
parent 4d09974cf3
commit 17a29a4847

View File

@ -1137,10 +1137,7 @@ SDNode *HexagonDAGToDAGISel::SelectBitOp(SDNode *N) {
return SelectCode(N);
// Get the bit position.
while (!(Val & 1)) {
Val >>= 1;
++bitpos;
}
bitpos = countTrailingZeros(uint64_t(Val));
} else {
// For fabs and fneg, it's always the 31st bit.
bitpos = 31;