summaryrefslogtreecommitdiffstats
path: root/llvm/tools/lto/LTOModule.cpp
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2011-12-02 22:16:29 +0000
committerNick Lewycky <nicholas@mxc.ca>2011-12-02 22:16:29 +0000
commit50f02cb21b62b6ac010d11601eff899e48777f87 (patch)
tree70ffe3f7f1ce17f244f7a2f3db2a7befbec53ba9 /llvm/tools/lto/LTOModule.cpp
parent7276397f41c1f8867cdbebf6a6b062809989faee (diff)
downloadbcm5719-llvm-50f02cb21b62b6ac010d11601eff899e48777f87.tar.gz
bcm5719-llvm-50f02cb21b62b6ac010d11601eff899e48777f87.zip
Move global variables in TargetMachine into new TargetOptions class. As an API
change, now you need a TargetOptions object to create a TargetMachine. Clang patch to follow. One small functionality change in PTX. PTX had commented out the machine verifier parts in their copy of printAndVerify. That now calls the version in LLVMTargetMachine. Users of PTX who need verification disabled should rely on not passing the command-line flag to enable it. llvm-svn: 145714
Diffstat (limited to 'llvm/tools/lto/LTOModule.cpp')
-rw-r--r--llvm/tools/lto/LTOModule.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/tools/lto/LTOModule.cpp b/llvm/tools/lto/LTOModule.cpp
index 8ea680d53c5..0b737293ae2 100644
--- a/llvm/tools/lto/LTOModule.cpp
+++ b/llvm/tools/lto/LTOModule.cpp
@@ -159,7 +159,9 @@ LTOModule *LTOModule::makeLTOModule(MemoryBuffer *buffer,
Features.getDefaultSubtargetFeatures(llvm::Triple(Triple));
std::string FeatureStr = Features.getString();
std::string CPU;
- TargetMachine *target = march->createTargetMachine(Triple, CPU, FeatureStr);
+ TargetOptions Options;
+ TargetMachine *target = march->createTargetMachine(Triple, CPU, FeatureStr,
+ Options);
LTOModule *Ret = new LTOModule(m.take(), target);
if (Ret->ParseSymbols(errMsg)) {
delete Ret;
OpenPOWER on IntegriCloud