spatel added inline comments.
================ Comment at: llvm/include/llvm/IR/PatternMatch.h:622 inline bind_ty<Instruction> m_Instruction(Instruction *&I) { return I; } /// Match a binary operator, capturing it if we match. +inline bind_ty<UnaryOperator> m_UnOp(UnaryOperator *&I) { return I; } ---------------- Match a binary -> Match a unary ================ Comment at: llvm/include/llvm/IR/PatternMatch.h:802-803 + + // The evaluation order is always stable, regardless of Commutability. + // The LHS is always matched first. + AnyUnaryOp_match(const OP_t &X) : X(X) {} ---------------- The copied comment doesn't make sense for a unary op; there's no commutability/LHS here. ================ Comment at: llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp:379 + // TODO de-duplicate binary and unary matches cmatchers with n-ary matching + UnaryOperator *UO; ---------------- typo: cmatchers? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75467/new/ https://reviews.llvm.org/D75467 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits