[PATCH] D34578: cmath: Support clang's -fdelayed-template-parsing

2017-06-23 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith created this revision. r283051 added some functions to cmath (in namespace std) that have the same name as functions in math.h (in the global namespace). Clang's limited support for `-fdelayed-template-parsing` chokes on this. Rename the ones in `cmath` and their uses in `complex`

Re: [PATCH] D34563: [ubsan] Disable the object-size check at -O0

2017-06-23 Thread Justin Bogner via cfe-commits
v...@apple.com writes: > Good point, it makes sense to hand users a warning when they explicitly enable > -fsanitize=object-size at -O0. I've added in the diagnostic. PTAL. LGTM. > diff --git a/include/clang/Basic/DiagnosticDriverKinds.td > b/include/clang/Basic/DiagnosticDriverKinds.td > index

[PATCH] D34523: AST: mangle BlockDecls under MS ABI

2017-06-23 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd updated this revision to Diff 103794. compnerd added a comment. This is a step in the right direction. Although the NSDMI cases and default parameter value cases are not yet handled, they break due to tracking of the global mangling number tracking, not due to the scheme. Repository:

r306181 - [ubsan] Disable the object size check at -O0

2017-06-23 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Fri Jun 23 18:15:24 2017 New Revision: 306181 URL: http://llvm.org/viewvc/llvm-project?rev=306181&view=rev Log: [ubsan] Disable the object size check at -O0 This check currently isn't able to diagnose any issues at -O0, not is it likely to [1]. Disabling the check at -O0 lea

[PATCH] D34563: [ubsan] Disable the object-size check at -O0

2017-06-23 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL306181: [ubsan] Disable the object size check at -O0 (authored by vedantk). Changed prior to commit: https://reviews.llvm.org/D34563?vs=103778&id=103796#toc Repository: rL LLVM https://reviews.llvm.

[PATCH] D34580: [CodeGen][ObjC] Load indirect ARC arguments in prolog

2017-06-23 Thread Dave Lee via Phabricator via cfe-commits
kastiglione created this revision. When generating a prolog, add loads for ARC arguments passed indirectly. https://reviews.llvm.org/D34580 Files: lib/CodeGen/CGDecl.cpp test/CodeGenObjCXX/arc-indirect.mm Index: test/CodeGenObjCXX/arc-indirect.mm ==

r306183 - Add a warning to a group

2017-06-23 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Fri Jun 23 18:34:32 2017 New Revision: 306183 URL: http://llvm.org/viewvc/llvm-project?rev=306183&view=rev Log: Add a warning to a group Add warn_drv_object_size_disabled_O0 to the invalid command line argument group. This should fix some bot failures: lab.llvm.org:8011/

[PATCH] D34523: AST: mangle BlockDecls under MS ABI

2017-06-23 Thread David Majnemer via Phabricator via cfe-commits
majnemer added inline comments. Comment at: lib/AST/MicrosoftMangle.cpp:981-984 + Out << "YAXPAU__block_literal"; + if (Discriminator) +Out<< '_' << Discriminator; + Out << "@@@Z"; I think you want to use mangleArtificalTagType here. Repo

[PATCH] D34574: [Sema] Disable c++17 aligned new and delete operators if not implemented in the deployment target's c++ standard library

2017-06-23 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. The motivation for this change was to silence linker errors I saw when compiling and linking programs in which operator new was called to allocate over-aligned types (similar to the code in cxx1z-aligned-allocation.cpp). Linkage failed because clang would emit the call

[PATCH] D34523: AST: mangle BlockDecls under MS ABI

2017-06-23 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added a comment. Ah, thanks for the explanation @efriedma. Comment at: lib/AST/MicrosoftMangle.cpp:981-984 + Out << "YAXPAU__block_literal"; + if (Discriminator) +Out<< '_' << Discriminator; + Out << "@@@Z"; majnemer wrote: > I t

[PATCH] D34523: AST: mangle BlockDecls under MS ABI

2017-06-23 Thread David Majnemer via Phabricator via cfe-commits
majnemer added inline comments. Comment at: lib/AST/MicrosoftMangle.cpp:981-984 + Out << "YAXPAU__block_literal"; + if (Discriminator) +Out<< '_' << Discriminator; + Out << "@@@Z"; compnerd wrote: > majnemer wrote: > > I think you want to u

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

2017-06-23 Thread Todd Lipcon via Phabricator via cfe-commits
toddlipcon added a comment. Anyone able to review this? Repository: rL LLVM https://reviews.llvm.org/D34415 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D34588: Check for _MSC_VER before define _LIBCPP_MSVCRT

2017-06-23 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno created this revision. _LIBCPP_MSVCRT is defined because _WIN32 is defined and __MINGW32__ is not. Some non-windows targets using MS extensions define _WIN32 for compatibility with Windows but do not have MSVC compatibility. This patch is an attempt to do not have _LIBCPP_MSVCRT defined f

[PATCH] D34588: Check for _MSC_VER before define _LIBCPP_MSVCRT

2017-06-23 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added reviewers: compnerd, majnemer, rnk. smeenai added subscribers: majnemer, compnerd. smeenai added a comment. This looks sensible to me. I don't know if there are any scenarios in which you'd be using the Microsoft CRT without having `_MSC_VER` defined, however. Added some people who

Re: [clang-tools-extra] r303735 - Modify test so that it looks for patterns in stderr as well

2017-06-23 Thread David Blaikie via cfe-commits
Ping (+Manuel, perhaps he's got some ideas about this, given background in the tooling & compilation database work, or could point this to someone who does?) On Thu, Jun 15, 2017 at 10:40 AM David Blaikie wrote: > https://sarcasm.github.io/notes/dev/compilation-database.html#cmake > > If you ena

[PATCH] D34574: [Sema] Disable c++17 aligned new and delete operators if not implemented in the deployment target's c++ standard library

2017-06-23 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. In https://reviews.llvm.org/D34574#789539, @ahatanak wrote: > Is there any cases where we can turn the linker error into a compile time > error? We could possibly implicitly put an availability attribute on the implicit declarations or something equivalent, to say "hey

[PATCH] D34590: [ubsan] Diagnose invalid uses of builtins (clang)

2017-06-23 Thread Vedant Kumar via Phabricator via cfe-commits
vsk created this revision. On some targets, passing zero to the clz() or ctz() builtins has undefined behavior. I ran into this issue while debugging UB in __hash_table from libcxx: the bug I was seeing manifested itself differently under -O0 vs -Os, due to a UB call to clz() (see: libcxx/r304617)

[PATCH] D34591: [ubsan] Diagnose invalid uses of builtins (compiler-rt)

2017-06-23 Thread Vedant Kumar via Phabricator via cfe-commits
vsk created this revision. Herald added subscribers: dberris, kubamracek. Compiler-rt changes and tests to go along with: https://reviews.llvm.org/D34590 https://reviews.llvm.org/D34591 Files: lib/ubsan/ubsan_checks.inc lib/ubsan/ubsan_handlers.cc lib/ubsan/ubsan_handlers.h lib/ubsan/ub

<    1   2