[PATCH] D35271: Fix printing policy for AST context loaded from file

2017-07-14 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. I wonder if it's possible to do away with the calls to 'updated()'... it seems strange that we initialize the same preprocessor repeatedly. Is there any way to finalize an ASTInfoCollector after ReadAST happens (or ASTReaderListeners in general)?

r308002 - [X86] Add 'movbe' to btver2 CPU.

2017-07-14 Thread Craig Topper via cfe-commits
Author: ctopper Date: Thu Jul 13 23:36:17 2017 New Revision: 308002 URL: http://llvm.org/viewvc/llvm-project?rev=308002=rev Log: [X86] Add 'movbe' to btver2 CPU. This probably doesn't change anything because the frotend doesn't do anything with this feature and the backend will infer from the

[PATCH] D26350: Keep invalid Switch in the AST

2017-07-14 Thread Olivier Goffart via Phabricator via cfe-commits
ogoffart added a comment. re-ping https://reviews.llvm.org/D26350 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Thanks for doing this! I have some comments: Comment at: docs/LanguageExtensions.rst:1277 +It is possible use the newest SDK but still build a program that can run on +older macOS and iOS versions, by passing ``-mmacosx-version-info=`` /

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D34440#808156, @vladimir.plyashkun wrote: > **To discuss:** > This patch is required for correct integration //Clang-Tidy// with //CLion > IDE//. > By this moment, we unable to use //CompilationDatabase.json// from //CLion > //side which is

[PATCH] D34267: do more processing in clang-fuzzer (use EmitAssemblyAction)

2017-07-14 Thread Manuel Klimek via Phabricator via cfe-commits
klimek accepted this revision. klimek added a comment. This revision is now accepted and ready to land. lg https://reviews.llvm.org/D34267 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D35190: __builtin_constant_p should consider the parameter of a constexpr function as constant

2017-07-14 Thread Olivier Goffart via Phabricator via cfe-commits
ogoffart added a comment. Is there any objections for this patch? https://reviews.llvm.org/D35190 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-07-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. The other possibility is to make the difference signed. https://reviews.llvm.org/D35109 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26350: Keep invalid Switch in the AST

2017-07-14 Thread Olivier Goffart via Phabricator via cfe-commits
ogoffart added a comment. The problem i'm trying to solve is precisely to keep as much as possible of the valid AST in the main AST, despite errors. I've already done some work with r249982, r272962 and more, and there is still a lot to do. But the goal is to keep as much as possible of it.

[PATCH] D35110: [Analyzer] Constraint Manager Negates Difference

2017-07-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 106627. baloghadamsoftware added a comment. Type selection simplified, FIXME added. https://reviews.llvm.org/D35110 Files: lib/StaticAnalyzer/Core/RangeConstraintManager.cpp test/Analysis/constraint_manager_negate_difference.c

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. The idea is to allows us changing the way we manage/rebuild PCHs and ASTs. ASTUnit is used for many things and has a fairly complicated and verbose interface and does a lot of mutations all other the place inside it, so making changes to it is not particularly

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D35406#809623, @malaperle wrote: > For synching with what I am doing. I am "only" looking right now at the > modeling of the index and its on-disk storage, not really on the speeding up > of the parsing of the TUs (i.e. the input of

[PATCH] D26350: Keep invalid Switch in the AST

2017-07-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. You've explained how you are accomplishing this but not why. I don't think Clang typically keeps erroneous AST nodes in the tree. What kind of problem is this intended to solve? https://reviews.llvm.org/D26350 ___

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. In https://reviews.llvm.org/D34440#809522, @klimek wrote: > In https://reviews.llvm.org/D34440#809325, @vladimir.plyashkun wrote: > > > Even if i'll change content of //arguments.rsp// to > > `-std=c++11 -Ipath/to/include -Ipath/to/include2 -DMACRO ` > > and will

[PATCH] D34275: [analyzer] Re-implemente current virtual calls checker in a path-sensitive way

2017-07-14 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp:72 +REGISTER_MAP_WITH_PROGRAMSTATE(CtorMap, const MemRegion *, bool) +REGISTER_MAP_WITH_PROGRAMSTATE(DtorMap, const MemRegion *, bool) + I was wondering if there is

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-07-14 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware updated this revision to Diff 106626. baloghadamsoftware added a comment. Difference of unsigned is converted to signed. https://reviews.llvm.org/D35109 Files: include/clang/AST/ASTContext.h lib/AST/ASTContext.cpp lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp

[clang-tools-extra] r308022 - [clang-tidy] Minor documentation fix. NFC.

2017-07-14 Thread Gabor Horvath via cfe-commits
Author: xazax Date: Fri Jul 14 05:31:21 2017 New Revision: 308022 URL: http://llvm.org/viewvc/llvm-project?rev=308022=rev Log: [clang-tidy] Minor documentation fix. NFC. Modified: clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-undefined-memory-manipulation.rst Modified:

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. In https://reviews.llvm.org/D34440#808156, @vladimir.plyashkun wrote: > **To discuss:** > ... > By this moment, we unable to use //CompilationDatabase.json// from //CLion > //side which is widely used in //Clang-Tidy// and in other common tools. It would be

[PATCH] D34654: Allow passing a regex for headers to exclude from clang-tidy

2017-07-14 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added reviewers: aaron.ballman, alexfh, hokein. JonasToth added a comment. i added reviewers, since it seems nobody takes care of this check. remove if this was bad. Repository: rL LLVM https://reviews.llvm.org/D34654 ___ cfe-commits

[clang-tools-extra] r308020 - [clang-tidy] Add bugprone-suspicious-memset-usage check

2017-07-14 Thread Gabor Horvath via cfe-commits
Author: xazax Date: Fri Jul 14 05:15:55 2017 New Revision: 308020 URL: http://llvm.org/viewvc/llvm-project?rev=308020=rev Log: [clang-tidy] Add bugprone-suspicious-memset-usage check Created new module bugprone and placed the check in that. Finds memset() calls with potential mistakes in their

[PATCH] D32700: [clang-tidy] Add bugprone-suspicious-memset-usage check.

2017-07-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308020: [clang-tidy] Add bugprone-suspicious-memset-usage check (authored by xazax). Changed prior to commit: https://reviews.llvm.org/D32700?vs=106620=106624#toc Repository: rL LLVM

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D34440#809581, @vladimir.plyashkun wrote: > > Are there any concerns using the alternative? > > I can't say that it's a big problems, but i think that: > //CompilationDatabase.json// is more //CMake //specific format. > It can be generated

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. In https://reviews.llvm.org/D34440#809325, @vladimir.plyashkun wrote: > Even if i'll change content of //arguments.rsp// to > `-std=c++11 -Ipath/to/include -Ipath/to/include2 -DMACRO ` > and will try to call clang-tidy process in this way: > `clang-tidy -checks=*

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. Could you explain what the goal of this change is? It would help understand how it will impact the indexing work I am currently doing. https://reviews.llvm.org/D35406 ___ cfe-commits mailing list

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. In https://reviews.llvm.org/D35406#809609, @ilya-biryukov wrote: > The idea is to allows us changing the way we manage/rebuild PCHs and ASTs. > ASTUnit is used for many things and has a fairly complicated and verbose > interface and does a lot of mutations all other

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Mostly done, thanks! Comment at: docs/LanguageExtensions.rst:1274 +Objective-C @available +-- sdy wrote: > sdy wrote: > > I think "Objective-C" is redundant, this is already in the ObjC section and > > most of the

[PATCH] D35081: [ThinLTO] Allow multiple summary entries.

2017-07-14 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. In https://reviews.llvm.org/D35081#808789, @tejohnson wrote: > In https://reviews.llvm.org/D35081#808517, @mehdi_amini wrote: > > > In https://reviews.llvm.org/D35081#808207, @tejohnson wrote: > > > > > My first option was if any copy is under the threshold, simply

[PATCH] D35427: [clang] Fix handling of "%zd" format specifier

2017-07-14 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! Repository: rL LLVM https://reviews.llvm.org/D35427 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D34475: [AArch64] Add support for __builtin_ms_va_list on aarch64

2017-07-14 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo updated this revision to Diff 106701. mstorsjo added a comment. Updated for the new version of https://reviews.llvm.org/D34474. https://reviews.llvm.org/D34475 Files: include/clang-c/Index.h include/clang/Basic/Builtins.def include/clang/Basic/BuiltinsX86.def

[PATCH] D35438: CodeGen: Ensure there is basic block when performing address space cast

2017-07-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Hmm. It doesn't seem unreasonable for this to require an insertion point as a precondition. In what situation do we emit addrspace casts after a return? https://reviews.llvm.org/D35438 ___ cfe-commits mailing list

[PATCH] D35427: [clang] Fix handling of "%zd" format specifier

2017-07-14 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexshap updated this revision to Diff 106694. alexshap added a comment. Address comments Repository: rL LLVM https://reviews.llvm.org/D35427 Files: lib/Analysis/PrintfFormatString.cpp test/FixIt/format.m Index: test/FixIt/format.m

[PATCH] D35438: CodeGen: Ensure there is basic block when performing address space cast

2017-07-14 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. There are cases when TargetCodeGenInfo::performAddrSpaceCast is called there is no basic block, e.g. right after a `return` statement. This causes dangling addrspacecast. This patch fixes that. https://reviews.llvm.org/D35438 Files: lib/CodeGen/TargetInfo.cpp

[PATCH] D35427: [clang] Fix handling of "%zd" format specifier

2017-07-14 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308067: [clang] Fix handling of "%zd" format specifier (authored by alexshap). Changed prior to commit: https://reviews.llvm.org/D35427?vs=106694=106726#toc Repository: rL LLVM

[PATCH] D35427: [clang] Fix handling of "%zd" format specifier

2017-07-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: aaron.ballman. aaron.ballman added inline comments. Comment at: lib/Analysis/PrintfFormatString.cpp:539 case LengthModifier::AsSizeT: return ArgType(); // FIXME: ssize_t case LengthModifier::AsPtrDiff: What

r308048 - Fix flag names in @available docs.

2017-07-14 Thread Nico Weber via cfe-commits
Author: nico Date: Fri Jul 14 11:52:30 2017 New Revision: 308048 URL: http://llvm.org/viewvc/llvm-project?rev=308048=rev Log: Fix flag names in @available docs. Modified: cfe/trunk/docs/LanguageExtensions.rst Modified: cfe/trunk/docs/LanguageExtensions.rst URL:

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis marked an inline comment as done. thakis added inline comments. Comment at: docs/LanguageExtensions.rst:1278 +It is possible use the newest SDK but still build a program that can run on +older macOS and iOS versions, by passing ``-mmacosx-version-info=`` /

Re: [PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Joerg Sonnenberger via cfe-commits
On Fri, Jul 14, 2017 at 02:40:25PM +, Manuel Klimek via Phabricator via cfe-commits wrote: > klimek added a comment. > > In https://reviews.llvm.org/D34440#809581, @vladimir.plyashkun wrote: > > > > Are there any concerns using the alternative? > > > > I can't say that it's a big problems,

[PATCH] D35426: [clang] Add abi-breaking-checks support to clang

2017-07-14 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added a comment. The test clang/test/Rewriter/objc-modern-metadata-visibility2.mm is listed as UNSUPPORTED since the test contains REQUIRES:abi-breaking-checks but clang does not support this yet. https://reviews.llvm.org/D35426 ___

r308041 - [Dominators] Update Clang's DominatorTree to use the new template argument

2017-07-14 Thread Jakub Kuderski via cfe-commits
Author: kuhar Date: Fri Jul 14 11:26:21 2017 New Revision: 308041 URL: http://llvm.org/viewvc/llvm-project?rev=308041=rev Log: [Dominators] Update Clang's DominatorTree to use the new template argument Summary: This patch makes the Clang's DominatorTree use the new IsPostDom template argument

[PATCH] D34475: [AArch64] Add support for __builtin_ms_va_list on aarch64

2017-07-14 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo updated this revision to Diff 106690. mstorsjo edited the summary of this revision. mstorsjo added a comment. Initial attempt at unifying the use of __builtin_ms_va_list and calling conventions between x86_64 and aarch64. This goes with the current (un-unified) version of

[PATCH] D35131: Prevent ClangTools from generating dependency files.D34304 created a way for ToolInvocations to conditionally generatedependency files, and updated call sites to preserve the old behav

2017-07-14 Thread Eric Christopher via Phabricator via cfe-commits
echristo accepted this revision. echristo added a comment. This revision is now accepted and ready to land. This sort of thing seems obvious in the future :) -eric https://reviews.llvm.org/D35131 ___ cfe-commits mailing list

r308044 - Add documentation for @available

2017-07-14 Thread Nico Weber via cfe-commits
Author: nico Date: Fri Jul 14 11:40:52 2017 New Revision: 308044 URL: http://llvm.org/viewvc/llvm-project?rev=308044=rev Log: Add documentation for @available https://reviews.llvm.org/D35379 Modified: cfe/trunk/docs/LanguageExtensions.rst cfe/trunk/include/clang/Basic/AttrDocs.td

r308046 - Fix link in docs.

2017-07-14 Thread Nico Weber via cfe-commits
Author: nico Date: Fri Jul 14 11:45:36 2017 New Revision: 308046 URL: http://llvm.org/viewvc/llvm-project?rev=308046=rev Log: Fix link in docs. Modified: cfe/trunk/include/clang/Basic/AttrDocs.td Modified: cfe/trunk/include/clang/Basic/AttrDocs.td URL:

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Sidney San Martín via Phabricator via cfe-commits
sdy added inline comments. Comment at: docs/LanguageExtensions.rst:1278 +It is possible use the newest SDK but still build a program that can run on +older macOS and iOS versions, by passing ``-mmacosx-version-info=`` / +``--miphoneos-version-min=``. thakis

r308043 - Prevent ClangTools from generating dependency files.

2017-07-14 Thread Sterling Augustine via cfe-commits
Author: saugustine Date: Fri Jul 14 11:33:30 2017 New Revision: 308043 URL: http://llvm.org/viewvc/llvm-project?rev=308043=rev Log: Prevent ClangTools from generating dependency files. D34304 created a way for ToolInvocations to conditionally generate dependency files, and updated call sites to

[PATCH] D35427: [clang] Fix handling of "%zd" format specifier

2017-07-14 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexshap created this revision. This diff addresses FIXME in lib/Analysis/PrintfFormatString.cpp and makes Clang warn on incorrect using of "%zd" format specifier. Test plan: make check-all Repository: rL LLVM https://reviews.llvm.org/D35427 Files: lib/Analysis/PrintfFormatString.cpp

[PATCH] D35426: [clang] Add abi-breaking-checks support to clang

2017-07-14 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang created this revision. You can now use REQUIRES:abi-breaking-checks in clang too https://reviews.llvm.org/D35426 Files: test/lit.cfg test/lit.site.cfg.in Index: test/lit.site.cfg.in === --- test/lit.site.cfg.in +++

r308045 - do more processing in clang-fuzzer (use EmitAssemblyAction)

2017-07-14 Thread Kostya Serebryany via cfe-commits
Author: kcc Date: Fri Jul 14 11:42:07 2017 New Revision: 308045 URL: http://llvm.org/viewvc/llvm-project?rev=308045=rev Log: do more processing in clang-fuzzer (use EmitAssemblyAction) Summary: use EmitAssemblyAction in clang-fuzzer Reviewers: klimek, rsmith Reviewed By: klimek Subscribers:

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. I went ahead and landed this in r308044, given that I addressed the nits and removed the possibly contentious bits. Happy to address remaining nits in a follow-up. https://reviews.llvm.org/D35379 ___ cfe-commits mailing

[PATCH] D34937: Suppressing Reference Counting Diagnostics for Functions Containing 'rc_ownership_trusted_implementation' Annotate Attribute

2017-07-14 Thread Malhar Thakkar via Phabricator via cfe-commits
malhar1995 updated this revision to Diff 106685. malhar1995 added a comment. Suppresses false positives involving functions which perform reference counting. Added relevant test-cases to test/Analysis/retain-release-inline.m https://reviews.llvm.org/D34937 Files:

[PATCH] D35051: [clang-tidy] Add bugprone-undefined-memory-manipulation check.

2017-07-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308021: [clang-tidy] Add bugprone-undefined-memory-manipulation check (authored by xazax). Changed prior to commit: https://reviews.llvm.org/D35051?vs=106234=106625#toc Repository: rL LLVM

[clang-tools-extra] r308021 - [clang-tidy] Add bugprone-undefined-memory-manipulation check

2017-07-14 Thread Gabor Horvath via cfe-commits
Author: xazax Date: Fri Jul 14 05:20:19 2017 New Revision: 308021 URL: http://llvm.org/viewvc/llvm-project?rev=308021=rev Log: [clang-tidy] Add bugprone-undefined-memory-manipulation check Patch by: Reka Nikolett Kovacs Differential Revision: https://reviews.llvm.org/D35051 Added:

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Vladimir Plyashkun via Phabricator via cfe-commits
vladimir.plyashkun added a comment. > Are there any concerns using the alternative? I can't say that it's a big problems, but i think that: //CompilationDatabase.json// is more //CMake //specific format. It can be generated automatically by //CMake//, while other build systems may not do it.

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis marked 7 inline comments as done. thakis added a comment. Thanks, all done, much better! Comment at: docs/LanguageExtensions.rst:1347 + +In rare cases, the availability annotation on an API might be overly +conservative. For example, ``[NSProcessInfo processInfo]``

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Sidney San Martín via Phabricator via cfe-commits
sdy added inline comments. Comment at: docs/LanguageExtensions.rst:1274 +Objective-C @available +-- I think "Objective-C" is redundant, this is already in the ObjC section and most of the other headers don't start with "Objective-C".

r308037 - [clang] Add getSignedSizeType method

2017-07-14 Thread Alexander Shaposhnikov via cfe-commits
Author: alexshap Date: Fri Jul 14 10:30:14 2017 New Revision: 308037 URL: http://llvm.org/viewvc/llvm-project?rev=308037=rev Log: [clang] Add getSignedSizeType method C11 standard refers to the signed counterpart of the type size_t in the paragraph 7.21.6.1 where it defines d, i, o, u, x, or x

[PATCH] D35378: [clang] Add getSignedSizeType method

2017-07-14 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308037: [clang] Add getSignedSizeType method (authored by alexshap). Changed prior to commit: https://reviews.llvm.org/D35378?vs=106496=106662#toc Repository: rL LLVM

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis updated this revision to Diff 106650. thakis marked an inline comment as done. thakis added a comment. arphaman comments https://reviews.llvm.org/D35379 Files: docs/LanguageExtensions.rst include/clang/Basic/AttrDocs.td Index: include/clang/Basic/AttrDocs.td

[PATCH] D34275: [analyzer] Re-implemente current virtual calls checker in a path-sensitive way

2017-07-14 Thread wangxin via Phabricator via cfe-commits
wangxindsb updated this revision to Diff 106654. wangxindsb marked an inline comment as done. wangxindsb added a comment. - Change two maps to one map. - Move the declarations of PSM and SVB after the next early return. - Delete the variable std::string DeclName. - Delete last return in

[PATCH] D34275: [analyzer] Re-implemente current virtual calls checker in a path-sensitive way

2017-07-14 Thread wangxin via Phabricator via cfe-commits
wangxindsb marked 5 inline comments as done. wangxindsb added inline comments. Comment at: lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp:72 +REGISTER_MAP_WITH_PROGRAMSTATE(CtorMap, const MemRegion *, bool) +REGISTER_MAP_WITH_PROGRAMSTATE(DtorMap, const MemRegion *, bool) +

r308035 - [Hexagon] Add intrinsics for data cache operations

2017-07-14 Thread Krzysztof Parzyszek via cfe-commits
Author: kparzysz Date: Fri Jul 14 09:01:24 2017 New Revision: 308035 URL: http://llvm.org/viewvc/llvm-project?rev=308035=rev Log: [Hexagon] Add intrinsics for data cache operations This is the clang part, adding support for void __builtin_HEXAGON_Y2_dccleana(void*); void

[PATCH] D35379: Add documentation for @available

2017-07-14 Thread Nico Weber via Phabricator via cfe-commits
thakis updated this revision to Diff 106652. thakis marked 3 inline comments as done. thakis added a comment. sdy comments https://reviews.llvm.org/D35379 Files: docs/LanguageExtensions.rst include/clang/Basic/AttrDocs.td Index: include/clang/Basic/AttrDocs.td

[PATCH] D35337: [Solaris] gcc runtime dropped support for .ctors, switch to .init_array

2017-07-14 Thread Fedor Sergeev via Phabricator via cfe-commits
fedor.sergeev added a comment. Can anybody commit this for me, please? :-/ https://reviews.llvm.org/D35337 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r308038 - Unconditionally use .init_array instead of .ctors on Solaris.

2017-07-14 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Fri Jul 14 10:49:52 2017 New Revision: 308038 URL: http://llvm.org/viewvc/llvm-project?rev=308038=rev Log: Unconditionally use .init_array instead of .ctors on Solaris. Patch by Fedor Sergeev Modified: cfe/trunk/lib/Driver/ToolChains/Gnu.cpp

[PATCH] D35337: [Solaris] gcc runtime dropped support for .ctors, switch to .init_array

2017-07-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Committed in r308038. https://reviews.llvm.org/D35337 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D32210: [Sema][ObjC] Add support for attribute "noescape"

2017-07-14 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 106735. ahatanak marked 3 inline comments as done. ahatanak added a comment. Address review comments. - Allow attaching "noescape" to pointers other than block pointers. Update the docs accordingly. - Attach attribute "nocapture" to parameters that are

[PATCH] D34654: Allow passing a regex for headers to exclude from clang-tidy

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added a comment. Please regenerate the patch with full context (e.g. as described in llvm.org/docs/Phabricator.html). Repository: rL LLVM https://reviews.llvm.org/D34654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D35438: CodeGen: Ensure there is basic block when performing address space cast

2017-07-14 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Oh, of course. Sadly, in C/C++ the declaration point of a variable does not necessarily dominate all uses of the variable, so you need to emit the cast immediately after the alloca. Just temporarily move CGF.Builder to that point; hopefully we can assume that this

[PATCH] D35438: CodeGen: Ensure there is basic block when performing address space cast

2017-07-14 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added a comment. In https://reviews.llvm.org/D35438#810234, @rjmccall wrote: > Hmm. It doesn't seem unreasonable for this to require an insertion point as > a precondition. In what situation do we emit addrspace casts after a return? When the alloca address space is not zero and we

r308077 - [ODRHash] Revert r307743 which reverted r307720

2017-07-14 Thread Richard Trieu via cfe-commits
Author: rtrieu Date: Fri Jul 14 19:55:13 2017 New Revision: 308077 URL: http://llvm.org/viewvc/llvm-project?rev=308077=rev Log: [ODRHash] Revert r307743 which reverted r307720 Reapply r307720 to allow processing of constructors and destructors. Reuse the diagnostics for CXXMethodDecl for them.

[PATCH] D26350: Keep invalid Switch in the AST

2017-07-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D26350#809577, @ogoffart wrote: > The problem i'm trying to solve is precisely to keep as much as possible of > the valid AST in the main AST, despite errors. > I've already done some work with r249982, r272962 and more, and there is

r308073 - [clang] Fix format test

2017-07-14 Thread Alexander Shaposhnikov via cfe-commits
Author: alexshap Date: Fri Jul 14 18:06:59 2017 New Revision: 308073 URL: http://llvm.org/viewvc/llvm-project?rev=308073=rev Log: [clang] Fix format test This diff makes the test FixIt/format.m more robust. The issue was caught by the build bot clang-cmake-thumbv7-a15. Test plan: make

r308067 - [clang] Fix handling of "%zd" format specifier

2017-07-14 Thread Alexander Shaposhnikov via cfe-commits
Author: alexshap Date: Fri Jul 14 15:57:00 2017 New Revision: 308067 URL: http://llvm.org/viewvc/llvm-project?rev=308067=rev Log: [clang] Fix handling of "%zd" format specifier This diff addresses FIXME in lib/Analysis/PrintfFormatString.cpp and makes PrintfSpecifier::getArgType return the

r308071 - Try to fix modules build

2017-07-14 Thread Matthias Braun via cfe-commits
Author: matze Date: Fri Jul 14 17:29:25 2017 New Revision: 308071 URL: http://llvm.org/viewvc/llvm-project?rev=308071=rev Log: Try to fix modules build Module builds somehow report an ambiguity between clang::Diagnostic and clang::Tooling::Diagnostic. It seems as if one of the additional headers

[PATCH] D35448: [Bash-autocompletion] Fixed a bug on bash

2017-07-14 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu accepted this revision. ruiu added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D35448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D35449: [X86] Implement __builtin_cpu_is

2017-07-14 Thread Craig Topper via Phabricator via cfe-commits
craig.topper created this revision. This patch adds support for __builtin_cpu_is. I've tried to match the strings supported to the latest version of gcc. I've only tested this on my Macbook so far so I'd appreciate if others would test it. An AMD system would be great.

[PATCH] D35447: [Bash-autocompletion] Add support for -W and -Wno

2017-07-14 Thread Yuka Takahashi via Phabricator via cfe-commits
yamaguchi created this revision. `-W[tab]` will autocomplete warnings defined in this link: https://clang.llvm.org/docs/DiagnosticsReference.html#wweak-vtables https://reviews.llvm.org/D35447 Files: clang/include/clang/Basic/DiagnosticIDs.h clang/lib/Basic/DiagnosticIDs.cpp

[PATCH] D35448: [Bash-autocompletion] Fixed a bug on bash

2017-07-14 Thread Yuka Takahashi via Phabricator via cfe-commits
yamaguchi created this revision. Maybe I mismerged when merging previous commits by hand. https://reviews.llvm.org/D35448 Files: clang/utils/bash-autocomplete.sh Index: clang/utils/bash-autocomplete.sh === ---

[PATCH] D35447: [Bash-autocompletion] Add support for -W and -Wno

2017-07-14 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added inline comments. Comment at: clang/include/clang/Basic/DiagnosticIDs.h:266 + static std::vector getDiagnosticFlags(); + Please write a function comment just like other member functions in this class. Comment at:

[PATCH] D32700: [clang-tidy] Add bugprone-suspicious-memset-usage check.

2017-07-14 Thread Whisperity via Phabricator via cfe-commits
whisperity added inline comments. Comment at: clang-tidy/bugprone/SuspiciousMemsetUsageCheck.cpp:57-58 +void SuspiciousMemsetUsageCheck::check(const MatchFinder::MatchResult ) { + // Case 1: fill_char of memset() is a character '0'. Probably an integer zero + // was intended.

[PATCH] D32700: [clang-tidy] Add bugprone-suspicious-memset-usage check.

2017-07-14 Thread Reka Kovacs via Phabricator via cfe-commits
rnkovacs updated this revision to Diff 106620. rnkovacs marked an inline comment as done. rnkovacs added a comment. Moved comments inside `if` bodies. https://reviews.llvm.org/D32700 Files: clang-tidy/CMakeLists.txt clang-tidy/bugprone/BugproneTidyModule.cpp

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 106632. ilya-biryukov added a comment. - Replaced TODO with FIXME in a comment. https://reviews.llvm.org/D35406 Files: clangd/ClangdServer.cpp clangd/ClangdUnit.cpp clangd/ClangdUnit.h Index: clangd/ClangdUnit.h

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman requested changes to this revision. arphaman added a comment. This revision now requires changes to proceed. Nice, I will need something like this for the refactoring stress test tool in the future that verifies that the indexer and renaming engine have a similar view of the code.

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked 2 inline comments as done. ilya-biryukov added inline comments. Comment at: lib/Index/IndexingAction.cpp:181 +void index::indexTopLevelDecls(ASTContext , ArrayRef Decls, +std::shared_ptr DataConsumer, +

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman accepted this revision. arphaman added a comment. This revision is now accepted and ready to land. LGTM, thanks. https://reviews.llvm.org/D35405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 106604. ilya-biryukov added a comment. - Fixed formatting. https://reviews.llvm.org/D35405 Files: include/clang/Index/IndexingAction.h lib/Index/IndexingAction.cpp Index: lib/Index/IndexingAction.cpp

r308012 - [analyzer] Add annotation for functions taking user-facing strings

2017-07-14 Thread Erik Verbruggen via cfe-commits
Author: erikjv Date: Fri Jul 14 03:24:36 2017 New Revision: 308012 URL: http://llvm.org/viewvc/llvm-project?rev=308012=rev Log: [analyzer] Add annotation for functions taking user-facing strings There was already a returns_localized_nsstring annotation to indicate that the return value could be

[PATCH] D35186: [analyzer] Add annotation for functions taking user-facing strings

2017-07-14 Thread Erik Verbruggen via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308012: [analyzer] Add annotation for functions taking user-facing strings (authored by erikjv). Changed prior to commit: https://reviews.llvm.org/D35186?vs=105792=106605#toc Repository: rL LLVM

[clang-tools-extra] r308015 - [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output

2017-07-14 Thread Alexander Kornienko via cfe-commits
Author: alexfh Date: Fri Jul 14 03:37:46 2017 New Revision: 308015 URL: http://llvm.org/viewvc/llvm-project?rev=308015=rev Log: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output Summary: To get properly integration Clang-Tidy with CLion IDE, next things were

r308014 - [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output

2017-07-14 Thread Alexander Kornienko via cfe-commits
Author: alexfh Date: Fri Jul 14 03:37:44 2017 New Revision: 308014 URL: http://llvm.org/viewvc/llvm-project?rev=308014=rev Log: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output Summary: To get properly integration Clang-Tidy with CLion IDE, next things were

[PATCH] D34404: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: unittests/Tooling/DiagnosticsYamlTest.cpp:35-45 +TEST(DiagnosticsYamlTest, serializesDiagnostics) { + TranslationUnitDiagnostics TUD; + TUD.MainSourceFile = "path/to/source.cpp"; + + StringMap Fix1 = { +{ +

[PATCH] D34404: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308014: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output (authored by alexfh). Changed prior to commit: https://reviews.llvm.org/D34404?vs=106402=106608#toc Repository:

[PATCH] D35349: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308015: [Clang-Tidy] Preserve Message, FileOffset, FilePath in Clang-Tidy YAML output (authored by alexfh). Changed prior to commit: https://reviews.llvm.org/D35349?vs=106406=106609#toc Repository:

[PATCH] D32700: [clang-tidy] Add bugprone-suspicious-memset-usage check.

2017-07-14 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. Looks good with a single comment. Thank you for working on this! Comment at: clang-tidy/bugprone/SuspiciousMemsetUsageCheck.cpp:74-75 + + // Case 2: fill_char of memset()

r308016 - [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Fri Jul 14 03:47:45 2017 New Revision: 308016 URL: http://llvm.org/viewvc/llvm-project?rev=308016=rev Log: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls. Summary: We need it in clangd for refactoring that replaces ASTUnit with manual AST

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL308016: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls. (authored by ibiryukov). Changed prior to commit: https://reviews.llvm.org/D35405?vs=106604=106614#toc Repository:

[PATCH] D35406: [clangd] Replace ASTUnit with manual AST management.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. This refactoring does not aim to introduce any significant changes to the behaviour of clangd to keep the change as simple as possible. https://reviews.llvm.org/D35406 Files: clangd/ClangdServer.cpp clangd/ClangdUnit.cpp clangd/ClangdUnit.h Index:

[PATCH] D35405: [index] Added a method indexTopLevelDecls to run indexing on a list of Decls.

2017-07-14 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. For reference: clangd refactoring https://reviews.llvm.org/D35406 https://reviews.llvm.org/D35405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34440: [Clang] Expand response files before loading compilation database

2017-07-14 Thread Vladimir Plyashkun via Phabricator via cfe-commits
vladimir.plyashkun added a comment. Thanks @klimek for the response! Let me give an example. Suppose we want to check //main.cpp// by clang-tidy. As i said before, i cannot use //CompilationDatabase.json// (due to some technical reasons), but there is way to pass all options though command line

r308008 - Keep the IdentifierInfo in the Token for alternative operator keyword

2017-07-14 Thread Olivier Goffart via cfe-commits
Author: ogoffart Date: Fri Jul 14 02:23:40 2017 New Revision: 308008 URL: http://llvm.org/viewvc/llvm-project?rev=308008=rev Log: Keep the IdentifierInfo in the Token for alternative operator keyword The goal of this commit is to fix clang-format so it does not merge tokens when using the

  1   2   >