diff options
Diffstat (limited to 'llvm/lib/TableGen')
-rw-r--r-- | llvm/lib/TableGen/Record.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/TableGen/SetTheory.cpp | 22 | ||||
-rw-r--r-- | llvm/lib/TableGen/TGLexer.cpp | 4 | ||||
-rw-r--r-- | llvm/lib/TableGen/TGParser.cpp | 18 |
4 files changed, 23 insertions, 23 deletions
diff --git a/llvm/lib/TableGen/Record.cpp b/llvm/lib/TableGen/Record.cpp index 27d1bdc7f4c..e4ab39df087 100644 --- a/llvm/lib/TableGen/Record.cpp +++ b/llvm/lib/TableGen/Record.cpp @@ -1616,7 +1616,7 @@ void VarDefInit::Profile(FoldingSetNodeID &ID) const { DefInit *VarDefInit::instantiate() { if (!Def) { RecordKeeper &Records = Class->getRecords(); - auto NewRecOwner = make_unique<Record>(Records.getNewAnonymousName(), + auto NewRecOwner = std::make_unique<Record>(Records.getNewAnonymousName(), Class->getLoc(), Records, /*IsAnonymous=*/true); Record *NewRec = NewRecOwner.get(); diff --git a/llvm/lib/TableGen/SetTheory.cpp b/llvm/lib/TableGen/SetTheory.cpp index a870e41d58f..5a30ee98cce 100644 --- a/llvm/lib/TableGen/SetTheory.cpp +++ b/llvm/lib/TableGen/SetTheory.cpp @@ -255,16 +255,16 @@ void SetTheory::Operator::anchor() {} void SetTheory::Expander::anchor() {} SetTheory::SetTheory() { - addOperator("add", llvm::make_unique<AddOp>()); - addOperator("sub", llvm::make_unique<SubOp>()); - addOperator("and", llvm::make_unique<AndOp>()); - addOperator("shl", llvm::make_unique<ShlOp>()); - addOperator("trunc", llvm::make_unique<TruncOp>()); - addOperator("rotl", llvm::make_unique<RotOp>(false)); - addOperator("rotr", llvm::make_unique<RotOp>(true)); - addOperator("decimate", llvm::make_unique<DecimateOp>()); - addOperator("interleave", llvm::make_unique<InterleaveOp>()); - addOperator("sequence", llvm::make_unique<SequenceOp>()); + addOperator("add", std::make_unique<AddOp>()); + addOperator("sub", std::make_unique<SubOp>()); + addOperator("and", std::make_unique<AndOp>()); + addOperator("shl", std::make_unique<ShlOp>()); + addOperator("trunc", std::make_unique<TruncOp>()); + addOperator("rotl", std::make_unique<RotOp>(false)); + addOperator("rotr", std::make_unique<RotOp>(true)); + addOperator("decimate", std::make_unique<DecimateOp>()); + addOperator("interleave", std::make_unique<InterleaveOp>()); + addOperator("sequence", std::make_unique<SequenceOp>()); } void SetTheory::addOperator(StringRef Name, std::unique_ptr<Operator> Op) { @@ -276,7 +276,7 @@ void SetTheory::addExpander(StringRef ClassName, std::unique_ptr<Expander> E) { } void SetTheory::addFieldExpander(StringRef ClassName, StringRef FieldName) { - addExpander(ClassName, llvm::make_unique<FieldExpander>(FieldName)); + addExpander(ClassName, std::make_unique<FieldExpander>(FieldName)); } void SetTheory::evaluate(Init *Expr, RecSet &Elts, ArrayRef<SMLoc> Loc) { diff --git a/llvm/lib/TableGen/TGLexer.cpp b/llvm/lib/TableGen/TGLexer.cpp index d28c62b3133..da2286e41fe 100644 --- a/llvm/lib/TableGen/TGLexer.cpp +++ b/llvm/lib/TableGen/TGLexer.cpp @@ -51,7 +51,7 @@ TGLexer::TGLexer(SourceMgr &SM, ArrayRef<std::string> Macros) : SrcMgr(SM) { // Pretend that we enter the "top-level" include file. PrepIncludeStack.push_back( - make_unique<std::vector<PreprocessorControlDesc>>()); + std::make_unique<std::vector<PreprocessorControlDesc>>()); // Put all macros defined in the command line into the DefinedMacros set. std::for_each(Macros.begin(), Macros.end(), @@ -393,7 +393,7 @@ bool TGLexer::LexInclude() { CurPtr = CurBuf.begin(); PrepIncludeStack.push_back( - make_unique<std::vector<PreprocessorControlDesc>>()); + std::make_unique<std::vector<PreprocessorControlDesc>>()); return false; } diff --git a/llvm/lib/TableGen/TGParser.cpp b/llvm/lib/TableGen/TGParser.cpp index a9ace152d59..a076966aff0 100644 --- a/llvm/lib/TableGen/TGParser.cpp +++ b/llvm/lib/TableGen/TGParser.cpp @@ -378,7 +378,7 @@ bool TGParser::resolve(const ForeachLoop &Loop, SubstStack &Substs, auto LI = dyn_cast<ListInit>(List); if (!LI) { if (!Final) { - Dest->emplace_back(make_unique<ForeachLoop>(Loop.Loc, Loop.IterVar, + Dest->emplace_back(std::make_unique<ForeachLoop>(Loop.Loc, Loop.IterVar, List)); return resolve(Loop.Entries, Substs, Final, &Dest->back().Loop->Entries, Loc); @@ -413,7 +413,7 @@ bool TGParser::resolve(const std::vector<RecordsEntry> &Source, if (E.Loop) { Error = resolve(*E.Loop, Substs, Final, Dest); } else { - auto Rec = make_unique<Record>(*E.Rec); + auto Rec = std::make_unique<Record>(*E.Rec); if (Loc) Rec->appendLoc(*Loc); @@ -1330,7 +1330,7 @@ Init *TGParser::ParseOperation(Record *CurRec, RecTy *ItemType) { std::unique_ptr<Record> ParseRecTmp; Record *ParseRec = CurRec; if (!ParseRec) { - ParseRecTmp = make_unique<Record>(".parse", ArrayRef<SMLoc>{}, Records); + ParseRecTmp = std::make_unique<Record>(".parse", ArrayRef<SMLoc>{}, Records); ParseRec = ParseRecTmp.get(); } @@ -1597,7 +1597,7 @@ Init *TGParser::ParseOperation(Record *CurRec, RecTy *ItemType) { std::unique_ptr<Record> ParseRecTmp; Record *ParseRec = CurRec; if (!ParseRec) { - ParseRecTmp = make_unique<Record>(".parse", ArrayRef<SMLoc>{}, Records); + ParseRecTmp = std::make_unique<Record>(".parse", ArrayRef<SMLoc>{}, Records); ParseRec = ParseRecTmp.get(); } @@ -2702,10 +2702,10 @@ bool TGParser::ParseDef(MultiClass *CurMultiClass) { return true; if (isa<UnsetInit>(Name)) - CurRec = make_unique<Record>(Records.getNewAnonymousName(), DefLoc, Records, + CurRec = std::make_unique<Record>(Records.getNewAnonymousName(), DefLoc, Records, /*Anonymous=*/true); else - CurRec = make_unique<Record>(Name, DefLoc, Records); + CurRec = std::make_unique<Record>(Name, DefLoc, Records); if (ParseObjectBody(CurRec.get())) return true; @@ -2783,7 +2783,7 @@ bool TGParser::ParseForeach(MultiClass *CurMultiClass) { Lex.Lex(); // Eat the in // Create a loop object and remember it. - Loops.push_back(llvm::make_unique<ForeachLoop>(Loc, IterName, ListValue)); + Loops.push_back(std::make_unique<ForeachLoop>(Loc, IterName, ListValue)); if (Lex.getCode() != tgtok::l_brace) { // FOREACH Declaration IN Object @@ -2834,7 +2834,7 @@ bool TGParser::ParseClass() { } else { // If this is the first reference to this class, create and add it. auto NewRec = - llvm::make_unique<Record>(Lex.getCurStrVal(), Lex.getLoc(), Records, + std::make_unique<Record>(Lex.getCurStrVal(), Lex.getLoc(), Records, /*Class=*/true); CurRec = NewRec.get(); Records.addClass(std::move(NewRec)); @@ -2963,7 +2963,7 @@ bool TGParser::ParseMultiClass() { auto Result = MultiClasses.insert(std::make_pair(Name, - llvm::make_unique<MultiClass>(Name, Lex.getLoc(),Records))); + std::make_unique<MultiClass>(Name, Lex.getLoc(),Records))); if (!Result.second) return TokError("multiclass '" + Name + "' already defined"); |