/freebsd/contrib/llvm-project/llvm/include/llvm/Support/ |
H A D | SourceMgr.h | 31 class SourceMgr { 96 SourceMgr() = default; 97 SourceMgr(const SourceMgr &) = delete; 98 SourceMgr &operator=(const SourceMgr &) = delete; 99 SourceMgr(SourceMgr &&) = default; 100 SourceMgr &operator=(SourceMgr &&) = default; 101 ~SourceMgr() = default; 157 void takeSourceBuffersFrom(SourceMgr &SrcMgr, 282 const SourceMgr *SM = nullptr; 287 SourceMgr::DiagKind Kind = SourceMgr::DK_Error; [all …]
|
/freebsd/contrib/llvm-project/llvm/tools/llvm-mca/ |
H A D | CodeRegion.cpp | 54 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Error, in beginRegion() 62 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Error, in beginRegion() 64 SM.PrintMessage(R.startLoc(), llvm::SourceMgr::DK_Note, in beginRegion() 104 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Error, in endRegion() 107 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Note, in endRegion() 110 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Note, in endRegion() 120 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Error, in beginRegion() 130 Loc, llvm::SourceMgr::DK_Error, in beginRegion() 132 SM.PrintMessage(R.startLoc(), llvm::SourceMgr::DK_Note, in beginRegion() 153 SM.PrintMessage(Loc, llvm::SourceMgr::DK_Error, in endRegion() [all …]
|
/freebsd/contrib/llvm-project/clang/lib/AST/ |
H A D | RawCommentList.cpp | 130 SourceMgr.getDecomposedLoc(Range.getBegin()); in RawComment() 160 SourceMgr.getDecomposedLoc(Range.getBegin()); in getRawTextSlow() 285 SourceMgr.getDecomposedLoc(RC.getBeginLoc()); in addComment() 317 commentsStartOnSameColumn(SourceMgr, C1, C2))) && in addComment() 322 RawComment(SourceMgr, MergedRange, CommentOpts, true); in addComment() 362 llvm::StringRef CommentText = getRawText(SourceMgr); in getFormattedText() 368 getFormattedLines(SourceMgr, Diags)) in getFormattedText() 378 RawComment::getFormattedLines(const SourceManager &SourceMgr, in getFormattedLines() argument 380 llvm::StringRef CommentText = getRawText(SourceMgr); in getFormattedLines() 429 llvm::StringRef TokText = L.getSpelling(Tok, SourceMgr); in getFormattedLines() [all …]
|
/freebsd/contrib/llvm-project/clang/include/clang/AST/ |
H A D | RawCommentList.h | 47 RawComment(const SourceManager &SourceMgr, SourceRange SR, 98 StringRef getRawText(const SourceManager &SourceMgr) const { in getRawText() argument 102 RawText = getRawTextSlow(SourceMgr); in getRawText() 118 bool hasUnsupportedSplice(const SourceManager &SourceMgr) const { in hasUnsupportedSplice() argument 121 StringRef Text = getRawText(SourceMgr); in hasUnsupportedSplice() 150 std::string getFormattedText(const SourceManager &SourceMgr, 165 std::vector<CommentLine> getFormattedLines(const SourceManager &SourceMgr, 198 StringRef getRawTextSlow(const SourceManager &SourceMgr) const; 209 RawCommentList(SourceManager &SourceMgr) : SourceMgr(SourceMgr) {} in RawCommentList() argument 225 SourceManager &SourceMgr;
|
/freebsd/contrib/llvm-project/llvm/lib/TableGen/ |
H A D | Error.cpp | 24 SourceMgr SrcMgr; 27 static void PrintMessage(ArrayRef<SMLoc> Loc, SourceMgr::DiagKind Kind, in PrintMessage() 31 if (Kind == SourceMgr::DK_Error) in PrintMessage() 39 SrcMgr.PrintMessage(Loc[i], SourceMgr::DK_Note, in PrintMessage() 50 PrintMessage(NoteLoc, SourceMgr::DK_Note, Msg); in PrintNote() 92 PrintMessage(WarningLoc, SourceMgr::DK_Warning, Msg); in PrintWarning() 96 SrcMgr.PrintMessage(SMLoc::getFromPointer(Loc), SourceMgr::DK_Warning, Msg); in PrintWarning() 104 PrintMessage(ErrorLoc, SourceMgr::DK_Error, Msg); in PrintError() 108 SrcMgr.PrintMessage(SMLoc::getFromPointer(Loc), SourceMgr::DK_Error, Msg); in PrintError() 114 PrintMessage(Rec->getLoc(), SourceMgr::DK_Error, Msg); in PrintError() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/FileCheck/ |
H A D | FileCheckImpl.h | 146 getImplicitFormat(const SourceMgr &SM) const { in getImplicitFormat() 293 getImplicitFormat(const SourceMgr &SM) const override { in getImplicitFormat() 333 getImplicitFormat(const SourceMgr &SM) const override; 457 SourceMgr &SM); 675 FileCheckPatternContext *Context, const SourceMgr &SM); 713 void printFuzzyMatch(const SourceMgr &SM, StringRef Buffer, 749 const SourceMgr &SM); 758 FileCheckPatternContext *Context, const SourceMgr &SM); 786 const SourceMgr &SM); 857 bool CheckNot(const SourceMgr &SM, StringRef Buffer, [all …]
|
H A D | FileCheck.cpp | 333 const SourceMgr &SM) { in parseNumericVariableDefinition() 406 const SourceMgr &SM) { in parseNumericOperand() 782 PatternLoc, SourceMgr::DK_Error, in parsePattern() 826 SourceMgr::DK_Error, in parsePattern() 870 SourceMgr::DK_Error, in parsePattern() 1773 SourceMgr &SM, StringRef Buffer, in readCheckFile() 1861 SourceMgr::DK_Error, in readCheckFile() 1922 SourceMgr::DK_Error, in readCheckFile() 2018 Loc, ExpectedMatch ? SourceMgr::DK_Remark : SourceMgr::DK_Error, Message); in printMatch() 2111 ExpectedMatch ? SourceMgr::DK_Error : SourceMgr::DK_Remark, in printNoMatch() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Support/ |
H A D | SourceMgr.cpp | 41 unsigned SourceMgr::AddIncludeFile(const std::string &Filename, in AddIncludeFile() 53 SourceMgr::OpenIncludeFile(const std::string &Filename, in OpenIncludeFile() 170 SourceMgr::SrcBuffer::SrcBuffer(SourceMgr::SrcBuffer &&Other) in SrcBuffer() 176 SourceMgr::SrcBuffer::~SrcBuffer() { in ~SrcBuffer() 274 SMDiagnostic SourceMgr::GetMessage(SMLoc Loc, SourceMgr::DiagKind Kind, in GetMessage() 352 void SourceMgr::PrintMessage(raw_ostream &OS, SMLoc Loc, in PrintMessage() 359 void SourceMgr::PrintMessage(SMLoc Loc, SourceMgr::DiagKind Kind, in PrintMessage() 511 case SourceMgr::DK_Error: in print() 514 case SourceMgr::DK_Warning: in print() 517 case SourceMgr::DK_Note: in print() [all …]
|
/freebsd/contrib/llvm-project/clang/lib/Format/ |
H A D | UsingDeclarationsSorter.cpp | 139 const SourceManager &SourceMgr, tooling::Replacements *Fixes, in endUsingDeclarationBlock() argument 187 StringRef Text(SourceMgr.getCharacterData(SortedBegin), in endUsingDeclarationBlock() 188 SourceMgr.getCharacterData(SortedEnd) - in endUsingDeclarationBlock() 189 SourceMgr.getCharacterData(SortedBegin)); in endUsingDeclarationBlock() 191 StringRef OldText(SourceMgr.getCharacterData(Begin), in endUsingDeclarationBlock() 192 SourceMgr.getCharacterData(End) - in endUsingDeclarationBlock() 193 SourceMgr.getCharacterData(Begin)); in endUsingDeclarationBlock() 215 const SourceManager &SourceMgr = Env.getSourceManager(); in analyze() local 223 endUsingDeclarationBlock(&UsingDeclarations, SourceMgr, &Fixes, in analyze() 228 endUsingDeclarationBlock(&UsingDeclarations, SourceMgr, &Fixes, in analyze() [all …]
|
H A D | QualifierAlignmentFixer.cpp | 57 static void replaceToken(const SourceManager &SourceMgr, in replaceToken() argument 69 static void removeToken(const SourceManager &SourceMgr, in removeToken() argument 74 replaceToken(SourceMgr, Fixes, Range, ""); in removeToken() 77 static void insertQualifierAfter(const SourceManager &SourceMgr, in insertQualifierAfter() argument 87 replaceToken(SourceMgr, Fixes, Range, NewText); in insertQualifierAfter() 100 replaceToken(SourceMgr, Fixes, Range, NewText); in insertQualifierBefore() 115 static void rotateTokens(const SourceManager &SourceMgr, in rotateTokens() argument 152 replaceToken(SourceMgr, Fixes, Range, NewText); in rotateTokens() 362 replaceToken(SourceMgr, Fixes, Range, ""); in analyzeRight() 503 removeToken(SourceMgr, Fixes, Tok); in analyzeLeft() [all …]
|
H A D | AffectedRangeManager.h | 27 AffectedRangeManager(const SourceManager &SourceMgr, in AffectedRangeManager() argument 29 : SourceMgr(SourceMgr), Ranges(Ranges.begin(), Ranges.end()) {} in AffectedRangeManager() 58 const SourceManager &SourceMgr; variable
|
H A D | WhitespaceManager.h | 42 WhitespaceManager(const SourceManager &SourceMgr, const FormatStyle &Style, in WhitespaceManager() argument 44 : SourceMgr(SourceMgr), Style(Style), UseCRLF(UseCRLF) {} in WhitespaceManager() 98 IsBeforeInFile(const SourceManager &SourceMgr) : SourceMgr(SourceMgr) {} in IsBeforeInFile() 102 const SourceManager &SourceMgr; 354 const SourceManager &SourceMgr; variable
|
H A D | UnwrappedLineFormatter.h | 34 const SourceManager &SourceMgr, in UnwrappedLineFormatter() argument 37 Keywords(Keywords), SourceMgr(SourceMgr), Status(Status) {} in UnwrappedLineFormatter() 70 const SourceManager &SourceMgr; variable
|
H A D | ObjCPropertyAttributeOrderFixer.cpp | 38 const SourceManager &SourceMgr, tooling::Replacements &Fixes, in sortPropertyAttributes() argument 150 auto Replacement = tooling::Replacement(SourceMgr, Range, NewText); in sortPropertyAttributes() 159 const SourceManager &SourceMgr, const AdditionalKeywords &Keywords, in analyzeObjCPropertyDecl() argument 178 sortPropertyAttributes(SourceMgr, Fixes, LParenTok->Next, RParenTok); in analyzeObjCPropertyDecl() 188 const SourceManager &SourceMgr = Env.getSourceManager(); in analyze() local 209 analyzeObjCPropertyDecl(SourceMgr, Keywords, Fixes, Tok); in analyze()
|
/freebsd/contrib/llvm-project/llvm/tools/llvm-mc/ |
H A D | Disassembler.cpp | 35 SourceMgr &SM, MCStreamer &Streamer, bool InAtomicBlock, in PrintInsts() 51 SourceMgr::DK_Warning, in PrintInsts() 64 SourceMgr::DK_Warning, in PrintInsts() 100 SourceMgr &SM) { in ByteArrayFromString() 114 SM.PrintMessage(SMLoc::getFromPointer(Value.data()), SourceMgr::DK_Error, in ByteArrayFromString() 132 MemoryBuffer &Buffer, SourceMgr &SM, in disassemble() 172 SM.PrintMessage(SMLoc::getFromPointer(Str.data()), SourceMgr::DK_Error, in disassemble() 181 SM.PrintMessage(SMLoc::getFromPointer(Str.data()), SourceMgr::DK_Error, in disassemble() 199 SM.PrintMessage(SMLoc::getFromPointer(Str.data()), SourceMgr::DK_Error, in disassemble()
|
/freebsd/contrib/llvm-project/clang/lib/Lex/ |
H A D | PPConditionalDirectiveRecord.cpp | 19 : SourceMgr(SM) { in PPConditionalDirectiveRecord() 29 CondDirectiveLocs, Range.getBegin(), CondDirectiveLoc::Comp(SourceMgr)); in rangeIntersectsConditionalDirective() 33 if (SourceMgr.isBeforeInTranslationUnit(Range.getEnd(), low->getLoc())) in rangeIntersectsConditionalDirective() 38 Range.getEnd(), CondDirectiveLoc::Comp(SourceMgr)); in rangeIntersectsConditionalDirective() 53 if (SourceMgr.isBeforeInTranslationUnit(CondDirectiveLocs.back().getLoc(), in findConditionalDirectiveRegionLoc() 58 CondDirectiveLocs, Loc, CondDirectiveLoc::Comp(SourceMgr)); in findConditionalDirectiveRegionLoc() 66 if (SourceMgr.isInSystemHeader(DirLoc.getLoc())) in addCondDirectiveLoc() 70 SourceMgr.isBeforeInTranslationUnit(CondDirectiveLocs.back().getLoc(), in addCondDirectiveLoc()
|
H A D | ScratchBuffer.cpp | 24 : SourceMgr(SM), CurBuffer(nullptr) { in ScratchBuffer() 40 SourceMgr.getSLocEntry(SourceMgr.getFileID(BufferStartLoc)) in getToken() 80 FileID FID = SourceMgr.createFileID(std::move(OwnBuf)); in AllocScratchBuffer() 81 BufferStartLoc = SourceMgr.getLocForStartOfFile(FID); in AllocScratchBuffer()
|
H A D | PreprocessingRecord.cpp | 55 PreprocessingRecord::PreprocessingRecord(SourceManager &SM) : SourceMgr(SM) {} in PreprocessingRecord() 111 return isPreprocessedEntityIfInFileID(PPE, FID, SourceMgr); in isEntityInFileID() 123 FID, SourceMgr); in isEntityInFileID() 131 FID, SourceMgr); in isEntityInFileID() 145 if (!ExternalSource || SourceMgr.isLocalSourceLocation(Range.getBegin())) in getPreprocessedEntitiesInRangeSlow() 212 if (SourceMgr.isLoadedSourceLocation(Loc)) in findBeginLocalPreprocessedEntity() 243 if (SourceMgr.isLoadedSourceLocation(Loc)) in findEndLocalPreprocessedEntity() 258 !SourceMgr.isBeforeInTranslationUnit( in addPreprocessedEntity() 268 !SourceMgr.isBeforeInTranslationUnit(BeginLoc, in addPreprocessedEntity() 296 if (!SourceMgr.isBeforeInTranslationUnit(BeginLoc, in addPreprocessedEntity() [all …]
|
/freebsd/contrib/llvm-project/clang/lib/Rewrite/ |
H A D | Rewriter.cpp | 199 const char *Ptr = SourceMgr->getCharacterData(Range.getBegin()); in getRewrittenText() 231 std::pair<FileID, unsigned> V = SourceMgr->getDecomposedLoc(Loc); in getLocationOffsetAndFileID() 244 StringRef MB = SourceMgr->getBufferData(FID); in getEditBuffer() 260 StringRef MB = SourceMgr->getBufferData(FID); in InsertText() 262 unsigned lineNo = SourceMgr->getLineNumber(FID, StartOffs) - 1; in InsertText() 264 &SourceMgr->getSLocEntry(FID).getFile().getContentCache(); in InsertText() 337 StringRef MB = SourceMgr->getBufferData(FID); in ReplaceText() 361 StringRef MB = SourceMgr->getBufferData(FID); in IncreaseIndentation() 364 unsigned startLineNo = SourceMgr->getLineNumber(FID, StartOff) - 1; in IncreaseIndentation() 365 unsigned endLineNo = SourceMgr->getLineNumber(FID, EndOff) - 1; in IncreaseIndentation() [all …]
|
/freebsd/contrib/llvm-project/clang/include/clang/Basic/ |
H A D | SourceMgrAdapter.h | 45 llvm::DenseMap<std::pair<const llvm::SourceMgr *, unsigned>, FileID> 63 SourceLocation mapLocation(const llvm::SourceMgr &LLVMSrcMgr, 68 SourceRange mapRange(const llvm::SourceMgr &LLVMSrcMgr, llvm::SMRange Range); 74 llvm::SourceMgr::DiagHandlerTy getDiagHandler() { in getDiagHandler()
|
/freebsd/contrib/llvm-project/clang/lib/Basic/ |
H A D | SourceMgrAdapter.cpp | 35 SourceLocation SourceMgrAdapter::mapLocation(const llvm::SourceMgr &LLVMSrcMgr, in mapLocation() 81 SourceRange SourceMgrAdapter::mapRange(const llvm::SourceMgr &LLVMSrcMgr, in mapRange() 103 case llvm::SourceMgr::DK_Error: in handleDiag() 107 case llvm::SourceMgr::DK_Warning: in handleDiag() 111 case llvm::SourceMgr::DK_Remark: in handleDiag() 114 case llvm::SourceMgr::DK_Note: in handleDiag()
|
/freebsd/contrib/llvm-project/clang/lib/Edit/ |
H A D | EditedSource.cpp | 37 assert(SourceMgr.isMacroArgExpansion(Loc)); in deconstructMacroArgLoc() 39 SourceMgr.getImmediateExpansionRange(Loc).getBegin(); in deconstructMacroArgLoc() 41 SourceMgr.getImmediateExpansionRange(DefArgLoc).getBegin(); in deconstructMacroArgLoc() 43 while (SourceMgr.isMacroBodyExpansion(ExpansionLoc)) in deconstructMacroArgLoc() 45 SourceMgr.getImmediateExpansionRange(ExpansionLoc).getBegin(); in deconstructMacroArgLoc() 48 Buf, SourceMgr, LangOpts); in deconstructMacroArgLoc() 52 SourceMgr.getSpellingLoc(DefArgLoc)}; in deconstructMacroArgLoc() 81 if (SourceMgr.isMacroArgExpansion(OrigLoc)) { in canInsertInOffset() 119 if (SourceMgr.isMacroArgExpansion(OrigLoc)) { in commitInsert() 445 applyRewrite(receiver, StrVec, CurOffs, CurLen, SourceMgr, LangOpts, in applyRewrites() [all …]
|
H A D | Commit.cpp | 44 : SourceMgr(Editor.getSourceManager()), LangOpts(Editor.getLangOpts()), in Commit() 232 const SourceManager &SM = SourceMgr; in canInsert() 255 SourceLocation spellLoc = SourceMgr.getSpellingLoc(loc); in canInsertAfterToken() 256 unsigned tokLen = Lexer::MeasureTokenLength(spellLoc, SourceMgr, LangOpts); in canInsertAfterToken() 262 const SourceManager &SM = SourceMgr; in canInsertAfterToken() 272 loc = Lexer::getLocForEndOfToken(loc, 0, SourceMgr, LangOpts); in canInsertAfterToken() 298 const SourceManager &SM = SourceMgr; in canRemoveRange() 332 StringRef file = SourceMgr.getBufferData(Offs.getFID(), &invalidTemp); in canReplaceText() 342 return Lexer::isAtStartOfMacroExpansion(loc, SourceMgr, LangOpts, MacroBegin); in isAtStartOfMacroExpansion() 347 return Lexer::isAtEndOfMacroExpansion(loc, SourceMgr, LangOpts, MacroEnd); in isAtEndOfMacroExpansion()
|
/freebsd/contrib/llvm-project/llvm/lib/AsmParser/ |
H A D | Parser.cpp | 27 SourceMgr SM; in parseAssemblyInto() 65 Err = SMDiagnostic(Filename, SourceMgr::DK_Error, in parseAssemblyFile() 108 Err = SMDiagnostic(Filename, SourceMgr::DK_Error, in parseAssemblyFileWithIndex() 146 SourceMgr SM; in parseSummaryIndexAssemblyInto() 173 Err = SMDiagnostic(Filename, SourceMgr::DK_Error, in parseSummaryIndexAssemblyFile() 189 SourceMgr SM; in parseConstantValue() 206 SourceMgr SM; in parseType() 210 SourceMgr::DK_Error, "expected end of string"); in parseType() 218 SourceMgr SM; in parseTypeAtBeginning()
|
/freebsd/contrib/llvm-project/clang/lib/Tooling/Refactoring/Rename/ |
H A D | USRFindingAction.cpp | 235 bool FindSymbol(ASTContext &Context, const SourceManager &SourceMgr, in FindSymbol() argument 238 const FileID MainFileID = SourceMgr.getMainFileID(); in FindSymbol() 240 if (SymbolOffset >= SourceMgr.getFileIDSize(MainFileID)) { in FindSymbol() 246 << SourceMgr.getFileEntryRefForID(MainFileID)->getName() in FindSymbol() 251 const SourceLocation Point = SourceMgr.getLocForStartOfFile(MainFileID) in FindSymbol() 259 FullSourceLoc FullLoc(Point, SourceMgr); in FindSymbol() 289 const SourceManager &SourceMgr = Context.getSourceManager(); in HandleTranslationUnit() local 291 if (!FindSymbol(Context, SourceMgr, Offset, "")) in HandleTranslationUnit() 295 if (!FindSymbol(Context, SourceMgr, 0, QualifiedName)) in HandleTranslationUnit()
|