From: Chris Lattner Date: Fri, 16 Jun 2006 18:23:49 +0000 (+0000) Subject: Don't pass target name into TargetData anymore, it is never used or needed. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=831b1210390b3a00f68de9a79be0f4e13d6287b0;p=oota-llvm.git Don't pass target name into TargetData anymore, it is never used or needed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28831 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/projects/Stacker/lib/compiler/StackerCompiler.cpp b/projects/Stacker/lib/compiler/StackerCompiler.cpp index 339c8afb3cd..b9e41a889ce 100644 --- a/projects/Stacker/lib/compiler/StackerCompiler.cpp +++ b/projects/Stacker/lib/compiler/StackerCompiler.cpp @@ -264,7 +264,7 @@ StackerCompiler::compile( // Set up a pass manager PassManager Passes; // Add in the passes we want to execute - Passes.add(new TargetData("stkrc",TheModule)); + Passes.add(new TargetData(TheModule)); // Verify we start with valid Passes.add(createVerifierPass()); diff --git a/tools/analyze/analyze.cpp b/tools/analyze/analyze.cpp index c3411ab627e..e6b2be5adab 100644 --- a/tools/analyze/analyze.cpp +++ b/tools/analyze/analyze.cpp @@ -148,7 +148,7 @@ int main(int argc, char **argv) { PassManager Passes; // Add an appropriate TargetData instance for this module... - Passes.add(new TargetData("analyze", CurMod)); + Passes.add(new TargetData(CurMod)); // Make sure the input LLVM is well formed. if (!NoVerify) diff --git a/tools/bugpoint/ExtractFunction.cpp b/tools/bugpoint/ExtractFunction.cpp index afc1c64b7c4..2b12519ff30 100644 --- a/tools/bugpoint/ExtractFunction.cpp +++ b/tools/bugpoint/ExtractFunction.cpp @@ -80,7 +80,7 @@ Module *BugDriver::deleteInstructionFromProgram(const Instruction *I, // Spiff up the output a little bit. PassManager Passes; // Make sure that the appropriate target data is always used... - Passes.add(new TargetData("bugpoint", Result)); + Passes.add(new TargetData(Result)); /// FIXME: If this used runPasses() like the methods below, we could get rid /// of the -disable-* options! diff --git a/tools/bugpoint/OptimizerDriver.cpp b/tools/bugpoint/OptimizerDriver.cpp index 6caced779b5..df4f470da2b 100644 --- a/tools/bugpoint/OptimizerDriver.cpp +++ b/tools/bugpoint/OptimizerDriver.cpp @@ -104,7 +104,7 @@ int BugDriver::runPassesAsChild(const std::vector &Passes) { PassManager PM; // Make sure that the appropriate target data is always used... - PM.add(new TargetData("bugpoint", Program)); + PM.add(new TargetData(Program)); for (unsigned i = 0, e = Passes.size(); i != e; ++i) { if (Passes[i]->getNormalCtor()) diff --git a/tools/gccas/gccas.cpp b/tools/gccas/gccas.cpp index 2a45779a4f6..0b7d05a8d15 100644 --- a/tools/gccas/gccas.cpp +++ b/tools/gccas/gccas.cpp @@ -192,7 +192,7 @@ int main(int argc, char **argv) { PassManager Passes; // Add an appropriate TargetData instance for this module... - Passes.add(new TargetData("gccas", M.get())); + Passes.add(new TargetData(M.get())); // Add all of the transformation passes to the pass manager to do the cleanup // and optimization of the GCC output. diff --git a/tools/gccld/GenerateCode.cpp b/tools/gccld/GenerateCode.cpp index 967fbf0b803..fc674f7088d 100644 --- a/tools/gccld/GenerateCode.cpp +++ b/tools/gccld/GenerateCode.cpp @@ -207,7 +207,7 @@ int llvm::GenerateBytecode(Module *M, int StripLevel, bool Internalize, if (Verify) Passes.add(createVerifierPass()); // Add an appropriate TargetData instance for this module... - addPass(Passes, new TargetData("gccld", M)); + addPass(Passes, new TargetData(M)); // Often if the programmer does not specify proper prototypes for the // functions they are calling, they end up calling a vararg version of the diff --git a/tools/llvm-extract/llvm-extract.cpp b/tools/llvm-extract/llvm-extract.cpp index e1088d2b2d5..c675e47c03a 100644 --- a/tools/llvm-extract/llvm-extract.cpp +++ b/tools/llvm-extract/llvm-extract.cpp @@ -66,7 +66,7 @@ int main(int argc, char **argv) { // In addition to deleting all other functions, we also want to spiff it // up a little bit. Do this now. PassManager Passes; - Passes.add(new TargetData("extract", M.get())); // Use correct TargetData + Passes.add(new TargetData(M.get())); // Use correct TargetData // Either isolate the function or delete it from the Module Passes.add(createFunctionExtractionPass(F, DeleteFn)); Passes.add(createGlobalDCEPass()); // Delete unreachable globals diff --git a/tools/llvm-ld/Optimize.cpp b/tools/llvm-ld/Optimize.cpp index 592b6225868..b61e8ef7db4 100644 --- a/tools/llvm-ld/Optimize.cpp +++ b/tools/llvm-ld/Optimize.cpp @@ -102,7 +102,7 @@ void Optimize(Module* M) { Passes.add(createVerifierPass()); // Add an appropriate TargetData instance for this module... - addPass(Passes, new TargetData("gccld", M)); + addPass(Passes, new TargetData(M)); // Often if the programmer does not specify proper prototypes for the // functions they are calling, they end up calling a vararg version of the diff --git a/tools/opt/opt.cpp b/tools/opt/opt.cpp index 9fddd944384..096506ff392 100644 --- a/tools/opt/opt.cpp +++ b/tools/opt/opt.cpp @@ -134,7 +134,7 @@ int main(int argc, char **argv) { PassManager Passes; // Add an appropriate TargetData instance for this module... - Passes.add(new TargetData("opt", M.get())); + Passes.add(new TargetData(M.get())); // Create a new optimization pass for each one specified on the command line for (unsigned i = 0; i < OptimizationList.size(); ++i) {