r333626 - [X86] Make 512-bit unmasked load/store builtins more like their 128/256-bit equivalents.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 22:02:08 2018 New Revision: 333626 URL: http://llvm.org/viewvc/llvm-project?rev=333626=rev Log: [X86] Make 512-bit unmasked load/store builtins more like their 128/256-bit equivalents. Previously we were just passing -1 mask to the masked builtin. This changes

[PATCH] D44480: [Sema] Don't skip function bodies with 'auto' without trailing return type

2018-05-30 Thread S. B. Tam via Phabricator via cfe-commits
cpplearner added a comment. Does `getAs()` work correctly with function returning `auto&`? Repository: rL LLVM https://reviews.llvm.org/D44480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47567: [wip] Implement CFI for indirect calls via a member function pointer.

2018-05-30 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc created this revision. pcc added a reviewer: vlad.tsyrklevich. Herald added a subscriber: mgrang. Similarly to CFI on virtual and indirect calls, this implementation tries to use program type information to make the checks as precise as possible. The basic way that it works is as follows,

r333617 - [X86] Fix wrong intrinsic semantic.

2018-05-30 Thread Tim Shen via cfe-commits
Author: timshen Date: Wed May 30 18:51:07 2018 New Revision: 333617 URL: http://llvm.org/viewvc/llvm-project?rev=333617=rev Log: [X86] Fix wrong intrinsic semantic. Modified: cfe/trunk/lib/Headers/avxintrin.h cfe/trunk/lib/Headers/emmintrin.h Modified: cfe/trunk/lib/Headers/avxintrin.h

r333615 - [X86] Fix some places where macro arguments to intrinsics weren't cast to _m512(i|d)/_m256(i|d/_m128(i|d) first.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 18:24:40 2018 New Revision: 333615 URL: http://llvm.org/viewvc/llvm-project?rev=333615=rev Log: [X86] Fix some places where macro arguments to intrinsics weren't cast to _m512(i|d)/_m256(i|d/_m128(i|d) first. The majority of the cases were correct. This fixes

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-30 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. Just minor comments. Feel free to commit after handling them. Comment at: include/clang/Basic/LangOptions.def:301 +LANGOPT(FixedPointEnabled, 1, 0, "Fixed point types are enabled") + ebevhan wrote: >

[PATCH] D46805: If some platforms do not support an attribute, we should exclude the platform

2018-05-30 Thread Dan Gohman via Phabricator via cfe-commits
sunfish added a comment. In https://reviews.llvm.org/D46805#1115681, @rsmith wrote: > In https://reviews.llvm.org/D46805#1113358, @aaron.ballman wrote: > > > @rsmith -- do the object file formats listed look correct to you? > > > They look at least plausible. We should be able to test whether

r333612 - [analyzer] Trust _Nonnull annotations, and trust analyzer knowledge about receiver nullability

2018-05-30 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Wed May 30 17:28:13 2018 New Revision: 333612 URL: http://llvm.org/viewvc/llvm-project?rev=333612=rev Log: [analyzer] Trust _Nonnull annotations, and trust analyzer knowledge about receiver nullability Previously, the checker was using the nullability of the

[PATCH] D47557: Filesystem tests: un-confuse write time

2018-05-30 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: test/std/experimental/filesystem/fs.op.funcs/fs.op.last_write_time/last_write_time.pass.cpp:257-258 TEST_CHECK(dtime2 > dtime); -TEST_CHECK(LastAccessTime(file) == file_access_time || - LastAccessTime(file) ==

[PATCH] D35450: [analyzer] Support generating and reasoning over more symbolic constraint types

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov requested changes to this revision. george.karpenkov added a comment. This revision now requires changes to proceed. @ddcc so would be great if we could split this patch into smaller chunks. https://reviews.llvm.org/D35450 ___

[PATCH] D18860: [analyzer] Fix the "Zombie symbols" issue.

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov requested changes to this revision. george.karpenkov added a comment. This revision now requires changes to proceed. Herald added a subscriber: baloghadamsoftware. The change LGTM after nits and rebasing IF the new evaluation will not show a too large regression.

[PATCH] D39398: [CFG][Analyzer] Add LoopExit element to the CFG in more cases

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov requested changes to this revision. george.karpenkov added inline comments. This revision now requires changes to proceed. Herald added a subscriber: dmgreen. Comment at: lib/Analysis/CFG.cpp:1348 +for (auto : ASTCtx.getParents(Node)) { +

[PATCH] D44238: [CFG] Fix automatic destructors when a member is bound to a reference.

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov accepted this revision. george.karpenkov added a comment. This revision is now accepted and ready to land. I'm not an expert in CFG construction, but looks good to me. https://reviews.llvm.org/D44238 ___ cfe-commits mailing list

[PATCH] D41150: [CFG] Adding new CFGStmt LoopEntrance for the StaticAnalyzer

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. Also loops created with gotos should also be supported (e.g. by finding backedges), but that could be done in a different patch. https://reviews.llvm.org/D41150 ___ cfe-commits mailing list

[PATCH] D41150: [CFG] Adding new CFGStmt LoopEntrance for the StaticAnalyzer

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. I would prefer a more detailed CFG element with more meta-information about nested loop, but this is a good starting point. https://reviews.llvm.org/D41150 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D47564: [Parse] Use CapturedStmt for @finally on MSVC

2018-05-30 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai updated this revision to Diff 149220. smeenai added a comment. Proper diff Repository: rC Clang https://reviews.llvm.org/D47564 Files: include/clang/AST/Stmt.h include/clang/Basic/CapturedStmt.h include/clang/Sema/ScopeInfo.h lib/Parse/ParseObjc.cpp

[PATCH] D47564: [Parse] Use CapturedStmt for @finally on MSVC

2018-05-30 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai created this revision. smeenai added reviewers: rjmccall, rnk, rsmith. Herald added a subscriber: cfe-commits. The body of a @finally needs to be executed on both exceptional and non-exceptional paths. On landingpad platforms, this is straightforward: the @finally body is emitted as a

[PATCH] D47557: Filesystem tests: un-confuse write time

2018-05-30 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added inline comments. Comment at: test/std/experimental/filesystem/fs.op.funcs/fs.op.last_write_time/last_write_time.pass.cpp:257-258 TEST_CHECK(dtime2 > dtime); -TEST_CHECK(LastAccessTime(file) == file_access_time || - LastAccessTime(file) ==

[PATCH] D46918: [Coverage] Discard the last uncompleted deferred region in a decl

2018-05-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL333609: [Coverage] Discard the last uncompleted deferred region in a decl (authored by vedantk, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit:

[PATCH] D46918: [Coverage] Discard the last uncompleted deferred region in a decl

2018-05-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333609: [Coverage] Discard the last uncompleted deferred region in a decl (authored by vedantk, committed by ). Repository: rL LLVM https://reviews.llvm.org/D46918 Files:

r333609 - [Coverage] Discard the last uncompleted deferred region in a decl

2018-05-30 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Wed May 30 16:35:44 2018 New Revision: 333609 URL: http://llvm.org/viewvc/llvm-project?rev=333609=rev Log: [Coverage] Discard the last uncompleted deferred region in a decl Discard the last uncompleted deferred region in a decl, if one exists. This prevents lines at the end

[PATCH] D45532: [StaticAnalyzer] Checker to find uninitialized fields after a constructor call

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @Szelethus I personally really like this idea, and I think it would be a great checker. Could you perform more evaluation on other projects? https://reviews.llvm.org/D45532 ___ cfe-commits mailing list

r333606 - [www] Update C++ status to cover P0620.

2018-05-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed May 30 16:30:36 2018 New Revision: 333606 URL: http://llvm.org/viewvc/llvm-project?rev=333606=rev Log: [www] Update C++ status to cover P0620. While here, mark three-way comparison as in progress and bump "Clang 6" items from yellow to green. Modified:

[PATCH] D46602: [clang-tidy] Store checks profiling info as YAML files

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov accepted this revision. george.karpenkov added a comment. LGTM with a nit to me, but maybe clang-tidy code owners would need to sign that off as well. Comment at: clang-tidy/ClangTidy.h:232 + bool EnableCheckProfile = false, +

[PATCH] D47350: [analyzer] Track class member initializer constructors path-sensitively within their construction context.

2018-05-30 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Refactor everything to address review comments. Comment at: lib/StaticAnalyzer/Core/ExprEngine.cpp:123 +/// AST nodes. +class ConstructedObjectKey : public ConstructedObjectKeyImpl { + const void *getAnyASTNodePtr() const {

[PATCH] D47350: [analyzer] Track class member initializer constructors path-sensitively within their construction context.

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov accepted this revision. george.karpenkov added a comment. This revision is now accepted and ready to land. LGTM, but I would really prefer if you could split that inheritance back into composition. Comment at: lib/StaticAnalyzer/Core/ExprEngine.cpp:123 +///

[PATCH] D47233: [CodeGen] Emit MSVC RTTI for Obj-C EH types

2018-05-30 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added a comment. In https://reviews.llvm.org/D47233#1115630, @DHowett-MSFT wrote: > This largely matches what we've done in the WinObjC clang patchset here > ,

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-30 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: include/clang/Basic/DiagnosticLexKinds.td:713 +def warn_quoted_include_in_framework_header : Warning< + "double-quoted include \"%0\" in framework header, expected system style include" + >, InGroup, DefaultIgnore;

r333603 - [X86] Use C style comments in intrinsic headers for overall consistency.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 15:33:21 2018 New Revision: 333603 URL: http://llvm.org/viewvc/llvm-project?rev=333603=rev Log: [X86] Use C style comments in intrinsic headers for overall consistency. Most of the origial comments used C style /* */ comments, but some C++ // comments had snuck

r333602 - IRGen: Rename bitsets -> type metadata. NFC.

2018-05-30 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Wed May 30 15:29:08 2018 New Revision: 333602 URL: http://llvm.org/viewvc/llvm-project?rev=333602=rev Log: IRGen: Rename bitsets -> type metadata. NFC. "Type metadata" is the term that we've been using for the CFI-related information on vtables for a while now. Modified:

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-30 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: include/clang/Basic/DiagnosticLexKinds.td:713 +def warn_quoted_include_in_framework_header : Warning< + "double-quoted include \"%0\" in framework header, expected system style include" + >, InGroup, DefaultIgnore;

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-30 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: include/clang/Basic/DiagnosticLexKinds.td:713 +def warn_quoted_include_in_framework_header : Warning< + "double-quoted include \"%0\" in framework header, expected system style include" + >, InGroup, DefaultIgnore;

r333600 - AST: Remove an unused ctor. NFC.

2018-05-30 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Wed May 30 15:14:17 2018 New Revision: 333600 URL: http://llvm.org/viewvc/llvm-project?rev=333600=rev Log: AST: Remove an unused ctor. NFC. Modified: cfe/trunk/include/clang/AST/VTableBuilder.h Modified: cfe/trunk/include/clang/AST/VTableBuilder.h URL:

r333599 - PR37631: verify that a member deduction guide has the same access as its template.

2018-05-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed May 30 15:13:43 2018 New Revision: 333599 URL: http://llvm.org/viewvc/llvm-project?rev=333599=rev Log: PR37631: verify that a member deduction guide has the same access as its template. Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

r333598 - AST: Remove an unused function. NFC.

2018-05-30 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Wed May 30 15:10:07 2018 New Revision: 333598 URL: http://llvm.org/viewvc/llvm-project?rev=333598=rev Log: AST: Remove an unused function. NFC. Modified: cfe/trunk/include/clang/AST/VTableBuilder.h Modified: cfe/trunk/include/clang/AST/VTableBuilder.h URL:

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-30 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added inline comments. Comment at: include/clang/Basic/DiagnosticLexKinds.td:713 +def warn_quoted_include_in_framework_header : Warning< + "double-quoted include \"%0\" in framework header, expected system style include" + >, InGroup, DefaultIgnore;

[PATCH] D47157: Warning for framework headers using double quote includes

2018-05-30 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a subscriber: arphaman. bruno added inline comments. Comment at: lib/Lex/HeaderSearch.cpp:753-754 + IncluderAndDir.second->getName())) +Diags.Report(IncludeLoc, + diag::warn_quoted_include_in_framework_header) +

[PATCH] D44954: [clangd] Add "member" symbols to the index

2018-05-30 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle updated this revision to Diff 149206. malaperle added a comment. Update with suggestions. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44954 Files: clangd/CodeComplete.cpp clangd/CodeComplete.h clangd/index/Index.h clangd/index/MemIndex.cpp

[PATCH] D44954: [clangd] Add "member" symbols to the index

2018-05-30 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle marked an inline comment as done. malaperle added inline comments. Comment at: clangd/index/Index.h:158 unsigned References = 0; - + /// Whether or not this is symbol is meant to be used for the global + /// completion. sammccall wrote: > ioeric

[PATCH] D47350: [analyzer] Track class member initializer constructors path-sensitively within their construction context.

2018-05-30 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 149205. NoQ marked 3 inline comments as done. NoQ added a comment. Refactor everything to address review comments. https://reviews.llvm.org/D47350 Files: include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h lib/StaticAnalyzer/Core/ExprEngine.cpp

[PATCH] D35450: [analyzer] Support generating and reasoning over more symbolic constraint types

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > I can also split out the APSInt fix into a separate patch. Yes please. In general I really dislike arbitrary "complexity cutoffs", as they make further debugging hard and may lead to weird bugs: could you explain why is that required and can not be avoided?

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @xazax.hun > So strictly speaking it is not a deduplication on the constraint level but on > the symbol level. Right, apologies, I was initially mistaken then. That's not even deduplication, I would call it using the interval solver to guide the constraint

r333594 - Add fopen to the list of builtins that we check and whitelist.

2018-05-30 Thread Eric Christopher via cfe-commits
Author: echristo Date: Wed May 30 14:11:45 2018 New Revision: 333594 URL: http://llvm.org/viewvc/llvm-project?rev=333594=rev Log: Add fopen to the list of builtins that we check and whitelist. Modified: cfe/trunk/include/clang/Basic/Builtins.def

r333593 - [X86] Add __extension__ to a bunch of places in our intrinsic headers that fail if you run it through -pedantic -ansi.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 14:08:27 2018 New Revision: 333593 URL: http://llvm.org/viewvc/llvm-project?rev=333593=rev Log: [X86] Add __extension__ to a bunch of places in our intrinsic headers that fail if you run it through -pedantic -ansi. All of these are lines that create a 'compound

[PATCH] D47557: Filesystem tests: un-confuse write time

2018-05-30 Thread JF Bastien via Phabricator via cfe-commits
jfb created this revision. jfb added reviewers: EricWF, mclow.lists, aemerson. Herald added subscribers: cfe-commits, christof. The filesystem test was confused about access versus write / modification time. The spec says: file_time_type last_write_time(const path& p, error_code& ec)

[PATCH] D47554: [analyzer] Check for dead/impossible status checks

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @trixirt I wrote a bunch of comments inline, but then after looking at the test cases, this would not work. This is a dataflow, all-paths check (the variable can NEVER be a nullptr), yet symbolic execution runs on A given paths. Currently in the analyzer

[PATCH] D47555: [HIP] Fix unbundling

2018-05-30 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added a reviewer: rjmccall. HIP uses clang-offload-bundler to bundle intermediate files for host and different gpu archs together. When a file is unbundled, clang-offload-bundler should be called only once, and the objects for host and different gpu archs

[PATCH] D35450: [analyzer] Support generating and reasoning over more symbolic constraint types

2018-05-30 Thread Dominic Chen via Phabricator via cfe-commits
ddcc added a comment. In https://reviews.llvm.org/D35450#1116535, @george.karpenkov wrote: > @ddcc Hi, are you still interested in landing the fixes associated with this > patch? I can take a look as I'm currently reviewing > https://reviews.llvm.org/D45517, but it is likely that the patch

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In https://reviews.llvm.org/D45517#1116770, @george.karpenkov wrote: > > I am not not sure that I got the idea what are you suggesting here. If we > > have the constraint of for example a symbol s > 10 and later on a path we > > discover s > 20, will we also

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > I am not not sure that I got the idea what are you suggesting here. If we > have the constraint of for example a symbol s > 10 and later on a path we > discover s > 20, will we also deduplicate this that way? No. But I thought in your optimization atoms

r333589 - PR34520: after instantiating a non-templated member deduction guide, don't forget to push it into the class scope.

2018-05-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed May 30 13:24:10 2018 New Revision: 333589 URL: http://llvm.org/viewvc/llvm-project?rev=333589=rev Log: PR34520: after instantiating a non-templated member deduction guide, don't forget to push it into the class scope. Modified:

[PATCH] D47554: [analyzer] Check for dead/impossible status checks

2018-05-30 Thread Tom Rix via Phabricator via cfe-commits
trixirt created this revision. trixirt added a reviewer: dcoughlin. Herald added subscribers: cfe-commits, a.sidorin, szepet, xazax.hun, mgorny. Herald added a reviewer: george.karpenkov. The c++ 'new' function has several variants. Only the no-throw versions of these return a nullptr on failure.

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In https://reviews.llvm.org/D45517#1116734, @george.karpenkov wrote: > @xazax.hun (I'll reply here to avoid scattering the conversation across many > subtrees) > > I was thinking about the optimization for not adding redundant constraints > some more, and I've

r333587 - As discussed with SG10, bump version of __cpp_deduction_guides macro to indicate support for P0620R0.

2018-05-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed May 30 12:54:52 2018 New Revision: 333587 URL: http://llvm.org/viewvc/llvm-project?rev=333587=rev Log: As discussed with SG10, bump version of __cpp_deduction_guides macro to indicate support for P0620R0. Modified: cfe/trunk/lib/Frontend/InitPreprocessor.cpp

[PATCH] D47121: [NEON] Support VLD1xN intrinsics in AArch32 mode (Clang part)

2018-05-30 Thread Ivan Kosarev via Phabricator via cfe-commits
kosarev added a comment. Thanks for reviewing. Comment at: lib/CodeGen/CGBuiltin.cpp:7865 } // FIXME: Sharing loads & stores with 32-bit is complicated by the absence // of an Align parameter here. SjoerdMeijer wrote: > How about this FIXME? Is it

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. @xazax.hun (I'll reply here to avoid scattering the conversation across many subtrees) I was thinking about the optimization for not adding redundant constraints some more, and I've decided I'm still against it --- we are creating a higher potential for bugs,

[PATCH] D47067: Update NRVO logic to support early return

2018-05-30 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Slightly reduced testcase: template T f(T u, bool b) { T t; if (b) return t; return u; } struct X { X(); X(const X&); ~X(); void *data; }; template X f(X, bool); ... which compiles to: X f(X u, bool b) { X::X(); if (b) return; X::X(,

[PATCH] D47067: Update NRVO logic to support early return

2018-05-30 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Based on the ASan output, it looks like the miscompile is probably happening in `SparseSolver::getValueState(LatticeKey)` at around include/llvm/Analysis/SparsePropagation.h:240: template LatticeVal SparseSolver::getValueState(LatticeKey Key) { auto I =

[PATCH] D47067: Update NRVO logic to support early return

2018-05-30 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. One of the sanitizer bots has more useful information on the problem: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-bootstrap/builds/5743 Repository: rC Clang https://reviews.llvm.org/D47067 ___ cfe-commits

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added inline comments. Comment at: lib/StaticAnalyzer/Core/BugReporterVisitors.cpp:2382 +// Reset the solver +RefutationMgr.reset(); + } xazax.hun wrote: > george.karpenkov wrote: > > xazax.hun wrote: > > > george.karpenkov wrote: > > >

[PATCH] D47350: [analyzer] Track class member initializer constructors path-sensitively within their construction context.

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov requested changes to this revision. george.karpenkov added a comment. This revision now requires changes to proceed. requesting changes due to minor nits inline Comment at: lib/StaticAnalyzer/Core/ExprEngine.cpp:152 +} + } + void

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: lib/StaticAnalyzer/Core/BugReporterVisitors.cpp:2382 +// Reset the solver +RefutationMgr.reset(); + } george.karpenkov wrote: > xazax.hun wrote: > > george.karpenkov wrote: > > > george.karpenkov wrote: > > >

[PATCH] D47445: [ASTImporter] Corrected diagnostic client handling in tests.

2018-05-30 Thread Argyrios Kyrtzidis via Phabricator via cfe-commits
akyrtzi added a comment. It's not clear to me what kind of issue you are addressing, for example is the unit test hitting an assertion hit without your changes ? Or is there something else ? Also it would be good to add some documentation comments to clarify what's the use case and when

[PATCH] D47135: [analyzer] A checker for dangling internal buffer pointers in C++

2018-05-30 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/StaticAnalyzer/Checkers/DanglingInternalBufferChecker.cpp:33 +public: + DanglingInternalBufferChecker() : CStrFn("c_str") {} + xbolva00 wrote: > string.data() support? Yup, there's a lot of API support improvements

[PATCH] D46846: [AST] Fix loss of enum forward decl from decl context

2018-05-30 Thread Joel E. Denny via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333574: [AST] Fix loss of enum forward decl from decl context (authored by jdenny, committed by ). Repository: rC Clang https://reviews.llvm.org/D46846 Files: lib/Sema/SemaDecl.cpp

r333574 - [AST] Fix loss of enum forward decl from decl context

2018-05-30 Thread Joel E. Denny via cfe-commits
Author: jdenny Date: Wed May 30 11:33:53 2018 New Revision: 333574 URL: http://llvm.org/viewvc/llvm-project?rev=333574=rev Log: [AST] Fix loss of enum forward decl from decl context For example, given: enum __attribute__((deprecated)) T *p; -ast-print produced: enum T *p; The attribute

[PATCH] D46664: Fix null MSInheritanceAttr deref in CXXRecordDecl::getMSInheritanceModel()

2018-05-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. As far as workarounds go, this looks great! Please add a test case, I think you had one in the initial patch. Should I go ahead and commit this? https://reviews.llvm.org/D46664

[PATCH] D47480: clang-cl: Expose -no-canonical-prefixes

2018-05-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. lgtm Comment at: test/Driver/cl-options.c:595 +// RUN: -no-canonical-prefixes \ +// RUN: -fno-coverage-mapping \ // RUN: --version \ takuto.ikuta

r333572 - [X86] Simplify the implementation of _mm_sqrt_ss, _mm_rcp_ss, and _mm_rsqrt_ss.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 11:27:07 2018 New Revision: 333572 URL: http://llvm.org/viewvc/llvm-project?rev=333572=rev Log: [X86] Simplify the implementation of _mm_sqrt_ss, _mm_rcp_ss, and _mm_rsqrt_ss. We don't need the insertion back into the original vector at the end. The builtin

[PATCH] D46911: [Fixed Point Arithmetic] Addition of the remaining fixed point types and their saturated equivalents

2018-05-30 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 149169. leonardchan added a comment. Forgot to include tests for the `_Fract` and `_Sat` keywords in c++ usage Repository: rC Clang https://reviews.llvm.org/D46911 Files: include/clang/AST/ASTContext.h include/clang/AST/BuiltinTypes.def

r333568 - [X86] Reduce the number of setzero intrinsics to just the set defined by the Intel Intrinsics Guide.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 11:02:11 2018 New Revision: 333568 URL: http://llvm.org/viewvc/llvm-project?rev=333568=rev Log: [X86] Reduce the number of setzero intrinsics to just the set defined by the Intel Intrinsics Guide. We had quite a few for different element sizes of integers

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-30 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan added inline comments. Comment at: include/clang/Basic/TokenKinds.def:393 +// ISO/IEC JTC1 SC22 WG14 N1169 Extension +KEYWORD(_Accum , KEYALL) + jfb wrote: > ebevhan wrote: > > I believe that having KEYALL will enable the keyword

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-30 Thread Leonard Chan via Phabricator via cfe-commits
leonardchan updated this revision to Diff 149162. Repository: rC Clang https://reviews.llvm.org/D46084 Files: include/clang-c/Index.h include/clang/AST/ASTContext.h include/clang/AST/BuiltinTypes.def include/clang/Basic/DiagnosticCommonKinds.td include/clang/Basic/LangOptions.def

[PATCH] D35450: [analyzer] Support generating and reasoning over more symbolic constraint types

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. Herald added subscribers: a.sidorin, zzheng, rnkovacs, szepet. Herald added a reviewer: george.karpenkov. @ddcc Hi, are you still interested in landing the fixes associated with this patch? I can take a look as I'm currently reviewing

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-30 Thread JF Bastien via Phabricator via cfe-commits
jfb added inline comments. Comment at: include/clang/Basic/TokenKinds.def:393 +// ISO/IEC JTC1 SC22 WG14 N1169 Extension +KEYWORD(_Accum , KEYALL) + ebevhan wrote: > I believe that having KEYALL will enable the keyword even if

[PATCH] D45517: [analyzer] False positive refutation with Z3

2018-05-30 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added inline comments. Comment at: lib/StaticAnalyzer/Core/BugReporterVisitors.cpp:2382 +// Reset the solver +RefutationMgr.reset(); + } xazax.hun wrote: > george.karpenkov wrote: > > george.karpenkov wrote: > > > (apologies in advance

r333563 - [X86] Remove 'return' from a bunch of intrinsics that return void and use a builtin that returns void.

2018-05-30 Thread Craig Topper via cfe-commits
Author: ctopper Date: Wed May 30 10:23:45 2018 New Revision: 333563 URL: http://llvm.org/viewvc/llvm-project?rev=333563=rev Log: [X86] Remove 'return' from a bunch of intrinsics that return void and use a builtin that returns void. Found by running the intrinsic headers through -pedantic -ansi.

[PATCH] D37035: Implement __builtin_LINE() et. al. to support source location capture.

2018-05-30 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF marked 5 inline comments as done. EricWF added a comment. In https://reviews.llvm.org/D37035#1116102, @kunitoki wrote: > Any news on the status of this ? Would be really nice to have it in. I think this patch is ready to go; but there is more work to be done, as a separate patch, to

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-30 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Responding to comments :) Comment at: include/clang/Basic/Attr.td:850 +def CpuSpecific : InheritableAttr { + let Spellings = [GCC<"cpu_specific">]; + let Args = [VariadicIdentifierArgument<"Cpus">]; aaron.ballman wrote: > Does GCC

[PATCH] D47474: Implement cpu_dispatch/cpu_specific Multiversioning

2018-05-30 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 149145. erichkeane marked 11 inline comments as done. erichkeane added a comment. Fix based on @craig.topper and @aaron.ballman s comments. https://reviews.llvm.org/D47474 Files: include/clang/AST/Decl.h include/clang/Basic/Attr.td

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. I would like to see more negative tests. What does it do if the len/size is a constant? Variable that wasn't just assigned with `strlen()` return? https://reviews.llvm.org/D45050 ___ cfe-commits mailing list

[PATCH] D47537: [clang-tools-extra] Cleanup documentation routine

2018-05-30 Thread Kirill Bobyrev via Phabricator via cfe-commits
omtcyfz updated this revision to Diff 149138. omtcyfz retitled this revision from "[clang-rename] Move clang-rename documentation to Clang repository" to "[clang-tools-extra] Cleanup documentation routine". omtcyfz edited the summary of this revision. omtcyfz added a comment. Herald added a

[PATCH] D44480: [Sema] Don't skip function bodies with 'auto' without trailing return type

2018-05-30 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov added a comment. In https://reviews.llvm.org/D44480#1116359, @nik wrote: > I've stumbled about this bug too and was looking into it and then I saw the > mail about this change being submitted :) > > I've ended up with a slightly different change (https://dpaste.de/PSpM/raw , >

[PATCH] D47121: [NEON] Support VLD1xN intrinsics in AArch32 mode (Clang part)

2018-05-30 Thread Sjoerd Meijer via Phabricator via cfe-commits
SjoerdMeijer added a comment. Had only a first brief look; see some first drive by comments inline. Comment at: lib/CodeGen/CGBuiltin.cpp:7865 } // FIXME: Sharing loads & stores with 32-bit is complicated by the absence // of an Align parameter here.

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. In https://reviews.llvm.org/D45050#1116396, @Charusso wrote: > In https://reviews.llvm.org/D45050#1116361, @xbolva00 wrote: > > > memcpy(crypt_buf, passwd, passwd_len); <--- warning > > memcpy(crypt_buf + passwd_len, salt, salt_len); > > > > This is a false warning

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso added a comment. In https://reviews.llvm.org/D45050#1116361, @xbolva00 wrote: > memcpy(crypt_buf, passwd, passwd_len); <--- warning > memcpy(crypt_buf + passwd_len, salt, salt_len); > > This is a false warning since it appends strings using memcpy. But no idea > what to do and if it

[PATCH] D47121: [NEON] Support VLD1xN intrinsics in AArch32 mode (Clang part)

2018-05-30 Thread Ivan Kosarev via Phabricator via cfe-commits
kosarev added a comment. Ping. https://reviews.llvm.org/D47121 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. memcpy(crypt_buf, passwd, passwd_len); <--- warning memcpy(crypt_buf + passwd_len, salt, salt_len); This is a false warning since it appends strings using memcpy. But no idea what to do and if it is possible to avoid these false warnings.

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso updated this revision to Diff 149129. Charusso added a comment. Clang format. https://reviews.llvm.org/D45050 Files: clang-tidy/bugprone/BugproneTidyModule.cpp clang-tidy/bugprone/CMakeLists.txt clang-tidy/bugprone/NotNullTerminatedResultCheck.cpp

[PATCH] D44480: [Sema] Don't skip function bodies with 'auto' without trailing return type

2018-05-30 Thread Nikolai Kosjar via Phabricator via cfe-commits
nik added a comment. I've stumbled about this bug too and was looking into it and then I saw the mail about this change being submitted :) I've ended up with a slightly different change (https://dpaste.de/PSpM/raw , instead of FD->getReturnType()->getContainedDeducedType() I have

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Thanks! Happy to see it is more powerful now :) https://reviews.llvm.org/D45050 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r333553 - [clang-format/ObjC] Correctly parse Objective-C methods with 'class' in name

2018-05-30 Thread Ben Hamilton via cfe-commits
Author: benhamilton Date: Wed May 30 08:21:38 2018 New Revision: 333553 URL: http://llvm.org/viewvc/llvm-project?rev=333553=rev Log: [clang-format/ObjC] Correctly parse Objective-C methods with 'class' in name Summary: Please take a close look at this CL. I haven't touched much of

[PATCH] D47095: [clang-format/ObjC] Correctly parse Objective-C methods with 'class' in name

2018-05-30 Thread Ben Hamilton via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC333553: [clang-format/ObjC] Correctly parse Objective-C methods with class in name (authored by benhamilton, committed by ). Changed prior to commit:

[PATCH] D47537: [clang-rename] Move clang-rename documentation to Clang repository

2018-05-30 Thread Kirill Bobyrev via Phabricator via cfe-commits
omtcyfz created this revision. omtcyfz added reviewers: ioeric, klimek, arphaman. omtcyfz added projects: clang, clang-tools-extra. clang-rename was moved to the Clang repository in r306840, but documentation was left behind, which might be confusing. The Doxygen configuration file in

[PATCH] D45050: [clang-tidy] New checker for not null-terminated result caused by strlen or wcslen

2018-05-30 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso updated this revision to Diff 149116. Charusso added a comment. @xbolva00 idea implemented, doubled the checker's power. Now if the given argument is a DeclRefExpr this should handle it as it would be inlined as a simple CallExpr. Results: I have found 37 `memcpy()` and 2 `memchr()`

[PATCH] D47067: Update NRVO logic to support early return

2018-05-30 Thread Taiju Tsuiki via Phabricator via cfe-commits
tzik added a comment. In https://reviews.llvm.org/D47067#1116246, @sammccall wrote: > Unfortunately this seems to miscompile, the stage1 built clang is crashing on > the multistage buildbots: > > http://lab.llvm.org:8011/builders/clang-s390x-linux-multistage/builds/2926 > shows this crash

[PATCH] D40988: Clang-format: add finer-grained options for putting all arguments on one line

2018-05-30 Thread Russell McClellan via Phabricator via cfe-commits
russellmcc added inline comments. Comment at: lib/Format/ContinuationIndenter.cpp:760 (!Style.AllowAllParametersOfDeclarationOnNextLine && State.Line->MustBeDeclaration) || +(!Style.AllowAllArgumentsOnNextLine && djasper wrote: > This

[PATCH] D47450: [ASTImporter] Use InjectedClassNameType at import of templated record.

2018-05-30 Thread Gabor Marton via Phabricator via cfe-commits
martong added inline comments. Comment at: test/ASTMerge/injected-class-name-decl-1/Inputs/inject1.cpp:16 +} // namespace google +namespace a { +template class g; balazske wrote: > a.sidorin wrote: > > This looks like raw creduce output. Is there a way to

[PATCH] D46084: [Fixed Point Arithmetic] Addition of the Fixed Point _Accum type

2018-05-30 Thread Bevin Hansson via Phabricator via cfe-commits
ebevhan added a comment. Sorry for the late notice; I missed something. Comment at: include/clang/Basic/TokenKinds.def:393 +// ISO/IEC JTC1 SC22 WG14 N1169 Extension +KEYWORD(_Accum , KEYALL) + I believe that having KEYALL will enable the

[clang-tools-extra] r333548 - [clangd] Add forgotten include guard to TestFS.h. NFC

2018-05-30 Thread Ilya Biryukov via cfe-commits
Author: ibiryukov Date: Wed May 30 07:21:31 2018 New Revision: 333548 URL: http://llvm.org/viewvc/llvm-project?rev=333548=rev Log: [clangd] Add forgotten include guard to TestFS.h. NFC Modified: clang-tools-extra/trunk/unittests/clangd/TestFS.h Modified:

  1   2   >