[PATCH] D74669: [clang-tidy] New check: bugprone-suspicious-include

2020-03-05 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tools-extra/clang-tidy/utils/FileExtensionsUtils.h:38 +/// extensions. +inline StringRef defaultHeaderFileExtensions() { return ",h,hh,hpp,hxx"; } + njames93 wrote: > A lot of configuration options for clang tid

[PATCH] D75582: [clangd] Track document versions, include them with diags, enhance logs

2020-03-05 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added inline comments. Comment at: clang-tools-extra/clangd/ClangdServer.h:73 virtual void onDiagnosticsReady(PathRef File, +const llvm::json::Value &Version, std::vector Diagnostics) {} --

[PATCH] D75356: [Analyzer][StreamChecker] Introduction of stream error state handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked 8 inline comments as done. balazske added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:37-40 + // NoError: No error flag is set or stream is not open. + // EofError: EOF condition (feof returns true) + // OtherError: other (n

[PATCH] D75603: [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread Kadir Cetinkaya via Phabricator via cfe-commits
kadircet added a comment. In D75603#1906418 , @sammccall wrote: > Forgot to mention: I also think the trace approach certainly has things going > for it, or even parsing out the messages from the existing logs. > But in this particular case the callback

[PATCH] D75356: [Analyzer][StreamChecker] Introduction of stream error state handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske marked 2 inline comments as done. balazske added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:37-40 + // NoError: No error flag is set or stream is not open. + // EofError: EOF condition (feof returns true) + // OtherError: other (n

Re: [clang] ec3060c - [AST] Refactor propagation of dependency bits. NFC

2020-03-05 Thread Mikael Holmén via cfe-commits
Hi Hokein, Ilya, Clang warns on this code when compiled without asserts: ../../clang/lib/AST/TemplateName.cpp:189:3: error: unannotated fall- through between switch labels [-Werror,-Wimplicit-fallthrough] default: ^ ../../clang/lib/AST/TemplateName.cpp:189:3: note: insert 'break;' to avoid fa

[PATCH] D75604: [clangd] Round WorkDoneProgressBegin.percentage down

2020-03-05 Thread Kirill Bobyrev via Phabricator via cfe-commits
kbobyrev abandoned this revision. kbobyrev marked an inline comment as done. kbobyrev added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:1409 (Stats.Enqueued - Stats.LastIdle); + // Round down to 2 decimal places for re

[PATCH] D75569: [clang-tidy] New check for methods marked __attribute__((unavailable)) that do not override a method from a superclass.

2020-03-05 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Fix the test case. Comment at: clang-tools-extra/clang-tidy/objc/MethodUnavailableNotOverrideCheck.cpp:29 +// intended to be matched here. +AST_MATCHER(ObjCMethodDecl, isUnavailableMethodNotOverriding) { + return !Node.isOverriding() && Node.hasAttr(

[clang-tools-extra] 5abfe64 - [clangd] Fix test (it worked by coincidence before)

2020-03-05 Thread Sam McCall via cfe-commits
Author: Sam McCall Date: 2020-03-05T10:11:55+01:00 New Revision: 5abfe646f5e194bb2330b80c7f0e23fba00e30fe URL: https://github.com/llvm/llvm-project/commit/5abfe646f5e194bb2330b80c7f0e23fba00e30fe DIFF: https://github.com/llvm/llvm-project/commit/5abfe646f5e194bb2330b80c7f0e23fba00e30fe.diff LO

[PATCH] D74669: [clang-tidy] New check: bugprone-suspicious-include

2020-03-05 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/clang-tidy/utils/FileExtensionsUtils.h:38 +/// extensions. +inline StringRef defaultHeaderFileExtensions() { return ",h,hh,hpp,hxx"; } + lebedev.ri wrote: > njames93 wrote: > > A lot of configuration o

[PATCH] D74935: [LangRef][AliasAnalysis] Clarify `noalias` affects only modified objects

2020-03-05 Thread Jeroen Dobbelaere via Phabricator via cfe-commits
jeroen.dobbelaere added a comment. Just to give an example: int foo(int* restrict *pA, int* restrict *pB) { int tmp=**pB; **pA=42; return tmp - **pB; // **pA and **pB can refer to the same objects } This gives following llvm-ir code with the 'full noalias' clang version (after o

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-03-05 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: martong, balazske. Herald added subscribers: cfe-commits, steakhal, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun, whisperity, mgorny. Herald added a reviewer: Szelet

[PATCH] D74669: [clang-tidy] New check: bugprone-suspicious-include

2020-03-05 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: clang-tools-extra/clang-tidy/utils/FileExtensionsUtils.h:38 +/// extensions. +inline StringRef defaultHeaderFileExtensions() { return ",h,hh,hpp,hxx"; } + njames93 wrote: > lebedev.ri wrote: > > njames93 wrote: > > >

[clang] cd1dc7f - [AST] Replace assert with llvm_unreachable to silence compiler warning

2020-03-05 Thread Mikael Holmen via cfe-commits
Author: Mikael Holmen Date: 2020-03-05T11:07:54+01:00 New Revision: cd1dc7f15d637b42067546e658574237cd0f0d46 URL: https://github.com/llvm/llvm-project/commit/cd1dc7f15d637b42067546e658574237cd0f0d46 DIFF: https://github.com/llvm/llvm-project/commit/cd1dc7f15d637b42067546e658574237cd0f0d46.diff

[PATCH] D74616: [ARM] Setting missing isLaneQ attribute on Neon Intrisics definitions

2020-03-05 Thread Diogo N. Sampaio via Phabricator via cfe-commits
dnsampaio accepted this revision. dnsampaio added a comment. This revision is now accepted and ready to land. LGTM with a nit: we can save some space using sintax like this: let isLaneQ = 1 in def UDOT_LANEQ : SOpInst<"vdot_laneq", "..(<<)(<; or concatenating those that are just one after th

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-03-05 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. This patch adds an alternative way of loading ASTs to provide the CTU definitions needed during analysis. The additional approach is to use Tooling with a user-provided compile_commands.json, and look up the needed file from the output of the ext-def-mapping tool (whic

[clang] 737394c - Revert "clang: Treat ieee mode as the default for denormal-fp-math"

2020-03-05 Thread Jeremy Morse via cfe-commits
Author: Jeremy Morse Date: 2020-03-05T10:55:24Z New Revision: 737394c490444e968a6f640b99a6614567ca7f28 URL: https://github.com/llvm/llvm-project/commit/737394c490444e968a6f640b99a6614567ca7f28 DIFF: https://github.com/llvm/llvm-project/commit/737394c490444e968a6f640b99a6614567ca7f28.diff LOG:

Re: [clang] c64ca93 - clang: Treat ieee mode as the default for denormal-fp-math

2020-03-05 Thread Jeremy Morse via cfe-commits
Hi Matt, FYI several build bots tripped on this commit: http://lab.llvm.org:8011/builders/clang-x86_64-debian-fast/builds/24703/ http://lab.llvm.org:8011/builders/clang-cmake-x86_64-avx2-linux/builds/13465/ http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu/builds/15994/

[PATCH] D75603: [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 248416. usaxena95 marked 5 inline comments as done. usaxena95 added a comment. Addressed comments. - Populated score in CodeCompletion before invoking the callback. - Tested that CodeCompletion is scored - Updated comment for callback. Repository: rG LL

[PATCH] D75603: [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 added inline comments. Comment at: clang-tools-extra/clangd/CodeComplete.h:139 + /// in the output. + std::function *RecordCCResult = nullptr; sammccall wrote: > I'd suggest including the final score in the signature rather than recompute > it, just

[PATCH] D74617: [ARM] Keeping sign information on bitcasts for Neon vdot_lane intrinsics

2020-03-05 Thread Diogo N. Sampaio via Phabricator via cfe-commits
dnsampaio added a comment. Is this missing a test? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74617/new/ https://reviews.llvm.org/D74617 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[PATCH] D75612: [Analyzer][StreamChecker] Adding PreCall and refactoring (NFC).

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus accepted this revision. Szelethus added a comment. This revision is now accepted and ready to land. LGTM! Lets have a link to the original discussion: D75163 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D

[PATCH] D75163: [analyzer][StreamChecker] Adding precall and refactoring.

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:64-70 +/// Get the value of the stream argument out of the passed call event. +/// The call should contain a function that is described by Desc. +SVal getStreamArg(const FnDescription

[PATCH] D75612: [Analyzer][StreamChecker] Adding PreCall and refactoring (NFC).

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. Wouldn't it be better just to upload this diff to D75163 by the way? It feels like we're discarding much of the discussion. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75612/new/ http

[clang-tools-extra] e397a0a - [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread Utkarsh Saxena via cfe-commits
Author: Utkarsh Saxena Date: 2020-03-05T12:39:15+01:00 New Revision: e397a0a5c3c0fa1912fbac23b550fa7d239196ba URL: https://github.com/llvm/llvm-project/commit/e397a0a5c3c0fa1912fbac23b550fa7d239196ba DIFF: https://github.com/llvm/llvm-project/commit/e397a0a5c3c0fa1912fbac23b550fa7d239196ba.diff

[PATCH] D75356: [Analyzer][StreamChecker] Introduction of stream error state handling.

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp:37-40 + // NoError: No error flag is set or stream is not open. + // EofError: EOF condition (feof returns true) + // OtherError: other (non-EOF) error (ferror returns true) + //

[PATCH] D74618: [ARM] Creating 'call_mangled' for Neon intrinsics definitions

2020-03-05 Thread Diogo N. Sampaio via Phabricator via cfe-commits
dnsampaio added inline comments. Comment at: clang/utils/TableGen/NeonEmitter.cpp:1890-1891 } +if (MangledName) + Good &= I.getMangledName(true) == MangledName; + Can we move this above the loop just before? Perhaps, if false, can we just continue

[PATCH] D75603: [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread UTKARSH SAXENA via Phabricator via cfe-commits
usaxena95 updated this revision to Diff 248422. usaxena95 added a comment. Passed score as a float as an explicit argument of the callback. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75603/new/ https://reviews.llvm.org/D75603 Files: clang-too

[PATCH] D75603: [clangd] Add instrumentation mode in clangd for metrics collection.

2020-03-05 Thread UTKARSH SAXENA via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe397a0a5c3c0: [clangd] Add instrumentation mode in clangd for metrics collection. (authored by usaxena95). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7560

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen updated this revision to Diff 248432. sdesmalen marked 11 inline comments as done. sdesmalen added a comment. - Renamed CK and BaseTS - Refactored switch statementsd in SVEType::getTypeFlags() CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75470/new/ https://reviews.llvm.org/D7

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Sander de Smalen via Phabricator via cfe-commits
sdesmalen added inline comments. Comment at: clang/include/clang/Basic/arm_sve.td:121 +// Load one vector (scalar base) +def SVLD1 : MInst<"svld1[_{2}]", "dPc", "csilUcUsUiUlhfd", [IsLoad]>; SjoerdMeijer wrote: > This encoding, e.g, this is "csilUcUsUiUlhfd",

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. krasimir edited the summary of this revision. krasimir added a reviewer: hans. hans added a comment. Very nice, thanks! Comment at: clang/lib/Format/TokenAnnotator.cpp:502

[PATCH] D75538: [clang-tidy] Updated language supported restrictions on some checks

2020-03-05 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/modernize-use-nullptr-basic.cpp:1 -// RUN: %check_clang_tidy -std=c++98 %s modernize-use-nullptr %t -- -- -Wno-non-literal-null-conversion -// njames93 wrote: > alexfh wrote: >

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Very nice, thanks! Comment at: clang/lib/Format/TokenAnnotator.cpp:502 Left->Type = TT_ObjCMethodExpr; + } else if (Style.isCpp() && InsideInlineASM) { +Left->Type = TT_InlineASMSymbolicNameLSquare; Is the Style.isCpp

[clang] 66addf8 - Revert "Fix regression in bdad0a1: force rebuilding of StmtExpr nodes in", "PR45083: Mark statement expressions as being dependent if they appear in"

2020-03-05 Thread Benjamin Kramer via cfe-commits
Author: Benjamin Kramer Date: 2020-03-05T14:14:31+01:00 New Revision: 66addf8e803618758457e4d578c5084e322ca448 URL: https://github.com/llvm/llvm-project/commit/66addf8e803618758457e4d578c5084e322ca448 DIFF: https://github.com/llvm/llvm-project/commit/66addf8e803618758457e4d578c5084e322ca448.dif

Re: [clang] bdad0a1 - PR45083: Mark statement expressions as being dependent if they appear in

2020-03-05 Thread Benjamin Kramer via cfe-commits
It's still crashing clang, reverted this and f545ede91c9d9f271e7504282cab7bf509607ead in 66addf8e8036. c-reduce is still chewing on the reproducer. On Wed, Mar 4, 2020 at 10:20 PM Richard Smith via cfe-commits wrote: > > We found a regression introduced by this patch; fixed in > f545ede91c9d9f27

[clang] 36c2ab8 - [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via cfe-commits
Author: Krasimir Georgiev Date: 2020-03-05T14:17:21+01:00 New Revision: 36c2ab8d04cd9ff2e50cffa1ca6b3de00e4faa81 URL: https://github.com/llvm/llvm-project/commit/36c2ab8d04cd9ff2e50cffa1ca6b3de00e4faa81 DIFF: https://github.com/llvm/llvm-project/commit/36c2ab8d04cd9ff2e50cffa1ca6b3de00e4faa81.d

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. In D75514#1905268 , @Szelethus wrote: > But why is this related to `UndefinedVal`? Because `UndefinedVal` seems to be the "null" value of `SVal` thus it is suitable for default value of the parameter. CHANGES SINCE

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir marked an inline comment as done. krasimir added inline comments. Comment at: clang/lib/Format/TokenAnnotator.cpp:502 Left->Type = TT_ObjCMethodExpr; + } else if (Style.isCpp() && InsideInlineASM) { +Left->Type = TT_InlineASMSymbolicNameLSquare; ---

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 248445. krasimir marked an inline comment as done. krasimir added a comment. Remove redundant check. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75675/new/ https://reviews.llvm.org/D75675 Files: clang/lib

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm, thanks for the quick fix! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75675/new/ https://reviews.llvm.org/D75675

[PATCH] D75677: [Analyzer] Only add iterator note tags to the operations of the affected iterators

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware created this revision. baloghadamsoftware added reviewers: NoQ, Szelethus. baloghadamsoftware added a project: clang. Herald added subscribers: martong, steakhal, Charusso, gamesh411, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, xazax.hun, whisperity. baloghadamsoft

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added a reviewer: NoQ. Herald added subscribers: cfe-commits, steakhal, Charusso, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun, whisperity. Herald added a reviewer: Szelethus. Herald ad

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG36c2ab8d04cd: [clang-format] do not insert spaces around inline asm symbolic names (authored by krasimir). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7567

[PATCH] D75675: [clang-format] do not insert spaces around inline asm symbolic names

2020-03-05 Thread Krasimir Georgiev via Phabricator via cfe-commits
krasimir updated this revision to Diff 248449. krasimir added a comment. Merging commits into 1 patch Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75675/new/ https://reviews.llvm.org/D75675 Files: clang/lib/Format/FormatToken.h clang/lib/Form

[PATCH] D74735: [analyzer] Add support for CXXInheritedCtorInitExpr.

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. Thanks Richard for the explanation. Artem, I think this justifies your suggestion to skip the analysis of inherited constructors as top level functions. I just created the patch https://reviews.llvm.org/D75678 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. For those who are interested in more details please refer to the related discussion after the commit of the patch that introduces handling of inherited ctors . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://r

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Thanks!! I also recommend a more direct test with `-analyzer-display-progress | FileCheck`. Comment at: clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp:507-508 + // Skip analysis of inherited constructors as top-level functions because we + // c

[PATCH] D75184: [clang-tidy] Optional inheritance of file configs from parent directories 

2020-03-05 Thread Dmitry Polukhin via Phabricator via cfe-commits
DmitryPolukhin updated this revision to Diff 248457. DmitryPolukhin added a comment. Comments resolved, please take another look. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75184/new/ https://reviews.llvm.org/D75184 Files: clang-tools-extra/c

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer added inline comments. Comment at: clang/include/clang/Basic/arm_sve.td:121 +// Load one vector (scalar base) +def SVLD1 : MInst<"svld1[_{2}]", "dPc", "csilUcUsUiUlhfd", [IsLoad]>; sdesmalen wrote: > SjoerdMeijer wrote: > > This encoding, e.g, this

[PATCH] D73638: [AST] Move dependence computations into a separate file

2020-03-05 Thread Haojian Wu via Phabricator via cfe-commits
hokein commandeered this revision. hokein added a reviewer: ilya-biryukov. hokein added a comment. This patch contains too many changes, most of them are just NFC, it likely takes a long time to do a full review. I actually did an review for the original patch. I have highlighted places (see me

Re: [clang] bdad0a1 - PR45083: Mark statement expressions as being dependent if they appear in

2020-03-05 Thread Benjamin Kramer via cfe-commits
creduce produced this. It's a crash on invalid, but was created from a valid input. $ cat r.ii template auto b(a) { auto c = [](auto, int) -> decltype(({})) {}; return c(0, 0); } using d = decltype(b(0)); bool f = d ::e; $ clang r.ii -std=c++17 -w clang-11: clang/lib/AST/Decl.cpp:2343: clang

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. In D75514#1907392 , @baloghadamsoftware wrote: > In D75514#1905268 , @Szelethus wrote: > > > But why is this related to `UndefinedVal`? > > > Because `UndefinedVal` seems to be the "null"

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus added a comment. I followed the discussion, on the other patch, and this seems to be the appropriate fix -- I lack the confidence to accept, but LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75678/new/ https://reviews.llvm.org/D756

[PATCH] D75623: [clangd][VSCode] Force VSCode to use the ranking provided by clangd.

2020-03-05 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. thanks for fixing that! Played around it locally, it seems work, found an issue where the global code completion is not triggered, see my comment. Comment at: clang-tools-extra/clangd/clients/clangd-vscode/src/extension.ts:116 +// Get the in

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In D75514#1907392 , @baloghadamsoftware wrote: > In D75514#1905268 , @Szelethus wrote: > > > But why is this related to `UndefinedVal`? > > > Because `UndefinedVal` seems to be the "null" value

[PATCH] D75632: Comment parsing: Treat \ref as inline command

2020-03-05 Thread Dmitri Gribenko via Phabricator via cfe-commits
gribozavr2 accepted this revision. gribozavr2 added a comment. This revision is now accepted and ready to land. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75632/new/ https://reviews.llvm.org/D75632

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong marked an inline comment as done. martong added a comment. In D75678#1907449 , @NoQ wrote: > Thanks!! I also recommend a more direct test with `-analyzer-display-progress > | FileCheck`. Ok, I added a new test file with FileCheck. ===

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer added a subscriber: simon_tatham. SjoerdMeijer added a comment. Adding @simon_tatham in case he feels wants to have a look too. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75470/new/ https://reviews.llvm.org/D75470 ___ cfe-co

[PATCH] D75678: [analyzer] Skip analysis of inherited ctor as top-level function

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong updated this revision to Diff 248473. martong marked an inline comment as done. martong added a comment. - Change comments, add FileCheck test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75678/new/ https://reviews.llvm.org/D75678 Files:

[clang] a8648fd - Replace getAs with castAs to fix null dereference static analyzer warning.

2020-03-05 Thread Simon Pilgrim via cfe-commits
Author: Simon Pilgrim Date: 2020-03-05T15:28:54Z New Revision: a8648fd19aecfe2aed3ce529f488930cc37db4c2 URL: https://github.com/llvm/llvm-project/commit/a8648fd19aecfe2aed3ce529f488930cc37db4c2 DIFF: https://github.com/llvm/llvm-project/commit/a8648fd19aecfe2aed3ce529f488930cc37db4c2.diff LOG:

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp:719-720 + const auto *PSBR = dyn_cast(&BR); + if (!PSBR) +return ""; + Mmm, this is definitely impossible. We should change the `NoteTag` API to pass

[PATCH] D74361: [Clang] Undef attribute for global variables

2020-03-05 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74361/new/ https://reviews.llvm.org/D74361 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[PATCH] D75163: [analyzer][StreamChecker] Adding precall and refactoring.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. To avoid problems I created a new version of this diff too that follows after the other new ones: https://reviews.llvm.org/D75682 (Adding a new diff can make inline comment positions even more inexact specially if the diff has many differences from an older one?) Repo

[PATCH] D75682: [Analyzer][StreamChecker] Introduction of stream error handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. For older discussion see this: https://reviews.llvm.org/D75356 Functions `feof` and `ferror` are added to show how the stream error flags are used and to make tests possible. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D

[PATCH] D75682: [Analyzer][StreamChecker] Introduction of stream error handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske created this revision. Herald added subscribers: cfe-commits, martong, Charusso, gamesh411, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: clang. balazske added a comment. For

[PATCH] D75470: [SVE] Auto-generate builtins and header for svld1.

2020-03-05 Thread Simon Tatham via Phabricator via cfe-commits
simon_tatham added inline comments. Comment at: clang/include/clang/Basic/arm_sve.td:121 +// Load one vector (scalar base) +def SVLD1 : MInst<"svld1[_{2}]", "dPc", "csilUcUsUiUlhfd", [IsLoad]>; SjoerdMeijer wrote: > sdesmalen wrote: > > SjoerdMeijer wrote: > >

[PATCH] D75682: [Analyzer][StreamChecker] Introduction of stream error handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. Some explanation of the error states: - `EofError` indicates an EOF condition in the stream. - `OtherError` indicates a generic (I/O or other but not EOF) error. - `AnyError` is a "placeholder" if the exact error kind is not important. This is a "Schrödinger's cat" type

[PATCH] D75682: [Analyzer][StreamChecker] Introduction of stream error handling.

2020-03-05 Thread Balázs Kéri via Phabricator via cfe-commits
balazske added a comment. We can not make a warning if a stream operation is called in failed state: The error was probably handled based on the return value of the previous failed operation. This thing is checked by the "ErrorReturnChecker" (https://reviews.llvm.org/D72705). Only some special

[PATCH] D75685: Add MS Mangling for OpenCL Pipe types, add mangling test.

2020-03-05 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. erichkeane added reviewers: bader, Anastasia, pxli168. Herald added a subscriber: yaxunl. SPIRV2.0 Spec only specifies Linux mangling, however our downstream has use for a Windows mangling for these types. Unfortunately, the SPIRV spec specifies a single mangling

[PATCH] D64464: [CodeGen] Emit destructor calls to destruct compound literals

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/lib/AST/ASTImporter.cpp:7918 + + return nullptr; +} I think ``` return make_errorhttps://reviews.llvm.org/D64464/new/ https://reviews.llvm.org/D64464 ___ cfe-commit

[PATCH] D74617: [ARM] Keeping sign information on bitcasts for Neon vdot_lane intrinsics

2020-03-05 Thread Lucas Prates via Phabricator via cfe-commits
pratlucas added a comment. This patch by itself is a NFC. It aims to enable the proper overload resolution of intrinsic calls when using the `call_mangled` operation introduced on D74618 . To make this more clear, I'll discard this review and merge this changes i

[PATCH] D74166: [AIX][Frontend] Static init implementation for AIX considering no priority

2020-03-05 Thread Xiangling Liao via Phabricator via cfe-commits
Xiangling_L marked 4 inline comments as done. Xiangling_L added inline comments. Comment at: clang/lib/CodeGen/CGDeclCXX.cpp:283 llvm::FunctionCallee atexit = - CGM.CreateRuntimeFunction(atexitTy, "atexit", llvm::AttributeList(), -/*Local=*

[PATCH] D75687: [clangd] Only minimally escape text when rendering to markdown.

2020-03-05 Thread Sam McCall via Phabricator via cfe-commits
sammccall created this revision. sammccall added a reviewer: kadircet. Herald added subscribers: cfe-commits, usaxena95, arphaman, jkorous, MaskRay, ilya-biryukov. Herald added a project: clang. Conservatively escaping everything is bad in coc.nvim which shows the markdown to the user, and we hav

[libunwind] 470f995 - Promote nameless lambda used by dl_iterate_phdr to named function.

2020-03-05 Thread Sterling Augustine via cfe-commits
Author: Sterling Augustine Date: 2020-03-05T08:55:22-08:00 New Revision: 470f995a517f5dbb53b1f5cd87ca3c9be0b32d79 URL: https://github.com/llvm/llvm-project/commit/470f995a517f5dbb53b1f5cd87ca3c9be0b32d79 DIFF: https://github.com/llvm/llvm-project/commit/470f995a517f5dbb53b1f5cd87ca3c9be0b32d79.

[PATCH] D75687: [clangd] Only minimally escape text when rendering to markdown.

2020-03-05 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 248493. sammccall added a comment. couple more tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75687/new/ https://reviews.llvm.org/D75687 Files: clang-tools-extra/clangd/FormattedString.cpp clang-too

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 248496. baloghadamsoftware added a comment. Updated according to the comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75514/new/ https://reviews.llvm.org/D75514 Files: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp cl

[PATCH] D73720: [Analyzer] Use note tags to track container begin and and changes

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 248495. baloghadamsoftware added a comment. Minor style change. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D73720/new/ https://reviews.llvm.org/D73720 Files: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp clang/lib/StaticA

[PATCH] D75623: [clangd][VSCode] Force VSCode to use the ranking provided by clangd.

2020-03-05 Thread Sam McCall via Phabricator via cfe-commits
sammccall updated this revision to Diff 248497. sammccall marked 2 inline comments as done. sammccall added a comment. address review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75623/new/ https://reviews.llvm.org/D75623 Files: clang-

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 248499. baloghadamsoftware added a comment. Updated according to the comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75514/new/ https://reviews.llvm.org/D75514 Files: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp cl

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 248502. baloghadamsoftware marked an inline comment as done. baloghadamsoftware added a comment. Typo fixed. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75514/new/ https://reviews.llvm.org/D75514 Files: clang/lib/StaticAnalyzer/Check

[PATCH] D75690: [SVE][Inline-Asm] Add constraints for SVE ACLE types

2020-03-05 Thread Kerry McLaughlin via Phabricator via cfe-commits
kmclaughlin created this revision. kmclaughlin added reviewers: sdesmalen, huntergr, rovka, cameron.mcinally, efriedma. Herald added subscribers: cfe-commits, psnobl, rkruppe, tschuett. Herald added a reviewer: rengolin. Herald added a project: clang. kmclaughlin added a parent revision: D75297: [

[PATCH] D74618: [ARM] Creating 'call_mangled' for Neon intrinsics definitions

2020-03-05 Thread Lucas Prates via Phabricator via cfe-commits
pratlucas updated this revision to Diff 248505. pratlucas added a comment. Addressing review comment Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74618/new/ https://reviews.llvm.org/D74618 Files: clang/include/clang/Basic/arm_neon_incl.td cla

[PATCH] D75514: [Analyzer] Only add container note tags to the operations of the affected container

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware marked 2 inline comments as done. baloghadamsoftware added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/ContainerModeling.cpp:719-720 + const auto *PSBR = dyn_cast(&BR); + if (!PSBR) +return ""; + NoQ wrote:

[PATCH] D75677: [Analyzer] Only add iterator note tags to the operations of the affected iterators

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 248509. baloghadamsoftware added a comment. Updated according to the comments to D75514 . CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75677/new/ https://reviews.llvm.org/D75677 Files: clang/lib/Static

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. The warning below suggests that we parse the ctu-other.c file (and presumably every file) as a C++ file, even if it should be parsed as a C file. Perhaps the invocation of the parser is missing some setting? Also, could this be the reason why on-the-fly and pch driven c

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added a comment. > As the CTUDir string prefix is only needed in case of the old approach, I > have refactored the external definition mapping storage to NOT include that. Both `ctu-main.c` and `ctu-on-demand-parsing.c` use the `-analyzer-config ctu-dir=%t/ctudir2` setting. So it is not

[PATCH] D75215: [DebugInfo] Fix for adding "returns cxx udt" option to functions in CodeView.

2020-03-05 Thread Amy Huang via Phabricator via cfe-commits
akhuang marked an inline comment as done. akhuang added inline comments. Comment at: llvm/include/llvm/IR/DebugInfoFlags.def:61 HANDLE_DI_FLAG((1 << 29), AllCallsDescribed) +HANDLE_DI_FLAG((1 << 30), CxxReturnUdt) rnk wrote: > aprantl wrote: > > dblaikie wrote

[PATCH] D74935: [LangRef][AliasAnalysis] Clarify `noalias` affects only modified objects

2020-03-05 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D74935#1907100 , @jeroen.dobbelaere wrote: > Just to give an example: > > int foo(int* restrict *pA, int* restrict *pB) { > int tmp=**pB; > **pA=42; > return tmp - **pB; // **pA and **pB can refer to the same ob

[PATCH] D73979: [HIP] Allow non-incomplete array type for extern shared var

2020-03-05 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. In D73979#1857736 , @yaxunl wrote: > BTW this is requested by HIP users, who have similar code for CUDA and HIP. > They found it surprised that nvcc allows it but hip-clang does not. I think I'm one of the HIP users here

[clang] 314b927 - Revert "[CGBlocks] Improve line info in backtraces containing *_helper_block"

2020-03-05 Thread Adrian Prantl via cfe-commits
Author: Adrian Prantl Date: 2020-03-05T09:58:42-08:00 New Revision: 314b9278f0975b12e15d6e12f896eaf7c4519ef2 URL: https://github.com/llvm/llvm-project/commit/314b9278f0975b12e15d6e12f896eaf7c4519ef2 DIFF: https://github.com/llvm/llvm-project/commit/314b9278f0975b12e15d6e12f896eaf7c4519ef2.diff

[PATCH] D75271: [analyzer][NFC] Change LangOptions to CheckerManager in the shouldRegister* functions.

2020-03-05 Thread Balogh, Ádám via Phabricator via cfe-commits
baloghadamsoftware requested changes to this revision. baloghadamsoftware added a comment. This revision now requires changes to proceed. This patch still does not help. Most of the functions of `CheckerManager` are non-const thus they cannot be called on a const object. E.g. `getAnalyzerOptions

[PATCH] D75494: [PowerPC] Delete PPCMachObjectWriter and triple for darwin

2020-03-05 Thread Sean Fertile via Phabricator via cfe-commits
sfertile accepted this revision. sfertile added a comment. This revision is now accepted and ready to land. LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75494/new/ https://reviews.llvm.org/D75494 __

[PATCH] D75697: [analyzer] Allow null false positive suppression for conditions

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, balazske, martong, xazax.hun, dcoughlin. Szelethus added a project: clang. Herald added subscribers: cfe-commits, steakhal, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, w

[PATCH] D75698: [analyzer][WIP] Suppress bug reports where a tracked expression's latest value change was a result of an invalidation

2020-03-05 Thread Kristóf Umann via Phabricator via cfe-commits
Szelethus created this revision. Szelethus added reviewers: NoQ, baloghadamsoftware, xazax.hun, rnkovacs, dcoughlin, martong, balazske. Szelethus added a project: clang. Herald added subscribers: cfe-commits, danielkiss, steakhal, Charusso, gamesh411, dkrupp, donat.nagy, mikhail.ramalho, a.sidori

[PATCH] D75690: [SVE][Inline-Asm] Add constraints for SVE ACLE types

2020-03-05 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added inline comments. Comment at: clang/lib/Basic/Targets/AArch64.h:95 +case 'U': // Three-character constraint; add "@3" hint for later parsing. + R = std::string("@3") + std::string(Constraint, 3); + Constraint += 2; Is "@3" some LLVM

[PATCH] D75563: [clang][Parse] properly parse asm-qualifiers, asm inline

2020-03-05 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/DiagnosticParseKinds.td:32 "'asm goto' cannot have output constraints">; +def err_asm_duplicate_qual : Error<"duplicate asm qualifier %0">; } `duplicate asm qualifier '%0'` (with the q

[PATCH] D75615: Revert "[CGBlocks] Improve line info in backtraces containing *_helper_block"

2020-03-05 Thread Adrian Prantl via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG314b9278f097: Revert "[CGBlocks] Improve line info in backtraces containing *_helper_block" (authored by aprantl). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[clang] f23df1b - Comment parsing: Treat \ref as inline command

2020-03-05 Thread Aaron Puchert via cfe-commits
Author: Aaron Puchert Date: 2020-03-05T19:44:34+01:00 New Revision: f23df1b2a323094e5a6869ef085f100fd065bc0d URL: https://github.com/llvm/llvm-project/commit/f23df1b2a323094e5a6869ef085f100fd065bc0d DIFF: https://github.com/llvm/llvm-project/commit/f23df1b2a323094e5a6869ef085f100fd065bc0d.diff

[PATCH] D75665: [analyzer] On-demand parsing capability for CTU

2020-03-05 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: clang/include/clang/CrossTU/CrossTranslationUnit.h:23 #include "llvm/ADT/StringMap.h" +#include "llvm/IR/DiagnosticInfo.h" +#include "llvm/IR/OperandTraits.h" Perhaps this include is needed only in the .cpp file?

  1   2   3   >