diff options
author | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-15 15:54:37 +0000 |
---|---|---|
committer | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-15 15:54:37 +0000 |
commit | 0eaee545eef49ff9498234d3a51a5cbde59bf976 (patch) | |
tree | fd7691e102022fb97622c5485fa8c4f506fc124e /llvm/tools/llvm-mca/llvm-mca.cpp | |
parent | 1c34d10776828c0756ff4f0b2b9aa8bda2be348a (diff) | |
download | bcm5719-llvm-0eaee545eef49ff9498234d3a51a5cbde59bf976.tar.gz bcm5719-llvm-0eaee545eef49ff9498234d3a51a5cbde59bf976.zip |
[llvm] Migrate llvm::make_unique to std::make_unique
Now that we've moved to C++14, we no longer need the llvm::make_unique
implementation from STLExtras.h. This patch is a mechanical replacement
of (hopefully) all the llvm::make_unique instances across the monorepo.
llvm-svn: 369013
Diffstat (limited to 'llvm/tools/llvm-mca/llvm-mca.cpp')
-rw-r--r-- | llvm/tools/llvm-mca/llvm-mca.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/llvm/tools/llvm-mca/llvm-mca.cpp b/llvm/tools/llvm-mca/llvm-mca.cpp index 1bcf850193e..dde42c11730 100644 --- a/llvm/tools/llvm-mca/llvm-mca.cpp +++ b/llvm/tools/llvm-mca/llvm-mca.cpp @@ -233,7 +233,7 @@ ErrorOr<std::unique_ptr<ToolOutputFile>> getOutputStream() { OutputFilename = "-"; std::error_code EC; auto Out = - llvm::make_unique<ToolOutputFile>(OutputFilename, EC, sys::fs::OF_None); + std::make_unique<ToolOutputFile>(OutputFilename, EC, sys::fs::OF_None); if (!EC) return std::move(Out); return EC; @@ -485,18 +485,18 @@ int main(int argc, char **argv) { if (PrintInstructionTables) { // Create a pipeline, stages, and a printer. - auto P = llvm::make_unique<mca::Pipeline>(); - P->appendStage(llvm::make_unique<mca::EntryStage>(S)); - P->appendStage(llvm::make_unique<mca::InstructionTables>(SM)); + auto P = std::make_unique<mca::Pipeline>(); + P->appendStage(std::make_unique<mca::EntryStage>(S)); + P->appendStage(std::make_unique<mca::InstructionTables>(SM)); mca::PipelinePrinter Printer(*P); // Create the views for this pipeline, execute, and emit a report. if (PrintInstructionInfoView) { - Printer.addView(llvm::make_unique<mca::InstructionInfoView>( + Printer.addView(std::make_unique<mca::InstructionInfoView>( *STI, *MCII, CE, ShowEncoding, Insts, *IP)); } Printer.addView( - llvm::make_unique<mca::ResourcePressureView>(*STI, *IP, Insts)); + std::make_unique<mca::ResourcePressureView>(*STI, *IP, Insts)); if (!runPipeline(*P)) return 1; @@ -511,37 +511,37 @@ int main(int argc, char **argv) { if (PrintSummaryView) Printer.addView( - llvm::make_unique<mca::SummaryView>(SM, Insts, DispatchWidth)); + std::make_unique<mca::SummaryView>(SM, Insts, DispatchWidth)); if (EnableBottleneckAnalysis) { - Printer.addView(llvm::make_unique<mca::BottleneckAnalysis>( + Printer.addView(std::make_unique<mca::BottleneckAnalysis>( *STI, *IP, Insts, S.getNumIterations())); } if (PrintInstructionInfoView) - Printer.addView(llvm::make_unique<mca::InstructionInfoView>( + Printer.addView(std::make_unique<mca::InstructionInfoView>( *STI, *MCII, CE, ShowEncoding, Insts, *IP)); if (PrintDispatchStats) - Printer.addView(llvm::make_unique<mca::DispatchStatistics>()); + Printer.addView(std::make_unique<mca::DispatchStatistics>()); if (PrintSchedulerStats) - Printer.addView(llvm::make_unique<mca::SchedulerStatistics>(*STI)); + Printer.addView(std::make_unique<mca::SchedulerStatistics>(*STI)); if (PrintRetireStats) - Printer.addView(llvm::make_unique<mca::RetireControlUnitStatistics>(SM)); + Printer.addView(std::make_unique<mca::RetireControlUnitStatistics>(SM)); if (PrintRegisterFileStats) - Printer.addView(llvm::make_unique<mca::RegisterFileStatistics>(*STI)); + Printer.addView(std::make_unique<mca::RegisterFileStatistics>(*STI)); if (PrintResourcePressureView) Printer.addView( - llvm::make_unique<mca::ResourcePressureView>(*STI, *IP, Insts)); + std::make_unique<mca::ResourcePressureView>(*STI, *IP, Insts)); if (PrintTimelineView) { unsigned TimelineIterations = TimelineMaxIterations ? TimelineMaxIterations : 10; - Printer.addView(llvm::make_unique<mca::TimelineView>( + Printer.addView(std::make_unique<mca::TimelineView>( *STI, *IP, Insts, std::min(TimelineIterations, S.getNumIterations()), TimelineMaxCycles)); } |