[PATCH] D53363: [clangd] Encode Line/Column as a 32-bits integer.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Nice, just nits! In https://reviews.llvm.org/D53363#1267721, @hokein wrote: > Yeah, I have a rough patch for it, using char* will save us ~50MB memory, > which will lead to ~300 MB memo

[PATCH] D53374: [clangd] Names that are not spelled in source code are reserved.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Idea looks good, I think it needs some renames and index support. Comment at: clangd/AST.h:33 +// `-DName=foo`, the spelling location will be "". +bool SpelledInSourceCode(const Decl *D); + nit: should start with lowercase: `isSpe

[PATCH] D52695: [clang][Parse] Diagnose useless null statements (PR39111)

2018-10-17 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. Ping. Repository: rC Clang https://reviews.llvm.org/D52695 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] r344724 - Fix warning about unused variable [NFC]

2018-10-17 Thread Mikael Holmen via cfe-commits
Author: uabelho Date: Wed Oct 17 23:00:39 2018 New Revision: 344724 URL: http://llvm.org/viewvc/llvm-project?rev=344724&view=rev Log: Fix warning about unused variable [NFC] Modified: clang-tools-extra/trunk/clangd/CodeComplete.cpp Modified: clang-tools-extra/trunk/clangd/CodeComplete.cpp UR

Re: [clang-tools-extra] r344650 - [clang-doc] Add unit tests for serialization

2018-10-17 Thread Mikael Holmén via cfe-commits
On 10/17/2018 08:30 PM, Julie Hockett wrote: > https://reviews.llvm.org/D53381 should fix this -- thanks for the note! Yep, thanks! /Mikael > > Julie > > On Wed, Oct 17, 2018 at 1:58 AM Mikael Holmén > mailto:mikael.hol...@ericsson.com>> wrote: > > Hi Julie, > > clang 3.6.0 compla

[PATCH] D53102: Support for the mno-tls-direct-seg-refs flag

2018-10-17 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM with that one style comment fixed. Comment at: lib/Driver/ToolChains/Clang.cpp:1743 + if (!Args.hasFlag(options::OPT_mtls_direct_seg_refs, + options::O

[PATCH] D53102: Support for the mno-tls-direct-seg-refs flag

2018-10-17 Thread Kristina Brooks via Phabricator via cfe-commits
kristina added a comment. @nruslan This patchset is still pending review so be patient, I landed https://reviews.llvm.org/D53103 as it was reviewed and accepted by the code owner, on which this patch depends on. That said it LGTM, it's simple enough as it just forwards the argument to the backe

[PATCH] D50403: [clang-format]AlignConsecutiveAssignments

2018-10-17 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir added inline comments. Comment at: include/clang/Format/Format.h:85 + /// matching assignment operators. This includes consecutive |=, += + /// -=, /=, *=. This will result in formattings like /// \code Please add tests for these. Also it's not clea

[PATCH] D53025: [clang-tidy] implement new check for const return types.

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: test/clang-tidy/readability-const-value-return.cpp:174 +int **const * n_multiple_ptr(); +int *const & n_pointer_ref(); I'd like to see some more complex examples, like: ``` int const foo(); int const * const foo();

[PATCH] D53382: [clang-doc] Update documentation

2018-10-17 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Will be good idea to mention improvements in Release Notes. Comment at: clang-tools-extra/docs/clang-doc.rst:20 Use -= + Isn't it should be same length as heading? Same in other places. https://reviews.llvm.org/D5338

[PATCH] D52301: [clang] Set TypeSourceInfo for vardecl's in addition to type when we can deduce.

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Thank you for the context and explanation! I don't feel like I have enough familiarity with this machinery to be an effective reviewer for signing off on anything. I've commented with some nits, but @rsmith should give the sign-off on this one.

[PATCH] D52771: [clang-tidy] Non-private member variables in classes (MISRA, CppCoreGuidelines, HICPP)

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D52771#1263404, @lebedev.ri wrote: > FIXME: `IgnoreClassesWithAllMemberVariablesBeingPublic` needs to be somehow > enabled for cppcoreguidelines check. > I don't know if it is possible, and how. IIRC, the idea is to override `getModul

[PATCH] D53387: [clangd] Lay JSONRPCDispatcher to rest.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: ioeric. Herald added subscribers: cfe-commits, kadircet, jfb, arphaman, jkorous, MaskRay, javed.absar, ilya-biryukov, mgorny. Most of its functionality is moved into ClangdLSPServer. The decoupling between JSONRPCDispatcher, ProtocolCal

[PATCH] D52670: [clang-tidy] Add new 'readability-uppercase-literal-suffix' check (CERT DCL16-C, MISRA C:2012, 7.3, MISRA C++:2008, 2-13-4)

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM aside from minor wording nits. Comment at: clang-tidy/readability/UppercaseLiteralSuffixCheck.cpp:31-32 + static constexpr llvm::StringLiteral SkipFirst =

[PATCH] D41648: [clang-tidy] implement cppcoreguidelines macro rules

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. LGTM aside from some minor nits. Comment at: clang-tidy/cppcoreguidelines/MacroUsageCheck.cpp:71 +void MacroUsageCheck::warnMacro(const MacroDirective *MD) { +

r344711 - AMDGPU: Add options to enable/disable code object v3

2018-10-17 Thread Konstantin Zhuravlyov via cfe-commits
Author: kzhuravl Date: Wed Oct 17 14:39:12 2018 New Revision: 344711 URL: http://llvm.org/viewvc/llvm-project?rev=344711&view=rev Log: AMDGPU: Add options to enable/disable code object v3 Differential Revision: https://reviews.llvm.org/D53386 Modified: cfe/trunk/include/clang/Driver/Options.

[PATCH] D53348: [AArch64] Define __ELF__ for aarch64-none-elf and other similar triples.

2018-10-17 Thread Eli Friedman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC344710: [AArch64] Define __ELF__ for aarch64-none-elf and other similar triples. (authored by efriedma, committed by ). Repository: rC Clang https://reviews.llvm.org/D53348 Files: lib/Basic/Targets/

r344710 - [AArch64] Define __ELF__ for aarch64-none-elf and other similar triples.

2018-10-17 Thread Eli Friedman via cfe-commits
Author: efriedma Date: Wed Oct 17 14:07:11 2018 New Revision: 344710 URL: http://llvm.org/viewvc/llvm-project?rev=344710&view=rev Log: [AArch64] Define __ELF__ for aarch64-none-elf and other similar triples. "aarch64-none-elf" is commonly used for AArch64 baremetal toolchains. Differential Revis

[PATCH] D51429: [AArch64] Return Address Signing B Key Support

2018-10-17 Thread Oliver Stannard via Phabricator via cfe-commits
olista01 added inline comments. Comment at: lib/CodeGen/CGDeclCXX.cpp:364 if (RASignKind != CodeGenOptions::SignReturnAddressScope::None) + { Fn->addFnAttr("sign-return-address", LLVM style has the opening brace on the same line as the if. There's a git

[PATCH] D53381: [clang-doc] Bringing bitcode tests in line

2018-10-17 Thread Julie Hockett via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. juliehockett marked an inline comment as done. Closed by commit rL344707: [clang-doc] Bringing bitcode tests in line (authored by juliehockett, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commi

[clang-tools-extra] r344707 - [clang-doc] Bringing bitcode tests in line

2018-10-17 Thread Julie Hockett via cfe-commits
Author: juliehockett Date: Wed Oct 17 13:16:05 2018 New Revision: 344707 URL: http://llvm.org/viewvc/llvm-project?rev=344707&view=rev Log: [clang-doc] Bringing bitcode tests in line Makes bitcode tests line up with what's actually called in the tool. Should fix the failing bot. Also fixes a warn

[PATCH] D53381: [clang-doc] Bringing bitcode tests in line

2018-10-17 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan accepted this revision. leonardchan added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/unittests/clang-doc/BitcodeTest.cpp:39-40 +return writeInfo(*static_cast(I)); + default: +return ""; + } ---

[PATCH] D53382: [clang-doc] Update documentation

2018-10-17 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett created this revision. juliehockett added reviewers: leonardchan, jakehehrlich, lebedev.ri. juliehockett added a project: clang-tools-extra. https://reviews.llvm.org/D53382 Files: clang-tools-extra/docs/clang-doc.rst Index: clang-tools-extra/docs/clang-doc.rst ===

Re: [clang-tools-extra] r344650 - [clang-doc] Add unit tests for serialization

2018-10-17 Thread Julie Hockett via cfe-commits
https://reviews.llvm.org/D53381 should fix this -- thanks for the note! Julie On Wed, Oct 17, 2018 at 1:58 AM Mikael Holmén wrote: > Hi Julie, > > clang 3.6.0 complains on this commit: > > /usr/bin/clang++ -march=corei7 -DGTEST_HAS_RTTI=0 > -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_LANG_CXX11=1 -D_DEBU

[PATCH] D53381: [clang-doc] Bringing bitcode tests in line

2018-10-17 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett created this revision. juliehockett added reviewers: leonardchan, jakehehrlich, lebedev.ri. juliehockett added a project: clang-tools-extra. Herald added subscribers: kadircet, arphaman. Makes bitcode tests line up with what's actually called in the tool. Should fix the failing bot.

[PATCH] D53377: [clang-tidy] Ignore a case where the fix of make_unique check introduces side effect.

2018-10-17 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons accepted this revision. malcolm.parsons added a comment. This revision is now accepted and ready to land. LGTM. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53377 ___ cfe-commits mailing list cfe-commits@lists.llvm

[PATCH] D46013: [ARM] Conform to AAPCS when passing overaligned composites as arguments

2018-10-17 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Starting multiple threads on the LLVM mailing lists with the same message is spam. Please don't do that. If you think you've run into a bug, file a bug report at bugs.llvm.org. For general questions, send an email to llvm-dev. Repository: rC Clang https://review

r344702 - Fix for arm bots afternew PM pass port. Prevent cross compiling on arm.

2018-10-17 Thread Leonard Chan via cfe-commits
Author: leonardchan Date: Wed Oct 17 11:12:18 2018 New Revision: 344702 URL: http://llvm.org/viewvc/llvm-project?rev=344702&view=rev Log: Fix for arm bots afternew PM pass port. Prevent cross compiling on arm. Modified: cfe/trunk/test/CodeGen/asan-new-pm.ll Modified: cfe/trunk/test/CodeGen/a

[PATCH] D53339: [clang-tidy] Add the abseil-duration-factory-float check

2018-10-17 Thread Zachary Turner via Phabricator via cfe-commits
zturner added inline comments. Comment at: clang-tidy/abseil/DurationFactoryFloatCheck.cpp:24 +truncateIfIntegral(const FloatingLiteral &FloatLiteral) { + double value = FloatLiteral.getValueAsApproximateDouble(); + if (std::fmod(value, 1) == 0) { All variables

r344701 - Fix for failing unit tests on some bots after r344696.

2018-10-17 Thread Leonard Chan via cfe-commits
Author: leonardchan Date: Wed Oct 17 09:21:19 2018 New Revision: 344701 URL: http://llvm.org/viewvc/llvm-project?rev=344701&view=rev Log: Fix for failing unit tests on some bots after r344696. Modified: cfe/trunk/test/CodeGen/asan-new-pm.ll Modified: cfe/trunk/test/CodeGen/asan-new-pm.ll URL

[PATCH] D45240: [ARM] Compute a target feature which corresponds to the ARM version.

2018-10-17 Thread Peter Smith via Phabricator via cfe-commits
peter.smith added a comment. In https://reviews.llvm.org/D45240#1267846, @stefson wrote: > hey there, I've run into problems with stripping static-libs on arm when > using llvm/clang-7. Could you imagine this patch being at fault? > > strip: armv7a-unknown-linux-gnueabihf-strip --strip-unneede

[PATCH] D45240: [ARM] Compute a target feature which corresponds to the ARM version.

2018-10-17 Thread Steffen Kuhn via Phabricator via cfe-commits
stefson added a comment. Herald added a reviewer: javed.absar. Herald added subscribers: dexonsmith, chrib. hey there, I've run into problems with stripping static-libs on arm when using llvm/clang-7. Could you imagine this patch being at fault? strip: armv7a-unknown-linux-gnueabihf-strip --st

[PATCH] D46013: [ARM] Conform to AAPCS when passing overaligned composites as arguments

2018-10-17 Thread Steffen Kuhn via Phabricator via cfe-commits
stefson added a comment. hey there, I've run into problems with stripping static-libs on arm when using llvm/clang-7. Could you imagine this patch being at fault? strip: armv7a-unknown-linux-gnueabihf-strip --strip-unneeded -R .comment -R .GCC.command.line -R .note.gnu.gold-version lib/l

[PATCH] D52814: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-17 Thread Leonard Chan via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL344699: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with… (authored by leonardchan, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://r

r344699 - [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-17 Thread Leonard Chan via cfe-commits
Author: leonardchan Date: Wed Oct 17 08:38:22 2018 New Revision: 344699 URL: http://llvm.org/viewvc/llvm-project?rev=344699&view=rev Log: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address Enable usage of `AddressSanitizer` and `AddressModuleSanitizer`

[PATCH] D52301: [clang] Set TypeSourceInfo for vardecl's in addition to type when we can deduce.

2018-10-17 Thread Shahms King via Phabricator via cfe-commits
shahms added a comment. It's worth noting that `RecursiveASTVisitor` appears to think they are at least somewhat equivalent in that it will only visit one or the other and prefers `TypeSourceInfo`, if present, via `VisitTypeLoc`. The fact that the TSI lacks this information makes it pretty awk

[PATCH] D53377: [clang-tidy] Ignore a case where the fix of make_unique check introduces side effect.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: alexfh. Herald added a subscriber: xazax.hun. Previously, ptr.reset(new char[5]) will be replaced with `p = make_unique(5)`, the fix has side effect -- doing default initialization, it may cause performace regression (we are bitten by this rec

[PATCH] D53374: [clangd] Names that are not spelled in source code are reserved.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: sammccall. Herald added subscribers: cfe-commits, kadircet, arphaman, jkorous, MaskRay, ilya-biryukov. These are often not expected to be used directly e.g. TEST_F(Fixture, X) { ^ // "Fixture_X_Test" expanded in the macro should be do

[PATCH] D52400: Improve -Wshadow warnings with enumerators

2018-10-17 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D52400#1267499, @sberg wrote: > In https://reviews.llvm.org/D52400#1266341, @aaron.ballman wrote: > > > In https://reviews.llvm.org/D52400#1266307, @sberg wrote: > > > > > > > > > > [...] > > > Then again, this is a case where you don't g

[PATCH] D53372: [clang-tidy] Resolve readability-else-after-return false positive for constexpr if.

2018-10-17 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. I think it would be good to add some more explanation as to *why* that `else` has to be kept. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53372 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D53363: [clangd] Encode Line/Column as a 32-bits integer.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. In https://reviews.llvm.org/D53363#1267628, @sammccall wrote: > (I think your math is off in the description: 20 bits should be 1M lines, not > 4M) Oops...Update the desccription. > I think this is a win, as I think truncation will be rare and not terrible. > We shoul

[PATCH] D53363: [clangd] Encode Line/Column as a 32-bits integer.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 170001. hokein marked 3 inline comments as done. hokein added a comment. Address review comments: - handle overflowed cases, and added tests - add getter/setters for line/column and clear all call sides Repository: rCTE Clang Tools Extra https://reviews.l

[PATCH] D53372: [clang-tidy] Resolve readability-else-after-return false positive for constexpr if.

2018-10-17 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius created this revision. curdeius added reviewers: alexfh, aaron.ballman. Herald added subscribers: cfe-commits, xazax.hun. It fixes the false positive when using constexpr if and where else cannot be removed: Example: if constexpr (sizeof(int) > 4) // ... return /* ... */; e

[PATCH] D51866: [analyzer][UninitializedObjectChecker] New flag to ignore guarded uninitialized fields

2018-10-17 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added a comment. Herald added subscribers: dkrupp, donat.nagy. Ping https://reviews.llvm.org/D51866 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D52988: [analyzer][PlistMacroExpansion] Part 5.: Support for # and ##

2018-10-17 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added a comment. I verified this project on tmux, which uses the preprocessor very heavily. It works perfectly, and doesn't crash anywhere despite the **very** liberal use of asserts. In https://reviews.llvm.org/D52988#1267382, @whisperity wrote: > Looks good. > > What happens if the

[PATCH] D53025: [clang-tidy] implement new check for const return types.

2018-10-17 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Thank you for the restructurings, i think the code is now way clearer and the check close to being done (at least from my side :)). Could you please mark all notes you consider done as done? Right now i am a bit lost on what to track on, as the locations of the notes a

Re: r339163 - [WebAssembly] Remove use of lld -flavor flag

2018-10-17 Thread Sam Clegg via cfe-commits
The symlink is correct, the linker's name is just `wasm-ld`. It is also the default so you should be able to just drop the -fuse-ld argument to make your command line work. I looks like the real fix is to update the handling of -fuse-ld. On Tue, Oct 16, 2018 at 9:26 AM Nico Weber wrote: > > $ b

[PATCH] D53339: [clang-tidy] Add the abseil-duration-factory-float check

2018-10-17 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added inline comments. Comment at: clang-tidy/abseil/DurationFactoryFloatCheck.cpp:34 +llvm::APSInt ApInt(/*BitWidth=*/64, /*isUnsigned=*/false); +ApInt = static_cast(value); +if (is_negative) Wouldn't it make more sense to use `std::uint64_

[PATCH] D53369: [CodeComplete] Fix accessibility of protected members when accessing members implicitly.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric created this revision. ioeric added a reviewer: ilya-biryukov. Herald added subscribers: cfe-commits, arphaman. Repository: rC Clang https://reviews.llvm.org/D53369 Files: lib/Sema/SemaCodeComplete.cpp test/Index/complete-access-checks.cpp Index: test/Index/complete-access-checks.

[PATCH] D52814: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-17 Thread Fedor Sergeev via Phabricator via cfe-commits
fedor.sergeev accepted this revision. fedor.sergeev added a comment. LGTM. Repository: rC Clang https://reviews.llvm.org/D52814 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53363: [clangd] Encode Line/Column as a 32-bits integer.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. (I think your math is off in the description: 20 bits should be 1M lines, not 4M) I think this is a win, as I think truncation will be rare and not terrible. We should document the intentions around truncation though. Incidentally, this means replacing just the String

[PATCH] D52814: [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with -fsanitize=address

2018-10-17 Thread Philip Pfaffe via Phabricator via cfe-commits
philip.pfaffe accepted this revision. philip.pfaffe added a comment. This revision is now accepted and ready to land. LGTM, thank you! Repository: rC Clang https://reviews.llvm.org/D52814 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL344688: [clangd] Support scope proximity in code completion. (authored by ioeric, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D53131 Files:

[clang-tools-extra] r344688 - [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via cfe-commits
Author: ioeric Date: Wed Oct 17 04:19:02 2018 New Revision: 344688 URL: http://llvm.org/viewvc/llvm-project?rev=344688&view=rev Log: [clangd] Support scope proximity in code completion. Summary: This should make all-scope completion more usable. Scope proximity for indexes will be added in follow

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 169983. ioeric added a comment. - rebase Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53131 Files: clangd/AST.cpp clangd/AST.h clangd/CodeComplete.cpp clangd/FileDistance.cpp clangd/FileDistance.h clangd/Quality.cpp clangd/Qu

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 169982. ioeric marked an inline comment as done. ioeric added a comment. - address comments Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53131 Files: clangd/AST.cpp clangd/AST.h clangd/CodeComplete.cpp clangd/FileDistance.cpp cla

[PATCH] D53363: [clangd] Encode Line/Column as a 32-bits integer.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein created this revision. hokein added a reviewer: sammccall. Herald added subscribers: kadircet, arphaman, jkorous, MaskRay, ioeric, ilya-biryukov. This would buy us more memory. Using a 32-bits integer is enough for most human-readable source code (up to 4M lines and 4K columns). Previsoul

[PATCH] D53200: [OpenCL] Fix serialization of OpenCLExtensionDecls

2018-10-17 Thread Alexey Sachkov via Phabricator via cfe-commits
AlexeySachkov added a comment. @yaxunl could you please review this patch? It fixes a bug in a feature implemented by you in: commit c6fb598a301143e9d21156a012cc6ef669ff0188 Author: Yaxun Liu

[PATCH] D51633: [ASTImporter] Added error handling for AST import.

2018-10-17 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. In the current version all clang tests do pass and most of the LLDB tests. Some LLDB tests do not work on my machine, the problems exist on master too. This code is still a temporary version (possible to commit now or wait until every change is made?). Later the `Import

[PATCH] D53200: [OpenCL] Fix serialization of OpenCLExtensionDecls

2018-10-17 Thread Alexey Sachkov via Phabricator via cfe-commits
AlexeySachkov updated this revision to Diff 169978. AlexeySachkov added a comment. Removed unnecessary empty line from test https://reviews.llvm.org/D53200 Files: lib/Serialization/ASTWriter.cpp test/Headers/opencl-pragma-extension-begin.cl test/Headers/opencl-pragma-extension-begin.h I

[PATCH] D52400: Improve -Wshadow warnings with enumerators

2018-10-17 Thread Stephan Bergmann via Phabricator via cfe-commits
sberg added a comment. In https://reviews.llvm.org/D52400#1266341, @aaron.ballman wrote: > In https://reviews.llvm.org/D52400#1266307, @sberg wrote: > > > > [...] > Then again, this is a case where you don't get any error but you do get a > silent behavioral ambiguity without the current enum

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added a comment. This revision is now accepted and ready to land. Awesome! Just nits. Comment at: clangd/CodeComplete.cpp:1224 std::vector QueryScopes; // Initialized once Sema runs. + // Initialized once QueryScopes is initialize

[PATCH] D53024: [analyzer][www] Add more open projects

2018-10-17 Thread Daniel Krupp via Phabricator via cfe-commits
dkrupp added inline comments. Comment at: www/analyzer/open_projects.html:198 + or using a dataflow framework. + (Difficulty: Hard) + Probably it is worth mentioning here, that there is a macro language already for describing summaries of standard

Re: [clang-tools-extra] r344650 - [clang-doc] Add unit tests for serialization

2018-10-17 Thread Mikael Holmén via cfe-commits
Hi Julie, clang 3.6.0 complains on this commit: /usr/bin/clang++ -march=corei7 -DGTEST_HAS_RTTI=0 -DGTEST_HAS_TR1_TUPLE=0 -DGTEST_LANG_CXX11=1 -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Itools/clang/tools/extra/unittests/clang-doc -I../tool

[clang-tools-extra] r344680 - [clangd] Fix buildbot failure.

2018-10-17 Thread Haojian Wu via cfe-commits
Author: hokein Date: Wed Oct 17 01:54:48 2018 New Revision: 344680 URL: http://llvm.org/viewvc/llvm-project?rev=344680&view=rev Log: [clangd] Fix buildbot failure. Modified: clang-tools-extra/trunk/clangd/index/SymbolCollector.cpp Modified: clang-tools-extra/trunk/clangd/index/SymbolCollecto

[clang-tools-extra] r344679 - [clangd] Print numbers of symbols and refs as well when loading the

2018-10-17 Thread Haojian Wu via cfe-commits
Author: hokein Date: Wed Oct 17 01:48:04 2018 New Revision: 344679 URL: http://llvm.org/viewvc/llvm-project?rev=344679&view=rev Log: [clangd] Print numbers of symbols and refs as well when loading the index. Modified: clang-tools-extra/trunk/clangd/index/Serialization.cpp Modified: clang-too

[PATCH] D53322: [clangd] Collect refs from headers.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rCTE344678: [clangd] Collect refs from headers. (authored by hokein, committed by ). Changed prior to commit: https://reviews.llvm.org/D53322?vs=169967&id=169968#toc Repository: rCTE Clang Tools Extra

[clang-tools-extra] r344678 - [clangd] Collect refs from headers.

2018-10-17 Thread Haojian Wu via cfe-commits
Author: hokein Date: Wed Oct 17 01:38:36 2018 New Revision: 344678 URL: http://llvm.org/viewvc/llvm-project?rev=344678&view=rev Log: [clangd] Collect refs from headers. Summary: Add a flag to SymbolCollector to collect refs fdrom headers. Note that we collect refs from headers in static index, a

[PATCH] D53322: [clangd] Collect refs from headers.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 169967. hokein added a comment. minor cleanup. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53322 Files: clangd/index/IndexAction.cpp clangd/index/IndexAction.h clangd/index/SymbolCollector.cpp clangd/index/SymbolCollector.h unit

[PATCH] D53322: [clangd] Collect refs from headers.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. In https://reviews.llvm.org/D53322#1266536, @sammccall wrote: > (please do check there are no duplicates in the output) We do deduplication when building the RefSlab. And double-checked with the output, no duplications there. Repository: rCTE Clang Tools Extra http

[PATCH] D53322: [clangd] Collect refs from headers.

2018-10-17 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 169963. hokein marked 5 inline comments as done. hokein added a comment. Address review comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53322 Files: clangd/index/IndexAction.cpp clangd/index/IndexAction.h clangd/index/SymbolCo

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 169962. ioeric marked 18 inline comments as done. ioeric added a comment. - Addressed review comments. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D53131 Files: clangd/AST.cpp clangd/AST.h clangd/CodeComplete.cpp clangd/FileDistanc

[PATCH] D53131: [clangd] Support scope proximity in code completion.

2018-10-17 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. Thanks for the suggestions! After taking a closer look at boosting factors for other signals, I think I was being too conservative about boosting preferred scopes and penalizing non-preferred ones. I have tuned the parameters to make these more aggressive now according t

[clang-tools-extra] r344676 - [clangd] Hide unused function. NFC

2018-10-17 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Oct 17 00:41:53 2018 New Revision: 344676 URL: http://llvm.org/viewvc/llvm-project?rev=344676&view=rev Log: [clangd] Hide unused function. NFC Modified: clang-tools-extra/trunk/clangd/JSONRPCDispatcher.cpp clang-tools-extra/trunk/clangd/JSONRPCDispatcher.h Mod

[clang-tools-extra] r344675 - [clangd] Rename and move trivial logger to Logger.cpp. NFC

2018-10-17 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Oct 17 00:39:32 2018 New Revision: 344675 URL: http://llvm.org/viewvc/llvm-project?rev=344675&view=rev Log: [clangd] Rename and move trivial logger to Logger.cpp. NFC Modified: clang-tools-extra/trunk/clangd/ClangdLSPServer.h clang-tools-extra/trunk/clangd/JSON

[PATCH] D53266: [clangd] Simplify client capabilities parsing.

2018-10-17 Thread Sam McCall via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL344673: [clangd] Simplify client capabilities parsing. (authored by sammccall, committed by ). Herald added a subscriber: llvm-commits. Repository: rL LLVM https://reviews.llvm.org/D53266 Files: cla

[clang-tools-extra] r344673 - [clangd] Simplify client capabilities parsing.

2018-10-17 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Oct 17 00:33:42 2018 New Revision: 344673 URL: http://llvm.org/viewvc/llvm-project?rev=344673&view=rev Log: [clangd] Simplify client capabilities parsing. Summary: Instead of parsing into structs that mirror LSP, simply parse into a flat struct that contains the info w

[clang-tools-extra] r344672 - [clangd] Refactor JSON-over-stdin/stdout code into Transport abstraction. (re-land r344620)

2018-10-17 Thread Sam McCall via cfe-commits
Author: sammccall Date: Wed Oct 17 00:32:05 2018 New Revision: 344672 URL: http://llvm.org/viewvc/llvm-project?rev=344672&view=rev Log: [clangd] Refactor JSON-over-stdin/stdout code into Transport abstraction. (re-land r344620) Summary: This paves the way for alternative transports (mac XPC, may