diff options
author | Chris Lattner <sabre@nondot.org> | 2003-04-24 18:26:03 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-04-24 18:26:03 +0000 |
commit | 961f7b4e4fc20785861a404c4bb882751933e358 (patch) | |
tree | 8ec6f4b62e5ec741e79cd52a9fa60b91368cafb9 /tools/gccas | |
parent | 5705f0c2ea2a75195bfb19840ac7c05542ea4b51 (diff) | |
download | external_llvm-961f7b4e4fc20785861a404c4bb882751933e358.zip external_llvm-961f7b4e4fc20785861a404c4bb882751933e358.tar.gz external_llvm-961f7b4e4fc20785861a404c4bb882751933e358.tar.bz2 |
LevelRaise now gets target data from passmanager
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5898 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/gccas')
-rw-r--r-- | tools/gccas/gccas.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/gccas/gccas.cpp b/tools/gccas/gccas.cpp index 2172782..eae0b28 100644 --- a/tools/gccas/gccas.cpp +++ b/tools/gccas/gccas.cpp @@ -23,9 +23,6 @@ #include <fstream> namespace { - // FIXME: This should eventually be parameterized... - TargetData TD("gccas target"); - cl::opt<std::string> InputFilename(cl::Positional,cl::desc("<input llvm assembly>"),cl::init("-")); @@ -74,7 +71,7 @@ void AddConfiguredTransformationPasses(PassManager &PM) { addPass(PM, createDeadInstEliminationPass()); // Remove Dead code/vars addPass(PM, createRaiseAllocationsPass()); // call %malloc -> malloc inst addPass(PM, createIndVarSimplifyPass()); // Simplify indvars - addPass(PM, createRaisePointerReferencesPass(TD));// Recover type information + addPass(PM, createRaisePointerReferencesPass());// Recover type information addPass(PM, createInstructionCombiningPass()); // Combine silly seq's addPass(PM, createPromoteMemoryToRegister()); // Promote alloca's to regs addPass(PM, createReassociatePass()); // Reassociate expressions @@ -97,6 +94,9 @@ void AddConfiguredTransformationPasses(PassManager &PM) { int main(int argc, char **argv) { cl::ParseCommandLineOptions(argc, argv, " llvm .s -> .o assembler for GCC\n"); + // FIXME: This should eventually be parameterized... + TargetData TD("gccas target"); + std::auto_ptr<Module> M; try { // Parse the file now... |