[llvm] r271804 - fix formatting, punctuation; NFC

Sanjay Patel via llvm-commits llvm-commits at lists.llvm.org
Sat Jun 4 13:39:23 PDT 2016


Author: spatel
Date: Sat Jun  4 15:39:22 2016
New Revision: 271804

URL: http://llvm.org/viewvc/llvm-project?rev=271804&view=rev
Log:
fix formatting, punctuation; NFC

Modified:
    llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp

Modified: llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp?rev=271804&r1=271803&r2=271804&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp (original)
+++ llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp Sat Jun  4 15:39:22 2016
@@ -2438,7 +2438,7 @@ Instruction *InstCombiner::visitICmpInst
     return new ICmpInst(ICI.getUnsignedPredicate(), LHSCIOp, RHSCIOp);
   }
 
-  // If we aren't dealing with a constant on the RHS, exit early
+  // If we aren't dealing with a constant on the RHS, exit early.
   ConstantInt *CI = dyn_cast<ConstantInt>(ICI.getOperand(1));
   if (!CI)
     return nullptr;
@@ -3166,8 +3166,7 @@ Instruction *InstCombiner::visitICmpInst
   /// complex to least complex.  This puts constants before unary operators,
   /// before binary operators.
   if (Op0Cplxity < Op1Cplxity ||
-        (Op0Cplxity == Op1Cplxity &&
-         swapMayExposeCSEOpportunities(Op0, Op1))) {
+      (Op0Cplxity == Op1Cplxity && swapMayExposeCSEOpportunities(Op0, Op1))) {
     I.swapOperands();
     std::swap(Op0, Op1);
     Changed = true;
@@ -3179,8 +3178,7 @@ Instruction *InstCombiner::visitICmpInst
 
   // comparing -val or val with non-zero is the same as just comparing val
   // ie, abs(val) != 0 -> val != 0
-  if (I.getPredicate() == ICmpInst::ICMP_NE && match(Op1, m_Zero()))
-  {
+  if (I.getPredicate() == ICmpInst::ICMP_NE && match(Op1, m_Zero())) {
     Value *Cond, *SelectTrue, *SelectFalse;
     if (match(Op0, m_Select(m_Value(Cond), m_Value(SelectTrue),
                             m_Value(SelectFalse)))) {




More information about the llvm-commits mailing list