Lines Matching refs:Name

48   std::string Name;  member
56 std::string Name; member
63 GenericField(StringRef Name) : Name(std::string(Name)) {} in GenericField()
67 std::string Name; member
75 std::string Name; member
85 const GenericField *getFieldByName(StringRef Name) const { in getFieldByName()
87 if (Name == Field.Name) in getFieldByName()
135 Twine("Entry for field '") + Field.Name + "' is null"); in primaryRepresentation()
138 PrintFatalError(Loc, Twine("invalid field type for field '") + Field.Name + in primaryRepresentation()
177 PrintFatalError(Index.Loc, Twine("In table '") + Table.Name + in searchableFieldType()
178 "' lookup method '" + Index.Name + in searchableFieldType()
179 "', key field '" + Field.Name + in searchableFieldType()
186 Twine("In table '") + Table.Name + "' lookup method '" + in searchableFieldType()
187 Index.Name + "', key field '" + Field.Name + in searchableFieldType()
201 parseSearchIndex(GenericTable &Table, const RecordVal *RecVal, StringRef Name,
223 Record *TheDef = Rec->getValueAsDef(Index.Fields[0].Name); in getNumericKey()
227 Record *EnumEntry = Rec->getValueAsDef(Index.Fields[0].Name); in getNumericKey()
231 return getInt(Rec, Index.Fields[0].Name); in getNumericKey()
239 Init *LHSI = LHS->getValueInit(Field.Name); in compareBy()
240 Init *RHSI = RHS->getValueInit(Field.Name); in compareBy()
252 if (std::tie(LHSi.TargetPrefix, LHSi.Name) < in compareBy()
253 std::tie(RHSi.TargetPrefix, RHSi.Name)) in compareBy()
255 if (std::tie(LHSi.TargetPrefix, LHSi.Name) > in compareBy()
256 std::tie(RHSi.TargetPrefix, RHSi.Name)) in compareBy()
313 OS << "enum " << Enum.Name << " {\n"; in emitGenericEnum()
336 IndexName = Table.Name; in emitLookupFunction()
343 << Field.Name << ";\n"; in emitLookupFunction()
368 Index.Loc, Field, Entry.first->getValueInit(Field.Name)); in emitLookupFunction()
401 Index.Loc, Field, IndexRows[0]->getValueInit(Field.Name)); in emitLookupFunction()
403 Index.Loc, Field, IndexRows.back()->getValueInit(Field.Name)); in emitLookupFunction()
404 OS << " if ((" << Field.Name << " < " << FirstRepr << ") ||\n"; in emitLookupFunction()
405 OS << " (" << Field.Name << " > " << LastRepr << "))\n"; in emitLookupFunction()
408 OS << " size_t Idx = " << Index.Fields[0].Name << " - " << FirstRepr in emitLookupFunction()
414 OS << "&" << Table.Name << "[Table[Idx]._index]"; in emitLookupFunction()
423 Index.Loc, Field, IndexRows[0]->getValueInit(Field.Name)); in emitLookupFunction()
425 Index.Loc, Field, IndexRows.back()->getValueInit(Field.Name)); in emitLookupFunction()
426 OS << " if ((" << Field.Name << " < " << FirstRepr << ") ||\n"; in emitLookupFunction()
427 OS << " (" << Field.Name << " > " << LastRepr << "))\n"; in emitLookupFunction()
434 << " " << Field.Name << ";\n"; in emitLookupFunction()
440 OS << LS << Field.Name; in emitLookupFunction()
445 Twine("In table '") + Table.Name + in emitLookupFunction()
448 Field.Name + "'"); in emitLookupFunction()
460 OS << " int Cmp" << Field.Name << " = StringRef(LHS." << Field.Name in emitLookupFunction()
461 << ").compare(RHS." << Field.Name << ");\n"; in emitLookupFunction()
462 OS << " if (Cmp" << Field.Name << " < 0) return true;\n"; in emitLookupFunction()
463 OS << " if (Cmp" << Field.Name << " > 0) return false;\n"; in emitLookupFunction()
467 OS << " if ((unsigned)LHS." << Field.Name << " < (unsigned)RHS." in emitLookupFunction()
468 << Field.Name << ")\n"; in emitLookupFunction()
470 OS << " if ((unsigned)LHS." << Field.Name << " > (unsigned)RHS." in emitLookupFunction()
471 << Field.Name << ")\n"; in emitLookupFunction()
474 OS << " if (LHS." << Field.Name << " < RHS." << Field.Name in emitLookupFunction()
477 OS << " if (LHS." << Field.Name << " > RHS." << Field.Name in emitLookupFunction()
504 OS << " ||\n Key." << Field.Name << " != Idx->" << Field.Name; in emitLookupFunction()
514 OS << " return &" << Table.Name << "[Idx->_index];\n"; in emitLookupFunction()
527 OS << Index.Name << "("; in emitLookupDeclaration()
531 << Field.Name; in emitLookupDeclaration()
554 OS << "constexpr " << Table.CppTypeName << " " << Table.Name << "[] = {\n"; in emitGenericTable()
563 Entry->getValueInit(Field.Name)); in emitGenericTable()
599 GenericTable &Table, const RecordVal *KeyRecVal, StringRef Name, in parseSearchIndex() argument
602 Index->Name = std::string(Name); in parseSearchIndex()
612 Twine("In table '") + Table.Name + in parseSearchIndex()
621 KeyRecVal, Twine("In lookup method '") + Name + "', early-out is not " + in parseSearchIndex()
632 StringRef Name; in collectEnumEntries() local
634 Name = EntryRec->getName(); in collectEnumEntries()
636 Name = EntryRec->getValueAsString(NameField); in collectEnumEntries()
642 Enum.Entries.push_back(std::make_unique<GenericEnum::Entry>(Name, Value)); in collectEnumEntries()
662 Twine("Table '") + Table.Name + "' has no entries"); in collectTableEntries()
666 auto TI = dyn_cast<TypedInit>(EntryRec->getValueInit(Field.Name)); in collectTableEntries()
669 "' for table '" + Table.Name + in collectTableEntries()
670 "' is missing field '" + Field.Name + in collectTableEntries()
678 PrintFatalError(EntryRec->getValue(Field.Name), in collectTableEntries()
679 Twine("Field '") + Field.Name + "' of table '" + in collectTableEntries()
680 Table.Name + "' entry has incompatible type: " + in collectTableEntries()
694 PrintFatalError(Twine("Cannot determine type of field '") + Field.Name + in collectTableEntries()
695 "' in table '" + Table.Name + "'. Maybe it is not used?"); in collectTableEntries()
731 Enum->Name = std::string(EnumRec->getName()); in run()
749 Table->Name = std::string(TableRec->getName()); in run()
763 Twine("Table '") + Table->Name + "' has invalid 'TypeOf_" + in run()
846 Enum->Name = (Twine(Class->getName()) + "Values").str(); in run()
856 Table->Name = (Twine(Class->getName()) + "sList").str(); in run()
878 std::string Name = in run() local
881 parseSearchIndex(*Table, Class->getValue(Field), Name, {Field}, in run()