diff options
Diffstat (limited to 'tools/llc')
-rw-r--r-- | tools/llc/CMakeLists.txt | 2 | ||||
-rw-r--r-- | tools/llc/llc.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tools/llc/CMakeLists.txt b/tools/llc/CMakeLists.txt index 484ff40..dcbcf9d 100644 --- a/tools/llc/CMakeLists.txt +++ b/tools/llc/CMakeLists.txt @@ -17,4 +17,4 @@ set(LLVM_NO_DEAD_STRIP 1) add_llvm_tool(llc llc.cpp ) -set_target_properties(llc PROPERTIES ENABLE_EXPORTS 1) +export_executable_symbols(llc) 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) |