[PATCH] D93393: [clangd] Ignore the static index refs from the dynamic index files.
Aleksandr Platonov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Dec 17 04:06:58 PST 2020
ArcsinX added a comment.
Thanks for your reply. I have updated the patch (changed signature of `hasFile`), but remote-index scenario is not clear for me yet.
In D93393#2458168 <https://reviews.llvm.org/D93393#2458168>, @sammccall wrote:
> Implementing a pseudo-batch form of hasFiles as an RPC for remote-index: we'd need to give up on getting answers for files one-by-one. That would be OK for an N-way merge (since we'd fetch all results before merging, we could build a list). But servers typically index *everything* under a certain directory, so fetching the list of directories and evaluating per-file queries client-side is a cheap and reasonable alternative (that's more accurate than `return false`!)
Seems I need some clarifications here.
Is it should be like this?:
- [client]->[server] Give me all directories and subdirectories
- [client]<-[server] All directories are .....
IndexClient::indexedFiles() {
<returns function which checks if the file is inside a directory from the list (i.e. full filename starts with a directory from the list)>
}
What structure should be used for directories list? I think we can use Trie
Am I right about your suggestion?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D93393/new/
https://reviews.llvm.org/D93393
More information about the cfe-commits
mailing list