/llvm-project/clang/lib/Tooling/Inclusions/ |
H A D | HeaderAnalysis.cpp | 19 bool isIf(llvm::StringRef Line) { in isIf() argument 20 Line = Line.ltrim(); in isIf() 21 if (!Line.consume_front("#")) in isIf() 23 Line = Line.ltrim(); in isIf() 24 return Line.starts_with("if"); in isIf() 28 bool isErrorAboutInclude(llvm::StringRef Line) { in isErrorAboutInclude() argument 29 Line = Line.ltrim(); in isErrorAboutInclude() 30 if (!Line.consume_front("#")) in isErrorAboutInclude() 32 Line = Line.ltrim(); in isErrorAboutInclude() 33 if (!Line.starts_with("error")) in isErrorAboutInclude() [all …]
|
/llvm-project/llvm/lib/DebugInfo/Symbolize/ |
H A D | Markup.cpp | 37 void MarkupParser::parseLine(StringRef Line) { 41 this->Line = Line; in parseLine() 55 if (Line.empty()) in nextNode() 59 if (std::optional<StringRef> MultilineEnd = parseMultiLineEnd(Line)) { in nextNode() 65 advanceTo(Line, MultilineEnd->end()); in nextNode() 70 llvm::append_range(InProgressMultiline, Line); in nextNode() 71 Line = Line.drop_front(Line in nextNode() 38 parseLine(StringRef Line) parseLine() argument 114 parseElement(StringRef Line) parseElement() argument 172 parseMultiLineBegin(StringRef Line) parseMultiLineBegin() argument 197 parseMultiLineEnd(StringRef Line) parseMultiLineEnd() argument [all...] |
/llvm-project/lldb/source/Plugins/ObjectFile/Breakpad/ |
H A D | BreakpadRecords.cpp | 132 std::optional<Record::Kind> Record::classify(llvm::StringRef Line) { in classify() argument 133 Token Tok = consume<Token>(Line); in classify() 146 Tok = consume<Token>(Line); in classify() 163 return Record::Line; in classify() 175 std::optional<ModuleRecord> ModuleRecord::parse(llvm::StringRef Line) { in parse() argument 177 if (consume<Token>(Line) != Token::Module) in parse() 180 llvm::Triple::OSType OS = consume<llvm::Triple::OSType>(Line); in parse() 184 llvm::Triple::ArchType Arch = consume<llvm::Triple::ArchType>(Line); in parse() 189 std::tie(Str, Line) = getToken(Line); in parse() 204 std::optional<InfoRecord> InfoRecord::parse(llvm::StringRef Line) { in parse() argument [all …]
|
/llvm-project/llvm/tools/llvm-rc/ |
H A D | ResourceScriptCppFilter.cpp | 31 bool parseLine(StringRef Line); 49 StringRef Line = Data.take_front(Pos).drop_front(LineStart); in run() local 51 if (parseLine(Line)) in run() 52 Output.push_back(Line); in run() 58 bool Filter::parseLine(StringRef Line) { in parseLine() argument 59 Line = Line.ltrim(); in parseLine() 61 if (!Line.consume_front("#")) { in parseLine() 69 Line.consume_front("line"); in parseLine() 70 if (!Line.starts_with(" ")) in parseLine() 76 Line = in parseLine() [all …]
|
/llvm-project/llvm/test/tools/llvm-debuginfo-analyzer/WebAssembly/ |
H A D | 03-wasm-incorrect-lexical-scope-typedef.test | 50 ; ONE-NEXT: [003] 1 {Line} 51 ; ONE-NEXT: [003] 1 {Line} 52 ; ONE-NEXT: [003] - {Line} 53 ; ONE-NEXT: [003] 1 {Line} 54 ; ONE-NEXT: [003] - {Line} 55 ; ONE-NEXT: [003] 1 {Line} 56 ; ONE-NEXT: [003] 1 {Line} 57 ; ONE-NEXT: [003] 1 {Line} 61 ; ONE-NEXT: [004] 9 {Line} 62 ; ONE-NEXT: [004] 9 {Line} [all …]
|
/llvm-project/clang/lib/Format/ |
H A D | AffectedRangeManager.cpp | 29 AnnotatedLine *Line = *I; in computeAffectedLines() local 30 assert(Line->First); in computeAffectedLines() 31 Line->LeadingEmptyLinesAffected = affectsLeadingEmptyLines(*Line->First); in computeAffectedLines() 35 if (Line->InPPDirective) { in computeAffectedLines() 36 FormatToken *Last = Line->Last; in computeAffectedLines() 43 if (affectsTokenRange(*Line->First, *Last, in computeAffectedLines() 52 if (nonPPLineAffected(Line, PreviousLine, Lines)) in computeAffectedLines() 55 PreviousLine = Line; in computeAffectedLines() 102 AnnotatedLine *Line, cons in nonPPLineAffected() argument [all...] |
H A D | TokenAnnotator.h | 51 AnnotatedLine(const UnwrappedLine &Line) in AnnotatedLine() 52 : First(Line.Tokens.front().Tok), Type(LT_Other), Level(Line.Level), in AnnotatedLine() 53 PPLevel(Line.PPLevel), in AnnotatedLine() 54 MatchingOpeningBlockLineIndex(Line.MatchingOpeningBlockLineIndex), in AnnotatedLine() 55 MatchingClosingBlockLineIndex(Line.MatchingClosingBlockLineIndex), in AnnotatedLine() 56 InPPDirective(Line.InPPDirective), in AnnotatedLine() 57 InPragmaDirective(Line.InPragmaDirective), in AnnotatedLine() 58 InMacroBody(Line.InMacroBody), in AnnotatedLine() 59 MustBeDeclaration(Line in AnnotatedLine() 49 AnnotatedLine(const UnwrappedLine & Line) AnnotatedLine() argument [all...] |
H A D | UnwrappedLineFormatter.cpp | 23 bool startsExternCBlock(const AnnotatedLine &Line) { in startsExternCBlock() argument 24 const FormatToken *Next = Line.First->getNextNonComment(); in startsExternCBlock() 26 return Line.startsWith(tok::kw_extern) && Next && Next->isStringLiteral() && in startsExternCBlock() 57 /// Update the indent state given that \p Line is going to be formatted 59 void nextLine(const AnnotatedLine &Line) { in nextLine() argument 60 Offset = getIndentOffset(Line); in nextLine() 63 if (Line.Level >= IndentForLevel.size()) in nextLine() 64 IndentForLevel.resize(Line.Level + 1, -1); in nextLine() 66 (Line.InPPDirective || in nextLine() 68 Line in nextLine() 97 adjustToUnmodifiedLine(const AnnotatedLine & Line) adjustToUnmodifiedLine() argument 114 getIndentOffset(const AnnotatedLine & Line) getIndentOffset() argument 187 getMatchingNamespaceToken(const AnnotatedLine * Line,const SmallVectorImpl<AnnotatedLine * > & AnnotatedLines) getMatchingNamespaceToken() argument 198 getNamespaceTokenText(const AnnotatedLine * Line) getNamespaceTokenText() argument 204 getMatchingNamespaceTokenText(const AnnotatedLine * Line,const SmallVectorImpl<AnnotatedLine * > & AnnotatedLines) getMatchingNamespaceTokenText() argument 334 const AnnotatedLine *Line = nullptr; tryFitMultipleLinesInOne() local 635 AnnotatedLine &Line = **I; tryMergeSimpleControlStatement() local 680 const AnnotatedLine *Line = I[1 + NumStmts]; tryMergeShortCaseLabels() local 724 AnnotatedLine &Line = **I; tryMergeSimpleBlock() local 747 __anon76deacb70502(const auto &Line) tryMergeSimpleBlock() argument 919 containsMustBreak(const AnnotatedLine * Line) containsMustBreak() argument 1108 formatLine(const AnnotatedLine & Line,unsigned FirstIndent,unsigned FirstStartColumn,bool DryRun) formatLine() argument 1134 formatLine(const AnnotatedLine & Line,unsigned FirstIndent,unsigned FirstStartColumn,bool DryRun) formatLine() argument 1159 formatLine(const AnnotatedLine & Line,unsigned FirstIndent,unsigned FirstStartColumn,bool DryRun) formatLine() argument 1357 for (const AnnotatedLine *Line = format() local 1460 computeNewlines(const AnnotatedLine & Line,const AnnotatedLine * PreviousLine,const AnnotatedLine * PrevPrevLine,const SmallVectorImpl<AnnotatedLine * > & Lines,const FormatStyle & Style) computeNewlines() argument 1553 formatFirstToken(const AnnotatedLine & Line,const AnnotatedLine * PreviousLine,const AnnotatedLine * PrevPrevLine,const SmallVectorImpl<AnnotatedLine * > & Lines,unsigned Indent,unsigned NewlineIndent) formatFirstToken() argument [all...] |
H A D | UnwrappedLineParser.cpp | 38 void printLine(llvm::raw_ostream &OS, const UnwrappedLine &Line, in printLine() argument 40 OS << Prefix << "Line(" << Line.Level << ", FSC=" << Line.FirstStartColumn in printLine() 41 << ")" << (Line.InPPDirective ? " MACRO" : "") << ": "; in printLine() 43 for (std::list<UnwrappedLineNode>::const_iterator I = Line.Tokens.begin(), in printLine() 44 E = Line.Tokens.end(); in printLine() 65 LLVM_ATTRIBUTE_UNUSED static void printDebugInfo(const UnwrappedLine &Line) { in printLine() 66 printLine(llvm::dbgs(), Line); 71 ScopedDeclarationState(UnwrappedLine &Line, llv 67 printDebugInfo(const UnwrappedLine & Line) printDebugInfo() argument 73 ScopedDeclarationState(UnwrappedLine & Line,llvm::BitVector & Stack,bool MustBeDeclaration) ScopedDeclarationState() argument 88 UnwrappedLine &Line; global() member in clang::format::__anon010f85700111::ScopedDeclarationState 94 operator <<(std::ostream & Stream,const UnwrappedLine & Line) operator <<() argument 220 for (auto &Line : Lines) parse() local 234 for (const auto &Line : Lines) { parse() local 252 for (const UnwrappedLine &Line : Lines) { parse() local 706 AnnotatedLine Line(ParsedLine); mightFitOnOneLine() local 919 isGoogScope(const UnwrappedLine & Line) isGoogScope() argument 937 isIIFE(const UnwrappedLine & Line,const AdditionalKeywords & Keywords) isIIFE() argument 1037 size_t Line = CurrentLines->size(); conditionalCompilationCondition() local 1101 for (auto &Line : Lines) { parsePPIf() local 1157 for (auto &Line : Lines) { parsePPDefine() local 2692 getLastNonComment(const UnwrappedLine & Line) getLastNonComment() argument 4593 continuesLineCommentSection(const FormatToken & FormatTok,const UnwrappedLine & Line,const llvm::Regex & CommentPragmasRegex) continuesLineCommentSection() argument [all...] |
H A D | UsingDeclarationsSorter.cpp | 95 const AnnotatedLine *Line; member 98 UsingDeclaration(const AnnotatedLine *Line, const std::string &Label) in UsingDeclaration() 99 : Line(Line), Label(Label) {} in UsingDeclaration() 143 if (Declaration.Line->Affected) { in endUsingDeclarationBlock() 170 (*UsingDeclarations)[I].Line->First->WhitespaceRange.getBegin(); in endUsingDeclarationBlock() 171 auto End = (*UsingDeclarations)[I].Line->Last->Tok.getEndLoc(); in endUsingDeclarationBlock() 180 if ((*UsingDeclarations)[I].Line == SortedUsingDeclarations[I].Line) in endUsingDeclarationBlock() 182 auto Begin = (*UsingDeclarations)[I].Line->First->Tok.getLocation(); in endUsingDeclarationBlock() 183 auto End = (*UsingDeclarations)[I].Line->Last->Tok.getEndLoc(); in endUsingDeclarationBlock() 185 SortedUsingDeclarations[I].Line->First->Tok.getLocation(); in endUsingDeclarationBlock() [all …]
|
/llvm-project/llvm/test/tools/llvm-debuginfo-analyzer/DWARF/ |
H A D | 03-dwarf-incorrect-lexical-scope-typedef.test | 47 ; ONE-NEXT: [003] 1 {Line} 48 ; ONE-NEXT: [003] 1 {Line} 49 ; ONE-NEXT: [003] 1 {Line} 53 ; ONE-NEXT: [004] 9 {Line} 54 ; ONE-NEXT: [004] 9 {Line} 55 ; ONE-NEXT: [004] 9 {Line} 56 ; ONE-NEXT: [004] 9 {Line} 57 ; ONE-NEXT: [004] 9 {Line} 58 ; ONE-NEXT: [004] 10 {Line} 59 ; ONE-NEXT: [004] 10 {Line} [all …]
|
H A D | pr-incorrect-logical-instructions.test | 44 ; ONE-NEXT: [003] 2 {Line} 48 ; ONE-NEXT: [003] 3 {Line} 50 ; ONE-NEXT: [003] 3 {Line} 52 ; ONE-NEXT: [003] 3 {Line} 54 ; ONE-NEXT: [003] 3 {Line} 56 ; ONE-NEXT: [003] 3 {Line} 60 ; ONE-NEXT: [003] 6 {Line} 65 ; ONE-NEXT: [003] 7 {Line} 68 ; ONE-NEXT: [003] 7 {Line} 70 ; ONE-NEXT: [003] 7 {Line} [all …]
|
/llvm-project/llvm/tools/llvm-cov/ |
H A D | SourceCoverageView.h | 57 unsigned Line; member 60 InstantiationView(StringRef FunctionName, unsigned Line, in InstantiationView() 62 : FunctionName(FunctionName), Line(Line), View(std::move(View)) {} in InstantiationView() 66 return LHS.Line < RHS.Line; 73 unsigned Line; member 75 BranchView(unsigned Line, SmallVector<CountedRegion, 0> Regions) in BranchView() 76 : Regions(std::move(Regions)), Line(Line) {} in BranchView() 88 unsigned Line; global() member 188 StringRef Line; global() member [all...] |
/llvm-project/clang-tools-extra/clang-query/ |
H A D | QueryParser.cpp | 31 Line = Line.ltrim(" \t\v\f\r"); in lexWord() 33 if (Line.empty()) in lexWord() 34 // Even though the Line is empty, it contains a pointer and in lexWord() 37 return Line; in lexWord() 40 if (Line.front() == '#') in lexWord() 41 Word = Line.substr(0, 1); in lexWord() 43 Word = Line.take_until(isWhitespace); in lexWord() 45 Line = Line in lexWord() 357 parse(StringRef Line,const QuerySession & QS) parse() argument 362 complete(StringRef Line,size_t Pos,const QuerySession & QS) complete() argument [all...] |
/llvm-project/llvm/test/DebugInfo/ |
H A D | debuglineinfo-macho.test | 20 TEST_SIMPLE-NEXT: Line info @ 0: simple.c, line:1 21 TEST_SIMPLE-NEXT: Line info @ 7: simple.c, line:2 22 TEST_SIMPLE-NOT: Line info @ 11: simple.c, line:2 25 TEST_MULTIPLE-NEXT: Line info @ 0: multiple.c, line:5 26 TEST_MULTIPLE-NEXT: Line info @ 7: multiple.c, line:6 27 TEST_MULTIPLE-NEXT: Line info @ 16: multiple.c, line:9 28 TEST_MULTIPLE-NEXT: Line info @ 21: multiple.c, line:9 29 TEST_MULTIPLE-NEXT: Line info @ 26: multiple.c, line:7 30 TEST_MULTIPLE-NEXT: Line info @ 33: multiple.c, line:10 31 TEST_MULTIPLE-NOT: Line info @ 48: multiple.c, line:12 [all …]
|
/llvm-project/llvm/lib/LineEditor/ |
H A D | LineEditor.cpp | 260 const char *Line = ::el_gets(Data->EL, &LineLen); in readLine() 263 if (!Line || LineLen == 0) in readLine() 268 (Line[LineLen - 1] == '\n' || Line[LineLen - 1] == '\r')) in readLine() 273 ::history(Data->Hist, &HE, H_ENTER, Line); 275 return std::string(Line, LineLen); 305 std::string Line; in readLine() 310 if (Line.empty()) in readLine() 313 return Line; in readLine() 315 Line in readLine() 254 const char *Line = ::el_gets(Data->EL, &LineLen); readLine() local 298 std::string Line; readLine() local [all...] |
/llvm-project/lldb/source/Host/linux/ |
H A D | Host.cpp | 187 llvm::StringRef Line; in GetStatusInfo() 188 std::tie(Line, Rest) = Rest.split('\n'); in GetStatusInfo() 190 if (Line.consume_front("Gid:")) { in GetStatusInfo() 192 Line = Line.ltrim(); in GetStatusInfo() 194 Line.consumeInteger(10, RGid); in GetStatusInfo() 195 Line = Line.ltrim(); in GetStatusInfo() 196 Line.consumeInteger(10, EGid); in GetStatusInfo() 200 } else if (Line in GetStatusInfo() 189 llvm::StringRef Line; GetStatusInfo() local [all...] |
/llvm-project/llvm/lib/DebugInfo/LogicalView/Readers/ |
H A D | LVBinaryReader.cpp | 498 LVLineAssembler *Line = createLineAssembler(); in createInstructions() local 499 Line->setAddress(Address); in createInstructions() 500 Line->setName(StringRef(Stream.str()).trim()); in createInstructions() 501 Instructions.push_back(Line); in createInstructions() 516 for (const LVLine *Line : Instructions) in createInstructions() 518 << hexValue(Line->getOffset()) << ", (" << Line->getName() in createInstructions() 603 for (const LVLine *Line : *DebugLines) { in processLines() 604 dbgs() << format_decimal(Index, 5) << ": " << hexValue(Line->getOffset()) in processLines() 605 << ", (" << Line in processLines() 806 __anonf55eebf90102(LVLine *Line) processLines() argument 810 __anonf55eebf90202(LVLine *Line) processLines() argument [all...] |
/llvm-project/llvm/test/tools/llvm-dwarfdump/X86/Inputs/ |
H A D | debug_line_malformed.s | 11 .byte -5 # Line Base 12 .byte 14 # Line Range 52 .byte -5 # Line Base 53 .byte 14 # Line Range 72 .byte -5 # Line Base 73 .byte 14 # Line Range 98 .byte -5 # Line Base 99 .byte 14 # Line Range 127 .byte -5 # Line Base 128 .byte 14 # Line Range [all …]
|
/llvm-project/llvm/test/tools/llvm-symbolizer/ |
H A D | source.ll | 18 ; COMMON-NEXT:2 : // Line 2 20 ; COMMON-NEXT:4 : // Line 4 25 …ileName":"/source.c","FunctionName":"foo","Line":3,"Source":"2 : // Line 2\n3 >: void foo() {}\n4… 28 ;; // Line 1 29 ;; // Line 2 31 ;; // Line 4 32 ;; // Line 5 48 …lename: "source.c", directory: "/", source: "// Line 1\0A// Line 2\0Avoid foo() {}\0A// Line 4\0A/…
|
/llvm-project/llvm/test/DebugInfo/PDB/DIA/ |
H A D | pdbdump-linenumbers.test | 5 ; LINE_NUMS_FPO: Line 5, Address: [0x000011a0 - 0x000011a5] (6 bytes) 6 ; LINE_NUMS_FPO: Line 6, Address: [0x000011a6 - 0x000011a6] (1 bytes) 9 ; LINE_NUMS: Line 6, Address: [0x00001060 - 0x00001066] (7 bytes) 10 ; LINE_NUMS: Line 80, Address: [0x000010d0 - 0x000010d1] (2 bytes) 11 ; LINE_NUMS: Line 81, Address: [0x000010d2 - 0x000010d5] (4 bytes) 12 ; LINE_NUMS: Line 28, Address: [0x00001170 - 0x0000117a] (11 bytes) 13 ; LINE_NUMS: Line 21, Address: [0x00001180 - 0x0000118a] (11 bytes) 14 ; LINE_NUMS: Line 20, Address: [0x00001190 - 0x0000119a] (11 bytes)
|
/llvm-project/llvm/lib/IR/ |
H A D | LLVMContextImpl.h | 317 unsigned Line; 323 MDNodeKeyImpl(unsigned Line, unsigned Column, Metadata *Scope, 325 : Line(Line), Column(Column), Scope(Scope), InlinedAt(InlinedAt), 328 : Line(L->getLine()), Column(L->getColumn()), Scope(L->getRawScope()), 332 return Line == RHS->getLine() && Column == RHS->getColumn() && 338 return hash_combine(Line, Column, Scope, InlinedAt, ImplicitCode); 543 unsigned Line; 555 MDNodeKeyImpl(unsigned Tag, MDString *Name, Metadata *File, unsigned Line, 561 : Tag(Tag), Name(Name), File(File), Line(Lin [all...] |
/llvm-project/compiler-rt/lib/xray/ |
H A D | xray_powerpc64.cpp | 37 for (intptr_t Line = StartLine; Line < EndLine; Line += LineSize) in clearCache() local 38 asm volatile("dcbf 0, %0" : : "r"(Line)); in clearCache() 41 for (intptr_t Line = StartLine; Line < EndLine; Line += LineSize) in clearCache() local 42 asm volatile("icbi 0, %0" : : "r"(Line)); in clearCache()
|
/llvm-project/lldb/tools/lldb-test/ |
H A D | FormatUtil.h | 28 class Line { 32 Line(LinePrinter &P) : P(&P) { P.OS.indent(P.CurrentIndent); } in Line() function 33 ~Line(); 35 Line(Line &&RHS) : P(RHS.P) { RHS.P = nullptr; } in Line() function 36 void operator=(Line &&) = delete; 57 Line line() { return Line(*this); } in line()
|
/llvm-project/clang/unittests/Format/ |
H A D | FormatTestBase.h | 83 bool _verifyFormat(const char *File, int Line, StringRef Expected, 87 testing::ScopedTrace t(File, Line, testing::Message() << Code.str()); 114 void _verifyFormat(const char *File, int Line, StringRef Code, 116 if (!_verifyFormat(File, Line, Code, Code, Style)) 119 _verifyFormat(File, Line, Code, MessedUpCode, Style); 122 void _verifyIncompleteFormat(const char *File, int Line, StringRef Code, 124 testing::ScopedTrace t(File, Line, testing::Message() << Code.str()); 129 _verifyIndependentOfContext(const char *File, int Line, StringRef Text, 131 _verifyFormat(File, Line, Text, Style); 132 _verifyFormat(File, Line, Twin [all...] |