aboutsummaryrefslogtreecommitdiffstats
path: root/tools/llc/llc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/llc/llc.cpp')
-rw-r--r--tools/llc/llc.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/llc/llc.cpp b/tools/llc/llc.cpp
index efa1422..55a45dc 100644
--- a/tools/llc/llc.cpp
+++ b/tools/llc/llc.cpp
@@ -14,6 +14,7 @@
//===----------------------------------------------------------------------===//
+#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/Triple.h"
#include "llvm/Analysis/TargetLibraryInfo.h"
#include "llvm/CodeGen/CommandFlags.h"
@@ -305,8 +306,7 @@ static int compileModule(char **argv, LLVMContext &Context) {
// Add the target data from the target machine, if it exists, or the module.
if (const DataLayout *DL = Target->getDataLayout())
- M->setDataLayout(DL);
- PM.add(new DataLayoutPass());
+ M->setDataLayout(*DL);
if (RelaxAll.getNumOccurrences() > 0 &&
FileType != TargetMachine::CGFT_ObjectFile)