Lines Matching refs:Rule
305 static Cursor maybeLexIndex(Cursor C, MIToken &Token, StringRef Rule, in maybeLexIndex() argument
307 if (!C.remaining().startswith(Rule) || !isdigit(C.peek(Rule.size()))) in maybeLexIndex()
310 C.advance(Rule.size()); in maybeLexIndex()
318 static Cursor maybeLexIndexAndName(Cursor C, MIToken &Token, StringRef Rule, in maybeLexIndexAndName() argument
320 if (!C.remaining().startswith(Rule) || !isdigit(C.peek(Rule.size()))) in maybeLexIndexAndName()
323 C.advance(Rule.size()); in maybeLexIndexAndName()
328 unsigned StringOffset = Rule.size() + Number.size(); in maybeLexIndexAndName()
359 const StringRef Rule = "%subreg."; in maybeLexSubRegisterIndex() local
360 if (!C.remaining().startswith(Rule)) in maybeLexSubRegisterIndex()
362 return lexName(C, Token, MIToken::SubRegisterIndex, Rule.size(), in maybeLexSubRegisterIndex()
368 const StringRef Rule = "%ir-block."; in maybeLexIRBlock() local
369 if (!C.remaining().startswith(Rule)) in maybeLexIRBlock()
371 if (isdigit(C.peek(Rule.size()))) in maybeLexIRBlock()
372 return maybeLexIndex(C, Token, Rule, MIToken::IRBlock); in maybeLexIRBlock()
373 return lexName(C, Token, MIToken::NamedIRBlock, Rule.size(), ErrorCallback); in maybeLexIRBlock()
378 const StringRef Rule = "%ir."; in maybeLexIRValue() local
379 if (!C.remaining().startswith(Rule)) in maybeLexIRValue()
381 if (isdigit(C.peek(Rule.size()))) in maybeLexIRValue()
382 return maybeLexIndex(C, Token, Rule, MIToken::IRValue); in maybeLexIRValue()
383 return lexName(C, Token, MIToken::NamedIRValue, Rule.size(), ErrorCallback); in maybeLexIRValue()
472 const StringRef Rule = "<mcsymbol "; in maybeLexMCSymbol() local
473 if (!C.remaining().startswith(Rule)) in maybeLexMCSymbol()
476 C.advance(Rule.size()); in maybeLexMCSymbol()
482 StringRef String = Start.upto(C).drop_front(Rule.size()); in maybeLexMCSymbol()
503 StringRef String = Start.upto(R).drop_front(Rule.size()); in maybeLexMCSymbol()