[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-17 Thread Nathan Ridge via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG15673d748acd: [clangd] Index refs to main-file symbols as well (authored by nridge). Changed prior to commit: https://reviews.llvm.org/D83536?vs=285920&id=286194#toc Repository: rG LLVM Github Monore

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-17 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/unittests/SymbolCollectorTests.cpp:727 + // Run the collector again with CollectMainFileRefs = true. + InMemoryFileSystem = new llvm::vfs::InMemoryFileSystem(); + CollectorOpts.CollectMainFileRefs = true; ---

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-17 Thread Nathan Ridge via Phabricator via cfe-commits
nridge added inline comments. Comment at: clang-tools-extra/clangd/unittests/SymbolCollectorTests.cpp:727 + // Run the collector again with CollectMainFileRefs = true. + InMemoryFileSystem = new llvm::vfs::InMemoryFileSystem(); + CollectorOpts.CollectMainFileRefs = true; -

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-17 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet accepted this revision. kadircet added a comment. This revision is now accepted and ready to land. thanks, LGTM! Comment at: clang-tools-extra/clangd/unittests/SymbolCollectorTests.cpp:727 + // Run the collector again with CollectMainFileRefs = true. + InMemoryFileSy

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-16 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 285920. nridge added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 Files: clang-tools-extra/clangd/ClangdServer.cpp clang-tools-extra/clangd/Clan

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-16 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 285907. nridge marked 4 inline comments as done. nridge added a comment. Address review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 Files: clang-tools-ext

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-11 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added a comment. thanks, lgtm. mostly comments arounds tests, sorry for not looking at them before. Comment at: clang-tools-extra/clangd/index/FileIndex.h:156 /// Exposed to assist in unit tests. -SlabTuple indexMainDecls(ParsedAST &AST); +SlabTuple indexMainDecls(Pa

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 284576. nridge marked 4 inline comments as done. nridge added a comment. Address review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 Files: clang-tools-ext

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-10 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/index/Background.h:143 + std::function ContextProvider = nullptr, + bool CollectMainFileRefs = true); ~BackgroundIndex(); // Blocks while the current task finishes. please set the d

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-09 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 284262. nridge added a comment. Add the requested flag Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 Files: clang-tools-extra/clangd/ClangdServer.cpp clang-tools-e

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-04 Thread Nathan Ridge via Phabricator via cfe-commits
nridge planned changes to this revision. nridge added a comment. Still need to add the flag. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 ___ cfe-commits maili

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-08-04 Thread Nathan Ridge via Phabricator via cfe-commits
nridge updated this revision to Diff 283134. nridge added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536 Files: clang-tools-extra/clangd/index/SymbolCollector.cpp clang-tools-extra/cl

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-07-13 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added a comment. In D83536#2144282 , @nridge wrote: > I can do that. > > Another thing we could consider, if the space increase is a concern, is to > limit which references we store, e.g. to functions only (not variables or > classes). Yes, th

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-07-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge added a comment. In D83536#2143436 , @kadircet wrote: > I can see how this is needed for implementing the full protocol though (we've > already cut on the multi-level callees support), so would you be so kind to > hide this behind an option to sym

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-07-10 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added a comment. Thanks a lot for doing this Nathan and sorry for not replying with a concrete decision on the issue tracker, we were still discussing it internally, as 7% increase for allowing multi-level call hierarchy support (compared to ~10% initial cost for single-level support)

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-07-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge added a comment. (As per discussion in https://github.com/clangd/clangd/issues/162#issuecomment-648923948 onwards.) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83536/new/ https://reviews.llvm.org/D83536

[PATCH] D83536: [clangd] Index refs to main-file symbols as well

2020-07-10 Thread Nathan Ridge via Phabricator via cfe-commits
nridge created this revision. nridge added a reviewer: kadircet. Herald added subscribers: cfe-commits, usaxena95, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. This will be needed to support call hierarchy Repository: rG LLVM Github Monorepo https://reviews.llvm.