- Teach SelectionDAG::isKnownNeverZero to return true (op x, c) when c is
authorEvan Cheng <evan.cheng@apple.com>
Tue, 24 May 2011 01:48:22 +0000 (01:48 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Tue, 24 May 2011 01:48:22 +0000 (01:48 +0000)
commitb5a55d979c84e100f383ce11c5c5e3b616b9dcc4
tree52d1aa5341d7eef05cc952b61bd9fdb68cabad10
parent4992b03cbdaad1df46ea771b587f247395e49999
- Teach SelectionDAG::isKnownNeverZero to return true (op x, c) when c is
  non-zero.
- Teach X86 cmov optimization to eliminate the cmov from ctlz, cttz extension
  when the source of X86ISD::BSR / X86ISD::BSF is proven to be non-zero.

rdar://9490949

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131948 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/Target/X86/X86ISelLowering.cpp
test/CodeGen/X86/clz.ll