Lines Matching full:init
211 void Init::anchor() { } in anchor()
212 LLVM_DUMP_METHOD void Init::dump() const { return print(errs()); } in dump()
219 Init *UnsetInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
221 SmallVector<Init *, 16> NewBits(BRT->getNumBits()); in convertInitializerTo()
240 Init *BitInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
257 ProfileBitsInit(FoldingSetNodeID &ID, ArrayRef<Init *> Range) { in ProfileBitsInit()
260 for (Init *I : Range) in ProfileBitsInit()
264 BitsInit *BitsInit::get(ArrayRef<Init *> Range) { in get()
275 void *Mem = ::operator new (totalSizeToAlloc<Init *>(Range.size())); in get()
278 I->getTrailingObjects<Init *>()); in get()
285 ProfileBitsInit(ID, makeArrayRef(getTrailingObjects<Init *>(), NumBits)); in Profile()
288 Init *BitsInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
314 Init *
316 SmallVector<Init *, 16> NewBits(Bits.size()); in convertInitializerBitRange()
330 if (Init *Bit = getBit(e-i-1)) in getAsString()
341 static Init *fixBitInit(const RecordVal *RV, Init *Before, Init *After) { in fixBitInit()
350 Init *BitsInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
352 SmallVector<Init *, 16> NewBits(getNumBits()); in resolveReferences()
354 Init *CachedInit = nullptr; in resolveReferences()
355 Init *CachedBitVar = nullptr; in resolveReferences()
359 Init *CurBit = getBit(i); in resolveReferences()
360 Init *CurBitVar = CurBit->getBitVar(); in resolveReferences()
366 Init *Bit = CachedInit->getBit(CurBit->getBitNum()); in resolveReferences()
374 Init *B; in resolveReferences()
384 Init *Bit = CurBitVar->getBit(CurBit->getBitNum()); in resolveReferences()
413 Init *IntInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
429 SmallVector<Init *, 16> NewBits(BRT->getNumBits()); in convertInitializerTo()
439 Init *
441 SmallVector<Init *, 16> NewBits(Bits.size()); in convertInitializerBitRange()
468 Init *StringInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
475 Init *CodeInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
483 ArrayRef<Init *> Range, in ProfileListInit()
488 for (Init *I : Range) in ProfileListInit()
492 ListInit *ListInit::get(ArrayRef<Init *> Range, RecTy *EltTy) { in get()
503 void *Mem = ::operator new (totalSizeToAlloc<Init *>(Range.size())); in get()
506 I->getTrailingObjects<Init *>()); in get()
518 Init *ListInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
520 std::vector<Init*> Elements; in convertInitializerTo()
524 for (Init *I : getValues()) in convertInitializerTo()
525 if (Init *CI = I->convertInitializerTo(LRT->getElementType())) in convertInitializerTo()
537 Init *
539 std::vector<Init*> Vals; in convertInitListSlice()
556 Init *ListInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
557 std::vector<Init*> Resolved; in resolveReferences()
561 for (Init *CurElt : getValues()) { in resolveReferences()
562 Init *E; in resolveReferences()
577 Init *ListInit::resolveListElementReference(Record &R, const RecordVal *IRV, in resolveListElementReference()
581 Init *E = getElement(Elt); in resolveListElementReference()
599 Init *OpInit::resolveListElementReference(Record &R, const RecordVal *IRV, in resolveListElementReference()
601 Init *Resolved = resolveReferences(R, IRV); in resolveListElementReference()
609 if (Init *New = Typed->resolveListElementReference(R, IRV, Elt)) in resolveListElementReference()
617 Init *OpInit::getBit(unsigned Bit) const { in getBit()
624 ProfileUnOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *Op, RecTy *Type) { in ProfileUnOpInit()
630 UnOpInit *UnOpInit::get(UnaryOp Opc, Init *LHS, RecTy *Type) { in get()
651 Init *UnOpInit::Fold(Record *CurRec, MultiClass *CurMultiClass) const { in Fold()
675 Init *TemplateArgName = QualifyName(*CurRec, CurMultiClass, Name, in Fold()
690 Init *MCName = QualifyName(CurMultiClass->Rec, CurMultiClass, Name, in Fold()
713 if (Init *NewInit = BI->convertInitializerTo(IntRecTy::get())) in Fold()
749 Init *UnOpInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
750 Init *lhs = LHS->resolveReferences(R, RV); in resolveReferences()
769 ProfileBinOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *LHS, Init *RHS, in ProfileBinOpInit()
777 BinOpInit *BinOpInit::get(BinaryOp Opc, Init *LHS, in get()
778 Init *RHS, RecTy *Type) { in get()
799 Init *BinOpInit::Fold(Record *CurRec, MultiClass *CurMultiClass) const { in Fold()
809 std::vector<Init*> Args; in Fold()
827 std::vector<Init *> Args; in Fold()
890 Init *BinOpInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
891 Init *lhs = LHS->resolveReferences(R, RV); in resolveReferences()
892 Init *rhs = RHS->resolveReferences(R, RV); in resolveReferences()
916 ProfileTernOpInit(FoldingSetNodeID &ID, unsigned Opcode, Init *LHS, Init *MHS, in ProfileTernOpInit()
917 Init *RHS, RecTy *Type) { in ProfileTernOpInit()
925 TernOpInit *TernOpInit::get(TernaryOp Opc, Init *LHS, Init *MHS, Init *RHS, in get()
947 static Init *ForeachHelper(Init *LHS, Init *MHS, Init *RHS, RecTy *Type,
950 static Init *EvaluateOperation(OpInit *RHSo, Init *LHS, Init *Arg, in EvaluateOperation()
958 std::vector<Init *> NewOperands; in EvaluateOperation()
961 if (Init *Result = EvaluateOperation(RHSoo, LHS, Arg, in EvaluateOperation()
975 Init *NewVal = NewOp->Fold(CurRec, CurMultiClass); in EvaluateOperation()
979 static Init *ForeachHelper(Init *LHS, Init *MHS, Init *RHS, RecTy *Type, in ForeachHelper()
994 Init *Val = MHSd->getOperator(); in ForeachHelper()
995 if (Init *Result = EvaluateOperation(RHSo, LHS, Val, in ForeachHelper()
999 std::vector<std::pair<Init *, std::string> > args; in ForeachHelper()
1001 Init *Arg = MHSd->getArg(i); in ForeachHelper()
1005 if (Init *Result = EvaluateOperation(RHSo, LHS, Arg, Type, in ForeachHelper()
1018 std::vector<Init *> NewOperands; in ForeachHelper()
1019 std::vector<Init *> NewList(MHSl->begin(), MHSl->end()); in ForeachHelper()
1021 for (Init *&Item : NewList) { in ForeachHelper()
1033 Init *NewItem = NewOp->Fold(CurRec, CurMultiClass); in ForeachHelper()
1042 Init *TernOpInit::Fold(Record *CurRec, MultiClass *CurMultiClass) const { in Fold()
1088 if (Init *Result = ForeachHelper(LHS, MHS, RHS, getType(), in Fold()
1096 if (Init *I = LHS->convertInitializerTo(IntRecTy::get())) in Fold()
1110 Init *TernOpInit::resolveReferences(Record &R, in resolveReferences()
1112 Init *lhs = LHS->resolveReferences(R, RV); in resolveReferences()
1116 if (Init *I = lhs->convertInitializerTo(IntRecTy::get())) in resolveReferences()
1121 Init *mhs = MHS->resolveReferences(R, RV); in resolveReferences()
1125 Init *rhs = RHS->resolveReferences(R, RV); in resolveReferences()
1131 Init *mhs = MHS->resolveReferences(R, RV); in resolveReferences()
1132 Init *rhs = RHS->resolveReferences(R, RV); in resolveReferences()
1158 Init *
1205 SmallVector<Init *, 16> NewBits(BRT->getNumBits()); in convertInitializerTo()
1240 Init *
1246 SmallVector<Init *, 16> NewBits(Bits.size()); in convertInitializerBitRange()
1256 Init *
1264 std::vector<Init*> ListInits; in convertInitListSlice()
1274 Init *Value = StringInit::get(VN); in get()
1278 VarInit *VarInit::get(Init *VN, RecTy *T) { in get()
1279 typedef std::pair<RecTy *, Init *> Key; in get()
1294 Init *VarInit::getBit(unsigned Bit) const { in getBit()
1300 Init *VarInit::resolveListElementReference(Record &R, in resolveListElementReference()
1314 Init *E = LI->getElement(Elt); in resolveListElementReference()
1331 Init *VarInit::getFieldInit(Record &R, const RecordVal *RV, in getFieldInit()
1337 Init *TheInit = Val->getValue(); in getFieldInit()
1339 if (Init *I = TheInit->getFieldInit(R, RV, FieldName)) in getFieldInit()
1346 Init *VarInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
1364 Init *VarBitInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
1375 Init *VarBitInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
1376 Init *I = TI->resolveReferences(R, RV); in resolveReferences()
1399 Init *
1401 if (Init *I = getVariable()->resolveListElementReference(R, RV, in resolveReferences()
1407 Init *VarListElementInit::getBit(unsigned Bit) const { in getBit()
1413 Init *VarListElementInit:: resolveListElementReference(Record &R, in resolveListElementReference()
1416 if (Init *Result = TI->resolveListElementReference(R, RV, Element)) { in resolveListElementReference()
1418 if (Init *Result2 = TInit->resolveListElementReference(R, RV, Elt)) in resolveListElementReference()
1432 Init *DefInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
1445 Init *DefInit::getFieldInit(Record &R, const RecordVal *RV, in getFieldInit()
1455 FieldInit *FieldInit::get(Init *R, const std::string &FN) { in get()
1456 typedef std::pair<Init *, TableGenStringKey> Key; in get()
1466 Init *FieldInit::getBit(unsigned Bit) const { in getBit()
1472 Init *FieldInit::resolveListElementReference(Record &R, const RecordVal *RV, in resolveListElementReference()
1474 if (Init *ListVal = Rec->getFieldInit(R, RV, FieldName)) in resolveListElementReference()
1477 Init *E = LI->getElement(Elt); in resolveListElementReference()
1488 Init *FieldInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
1489 Init *NewRec = RV ? Rec->resolveReferences(R, RV) : Rec; in resolveReferences()
1491 if (Init *BitsVal = NewRec->getFieldInit(R, RV, FieldName)) { in resolveReferences()
1492 Init *BVR = BitsVal->resolveReferences(R, RV); in resolveReferences()
1501 static void ProfileDagInit(FoldingSetNodeID &ID, Init *V, const std::string &VN, in ProfileDagInit()
1502 ArrayRef<Init *> ArgRange, in ProfileDagInit()
1507 ArrayRef<Init *>::iterator Arg = ArgRange.begin(); in ProfileDagInit()
1518 DagInit::get(Init *V, const std::string &VN, in get()
1519 ArrayRef<Init *> ArgRange, in get()
1538 DagInit::get(Init *V, const std::string &VN, in get()
1539 const std::vector<std::pair<Init*, std::string> > &args) { in get() argument
1540 std::vector<Init *> Args; in get()
1555 Init *DagInit::convertInitializerTo(RecTy *Ty) const { in convertInitializerTo()
1562 Init *DagInit::resolveReferences(Record &R, const RecordVal *RV) const { in resolveReferences()
1563 std::vector<Init*> NewArgs; in resolveReferences()
1567 Init *Op = Val->resolveReferences(R, RV); in resolveReferences()
1596 RecordVal::RecordVal(Init *N, RecTy *T, bool P) in RecordVal()
1626 void Record::init() { in init() function in Record
1652 void Record::setName(Init *NewName) { in setName()
1663 // record name be an Init is to provide this flexibility. The extra in setName()
1676 if (Init *V = Values[i].getValue()) in resolveReferencesTo()
1686 Init *OldName = getNameInit(); in resolveReferencesTo()
1687 Init *NewName = Name->resolveReferences(*this, RV); in resolveReferencesTo()
1699 ArrayRef<Init *> TArgs = R.getTemplateArgs(); in operator <<()
1703 for (const Init *TA : TArgs) { in operator <<()
1732 Init *Record::getValueInit(StringRef FieldName) const { in getValueInit()
1784 for (Init *I : List->getValues()) { in getValueAsListOfDefs()
1810 for (Init *I : List->getValues()) { in getValueAsListOfInts()
1824 for (Init *I : List->getValues()) { in getValueAsListOfStrings()
1925 Init *llvm::QualifyName(Record &CurRec, MultiClass *CurMultiClass, in QualifyName()
1926 Init *Name, const std::string &Scoper) { in QualifyName()
1952 Init *llvm::QualifyName(Record &CurRec, MultiClass *CurMultiClass, in QualifyName()