diff options
author | Sanjay Patel <spatel@rotateright.com> | 2016-07-03 14:08:19 +0000 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2016-07-03 14:08:19 +0000 |
commit | a1a4e100be1e376776252a5da0eb2ebd8f9ca034 (patch) | |
tree | fc4f138195ffcb7025eba85c02ae006480b4cc07 /llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp | |
parent | 1f59076196f6f8d66ef0bf643b2a1a242e4ebab2 (diff) | |
download | bcm5719-llvm-a1a4e100be1e376776252a5da0eb2ebd8f9ca034.tar.gz bcm5719-llvm-a1a4e100be1e376776252a5da0eb2ebd8f9ca034.zip |
fix formatting; NFC
llvm-svn: 274463
Diffstat (limited to 'llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp')
-rw-r--r-- | llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp b/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp index 7c3ef99d227..da4d7c39025 100644 --- a/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp +++ b/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp @@ -925,7 +925,7 @@ Instruction *InstCombiner::visitSelectInst(SelectInst &SI) { return BinaryOperator::CreateOr(CondVal, FalseVal); } // Change: A = select B, false, C --> A = and !B, C - Value *NotCond = Builder->CreateNot(CondVal, "not."+CondVal->getName()); + Value *NotCond = Builder->CreateNot(CondVal, "not." + CondVal->getName()); return BinaryOperator::CreateAnd(NotCond, FalseVal); } if (ConstantInt *C = dyn_cast<ConstantInt>(FalseVal)) { @@ -934,19 +934,19 @@ Instruction *InstCombiner::visitSelectInst(SelectInst &SI) { return BinaryOperator::CreateAnd(CondVal, TrueVal); } // Change: A = select B, C, true --> A = or !B, C - Value *NotCond = Builder->CreateNot(CondVal, "not."+CondVal->getName()); + Value *NotCond = Builder->CreateNot(CondVal, "not." + CondVal->getName()); return BinaryOperator::CreateOr(NotCond, TrueVal); } - // select a, b, a -> a&b - // select a, a, b -> a|b + // select a, a, b -> a | b + // select a, b, a -> a & b if (CondVal == TrueVal) return BinaryOperator::CreateOr(CondVal, FalseVal); if (CondVal == FalseVal) return BinaryOperator::CreateAnd(CondVal, TrueVal); - // select a, ~a, b -> (~a)&b - // select a, b, ~a -> (~a)|b + // select a, ~a, b -> (~a) & b + // select a, b, ~a -> (~a) | b if (match(TrueVal, m_Not(m_Specific(CondVal)))) return BinaryOperator::CreateAnd(TrueVal, FalseVal); if (match(FalseVal, m_Not(m_Specific(CondVal)))) |