Add comments
authorChris Lattner <sabre@nondot.org>
Wed, 23 Jul 2003 21:41:57 +0000 (21:41 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 23 Jul 2003 21:41:57 +0000 (21:41 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7283 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Scalar/InstructionCombining.cpp

index 7411428f40f6e7b2ca3725ed06f6fdf0b7183fdb..6d5502533a042f87bdbc2147790ca70cb2679393 100644 (file)
 //
 // This is a simple worklist driven algorithm.
 //
+// This pass guarantees that the following cannonicalizations are performed on
+// the program:
+//    1. If a binary operator has a constant operand, it is moved to the RHS
+//    2. Logical operators with constant operands are always grouped so that
+//       'or's are performed first, then 'and's, then 'xor's.
+//    3. SetCC instructions are converted from <,>,<=,>= to ==,!= if possible
+//    4. All SetCC instructions on boolean values are replaced with logical ops
+//    N. This list is incomplete
+//
 //===----------------------------------------------------------------------===//
 
 #include "llvm/Transforms/Scalar.h"