[PATCH] D49158: [clang-tidy] Fixing segfault when there's no IdentifierInfo

2018-07-10 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett created this revision. juliehockett added reviewers: aaron.ballman, hokein, ilya-biryukov. juliehockett added a project: clang-tools-extra. Herald added a subscriber: xazax.hun. Bug 36150 found a segfault on mac when a CXXRecordDecl has no IdentifierInfo, this fixes it. https://rev

[PATCH] D49083: [HIP] Register/unregister device fat binary only once

2018-07-10 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 154894. yaxunl marked an inline comment as done. yaxunl added a comment. clean up function prefix. https://reviews.llvm.org/D49083 Files: lib/CodeGen/CGCUDANV.cpp test/CodeGenCUDA/device-stub.cu Index: test/CodeGenCUDA/device-stub.cu ===

[PATCH] D47894: [clang]: Add support for "-fno-delete-null-pointer-checks"

2018-07-10 Thread Manoj Gupta via Phabricator via cfe-commits
manojgupta updated this revision to Diff 154895. manojgupta added a comment. Do not generate calls with "nonnull" attribute with "-fno-delete-null-pointer-checks". The warnings are still generated when nullptr is passed to a function with nonnull attribute. Repository: rC Clang https://revi

[PATCH] D48753: [libcxx] Use custom allocator's `construct` in C++03 when available.

2018-07-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai added a comment. In https://reviews.llvm.org/D48753#1157907, @Quuxplusone wrote: > In https://reviews.llvm.org/D48753#1157695, @EricWF wrote: > > > Why are we doing this? > > > > I can't find the language in the C++03 specification that requires us to > > call an allocators `construct` m

[PATCH] D48854: Use ExprMutationAnalyzer in performance-for-range-copy

2018-07-10 Thread Shuai Wang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. shuaiwang marked an inline comment as done. Closed by commit rL336737: Use ExprMutationAnalyzer in performance-for-range-copy (authored by shuaiwang, committed by ). Herald added a subscriber: llvm-commits. Repository: rL

[clang-tools-extra] r336737 - Use ExprMutationAnalyzer in performance-for-range-copy

2018-07-10 Thread Shuai Wang via cfe-commits
Author: shuaiwang Date: Tue Jul 10 15:51:06 2018 New Revision: 336737 URL: http://llvm.org/viewvc/llvm-project?rev=336737&view=rev Log: Use ExprMutationAnalyzer in performance-for-range-copy Summary: This gives better coverage to the check as ExprMutationAnalyzer is more accurate comparing to isO

r336738 - Fix determination of whether a reinterpret_cast casts away constness.

2018-07-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Jul 10 16:04:35 2018 New Revision: 336738 URL: http://llvm.org/viewvc/llvm-project?rev=336738&view=rev Log: Fix determination of whether a reinterpret_cast casts away constness. The "casts away constness" check doesn't care at all how the different layers of the source an

r336739 - [X86] Fix the test for _mm512_mullox_epi64 to test the intrinsic instead of a copy of the intrinsic implementation.

2018-07-10 Thread Craig Topper via cfe-commits
Author: ctopper Date: Tue Jul 10 16:13:01 2018 New Revision: 336739 URL: http://llvm.org/viewvc/llvm-project?rev=336739&view=rev Log: [X86] Fix the test for _mm512_mullox_epi64 to test the intrinsic instead of a copy of the intrinsic implementation. Modified: cfe/trunk/test/CodeGen/avx512f-b

[PATCH] D49114: [clang-tidy] Add a check for "magic numbers"

2018-07-10 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- added inline comments. Comment at: clang-tidy/readability/MagicNumbersCheck.cpp:42 + +const auto &Parents = Result.Context->getParents(*MatchedDecl); +for (const auto &Parent : Parents) { Eugene.Zelenko wrote: > Please don't use auto where typ

r336740 - [X86] Also fix the test for _mm512_mullo_epi64 to test the intrinsic instead of a copy of the intrinsic implementation.

2018-07-10 Thread Craig Topper via cfe-commits
Author: ctopper Date: Tue Jul 10 16:28:05 2018 New Revision: 336740 URL: http://llvm.org/viewvc/llvm-project?rev=336740&view=rev Log: [X86] Also fix the test for _mm512_mullo_epi64 to test the intrinsic instead of a copy of the intrinsic implementation. This had the same issue I just fixed in r3

[PATCH] D48845: [Sema] Add fixit for unused lambda captures

2018-07-10 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexshap added a comment. I'm kind of interested in this fixit, but one thought which i have - probably it should be more conservative (i.e. fix captures by reference, integral types, etc) (since the code might rely on side-effects of copy-ctors/move-ctors or extend the lifetime of an object),

[PATCH] D48958: [clang][ubsan] Implicit Cast Sanitizer - integer truncation - clang part

2018-07-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 154877. lebedev.ri marked 2 inline comments as done. lebedev.ri added a comment. @vsk thank you for taking a look! Addressed the trivial part of nits. Repository: rC Clang https://reviews.llvm.org/D48958 Files: docs/ReleaseNotes.rst docs/Undefine

[PATCH] D48958: [clang][ubsan] Implicit Cast Sanitizer - integer truncation - clang part

2018-07-10 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: lib/CodeGen/CGExprScalar.cpp:318 - Value *EmitScalarConversion(Value *Src, QualType SrcTy, QualType DstTy, + Value *EmitScalarConversion(Value *Src, QualType SrcType, QualType DstType, SourceLocation

[PATCH] D48958: [clang][ubsan] Implicit Cast Sanitizer - integer truncation - clang part

2018-07-10 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Thanks for working on this! Comment at: docs/ReleaseNotes.rst:277 + behaviour. But they are not *always* intentional, and are somewhat hard to + track down. Could you mention whether the group is enabled by -fsanitize=undefined? =

r336745 - DR330: look through array types when forming the cv-decomposition of a type.

2018-07-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Jul 10 17:19:19 2018 New Revision: 336745 URL: http://llvm.org/viewvc/llvm-project?rev=336745&view=rev Log: DR330: look through array types when forming the cv-decomposition of a type. This allows more qualification conversions, eg. conversion from 'int *(*)[]' -> 'con

r336746 - PR38095: Allow constant-folding of loads through bitcasted pointers if

2018-07-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Jul 10 17:29:05 2018 New Revision: 336746 URL: http://llvm.org/viewvc/llvm-project?rev=336746&view=rev Log: PR38095: Allow constant-folding of loads through bitcasted pointers if the bitcast only changed cvr-qualifications within the pointer type. Modified: cfe/trunk/

[PATCH] D48681: [CFG] [analyzer] Add construction contexts for function arguments.

2018-07-10 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: lib/Analysis/ConstructionContext.cpp:186 +isa(TopLayer->getTriggerStmt())) { + return create( + C, cast(TopLayer->getTriggerStmt()), TopLayer->getIndex(), Should assert that we only have one layer. Re

r336747 - [docs] List correct default for -ftemplate-depth; also add missing

2018-07-10 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Jul 10 17:34:54 2018 New Revision: 336747 URL: http://llvm.org/viewvc/llvm-project?rev=336747&view=rev Log: [docs] List correct default for -ftemplate-depth; also add missing documentation for -fconstexpr-steps. Modified: cfe/trunk/docs/UsersManual.rst Modified: cfe/

r336748 - Remove qualtype qualifier in coroutine error to prevent assert in debug

2018-07-10 Thread Brian Gesiak via cfe-commits
Author: modocache Date: Tue Jul 10 17:45:48 2018 New Revision: 336748 URL: http://llvm.org/viewvc/llvm-project?rev=336748&view=rev Log: Remove qualtype qualifier in coroutine error to prevent assert in debug Summary: A forward-declared coroutine_traits should trip an error; we need a complete typ

[PATCH] D49099: Remove qualtype qualifier in coroutine error to prevent assert in debug

2018-07-10 Thread Brian Gesiak via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC336748: Remove qualtype qualifier in coroutine error to prevent assert in debug (authored by modocache, committed by ). Changed prior to commit: https://reviews.llvm.org/D49099?vs=154692&id=154910#toc

[PATCH] D22391: [Sema] Add warning for implicitly casting a null constant to a non null pointer type

2018-07-10 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak updated this revision to Diff 154908. ahatanak marked 3 inline comments as done. ahatanak added a comment. Address review comments. Repository: rC Clang https://reviews.llvm.org/D22391 Files: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td in

[PATCH] D22391: [Sema] Add warning for implicitly casting a null constant to a non null pointer type

2018-07-10 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added inline comments. Comment at: lib/Sema/SemaExpr.cpp:11103 + if (const auto *DeclRef = dyn_cast(LHSExpr)) +checkNullConstantToNonNull(DeclRef->getType(), RHS.get()); jordan_rose wrote: > This could come later, but what about struct members or

[PATCH] D48753: [libcxx] Use custom allocator's `construct` in C++03 when available.

2018-07-10 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 154912. vsapsai added a comment. - In C++03 call allocator's `destroy` when available. - Rename `_Args` as it's not a variadic template pack. https://reviews.llvm.org/D48753 Files: libcxx/include/memory libcxx/test/std/containers/sequences/vector/vecto

[PATCH] D35388: [libc++] Give extern templates default visibility on gcc

2018-07-10 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a reviewer: ldionne. EricWF added a subscriber: ldionne. EricWF added a comment. Adding @ldionne as an observer, since he's knee-deep in the visibility mess right now. After re-evaluating, I think I was being overly cautious the last time I looked at this. I think this patch should

r336750 - [SemaCXX] Remove comment from coroutines test, NFC

2018-07-10 Thread Brian Gesiak via cfe-commits
Author: modocache Date: Tue Jul 10 18:00:53 2018 New Revision: 336750 URL: http://llvm.org/viewvc/llvm-project?rev=336750&view=rev Log: [SemaCXX] Remove comment from coroutines test, NFC Summary: The file name was accidentally included when the test file was added. Test Plan: check-clang Modif

[PATCH] D49050: [analyzer] Pass through all arguments from the registerChecker() to the checker constructor

2018-07-10 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC336753: [analyzer] Pass through all arguments from the registerChecker() to the checker… (authored by george.karpenkov, committed by ). Herald added a subscriber: cfe-commits. Repository: rC Clang http

r336753 - [analyzer] Pass through all arguments from the registerChecker() to the checker constructor

2018-07-10 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Tue Jul 10 18:23:27 2018 New Revision: 336753 URL: http://llvm.org/viewvc/llvm-project?rev=336753&view=rev Log: [analyzer] Pass through all arguments from the registerChecker() to the checker constructor A lot of checkers could be cleaned up in a similar way Diffe

[PATCH] D49114: [clang-tidy] Add a check for "magic numbers"

2018-07-10 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- marked 7 inline comments as done. 0x8000- added inline comments. Comment at: docs/clang-tidy/checks/readability-magic-numbers.rst:11 + + double circleArea = 3.1415926535 * radius * radius; + Eugene.Zelenko wrote: > JonasToth wrote: > > This exam

r336755 - [analyzer] Partial revert of https://reviews.llvm.org/D49050

2018-07-10 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Tue Jul 10 18:58:08 2018 New Revision: 336755 URL: http://llvm.org/viewvc/llvm-project?rev=336755&view=rev Log: [analyzer] Partial revert of https://reviews.llvm.org/D49050 Modified: cfe/trunk/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp Modified: cfe

r336756 - [analyzer] Fix bots by changing the analyzer-config tests.

2018-07-10 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Tue Jul 10 19:01:18 2018 New Revision: 336756 URL: http://llvm.org/viewvc/llvm-project?rev=336756&view=rev Log: [analyzer] Fix bots by changing the analyzer-config tests. To be investigated. Modified: cfe/trunk/test/Analysis/analyzer-config.c cfe/trunk/test

[PATCH] D49114: [clang-tidy] Add a check for "magic numbers"

2018-07-10 Thread Florin Iucha via Phabricator via cfe-commits
0x8000- updated this revision to Diff 154921. 0x8000- added a comment. Herald added a subscriber: mgrang. Incorporate review comments. Add support for floating point detection. Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D49114 Files: clang-tidy/readability/CMakeLis

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

2018-07-10 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added inline comments. Comment at: lib/CodeGen/CGObjCMac.cpp:7457-7460 CGObjCNonFragileABIMac::GetEHType(QualType T) { // There's a particular fixed type info for 'id'. if (T->isObjCIdType() || T->isObjCQualifiedIdType()) { +if (CGM.getTriple().isWindowsMSVCEnv

[PATCH] D48719: [clang-format/ObjC] Improve split priorities for ObjC methods

2018-07-10 Thread Jacek Olesiak via Phabricator via cfe-commits
jolesiak closed this revision. jolesiak added a comment. This change was submitted (for some reason (probably some rebase operations) it was not automatically connected to the commit): https://reviews.llvm.org/rC336520, https://reviews.llvm.org/rL336520 Repository: rC Clang https://reviews.l

[PATCH] D48720: [clang-format/ObjC] Put ObjC method arguments into one line when they fit

2018-07-10 Thread Jacek Olesiak via Phabricator via cfe-commits
jolesiak closed this revision. jolesiak added a comment. This change was submitted (for some reason (probably some rebase operations) it was not automatically connected to the commit): https://reviews.llvm.org/rC336521, https://reviews.llvm.org/rL336521. Repository: rC Clang https://reviews.

[PATCH] D44634: [clang-format] Detect Objective-C for #import

2018-07-10 Thread Jacek Olesiak via Phabricator via cfe-commits
jolesiak added a comment. Herald added a subscriber: acoomans. I think we should reconsider applying this change, at least for a very common "#import ". Repository: rC Clang https://reviews.llvm.org/D44634 ___ cfe-commits mailing list cfe-commit

<    1   2