- GCCAS now uses load value #ing for GCSE
authorChris Lattner <sabre@nondot.org>
Fri, 30 Aug 2002 20:25:25 +0000 (20:25 +0000)
committerChris Lattner <sabre@nondot.org>
Fri, 30 Aug 2002 20:25:25 +0000 (20:25 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3536 91177308-0d34-0410-b5e6-96231b3b80d8

tools/gccas/gccas.cpp

index a5ceace4456a6808c514a85bbc638131411cce48..b12ae0de629ea31ca283f30d2dd8cb0c0720aedb 100644 (file)
@@ -13,6 +13,7 @@
 #include "llvm/Transforms/RaisePointerReferences.h"
 #include "llvm/Transforms/IPO.h"
 #include "llvm/Transforms/Scalar.h"
 #include "llvm/Transforms/RaisePointerReferences.h"
 #include "llvm/Transforms/IPO.h"
 #include "llvm/Transforms/Scalar.h"
+#include "llvm/Analysis/LoadValueNumbering.h"
 #include "llvm/Analysis/Verifier.h"
 #include "llvm/Bytecode/WriteBytecodePass.h"
 #include "llvm/Target/TargetData.h"
 #include "llvm/Analysis/Verifier.h"
 #include "llvm/Bytecode/WriteBytecodePass.h"
 #include "llvm/Target/TargetData.h"
@@ -86,6 +87,7 @@ void AddConfiguredTransformationPasses(PassManager &PM) {
   addPass(PM, createInstructionCombiningPass());  // Combine silly seq's
   addPass(PM, createDeadInstEliminationPass());   // Kill InstCombine remnants
   addPass(PM, createLICMPass());                  // Hoist loop invariants
   addPass(PM, createInstructionCombiningPass());  // Combine silly seq's
   addPass(PM, createDeadInstEliminationPass());   // Kill InstCombine remnants
   addPass(PM, createLICMPass());                  // Hoist loop invariants
+  addPass(PM, createLoadValueNumberingPass());    // GVN for load instructions
   addPass(PM, createGCSEPass());                  // Remove common subexprs
   addPass(PM, createSCCPPass());                  // Constant prop with SCCP
 
   addPass(PM, createGCSEPass());                  // Remove common subexprs
   addPass(PM, createSCCPPass());                  // Constant prop with SCCP