diff options
Diffstat (limited to 'llvm/tools/llvm-exegesis')
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/Analysis.cpp | 2 | ||||
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/Assembler.cpp | 14 | ||||
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/BenchmarkRunner.cpp | 2 | ||||
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/BenchmarkRunner.h | 2 | ||||
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/Target.cpp | 8 | ||||
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/X86/Target.cpp | 4 |
6 files changed, 16 insertions, 16 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/Analysis.cpp b/llvm/tools/llvm-exegesis/lib/Analysis.cpp index 53b2005d0db..eb8320e06bb 100644 --- a/llvm/tools/llvm-exegesis/lib/Analysis.cpp +++ b/llvm/tools/llvm-exegesis/lib/Analysis.cpp @@ -178,7 +178,7 @@ Analysis::Analysis(const llvm::Target &Target, llvm::Triple(FirstPoint.LLVMTriple), 0 /*default variant*/, *AsmInfo_, *InstrInfo_, *RegInfo_)); - Context_ = llvm::make_unique<llvm::MCContext>(AsmInfo_.get(), RegInfo_.get(), + Context_ = std::make_unique<llvm::MCContext>(AsmInfo_.get(), RegInfo_.get(), &ObjectFileInfo_); Disasm_.reset(Target.createMCDisassembler(*SubtargetInfo_, *Context_)); assert(Disasm_ && "cannot create MCDisassembler. missing call to " diff --git a/llvm/tools/llvm-exegesis/lib/Assembler.cpp b/llvm/tools/llvm-exegesis/lib/Assembler.cpp index 437fe892603..9695c79b57a 100644 --- a/llvm/tools/llvm-exegesis/lib/Assembler.cpp +++ b/llvm/tools/llvm-exegesis/lib/Assembler.cpp @@ -131,20 +131,20 @@ static void fillMachineFunction(llvm::MachineFunction &MF, static std::unique_ptr<llvm::Module> createModule(const std::unique_ptr<llvm::LLVMContext> &Context, const llvm::DataLayout DL) { - auto Module = llvm::make_unique<llvm::Module>(ModuleID, *Context); + auto Module = std::make_unique<llvm::Module>(ModuleID, *Context); Module->setDataLayout(DL); return Module; } llvm::BitVector getFunctionReservedRegs(const llvm::TargetMachine &TM) { std::unique_ptr<llvm::LLVMContext> Context = - llvm::make_unique<llvm::LLVMContext>(); + std::make_unique<llvm::LLVMContext>(); std::unique_ptr<llvm::Module> Module = createModule(Context, TM.createDataLayout()); // TODO: This only works for targets implementing LLVMTargetMachine. const LLVMTargetMachine &LLVMTM = static_cast<const LLVMTargetMachine&>(TM); std::unique_ptr<llvm::MachineModuleInfo> MMI = - llvm::make_unique<llvm::MachineModuleInfo>(&LLVMTM); + std::make_unique<llvm::MachineModuleInfo>(&LLVMTM); llvm::MachineFunction &MF = createVoidVoidPtrMachineFunction(FunctionID, Module.get(), MMI.get()); // Saving reserved registers for client. @@ -158,11 +158,11 @@ void assembleToStream(const ExegesisTarget &ET, llvm::ArrayRef<llvm::MCInst> Instructions, llvm::raw_pwrite_stream &AsmStream) { std::unique_ptr<llvm::LLVMContext> Context = - llvm::make_unique<llvm::LLVMContext>(); + std::make_unique<llvm::LLVMContext>(); std::unique_ptr<llvm::Module> Module = createModule(Context, TM->createDataLayout()); std::unique_ptr<llvm::MachineModuleInfo> MMI = - llvm::make_unique<llvm::MachineModuleInfo>(TM.get()); + std::make_unique<llvm::MachineModuleInfo>(TM.get()); llvm::MachineFunction &MF = createVoidVoidPtrMachineFunction(FunctionID, Module.get(), MMI.get()); @@ -268,7 +268,7 @@ private: ExecutableFunction::ExecutableFunction( std::unique_ptr<llvm::LLVMTargetMachine> TM, llvm::object::OwningBinary<llvm::object::ObjectFile> &&ObjectFileHolder) - : Context(llvm::make_unique<llvm::LLVMContext>()) { + : Context(std::make_unique<llvm::LLVMContext>()) { assert(ObjectFileHolder.getBinary() && "cannot create object file"); // Initializing the execution engine. // We need to use the JIT EngineKind to be able to add an object file. @@ -281,7 +281,7 @@ ExecutableFunction::ExecutableFunction( .setMCPU(TM->getTargetCPU()) .setEngineKind(llvm::EngineKind::JIT) .setMCJITMemoryManager( - llvm::make_unique<TrackingSectionMemoryManager>(&CodeSize)) + std::make_unique<TrackingSectionMemoryManager>(&CodeSize)) .create(TM.release())); if (!ExecEngine) llvm::report_fatal_error(Error); diff --git a/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.cpp b/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.cpp index 1f0ca6f8bf5..38abf3eefa3 100644 --- a/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.cpp +++ b/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.cpp @@ -29,7 +29,7 @@ BenchmarkFailure::BenchmarkFailure(const llvm::Twine &S) BenchmarkRunner::BenchmarkRunner(const LLVMState &State, InstructionBenchmark::ModeE Mode) - : State(State), Mode(Mode), Scratch(llvm::make_unique<ScratchSpace>()) {} + : State(State), Mode(Mode), Scratch(std::make_unique<ScratchSpace>()) {} BenchmarkRunner::~BenchmarkRunner() = default; diff --git a/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.h b/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.h index 395c0f8e32d..29e98619301 100644 --- a/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.h +++ b/llvm/tools/llvm-exegesis/lib/BenchmarkRunner.h @@ -53,7 +53,7 @@ public: static constexpr const size_t kAlignment = 1024; static constexpr const size_t kSize = 1 << 20; // 1MB. ScratchSpace() - : UnalignedPtr(llvm::make_unique<char[]>(kSize + kAlignment)), + : UnalignedPtr(std::make_unique<char[]>(kSize + kAlignment)), AlignedPtr( UnalignedPtr.get() + kAlignment - (reinterpret_cast<intptr_t>(UnalignedPtr.get()) % kAlignment)) {} diff --git a/llvm/tools/llvm-exegesis/lib/Target.cpp b/llvm/tools/llvm-exegesis/lib/Target.cpp index 945aabb8a3f..a5ba24c20f2 100644 --- a/llvm/tools/llvm-exegesis/lib/Target.cpp +++ b/llvm/tools/llvm-exegesis/lib/Target.cpp @@ -68,22 +68,22 @@ ExegesisTarget::createBenchmarkRunner(InstructionBenchmark::ModeE Mode, std::unique_ptr<SnippetGenerator> ExegesisTarget::createLatencySnippetGenerator(const LLVMState &State) const { - return llvm::make_unique<LatencySnippetGenerator>(State); + return std::make_unique<LatencySnippetGenerator>(State); } std::unique_ptr<SnippetGenerator> ExegesisTarget::createUopsSnippetGenerator(const LLVMState &State) const { - return llvm::make_unique<UopsSnippetGenerator>(State); + return std::make_unique<UopsSnippetGenerator>(State); } std::unique_ptr<BenchmarkRunner> ExegesisTarget::createLatencyBenchmarkRunner( const LLVMState &State, InstructionBenchmark::ModeE Mode) const { - return llvm::make_unique<LatencyBenchmarkRunner>(State, Mode); + return std::make_unique<LatencyBenchmarkRunner>(State, Mode); } std::unique_ptr<BenchmarkRunner> ExegesisTarget::createUopsBenchmarkRunner(const LLVMState &State) const { - return llvm::make_unique<UopsBenchmarkRunner>(State); + return std::make_unique<UopsBenchmarkRunner>(State); } void ExegesisTarget::randomizeMCOperand( diff --git a/llvm/tools/llvm-exegesis/lib/X86/Target.cpp b/llvm/tools/llvm-exegesis/lib/X86/Target.cpp index 21d424a4bee..cebcb1c1aea 100644 --- a/llvm/tools/llvm-exegesis/lib/X86/Target.cpp +++ b/llvm/tools/llvm-exegesis/lib/X86/Target.cpp @@ -453,12 +453,12 @@ private: std::unique_ptr<SnippetGenerator> createLatencySnippetGenerator(const LLVMState &State) const override { - return llvm::make_unique<X86LatencySnippetGenerator>(State); + return std::make_unique<X86LatencySnippetGenerator>(State); } std::unique_ptr<SnippetGenerator> createUopsSnippetGenerator(const LLVMState &State) const override { - return llvm::make_unique<X86UopsSnippetGenerator>(State); + return std::make_unique<X86UopsSnippetGenerator>(State); } bool matchesArch(llvm::Triple::ArchType Arch) const override { |