[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Ryan Prichard via Phabricator via cfe-commits
rprichard added a comment. Some relevant code links: - https://github.com/llvm-mirror/clang/blob/8c9bf999aa40ab6077b958b5edcf587b9d76ce24/lib/CodeGen/ItaniumCXXABI.cpp#L359 ==> iOS64CXXABI overrides shouldRTTIBeUnique to return false. - https://github.com/llvm-mirror/libcxx/blob/ca79c159d8bfbe

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Jonathan Roelofs via Phabricator via cfe-commits
jroelofs added a comment. That reminds me... this does need a testcase or two. Repository: rL LLVM https://reviews.llvm.org/D38599 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 118493. https://reviews.llvm.org/D38764 Files: include/clang/StaticAnalyzer/Checkers/Checkers.td lib/StaticAnalyzer/Checkers/CMakeLists.txt lib/StaticAnalyzer/Checkers/NonnilStringConstantsChecker.cpp test/Analysis/nonnil-string-constants.mm

[PATCH] D26350: Keep invalid Switch in the AST

2017-10-10 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/Parse/ParseStmt.cpp:1297 - if (Switch.isInvalid()) { -// Skip the switch body. -// FIXME: This is not optimal recovery, but parsing the body is more -// dangerous due to the presence of case and default statements, whic

[clang-tools-extra] r315378 - Support: Have directory_iterator::status() return FindFirstFileEx/FindNextFile results on Windows.

2017-10-10 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Tue Oct 10 15:19:46 2017 New Revision: 315378 URL: http://llvm.org/viewvc/llvm-project?rev=315378&view=rev Log: Support: Have directory_iterator::status() return FindFirstFileEx/FindNextFile results on Windows. This allows clients to avoid an unnecessary fs::status() call on ea

r315378 - Support: Have directory_iterator::status() return FindFirstFileEx/FindNextFile results on Windows.

2017-10-10 Thread Peter Collingbourne via cfe-commits
Author: pcc Date: Tue Oct 10 15:19:46 2017 New Revision: 315378 URL: http://llvm.org/viewvc/llvm-project?rev=315378&view=rev Log: Support: Have directory_iterator::status() return FindFirstFileEx/FindNextFile results on Windows. This allows clients to avoid an unnecessary fs::status() call on ea

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Dan Albert via Phabricator via cfe-commits
danalbert added a comment. In https://reviews.llvm.org/D38599#893903, @jroelofs wrote: > That reminds me... this does need a testcase or two. Didn't realize I could do multi binary test cases with this test runner. It'll be a little messy, but I'll try adding one. Repository: rL LLVM http

[PATCH] D38770: AMDGPU: Use stricter bounds for workitem builtins

2017-10-10 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm created this revision. Herald added subscribers: t-tye, tpr, dstuttard, nhaehnle, wdng. https://reviews.llvm.org/D38770 Files: include/clang/Basic/TargetInfo.h lib/Basic/Targets/AMDGPU.cpp lib/Basic/Targets/AMDGPU.h lib/CodeGen/CGBuiltin.cpp test/CodeGenOpenCL/builtins-amdgcn.cl

r315379 - [Modules TS] Module ownership semantics for redeclarations.

2017-10-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Oct 10 15:33:17 2017 New Revision: 315379 URL: http://llvm.org/viewvc/llvm-project?rev=315379&view=rev Log: [Modules TS] Module ownership semantics for redeclarations. When declaring an entity in the "purview" of a module, it's never a redeclaration of an entity in the pu

r315381 - [Modules TS] Diagnose attempts to enter module implementation units without the module interface being available.

2017-10-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Oct 10 15:35:27 2017 New Revision: 315381 URL: http://llvm.org/viewvc/llvm-project?rev=315381&view=rev Log: [Modules TS] Diagnose attempts to enter module implementation units without the module interface being available. Added: cfe/trunk/test/CXX/modules-ts/dcl.dcl/

[PATCH] D38717: Patch to Bugzilla 31373

2017-10-10 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Please make sure the title (subject line) for a patch reflects the actual contents of the change, as opposed to referring to Bugzilla; a lot of people skim cfe-commits, so you want to make sure interested reviewers find you patch. Needs a regression test to verify we g

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Dan Albert via Phabricator via cfe-commits
danalbert added a comment. In https://reviews.llvm.org/D38599#893903, @jroelofs wrote: > That reminds me... this does need a testcase or two. Oh, also, any test I add is going to fail, since the case I'm trying to account for here is not the default behavior. I could make the more invasive ch

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Dan Albert via Phabricator via cfe-commits
danalbert updated this revision to Diff 118502. danalbert edited the summary of this revision. danalbert added a comment. Added a (failing) test case. The test case will fail unless the default value of `_LIBCXX_DYNAMIC_FALLBACK` is changed. https://reviews.llvm.org/D38599 Files: src/private

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Jonathan Roelofs via Phabricator via cfe-commits
jroelofs added a comment. In https://reviews.llvm.org/D38599#893985, @danalbert wrote: > In https://reviews.llvm.org/D38599#893903, @jroelofs wrote: > > > That reminds me... this does need a testcase or two. > > > Oh, also, any test I add is going to fail, since the case I'm trying to > account

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-10 Thread Adrian Prantl via Phabricator via cfe-commits
aprantl added a comment. I can commit this for you if John is happy with it. https://reviews.llvm.org/D38473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-10 Thread John McCall via Phabricator via cfe-commits
rjmccall accepted this revision. rjmccall added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D38473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/

Re: r298369 - [OpenCL] Added diagnostic for checking length of vector

2017-10-10 Thread Bruno Cardoso Lopes via cfe-commits
Hi Egor, On Tue, Mar 21, 2017 at 6:20 AM, Egor Churaev via cfe-commits wrote: > Author: echuraev > Date: Tue Mar 21 08:20:57 2017 > New Revision: 298369 > > URL: http://llvm.org/viewvc/llvm-project?rev=298369&view=rev > Log: > [OpenCL] Added diagnostic for checking length of vector > > Reviewers:

Re: [clang-tools-extra] r315287 - Revert "Revert r315214 since diff -Z isn't portable, this is breaking:"

2017-10-10 Thread Bruno Cardoso Lopes via cfe-commits
On Tue, Oct 10, 2017 at 2:08 AM, Ilya Biryukov via cfe-commits wrote: > Author: ibiryukov > Date: Tue Oct 10 02:08:47 2017 > New Revision: 315287 > > URL: http://llvm.org/viewvc/llvm-project?rev=315287&view=rev > Log: > Revert "Revert r315214 since diff -Z isn't portable, this is breaking:" > > Th

r315392 - Include getting generated struct offsets in CodegenABITypes

2017-10-10 Thread Adrian Prantl via cfe-commits
Author: adrian Date: Tue Oct 10 16:54:21 2017 New Revision: 315392 URL: http://llvm.org/viewvc/llvm-project?rev=315392&view=rev Log: Include getting generated struct offsets in CodegenABITypes This change adds a new function, CodeGen::getFieldNumber, that enables a user of clang's code generation

[PATCH] D38473: Include getting generated struct offsets in CodegenABITypes

2017-10-10 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL315392: Include getting generated struct offsets in CodegenABITypes (authored by adrian). Changed prior to commit: https://reviews.llvm.org/D38473?vs=117806&id=118505#toc Repository: rL LLVM https:/

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a comment. Looks like a great start! There are a bunch of minor nits inline. The one big thing is that I think your handling of 'const char *' in `typeIsConstString()` isn't quite right. 'const char *' means that the pointed-to characters can't be modified but does allow modifi

[PATCH] D38772: [refactor] allow the use of refactoring diagnostics

2017-10-10 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. Herald added a subscriber: mgorny. This patch allows the refactoring library to use its own set of refactoring-specific diagnostics to reports things like initiation errors. Repository: rL LLVM https://reviews.llvm.org/D38772 Files: include/clang/Basic/AllD

[PATCH] D38599: Remove warnings for dynamic_cast fallback.

2017-10-10 Thread Jonathan Roelofs via Phabricator via cfe-commits
jroelofs added a comment. In https://reviews.llvm.org/D38599#893990, @jroelofs wrote: > In https://reviews.llvm.org/D38599#893985, @danalbert wrote: > > > In https://reviews.llvm.org/D38599#893903, @jroelofs wrote: > > > > > That reminds me... this does need a testcase or two. > > > > > > Oh, als

[PATCH] D38773: [Sema] Add support for flexible array members in Obj-C.

2017-10-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai created this revision. Allow Obj-C ivars with incomplete array type but only as the last ivar. Also add a requirement for ivars that contain a flexible array member to be at the end of class too. It is possible to add in a subclass another ivar at the end but we'll emit a warning in this c

[PATCH] D38774: [CodeGen] Add support for IncompleteArrayType in Obj-C ivars.

2017-10-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai created this revision. Fixes an assertion failure when ivar is a struct containing incomplete array. Also completes support for direct flexible array members. rdar://problem/21054495 https://reviews.llvm.org/D38774 Files: clang/lib/CodeGen/CGObjCMac.cpp clang/test/CodeGenObjC/ivar-

[PATCH] D38773: [Sema] Add support for flexible array members in Obj-C.

2017-10-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. Previous discussion on the mailing list can be found at http://lists.llvm.org/pipermail/cfe-dev/2017-September/055548.html The implementation is not exactly like it was discussed, it has some changes. There is another case when extra ivar is added at the end, it is for

r315397 - [Modules TS] Diagnose missing/duplicate module-declaration.

2017-10-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Oct 10 17:36:56 2017 New Revision: 315397 URL: http://llvm.org/viewvc/llvm-project?rev=315397&view=rev Log: [Modules TS] Diagnose missing/duplicate module-declaration. Added: cfe/trunk/test/CXX/modules-ts/dcl.dcl/dcl.module/p1.cpp Modified: cfe/trunk/include/clang

[PATCH] D38774: [CodeGen] Add support for IncompleteArrayType in Obj-C ivars.

2017-10-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. This patch depends on sema change https://reviews.llvm.org/D38773 https://reviews.llvm.org/D38774 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r315398 - A '<' with a trigraph '#' is not a valid editor placeholder

2017-10-10 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Tue Oct 10 17:41:20 2017 New Revision: 315398 URL: http://llvm.org/viewvc/llvm-project?rev=315398&view=rev Log: A '<' with a trigraph '#' is not a valid editor placeholder Credit to OSS-Fuzz for discovery: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3137#c5 rdar:

[PATCH] D38774: [CodeGen] Add support for IncompleteArrayType in Obj-C ivars.

2017-10-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. To save reviewers some time. Incomplete array type is not the same as for zero-sized array, it is `c"^c\00"` while for zero-sized array it is `c"[0c]\00"`. Don't know if it matters, I haven't found any difference in behaviour. Though maybe I wasn't looking in the right

r315402 - [modules] Only take visible using-directives into account during name lookup.

2017-10-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Oct 10 18:19:11 2017 New Revision: 315402 URL: http://llvm.org/viewvc/llvm-project?rev=315402&view=rev Log: [modules] Only take visible using-directives into account during name lookup. Added: cfe/trunk/test/Modules/using-directive.cpp Modified: cfe/trunk/lib/Sema

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. Marking requests as "done". https://reviews.llvm.org/D38764 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 118521. george.karpenkov marked 12 inline comments as done. george.karpenkov added a comment. Adhering to comments. https://reviews.llvm.org/D38764 Files: include/clang/StaticAnalyzer/Checkers/Checkers.td lib/StaticAnalyzer/Checkers/CMakeLists.

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 118522. george.karpenkov added a comment. Typo fix. https://reviews.llvm.org/D38764 Files: include/clang/StaticAnalyzer/Checkers/Checkers.td lib/StaticAnalyzer/Checkers/CMakeLists.txt lib/StaticAnalyzer/Checkers/NonnullStringConstantsChecker.

r315408 - [modules] Fix visibility checking for using declarations via ADL.

2017-10-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Oct 10 18:49:57 2017 New Revision: 315408 URL: http://llvm.org/viewvc/llvm-project?rev=315408&view=rev Log: [modules] Fix visibility checking for using declarations via ADL. We want to check whether the using (shadow) declaration itself is visible, not whether its target

r315411 - Update cc1as_main for MCAsmBackend ownership change in r315410.

2017-10-10 Thread Lang Hames via cfe-commits
Author: lhames Date: Tue Oct 10 18:58:08 2017 New Revision: 315411 URL: http://llvm.org/viewvc/llvm-project?rev=315411&view=rev Log: Update cc1as_main for MCAsmBackend ownership change in r315410. Modified: cfe/trunk/tools/driver/cc1as_main.cpp Modified: cfe/trunk/tools/driver/cc1as_main.cpp

r315428 - ClangCodeGenTests: Update libdeps in rL315392, +clangAST.

2017-10-10 Thread NAKAMURA Takumi via cfe-commits
Author: chapuni Date: Tue Oct 10 21:20:19 2017 New Revision: 315428 URL: http://llvm.org/viewvc/llvm-project?rev=315428&view=rev Log: ClangCodeGenTests: Update libdeps in rL315392, +clangAST. Modified: cfe/trunk/unittests/CodeGen/CMakeLists.txt Modified: cfe/trunk/unittests/CodeGen/CMakeList

r315435 - Reorder.

2017-10-10 Thread NAKAMURA Takumi via cfe-commits
Author: chapuni Date: Tue Oct 10 21:54:05 2017 New Revision: 315435 URL: http://llvm.org/viewvc/llvm-project?rev=315435&view=rev Log: Reorder. Modified: cfe/trunk/unittests/CodeGen/CMakeLists.txt Modified: cfe/trunk/unittests/CodeGen/CMakeLists.txt URL: http://llvm.org/viewvc/llvm-project/c

[PATCH] D38679: [libunwind] Support dwarf unwinding on i386 windows

2017-10-10 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. Are there any further comments on this, or can someone of those who commented on it before approve it? https://reviews.llvm.org/D38679 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/m

[PATCH] D38764: [Analyzer] Assume const string-like globals are non-null

2017-10-10 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added a comment. This revision is now accepted and ready to land. Looks good to me. Please fix the additional nits mentioned inline and commit! Also, make sure to do a pass to update the capitalization of variables throughout the file to match the LLV

[PATCH] D30295: [analyzer] clarify undef shift result when shift count is negative or exceeds the bit width

2017-10-10 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna accepted this revision. zaks.anna added a comment. Once the comments by @paquette are addressed, LGTM. Thanks! Comment at: lib/StaticAnalyzer/Checkers/UndefResultChecker.cpp:138 + +OS << " larger or equal to the width of type '" + << B->getLHS()->get

<    1   2