[PATCH] D77794: [clangd] Pull installed gRPC and introduce shared-index-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257240. kbobyrev marked 19 inline comments as done. kbobyrev added a comment. Address a bunch of comments (still a couple left though). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257270. kbobyrev marked 6 inline comments as done. kbobyrev added a comment. Improve CMake infrastructure. - Move client and server into separate directories and enable LLVM's error logic - Address a bunch of comments regarding flags enabling gRPC & remote i

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev planned changes to this revision. kbobyrev added a comment. Still need to do: - Add documentation for enabling gRPC - Simplify `clangd-index-(server|client)` as proposed - Find out why lookup is working differently than in Dexp (debug a little bit, I'm pretty sure there is some minor bu

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/CMakeLists.txt:156 + +option(GRPC_INSTALL_PATH "Path to gRPC library installation." OFF) +if (GRPC_INSTALL_PATH) sammccall wrote: > sammccall wrote: > > sammccall wrote: > > > We'll eventually w

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257334. kbobyrev marked 3 inline comments as done. kbobyrev added a comment. Improve CMake machinery and cleanup code Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llvm.org/D77794 F

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257341. kbobyrev marked 2 inline comments as done. kbobyrev added a comment. Give gRPC and Protobuf libraries better names in CMake. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llv

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/CMakeLists.txt:19 +add_library(gRPCProtos ${Index_proto_source} ${Index_grpc_header} ${Index_grpc_source} ${Index_grpc_header}) +target_link_libraries(gRPCProtos gRPC::grpc++ protobuf::libprotobuf)

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257353. kbobyrev added a comment. Alias libraries in CMake: gRPC::grpc++ to grpc++ and protobuf::libprotobuf to protobuf. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llvm.org/D777

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257658. kbobyrev marked 14 inline comments as done. kbobyrev added a comment. Address the current round of comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llvm.org/D77794 Fi

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257659. kbobyrev added a comment. Trim dexp output in remote index README. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llvm.org/D77794 Files: clang-tools-extra/clangd/CMakeLists

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked an inline comment as done. kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/CMakeLists.txt:194 + + add_definitions(-DGOOGLE_PROTOBUF_NO_RTTI=1) + include_directories(${Protobuf_INCLUDE_DIRS}) sammccall wrote: > these global s

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257664. kbobyrev added a comment. Fix protobuf & grpc_cpp_plugin settings in system-installed libs scenario and confirm that everything works as expected with -DLLVM_OPTIMIZED_TABLEGEN=On. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D78089: [dexp] NFC: Change positional argument format

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGf05867339737: [dexp] NFC: Change positional argument format (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78089/new/ https://reviews

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 257893. kbobyrev marked 18 inline comments as done. kbobyrev added a comment. Address a bunch of comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77794/new/ https://reviews.llvm.org/D77794 Files: cla

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. Prevent a second pair of parenthesis from being added when there already is one right after c

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/CodeComplete.cpp:1283 + Recorder->CCSema->getSourceManager(), Recorder->CCSema->LangOpts); + HasParenthesisAfter = NextToken->getKind() == tok::l_paren; auto Style = getFormatStyleForFile(Se

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 269430. kbobyrev marked 9 inline comments as done. kbobyrev added a comment. Make sure snippets are omitted only in the function/method/constructor calls for safety and extend the testset. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/CodeComplete.cpp:1715 +CCContextKind, Opts, !IsUsingDeclaration, +NextTokenKind); else sammccall wrote: > now you've got the "should we gen

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 269464. kbobyrev marked 4 inline comments as done. kbobyrev added a comment. Address most comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D81380/new/ https://reviews.llvm.org/D81380 Files: clang-tool

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 269471. kbobyrev marked 2 inline comments as done. kbobyrev added a comment. Don't split the snippet omitting logic between the builder and its caller. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D81380/new/

[PATCH] D81380: [clangd] Don't produce snippets when completion location is followed by parenthesis

2020-06-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG348364bffd37: [clangd] Don't produce snippets when completion location is followed by… (authored by kbobyrev). Changed prior to commit: https://reviews.llvm.org/D81380?vs=269471&id=269501#toc Repositor

[PATCH] D82844: [clangd] Set gRPC deadlines to all remote index requests

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 274744. kbobyrev marked 2 inline comments as done. kbobyrev added a comment. Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82844/new/ https://reviews.llvm.org/D82844 Files: clang-to

[PATCH] D82844: [clangd] Set gRPC deadlines to all remote index requests

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG22a3e4055f43: [clangd] Set gRPC deadlines to all remote index requests (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82844/new/ http

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-06 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/marshalling/Marshalling.cpp:61 + if (IndexedProjectRoot.empty()) +return static_cast(Result); + llvm::sys::path::replace_path_prefix(Result, IndexedProjectRoot, ""); sammccall

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-06 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275613. kbobyrev marked 19 inline comments as done. kbobyrev added a comment. Store the progress so that I don't lose it. Still WIP. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llv

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-06 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275672. kbobyrev added a comment. Use std::string() instead of static_cast() Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang-tools-extra/clangd/index/de

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-06 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275670. kbobyrev added a comment. Remove IndexRoot conversion to UNIX slashes from the Marshalling hot path. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: c

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-06 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275667. kbobyrev marked 12 inline comments as done. kbobyrev added a comment. Resolve the rest of patch comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275929. kbobyrev marked 7 inline comments as done. kbobyrev added a comment. Hide FoldingRanges feature behind the flag. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 275945. kbobyrev added a comment. Don't convert test paths to system native, UNIX native is good enough. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/FindSymbols.cpp:281 + Range.startCharacter = Symbol.range.start.character; + Range.endLine = Symbol.range.end.line; + Range.endCharacter = Symbol.range.end.character; sammccall wrote: > kboby

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276029. kbobyrev added a comment. Convert prefix paths to native slash format for _serialization_ calls (deserializations should use UNIX slashes). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ http

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-07 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276030. kbobyrev added a comment. Add assertions for ensuring paths have UNIX slashes during deserialization. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files:

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276366. kbobyrev marked 12 inline comments as done. kbobyrev added a comment. Store progress. Still WIP. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked 2 inline comments as done. kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/unittests/remote/MarshallingTests.cpp:25 +const char *unittestURIToFilesystem(const char *UnittestURI, +llvm::UniqueStringSaver &S

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-08 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276454. kbobyrev marked 10 inline comments as done. kbobyrev added a comment. Address the rest of the comments and refactor code. Patch is ready for the review again. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276642. kbobyrev added a comment. Fix formatting on one line. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276646. kbobyrev added a comment. Rebase on top of master Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp c

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276647. kbobyrev added a comment. Replace Sym in Client response with a more generic name (it can be a reference). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 File

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 276692. kbobyrev marked 15 inline comments as done. kbobyrev added a comment. Address post-LGTM round of comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 File

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG93bb9944cb57: [clangd] Implement path and URI translation for remote index (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked an inline comment as done. kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/marshalling/Marshalling.cpp:64 + if (ParsedURI->scheme() != "file") { +elog("Can not parse URI with scheme other than \"file\" {0}", URI); +return

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-09 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked an inline comment as done. kbobyrev added a comment. In D82436#2141953 , @sammccall wrote: > Tests :-) I was hoping glorious DocumentSymbols super tested API would shield me from that :P Didn't think of reasonable testing strategy but fa

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277357. kbobyrev marked 4 inline comments as done. kbobyrev added a comment. Add tests and fix DocumentSymbol ranges. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 F

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277359. kbobyrev added a comment. Updated a couple of comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 Files: clang-tools-extra/clangd/ClangdLSPServer.cpp

[PATCH] D83668: [clangd] Fix DocumentSymbol ranges

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. DocumentSymbol ranges were not previously tested and, as a result, had invalid end location.

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277381. kbobyrev marked 5 inline comments as done. kbobyrev added a comment. Isolate DocumentSymbol range changes into D83668 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277382. kbobyrev added a comment. Rebase on top of master. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 Files: clang-tools-extra/clangd/ClangdLSPServer.cpp clan

[PATCH] D83668: [clangd] Fix DocumentSymbol ranges

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277387. kbobyrev added a comment. Use open half ranges for all symbol kinds, adjust variable ranges in tests. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83668/new/ https://reviews.llvm.org/D83668 Files:

[PATCH] D83668: [clangd] Fix DocumentSymbol ranges

2020-07-13 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd7d1af39168c: [clangd] Fix DocumentSymbol ranges (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83668/new/ https://reviews.llvm.org/D

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277683. kbobyrev marked an inline comment as done. kbobyrev added a comment. Remove llvm::Optional from character fields. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D8243

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG7a514c9bf8f2: [clangd] Implement textDocument/foldingRange (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov, mgorny. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D83817 Files: clang-tools-extra/clangd/CMakeLists.txt

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 277985. kbobyrev added a comment. Remove unintended change. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83817/new/ https://reviews.llvm.org/D83817 Files: clang-tools-extra/clangd/CMakeLists.txt clang-to

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev planned changes to this revision. kbobyrev added a comment. Just stash changes, this is not a patch that is ready for a review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83817/new/ https://reviews.llvm.org/D83817 ___

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. Remote server should not send messages that are invalid and will cause problems on the client

[PATCH] D83827: [clangd] Use llvm::errs() instead of outs() for errors

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. errs() is more appropriate for error messages in dexp and clangd-index-server. Repository:

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278008. kbobyrev added a comment. Also do not attempt to use callback on unserialized messages. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83826/new/ https://reviews.llvm.org/D83826 Files: clang-tools-ex

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278012. kbobyrev added a comment. Don't touch Marshalling.cpp Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83817/new/ https://reviews.llvm.org/D83817 Files: clang-tools-extra/clangd/CMakeLists.txt clang-

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278013. kbobyrev added a comment. Remove remaining changes from Marshalling.cpp Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83817/new/ https://reviews.llvm.org/D83817 Files: clang-tools-extra/clangd/CMake

[PATCH] D83817: [clangd] Add remote index support for Clangd itself

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev planned changes to this revision. kbobyrev added a comment. Still WIP, stashing changes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83817/new/ https://reviews.llvm.org/D83817 ___ cfe-commit

[PATCH] D83831: [clangd] Add more logs and attach tracers to remote index server routines

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D83831 Files: clang-tools-

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278022. kbobyrev added a comment. Use the same style for elog messages (1-based indexing, message format). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83826/new/ https://reviews.llvm.org/D83826 Files: cla

[PATCH] D83831: [clangd] Add more logs and attach tracers to remote index server routines

2020-07-14 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278081. kbobyrev added a comment. Rebase on top of parent revision, add more logging on the client side. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83831/new/ https://reviews.llvm.org/D83831 Files: clang

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278086. kbobyrev added a comment. Don't allow empty paths. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83826/new/ https://reviews.llvm.org/D83826 Files: clang-tools-extra/clangd/index/remote/Client.cpp

[PATCH] D83827: [clangd] Use llvm::errs() instead of outs() for errors

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc11c78a1bd0b: [clangd] Use llvm::errs() instead of outs() for errors (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83827/new/ https:

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked 4 inline comments as done. kbobyrev added a comment. In D83826#2152857 , @sammccall wrote: > > Also add more error messages and logs. > > I'm not sure about the error-handling strategy here: > > - it's very verbose in the marshalling code.

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278162. kbobyrev marked an inline comment as done. kbobyrev added a comment. Small update: resolve a couple of comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83826/new/ https://reviews.llvm.org/D83826

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278170. kbobyrev added a comment. Use DebugStrings instead of ShortDebugStrings. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83826/new/ https://reviews.llvm.org/D83826 Files: clang-tools-extra/clangd/inde

[PATCH] D83831: [clangd] Add more logs and attach tracers to remote index server routines

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278237. kbobyrev marked 5 inline comments as done. kbobyrev added a comment. Resolve the comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83831/new/ https://reviews.llvm.org/D83831 Files: clang-tools

[PATCH] D83831: [clangd] Add more logs and attach tracers to remote index server routines

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/server/Server.cpp:63 +trace::Span Tracer("Remote index server Lookup"); +SPAN_ATTACH(Tracer, "LookupRequest", Request->ShortDebugString()); clangd::LookupRequest Req; s

[PATCH] D83826: [clangd] Don't send invalid messages from remote index

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev planned changes to this revision. kbobyrev added a comment. Wrap marshalling into a class, think about filtering vs failing? I think filtering should be done on the clangd-indexer side and marshalling should deal with **valid** symbols only and shouldn't have to filter them. Repositor

[PATCH] D83914: [clangd] Plan features for FoldingRanges

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. This is not an actual patch, this is an RFC + TDD plan for future RAV implementation. Hopeful

[PATCH] D83914: [clangd] Plan features for FoldingRanges

2020-07-15 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 278327. kbobyrev added a comment. Fix some typos. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83914/new/ https://reviews.llvm.org/D83914 Files: clang-tools-extra/clangd/unittests/SemanticSelectionTests.cp

[PATCH] D82354: [clangd] Implement RepoScheme for portable URIs

2020-06-23 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. This is not a complete patch, but rather RFC: while the schema implementation itself does not

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-06-24 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. This patch introduces basic textDocument/foldingRange support. It relies on textDocument/docu

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-06-29 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added a comment. @sammccall ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.

[PATCH] D82844: [clangd] Set gRPC deadlines to all remote index requests

2020-06-30 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. "TL;DR: Always set a deadline.", https://grpc.io/blog/deadlines/ Repository: rG LLVM Gith

[PATCH] D82642: [clangd] Run formatting operations asynchronously.

2020-06-30 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev accepted this revision. kbobyrev added a comment. This revision is now accepted and ready to land. Looks nice just a couple of nits. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:900 + llvm::Expected Result) mutable { +if (Result) +

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. kbobyrev updated this revision to Diff 274719. kbobyrev added a comment. Herald added a subscr

[PATCH] D82938: [clangd] Implement path and URI translation for remote index

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 274719. kbobyrev added a comment. Herald added a subscriber: ormris. %s/PrefixPath/ProjectRoot/g Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82938/new/ https://reviews.llvm.org/D82938 Files: clang-tools-e

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 274743. kbobyrev added a comment. Remove unused variable. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 Files: clang-tools-extra/clangd/ClangdLSPServer.cpp clang

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 274741. kbobyrev marked 7 inline comments as done. kbobyrev added a comment. Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82436/new/ https://reviews.llvm.org/D82436 Files: clang-to

[PATCH] D82436: [clangd] Implement textDocument/foldingRange

2020-07-01 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/FindSymbols.cpp:281 + Range.startCharacter = Symbol.range.start.character; + Range.endLine = Symbol.range.end.line; + Range.endCharacter = Symbol.range.end.character; sammccall wrote: > How u

[PATCH] D77794: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client)

2020-04-16 Thread Kirill Bobyrev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcee80c0489e9: [clangd] Pull installed gRPC and introduce clangd-remote-(server|client) (authored by kbobyrev). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-20 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev created this revision. kbobyrev added a reviewer: sammccall. Herald added subscribers: cfe-commits, usaxena95, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov, mgorny. Herald added a project: clang. - Make it possible for dexp to use remote server - Remove clangd-index-client (since

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-20 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 258861. kbobyrev added a comment. Fix build. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-extra/clangd/CMakeLists.txt clang-tools-extra/clang

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-20 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev marked 5 inline comments as done. kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/dex/dexp/Dexp.cpp:14 +#include "Index.grpc.pb.h" #include "SourceCode.h" sammccall wrote: > this include and the stuff depending on it needs t

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-21 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 258936. kbobyrev marked 2 inline comments as done. kbobyrev added a comment. Implement refs(), address some comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 F

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-21 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 258942. kbobyrev added a comment. Add correct definition and fix build. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-extra/clangd/CMakeLists.tx

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-21 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 258958. kbobyrev added a comment. Move type conversions to Marshalling.(h|cpp) and hide IndexClient behind a factory function. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-21 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259167. kbobyrev added a comment. Resolve a couple of FIXMEs. The patch is review-ready now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-extra

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-22 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259233. kbobyrev marked an inline comment as done. kbobyrev added a comment. Make sure the value of `--remote` flag is stored. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-22 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259257. kbobyrev added a comment. Stream responses in refs() and fuzzyFind() Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-extra/clangd/CMakeLis

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-22 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259356. kbobyrev marked 10 inline comments as done. kbobyrev added a comment. Just a checkpoint: resolve several comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D785

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-22 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/Index.proto:37 +message FuzzyFindReply { + // FIXME(kirillbobyrev): Convert to Symbol. + repeated string symbols = 1; sammccall wrote: > kbobyrev wrote: > > sammccall wrote: > > >

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-23 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/index/remote/Index.cpp:97 +std::unique_ptr connect(llvm::StringRef Address) { +#ifdef CLANGD_REMOTE + return std::unique_ptr(new IndexClient(Address)); sammccall wrote: > if remote is disabled

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-23 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259547. kbobyrev marked 13 inline comments as done. kbobyrev added a comment. Address the remaining comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files:

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-23 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259553. kbobyrev added a comment. Convert plain function pointers to std::function in templates. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-e

[PATCH] D78521: [clangd] Extend dexp to support remote index

2020-04-23 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev updated this revision to Diff 259604. kbobyrev added a comment. Implement (B) for now Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D78521/new/ https://reviews.llvm.org/D78521 Files: clang-tools-extra/clangd/CMakeLists.txt clang-tools-

<    1   2   3   4   5   6   7   8   9   10   >