diff options
| author | Clement Courbet <courbet@google.com> | 2018-11-19 14:31:43 +0000 |
|---|---|---|
| committer | Clement Courbet <courbet@google.com> | 2018-11-19 14:31:43 +0000 |
| commit | bbab546a7195350ca58a189247d6baf6ab5fb81a (patch) | |
| tree | e60e881a4459024c75a3ac26a1dc4bcba02ab255 /llvm/tools/llvm-exegesis/lib/LlvmState.cpp | |
| parent | fef3036d3721a9a6a234c54786e3b8bf3d2d0f93 (diff) | |
| download | bcm5719-llvm-bbab546a7195350ca58a189247d6baf6ab5fb81a.tar.gz bcm5719-llvm-bbab546a7195350ca58a189247d6baf6ab5fb81a.zip | |
[llvm-exegesis][NFC] More tests for ExegesisTarget::fillMemoryOperands().
Reviewers: gchatelet
Subscribers: tschuett, llvm-commits
Differential Revision: https://reviews.llvm.org/D54304
llvm-svn: 347209
Diffstat (limited to 'llvm/tools/llvm-exegesis/lib/LlvmState.cpp')
| -rw-r--r-- | llvm/tools/llvm-exegesis/lib/LlvmState.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/LlvmState.cpp b/llvm/tools/llvm-exegesis/lib/LlvmState.cpp index b5580c83cf5..cc01f1fa4ca 100644 --- a/llvm/tools/llvm-exegesis/lib/LlvmState.cpp +++ b/llvm/tools/llvm-exegesis/lib/LlvmState.cpp @@ -22,15 +22,16 @@ namespace llvm { namespace exegesis { -LLVMState::LLVMState(const std::string &Triple, const std::string &CpuName) { +LLVMState::LLVMState(const std::string &Triple, const std::string &CpuName, + const std::string &Features) { std::string Error; const llvm::Target *const TheTarget = llvm::TargetRegistry::lookupTarget(Triple, Error); assert(TheTarget && "unknown target for host"); const llvm::TargetOptions Options; - TargetMachine.reset(static_cast<llvm::LLVMTargetMachine *>( - TheTarget->createTargetMachine(Triple, CpuName, /*Features*/ "", Options, - llvm::Reloc::Model::Static))); + TargetMachine.reset( + static_cast<llvm::LLVMTargetMachine *>(TheTarget->createTargetMachine( + Triple, CpuName, Features, Options, llvm::Reloc::Model::Static))); TheExegesisTarget = ExegesisTarget::lookup(TargetMachine->getTargetTriple()); if (!TheExegesisTarget) { llvm::errs() << "no exegesis target for " << Triple << ", using default\n"; @@ -45,8 +46,8 @@ LLVMState::LLVMState(const std::string &Triple, const std::string &CpuName) { LLVMState::LLVMState(const std::string &CpuName) : LLVMState(llvm::sys::getProcessTriple(), - CpuName.empty() ? llvm::sys::getHostCPUName().str() : CpuName) { -} + CpuName.empty() ? llvm::sys::getHostCPUName().str() : CpuName, + "") {} std::unique_ptr<llvm::LLVMTargetMachine> LLVMState::createTargetMachine() const { |

