1 //===- llvm/Transforms/Scalar/InstructionCombining.h -------------*- C++ -*--=//
3 // InstructionCombining - Combine instructions to form fewer, simple
4 // instructions. This pass does not modify the CFG, and has a tendancy to
5 // make instructions dead, so a subsequent DCE pass is useful.
7 // This pass combines things like:
13 //===----------------------------------------------------------------------===//
15 #ifndef LLVM_TRANSFORMS_SCALAR_INSTRUCTIONCOMBINING_H
16 #define LLVM_TRANSFORMS_SCALAR_INSTRUCTIONCOMBINING_H
18 #include "llvm/Pass.h"
21 struct InstructionCombining : public MethodPass {
22 static bool doit(Method *M);
23 static bool CombineInstruction(Instruction *I);
25 virtual bool runOnMethod(Method *M) { return doit(M); }