• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-13-stable/contrib/llvm-project/llvm/lib/AsmParser/

Lines Matching refs:Lex

65   Lex.Lex();
69 Lex.getLoc(),
87 Lex.Lex();
92 if (Lex.getKind() != lltok::Eof)
93 return Error(Lex.getLoc(), "expected end of string");
100 Lex.Lex();
103 SMLoc Start = Lex.getLoc();
107 SMLoc End = Lex.getLoc();
306 switch (Lex.getKind()) {
325 switch (Lex.getKind()) {
338 Lex.Lex();
343 switch (Lex.getKind()) {
374 assert(Lex.getKind() == lltok::kw_module);
375 Lex.Lex();
389 assert(Lex.getKind() == lltok::kw_target);
391 switch (Lex.Lex()) {
394 Lex.Lex();
401 Lex.Lex();
413 assert(Lex.getKind() == lltok::kw_source_filename);
414 Lex.Lex();
428 assert(Lex.getKind() == lltok::kw_deplibs);
429 Lex.Lex();
448 LocTy TypeLoc = Lex.getLoc();
449 unsigned TypeID = Lex.getUIntVal();
450 Lex.Lex(); // eat LocalVarID;
474 std::string Name = Lex.getStrVal();
475 LocTy NameLoc = Lex.getLoc();
476 Lex.Lex(); // eat LocalVar.
500 assert(Lex.getKind() == lltok::kw_declare);
501 Lex.Lex();
504 while (Lex.getKind() == lltok::MetadataVar) {
523 assert(Lex.getKind() == lltok::kw_define);
524 Lex.Lex();
536 if (Lex.getKind() == lltok::kw_constant)
538 else if (Lex.getKind() == lltok::kw_global)
544 Lex.Lex();
571 LocTy NameLoc = Lex.getLoc();
574 if (Lex.getKind() == lltok::GlobalID) {
575 if (Lex.getUIntVal() != VarID)
576 return Error(Lex.getLoc(), "variable expected to be numbered '%" +
578 Lex.Lex(); // eat GlobalID;
594 if (Lex.getKind() != lltok::kw_alias && Lex.getKind() != lltok::kw_ifunc)
608 assert(Lex.getKind() == lltok::GlobalVar);
609 LocTy NameLoc = Lex.getLoc();
610 std::string Name = Lex.getStrVal();
611 Lex.Lex();
624 if (Lex.getKind() != lltok::kw_alias && Lex.getKind() != lltok::kw_ifunc)
633 assert(Lex.getKind() == lltok::ComdatVar);
634 std::string Name = Lex.getStrVal();
635 LocTy NameLoc = Lex.getLoc();
636 Lex.Lex();
645 switch (Lex.getKind()) {
664 Lex.Lex();
695 LocTy IDLoc = Lex.getLoc();
718 assert(Lex.getKind() == lltok::MetadataVar);
719 std::string Name = Lex.getStrVal();
720 Lex.Lex();
728 if (Lex.getKind() != lltok::rbrace)
734 if (Lex.getKind() == lltok::MetadataVar &&
735 Lex.getStrVal() == "DIExpression") {
751 assert(Lex.getKind() == lltok::exclaim);
752 Lex.Lex();
761 if (Lex.getKind() == lltok::Type)
765 if (Lex.getKind() == lltok::MetadataVar) {
794 if (Lex.getKind() != lltok::kw_gv && Lex.getKind() != lltok::kw_module &&
795 Lex.getKind() != lltok::kw_typeid)
798 Lex.Lex();
806 switch (Lex.getKind()) {
819 Lex.Lex();
827 assert(Lex.getKind() == lltok::SummaryID);
828 unsigned SummaryID = Lex.getUIntVal();
832 Lex.setIgnoreColonInIdentifiers(true);
834 Lex.Lex();
843 switch (Lex.getKind()) {
863 result = Error(Lex.getLoc(), "unexpected summary kind");
866 Lex.setIgnoreColonInIdentifiers(false);
902 if (Lex.getKind() == lltok::kw_alias)
904 else if (Lex.getKind() == lltok::kw_ifunc)
908 Lex.Lex();
920 LocTy ExplicitTypeLoc = Lex.getLoc();
926 LocTy AliaseeLoc = Lex.getLoc();
927 if (Lex.getKind() != lltok::kw_bitcast &&
928 Lex.getKind() != lltok::kw_getelementptr &&
929 Lex.getKind() != lltok::kw_addrspacecast &&
930 Lex.getKind() != lltok::kw_inttoptr) {
995 while (Lex.getKind() == lltok::comma) {
996 Lex.Lex();
998 if (Lex.getKind() == lltok::kw_partition) {
999 Lex.Lex();
1000 GA->setPartition(Lex.getStrVal());
1135 while (Lex.getKind() == lltok::comma) {
1136 Lex.Lex();
1138 if (Lex.getKind() == lltok::kw_section) {
1139 Lex.Lex();
1140 GV->setSection(Lex.getStrVal());
1143 } else if (Lex.getKind() == lltok::kw_partition) {
1144 Lex.Lex();
1145 GV->setPartition(Lex.getStrVal());
1148 } else if (Lex.getKind() == lltok::kw_align) {
1152 } else if (Lex.getKind() == lltok::MetadataVar) {
1182 assert(Lex.getKind() == lltok::kw_attributes);
1183 LocTy AttrGrpLoc = Lex.getLoc();
1184 Lex.Lex();
1186 if (Lex.getKind() != lltok::AttrGrpID)
1189 unsigned VarID = Lex.getUIntVal();
1192 Lex.Lex();
1217 lltok::Kind Token = Lex.getKind();
1219 BuiltinLoc = Lex.getLoc();
1223 return Error(Lex.getLoc(), "unterminated attribute group");
1234 Error(Lex.getLoc(),
1237 unsigned AttrGrpNum = Lex.getUIntVal();
1258 Lex.Lex();
1273 Lex.Lex();
1368 Error(Lex.getLoc(),
1386 Error(Lex.getLoc(),
1393 Lex.Lex();
1522 if (Lex.getKind() != T)
1524 Lex.Lex();
1531 if (Lex.getKind() != lltok::StringConstant)
1533 Result = Lex.getStrVal();
1534 Lex.Lex();
1541 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned())
1543 uint64_t Val64 = Lex.getAPSIntVal().getLimitedValue(0xFFFFFFFFULL+1);
1547 Lex.Lex();
1554 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned())
1556 Val = Lex.getAPSIntVal().getLimitedValue();
1557 Lex.Lex();
1566 switch (Lex.getKind()) {
1580 Lex.Lex();
1594 if (Lex.getKind() == lltok::lparen) {
1595 Lex.Lex();
1618 std::string Attr = Lex.getStrVal();
1619 Lex.Lex();
1634 lltok::Kind Token = Lex.getKind();
1734 HaveError |= Error(Lex.getLoc(), "invalid use of function-only attribute");
1738 Lex.Lex();
1749 lltok::Kind Token = Lex.getKind();
1798 HaveError |= Error(Lex.getLoc(), "invalid use of parameter-only attribute");
1837 HaveError |= Error(Lex.getLoc(), "invalid use of function-only attribute");
1841 HaveError |= Error(Lex.getLoc(), "invalid use of attribute on return type");
1845 Error(Lex.getLoc(),
1850 Lex.Lex();
1902 Res = parseOptionalLinkageAux(Lex.getKind(), HasLinkage);
1904 Lex.Lex();
1910 return Error(Lex.getLoc(), "dso_location and DLL-StorageClass mismatch");
1917 switch (Lex.getKind()) {
1923 Lex.Lex();
1927 Lex.Lex();
1939 switch (Lex.getKind()) {
1953 Lex.Lex();
1962 switch (Lex.getKind()) {
1973 Lex.Lex();
2023 switch (Lex.getKind()) {
2071 Lex.Lex();
2076 Lex.Lex();
2083 assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata attachment");
2085 std::string Name = Lex.getStrVal();
2087 Lex.Lex();
2096 if (Lex.getKind() != lltok::MetadataVar)
2128 while (Lex.getKind() == lltok::MetadataVar)
2141 LocTy AlignLoc = Lex.getLoc();
2144 LocTy ParenLoc = Lex.getLoc();
2179 LocTy ParenLoc = Lex.getLoc();
2182 LocTy DerefLoc = Lex.getLoc();
2184 ParenLoc = Lex.getLoc();
2203 if (Lex.getKind() == lltok::MetadataVar) {
2208 if (Lex.getKind() != lltok::kw_align)
2209 return Error(Lex.getLoc(), "expected metadata or 'align'");
2229 if (Lex.getKind() == lltok::MetadataVar) {
2234 Loc = Lex.getLoc();
2235 if (Lex.getKind() != lltok::kw_addrspace)
2236 return Error(Lex.getLoc(), "expected metadata or 'addrspace'");
2247 Lex.Lex();
2249 auto StartParen = Lex.getLoc();
2257 auto HowManyAt = Lex.getLoc();
2268 auto EndParen = Lex.getLoc();
2294 auto StartParenAt = Lex.getLoc();
2299 auto SSNAt = Lex.getLoc();
2303 auto EndParenAt = Lex.getLoc();
2318 switch (Lex.getKind()) {
2331 Lex.Lex();
2342 LocTy ParenLoc = Lex.getLoc();
2345 LocTy AlignLoc = Lex.getLoc();
2347 ParenLoc = Lex.getLoc();
2368 if (Lex.getKind() != lltok::comma)
2372 if (Lex.getKind() == lltok::MetadataVar) {
2391 SMLoc TypeLoc = Lex.getLoc();
2392 switch (Lex.getKind()) {
2397 Result = Lex.getTyVal();
2398 Lex.Lex();
2407 Lex.Lex(); // eat the lsquare.
2413 Lex.Lex();
2414 if (Lex.getKind() == lltok::lbrace) {
2423 std::pair<Type*, LocTy> &Entry = NamedTypes[Lex.getStrVal()];
2428 Entry.first = StructType::create(Context, Lex.getStrVal());
2429 Entry.second = Lex.getLoc();
2432 Lex.Lex();
2438 std::pair<Type*, LocTy> &Entry = NumberedTypes[Lex.getUIntVal()];
2444 Entry.second = Lex.getLoc();
2447 Lex.Lex();
2454 switch (Lex.getKind()) {
2470 Lex.Lex();
2510 while (Lex.getKind() != lltok::rparen) {
2517 if (Lex.getKind() == lltok::dotdotdot) {
2523 Lex.Lex(); // Lex the '...', it is purely for readability.
2551 Lex.Lex(); // Lex the ')'.
2567 return Error(Lex.getLoc(), "expected ')'");
2578 return Error(Lex.getLoc(), "expected '('");
2582 return Error(Lex.getLoc(), "expected ')'");
2597 LocTy BeginLoc = Lex.getLoc();
2601 while (Lex.getKind() != lltok::rsquare) {
2615 while (Lex.getKind() != lltok::rparen) {
2630 Lex.Lex(); // Lex the ')'.
2636 Lex.Lex(); // Lex the ']'.
2653 assert(Lex.getKind() == lltok::lparen);
2654 Lex.Lex(); // eat the (.
2656 if (Lex.getKind() == lltok::rparen) {
2658 } else if (Lex.getKind() == lltok::dotdotdot) {
2660 Lex.Lex();
2662 LocTy TypeLoc = Lex.getLoc();
2673 if (Lex.getKind() == lltok::LocalVar) {
2674 Name = Lex.getStrVal();
2675 Lex.Lex();
2676 } else if (Lex.getKind() == lltok::LocalVarID) {
2677 if (Lex.getUIntVal() != CurValID)
2681 Lex.Lex();
2699 TypeLoc = Lex.getLoc();
2705 if (Lex.getKind() == lltok::LocalVar) {
2706 Name = Lex.getStrVal();
2707 Lex.Lex();
2709 if (Lex.getKind() == lltok::LocalVarID) {
2710 if (Lex.getUIntVal() != CurValID)
2713 Lex.Lex();
2734 assert(Lex.getKind() == lltok::lparen);
2798 if (Lex.getKind() != lltok::lbrace) {
2834 assert(Lex.getKind() == lltok::lbrace);
2835 Lex.Lex(); // Consume the '{'
2841 LocTy EltTyLoc = Lex.getLoc();
2850 EltTyLoc = Lex.getLoc();
2871 if (isVector && Lex.getKind() == lltok::kw_vscale) {
2872 Lex.Lex(); // consume the 'vscale'
2879 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned() ||
2880 Lex.getAPSIntVal().getBitWidth() > 64)
2883 LocTy SizeLoc = Lex.getLoc();
2884 uint64_t Size = Lex.getAPSIntVal().getZExtValue();
2885 Lex.Lex();
2890 LocTy TypeLoc = Lex.getLoc();
3159 ID.Loc = Lex.getLoc();
3160 switch (Lex.getKind()) {
3163 ID.UIntVal = Lex.getUIntVal();
3167 ID.StrVal = Lex.getStrVal();
3171 ID.UIntVal = Lex.getUIntVal();
3175 ID.StrVal = Lex.getStrVal();
3179 ID.APSIntVal = Lex.getAPSIntVal();
3183 ID.APFloatVal = Lex.getAPFloatVal();
3201 Lex.Lex();
3217 Lex.Lex();
3221 LocTy FirstEltLoc = Lex.getLoc();
3258 Lex.Lex();
3260 LocTy FirstEltLoc = Lex.getLoc();
3292 Lex.Lex();
3293 ID.ConstantVal = ConstantDataArray::getString(Context, Lex.getStrVal(),
3303 Lex.Lex();
3311 ID.StrVal2 = Lex.getStrVal();
3320 Lex.Lex();
3408 unsigned Opc = Lex.getUIntVal();
3411 Lex.Lex();
3428 Lex.Lex();
3446 Lex.Lex();
3473 unsigned PredVal, Opc = Lex.getUIntVal();
3475 Lex.Lex();
3506 unsigned Opc = Lex.getUIntVal();
3508 Lex.Lex();
3547 unsigned Opc = Lex.getUIntVal();
3549 Lex.Lex();
3611 unsigned Opc = Lex.getUIntVal();
3613 Lex.Lex();
3635 unsigned Opc = Lex.getUIntVal();
3639 Lex.Lex();
3647 LocTy ExplicitTypeLoc = Lex.getLoc();
3746 Lex.Lex();
3771 LocTy KwLoc = Lex.getLoc();
3776 if (Lex.getKind() != lltok::ComdatVar)
3778 C = getComdat(Lex.getStrVal(), Lex.getLoc());
3779 Lex.Lex();
3797 if (Lex.getKind() == lltok::rbrace ||
3798 Lex.getKind() == lltok::rsquare ||
3799 Lex.getKind() == lltok::greater ||
3800 Lex.getKind() == lltok::rparen)
3829 if (Lex.getKind() == lltok::MetadataVar)
3838 if (Lex.getKind() == lltok::lbrace)
4041 if (Lex.getKind() != lltok::APSInt)
4044 Result.assign(Lex.getAPSIntVal());
4045 Lex.Lex();
4052 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned())
4055 auto &U = Lex.getAPSIntVal();
4061 Lex.Lex();
4076 if (Lex.getKind() == lltok::APSInt)
4079 if (Lex.getKind() != lltok::DwarfTag)
4082 unsigned Tag = dwarf::getTag(Lex.getStrVal());
4084 return TokError("invalid DWARF tag" + Twine(" '") + Lex.getStrVal() + "'");
4088 Lex.Lex();
4095 if (Lex.getKind() == lltok::APSInt)
4098 if (Lex.getKind() != lltok::DwarfMacinfo)
4101 unsigned Macinfo = dwarf::getMacinfo(Lex.getStrVal());
4104 "invalid DWARF macinfo type" + Twine(" '") + Lex.getStrVal() + "'");
4108 Lex.Lex();
4115 if (Lex.getKind() == lltok::APSInt)
4118 if (Lex.getKind() != lltok::DwarfVirtuality)
4121 unsigned Virtuality = dwarf::getVirtuality(Lex.getStrVal());
4124 Lex.getStrVal() + "'");
4127 Lex.Lex();
4133 if (Lex.getKind() == lltok::APSInt)
4136 if (Lex.getKind() != lltok::DwarfLang)
4139 unsigned Lang = dwarf::getLanguage(Lex.getStrVal());
4141 return TokError("invalid DWARF language" + Twine(" '") + Lex.getStrVal() +
4145 Lex.Lex();
4151 if (Lex.getKind() == lltok::APSInt)
4154 if (Lex.getKind() != lltok::DwarfCC)
4157 unsigned CC = dwarf::getCallingConvention(Lex.getStrVal());
4159 return TokError("invalid DWARF calling convention" + Twine(" '") + Lex.getStrVal() +
4163 Lex.Lex();
4169 if (Lex.getKind() == lltok::APSInt)
4172 if (Lex.getKind() != lltok::EmissionKind)
4175 auto Kind = DICompileUnit::getEmissionKind(Lex.getStrVal());
4177 return TokError("invalid emission kind" + Twine(" '") + Lex.getStrVal() +
4181 Lex.Lex();
4188 if (Lex.getKind() == lltok::APSInt)
4191 if (Lex.getKind() != lltok::NameTableKind)
4194 auto Kind = DICompileUnit::getNameTableKind(Lex.getStrVal());
4196 return TokError("invalid nameTable kind" + Twine(" '") + Lex.getStrVal() +
4200 Lex.Lex();
4207 if (Lex.getKind() == lltok::APSInt)
4210 if (Lex.getKind() != lltok::DwarfAttEncoding)
4213 unsigned Encoding = dwarf::getAttributeEncoding(Lex.getStrVal());
4216 Lex.getStrVal() + "'");
4219 Lex.Lex();
4232 if (Lex.getKind() == lltok::APSInt && !Lex.getAPSIntVal().isSigned()) {
4239 if (Lex.getKind() != lltok::DIFlag)
4242 Val = DINode::getFlag(Lex.getStrVal());
4245 Lex.getStrVal() + "'");
4246 Lex.Lex();
4272 if (Lex.getKind() == lltok::APSInt && !Lex.getAPSIntVal().isSigned()) {
4279 if (Lex.getKind() != lltok::DISPFlag)
4282 Val = DISubprogram::getFlag(Lex.getStrVal());
4285 Lex.getStrVal() + "'");
4286 Lex.Lex();
4306 if (Lex.getKind() != lltok::APSInt)
4309 auto &S = Lex.getAPSIntVal();
4319 Lex.Lex();
4325 switch (Lex.getKind()) {
4335 Lex.Lex();
4341 if (Lex.getKind() == lltok::kw_null) {
4344 Lex.Lex();
4361 if (Lex.getKind() == lltok::APSInt) {
4382 LocTy ValueLoc = Lex.getLoc();
4408 DIFile::getChecksumKind(Lex.getStrVal());
4410 if (Lex.getKind() != lltok::ChecksumKind || !CSKind)
4412 "invalid checksum kind" + Twine(" '") + Lex.getStrVal() + "'");
4415 Lex.Lex();
4424 if (Lex.getKind() != lltok::LabelStr)
4436 assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
4437 Lex.Lex();
4441 if (Lex.getKind() != lltok::rparen)
4445 ClosingLoc = Lex.getLoc();
4454 LocTy Loc = Lex.getLoc();
4455 Lex.Lex();
4460 assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
4463 if (Lex.getStrVal() == #CLASS) \
4476 if (Lex.getStrVal() == #NAME) \
4484 return TokError(Twine("invalid field '") + Lex.getStrVal() + "'"); \
4725 return Lex.Error("'checksumkind' and 'checksum' must be provided together");
4744 return Lex.Error("missing 'distinct', required for !DICompileUnit");
4788 auto Loc = Lex.getLoc();
4821 return Lex.Error(
5061 assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
5062 Lex.Lex();
5068 if (Lex.getKind() != lltok::rparen)
5070 if (Lex.getKind() == lltok::DwarfOp) {
5071 if (unsigned Op = dwarf::getOperationEncoding(Lex.getStrVal())) {
5072 Lex.Lex();
5076 return TokError(Twine("invalid DWARF op '") + Lex.getStrVal() + "'");
5079 if (Lex.getKind() == lltok::DwarfAttEncoding) {
5080 if (unsigned Op = dwarf::getAttributeEncoding(Lex.getStrVal())) {
5081 Lex.Lex();
5085 return TokError(Twine("invalid DWARF attribute encoding '") + Lex.getStrVal() + "'");
5088 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned())
5091 auto &U = Lex.getAPSIntVal();
5095 Lex.Lex();
5213 if (Lex.getKind() == lltok::MetadataVar) {
5223 if (Lex.getKind() != lltok::exclaim)
5227 assert(Lex.getKind() == lltok::exclaim && "Expected '!' here");
5228 Lex.Lex();
5232 if (Lex.getKind() == lltok::StringConstant) {
5374 auto Loc = Lex.getLoc();
5415 Loc = Lex.getLoc();
5430 LocTy LinkageLoc = Lex.getLoc();
5439 LocTy RetTypeLoc = Lex.getLoc();
5476 LocTy NameLoc = Lex.getLoc();
5479 if (Lex.getKind() == lltok::GlobalVar) {
5480 FunctionName = Lex.getStrVal();
5481 } else if (Lex.getKind() == lltok::GlobalID) { // @42 is ok.
5482 unsigned NameID = Lex.getUIntVal();
5491 Lex.Lex();
5493 if (Lex.getKind() != lltok::lparen)
5702 if (Lex.getKind() != lltok::lbrace)
5704 Lex.Lex(); // eat the {.
5718 if (Lex.getKind() == lltok::rbrace || Lex.getKind() == lltok::kw_uselistorder)
5721 while (Lex.getKind() != lltok::rbrace &&
5722 Lex.getKind() != lltok::kw_uselistorder)
5725 while (Lex.getKind() != lltok::rbrace)
5730 Lex.Lex();
5742 LocTy NameLoc = Lex.getLoc();
5743 if (Lex.getKind() == lltok::LabelStr) {
5744 Name = Lex.getStrVal();
5745 Lex.Lex();
5746 } else if (Lex.getKind() == lltok::LabelID) {
5747 NameID = Lex.getUIntVal();
5748 Lex.Lex();
5762 LocTy NameLoc = Lex.getLoc();
5766 if (Lex.getKind() == lltok::LocalVarID) {
5767 NameID = Lex.getUIntVal();
5768 Lex.Lex();
5771 } else if (Lex.getKind() == lltok::LocalVar) {
5772 NameStr = Lex.getStrVal();
5773 Lex.Lex();
5815 lltok::Kind Token = Lex.getKind();
5818 LocTy Loc = Lex.getLoc();
5819 unsigned KeywordVal = Lex.getUIntVal();
5820 Lex.Lex(); // Eat the keyword.
5973 switch (Lex.getKind()) {
5993 switch (Lex.getKind()) {
6007 Lex.Lex();
6020 SMLoc TypeLoc = Lex.getLoc();
6094 while (Lex.getKind() != lltok::rsquare) {
6111 Lex.Lex(); // Eat the ']'.
6137 if (Lex.getKind() != lltok::rsquare) {
6164 LocTy CallLoc = Lex.getLoc();
6274 while (Lex.getKind() != lltok::rsquare) {
6297 Lex.Lex(); // Lex the ']'.
6316 if (Lex.getKind() == lltok::kw_to) {
6317 Lex.Lex();
6358 if (Lex.getKind() != lltok::kw_none && Lex.getKind() != lltok::LocalVar &&
6359 Lex.getKind() != lltok::LocalVarID)
6408 if (Lex.getKind() != lltok::LocalVar && Lex.getKind() != lltok::LocalVarID)
6430 if (Lex.getKind() != lltok::kw_none && Lex.getKind() != lltok::LocalVar &&
6431 Lex.getKind() != lltok::LocalVarID)
6475 LocTy CallLoc = Lex.getLoc();
6501 if (Lex.getKind() != lltok::rsquare) {
6800 if (Lex.getKind() == lltok::MetadataVar) {
6838 while (Lex.getKind() == lltok::kw_catch || Lex.getKind() == lltok::kw_filter){
6905 LocTy CallLoc = Lex.getLoc();
7024 if (Lex.getKind() == lltok::kw_align) {
7029 } else if (Lex.getKind() == lltok::kw_addrspace) {
7030 ASLoc = Lex.getLoc();
7033 } else if (Lex.getKind() == lltok::MetadataVar) {
7039 if (Lex.getKind() == lltok::kw_align) {
7044 } else if (Lex.getKind() == lltok::kw_addrspace) {
7045 ASLoc = Lex.getLoc();
7048 } else if (Lex.getKind() == lltok::MetadataVar) {
7082 if (Lex.getKind() == lltok::kw_atomic) {
7084 Lex.Lex();
7088 if (Lex.getKind() == lltok::kw_volatile) {
7090 Lex.Lex();
7094 LocTy ExplicitTypeLoc = Lex.getLoc();
7135 if (Lex.getKind() == lltok::kw_atomic) {
7137 Lex.Lex();
7141 if (Lex.getKind() == lltok::kw_volatile) {
7143 Lex.Lex();
7247 switch (Lex.getKind()) {
7269 Lex.Lex(); // Eat the operation.
7346 LocTy ExplicitTypeLoc = Lex.getLoc();
7370 if (Lex.getKind() == lltok::MetadataVar) {
7507 SMLoc Loc = Lex.getLoc();
7510 if (Lex.getKind() == lltok::rbrace)
7511 return Lex.Error("expected non-empty list of uselistorder indexes");
7549 SMLoc Loc = Lex.getLoc();
7566 assert(Lex.getKind() == lltok::kw_uselistorder_bb);
7567 SMLoc Loc = Lex.getLoc();
7568 Lex.Lex();
7613 assert(Lex.getKind() == lltok::kw_module);
7614 Lex.Lex();
7649 assert(Lex.getKind() == lltok::kw_typeid);
7650 Lex.Lex();
7709 assert(Lex.getKind() == lltok::kw_typeidCompatibleVTable);
7710 Lex.Lex();
7738 LocTy Loc = Lex.getLoc();
7801 switch (Lex.getKind()) {
7821 return Error(Lex.getLoc(), "unexpected TypeTestResolution kind");
7823 Lex.Lex();
7833 switch (Lex.getKind()) {
7835 Lex.Lex();
7841 Lex.Lex();
7847 Lex.Lex();
7855 Lex.Lex();
7861 return Error(Lex.getLoc(), "expected optional TypeTestResolution field");
7915 switch (Lex.getKind()) {
7926 return Error(Lex.getLoc(), "unexpected WholeProgramDevirtResolution kind");
7928 Lex.Lex();
7932 switch (Lex.getKind()) {
7934 Lex.Lex();
7944 return Error(Lex.getLoc(),
7981 switch (Lex.getKind()) {
7995 return Error(Lex.getLoc(),
7998 Lex.Lex();
8002 switch (Lex.getKind()) {
8004 Lex.Lex();
8010 Lex.Lex();
8016 Lex.Lex();
8022 return Error(Lex.getLoc(),
8140 assert(Lex.getKind() == lltok::kw_flags);
8141 Lex.Lex();
8155 assert(Lex.getKind() == lltok::kw_blockcount);
8156 Lex.Lex();
8172 assert(Lex.getKind() == lltok::kw_gv);
8173 Lex.Lex();
8181 switch (Lex.getKind()) {
8183 Lex.Lex();
8190 Lex.Lex();
8195 return Error(Lex.getLoc(), "expected name or guid tag");
8219 switch (Lex.getKind()) {
8233 return Error(Lex.getLoc(), "expected summary type");
8251 assert(Lex.getKind() == lltok::kw_function);
8252 Lex.Lex();
8276 switch (Lex.getKind()) {
8298 return Error(Lex.getLoc(), "expected optional function summary field");
8327 assert(Lex.getKind() == lltok::kw_variable);
8328 Lex.Lex();
8350 switch (Lex.getKind()) {
8360 return Error(Lex.getLoc(), "expected optional variable summary field");
8384 assert(Lex.getKind() == lltok::kw_alias);
8385 LocTy Loc = Lex.getLoc();
8386 Lex.Lex();
8433 if (Lex.getKind() != lltok::APSInt || Lex.getAPSIntVal().isSigned())
8435 Val = (unsigned)Lex.getAPSIntVal().getBoolValue();
8436 Lex.Lex();
8448 assert(Lex.getKind() == lltok::kw_funcFlags);
8449 Lex.Lex();
8457 switch (Lex.getKind()) {
8459 Lex.Lex();
8465 Lex.Lex();
8471 Lex.Lex();
8477 Lex.Lex();
8483 Lex.Lex();
8489 Lex.Lex();
8495 return Error(Lex.getLoc(), "expected function flag type");
8510 assert(Lex.getKind() == lltok::kw_calls);
8511 Lex.Lex();
8526 LocTy Loc = Lex.getLoc();
8577 switch (Lex.getKind()) {
8594 return Error(Lex.getLoc(), "invalid call edge hotness");
8596 Lex.Lex();
8604 assert(Lex.getKind() == lltok::kw_vTableFuncs);
8605 Lex.Lex();
8620 LocTy Loc = Lex.getLoc();
8674 if (Lex.getKind() != lltok::APSInt)
8676 Val = Lex.getAPSIntVal();
8679 Lex.Lex();
8761 assert(Lex.getKind() == lltok::kw_params);
8762 Lex.Lex();
8784 assert(Lex.getKind() == lltok::kw_refs);
8785 Lex.Lex();
8800 VC.Loc = Lex.getLoc();
8847 assert(Lex.getKind() == lltok::kw_typeIdInfo);
8848 Lex.Lex();
8855 switch (Lex.getKind()) {
8881 return Error(Lex.getLoc(), "invalid typeIdInfo list type");
8895 assert(Lex.getKind() == lltok::kw_typeTests);
8896 Lex.Lex();
8905 if (Lex.getKind() == lltok::SummaryID) {
8906 unsigned ID = Lex.getUIntVal();
8907 LocTy Loc = Lex.getLoc();
8912 Lex.Lex();
8941 assert(Lex.getKind() == Kind);
8942 Lex.Lex();
8980 assert(Lex.getKind() == Kind);
8981 Lex.Lex();
9037 assert(Lex.getKind() == lltok::kw_vFuncId);
9038 Lex.Lex();
9044 if (Lex.getKind() == lltok::SummaryID) {
9046 unsigned ID = Lex.getUIntVal();
9047 LocTy Loc = Lex.getLoc();
9052 Lex.Lex();
9073 assert(Lex.getKind() == lltok::kw_flags);
9074 Lex.Lex();
9082 switch (Lex.getKind()) {
9084 Lex.Lex();
9088 GVFlags.Linkage = parseOptionalLinkageAux(Lex.getKind(), HasLinkage);
9090 Lex.Lex();
9093 Lex.Lex();
9099 Lex.Lex();
9105 Lex.Lex();
9111 Lex.Lex();
9117 return Error(Lex.getLoc(), "expected gv flag type");
9132 assert(Lex.getKind() == lltok::kw_varFlags);
9133 Lex.Lex();
9140 Lex.Lex();
9148 switch (Lex.getKind()) {
9170 return Error(Lex.getLoc(), "expected gvar flag type");
9185 unsigned ModuleID = Lex.getUIntVal();
9202 GVId = Lex.getUIntVal();