forked from OSchip/llvm-project
[InstCombine] Add TODOs for a couple things that should maybe be in InstSimplify instead. NFC
llvm-svn: 307065
This commit is contained in:
parent
872d750560
commit
0f746c2793
|
@ -1965,6 +1965,7 @@ Instruction *InstCombiner::visitCallInst(CallInst &CI) {
|
||||||
Value *IIOperand = II->getArgOperand(0);
|
Value *IIOperand = II->getArgOperand(0);
|
||||||
Value *X = nullptr;
|
Value *X = nullptr;
|
||||||
|
|
||||||
|
// TODO should this be in InstSimplify?
|
||||||
// bswap(bswap(x)) -> x
|
// bswap(bswap(x)) -> x
|
||||||
if (match(IIOperand, m_BSwap(m_Value(X))))
|
if (match(IIOperand, m_BSwap(m_Value(X))))
|
||||||
return replaceInstUsesWith(CI, X);
|
return replaceInstUsesWith(CI, X);
|
||||||
|
@ -1984,6 +1985,7 @@ Instruction *InstCombiner::visitCallInst(CallInst &CI) {
|
||||||
Value *IIOperand = II->getArgOperand(0);
|
Value *IIOperand = II->getArgOperand(0);
|
||||||
Value *X = nullptr;
|
Value *X = nullptr;
|
||||||
|
|
||||||
|
// TODO should this be in InstSimplify?
|
||||||
// bitreverse(bitreverse(x)) -> x
|
// bitreverse(bitreverse(x)) -> x
|
||||||
if (match(IIOperand, m_BitReverse(m_Value(X))))
|
if (match(IIOperand, m_BitReverse(m_Value(X))))
|
||||||
return replaceInstUsesWith(CI, X);
|
return replaceInstUsesWith(CI, X);
|
||||||
|
|
Loading…
Reference in New Issue