From 0f5a8d47494e278c7b61c4b3e2807afc47cc926b Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 5 Dec 2001 06:34:58 +0000 Subject: [PATCH] Simplify induction variables before 'raising' the representation llvm-svn: 1418 --- llvm/tools/gccas/Makefile | 2 +- llvm/tools/gccas/gccas.cpp | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/llvm/tools/gccas/Makefile b/llvm/tools/gccas/Makefile index bdd41a30246a..c5f6a4976121 100644 --- a/llvm/tools/gccas/Makefile +++ b/llvm/tools/gccas/Makefile @@ -1,6 +1,6 @@ LEVEL = ../.. TOOLNAME = gccas -USEDLIBS = asmparser bcwriter transforms analysis opt vmcore asmwriter support target +USEDLIBS = asmparser bcwriter scalaropts transforms analysis opt vmcore asmwriter support target include $(LEVEL)/Makefile.common diff --git a/llvm/tools/gccas/gccas.cpp b/llvm/tools/gccas/gccas.cpp index c5ab2dff68dc..376aff083a43 100644 --- a/llvm/tools/gccas/gccas.cpp +++ b/llvm/tools/gccas/gccas.cpp @@ -14,6 +14,7 @@ #include "llvm/Optimizations/ConstantProp.h" #include "llvm/Optimizations/DCE.h" #include "llvm/Transforms/ConstantMerge.h" +#include "llvm/Transforms/Scalar/IndVarSimplify.h" #include "llvm/Bytecode/Writer.h" #include "Support/CommandLine.h" #include @@ -64,6 +65,7 @@ int main(int argc, char **argv) { // vector Passes; Passes.push_back(new CleanupGCCOutput()); // Fix gccisms + Passes.push_back(new InductionVariableSimplify()); // Simplify indvars Passes.push_back(new RaisePointerReferences()); // Fix general low level code Passes.push_back(new ConstantMerge()); // Merge dup global constants