[PATCH] D30087: [Driver] Unify linking of OpenMP runtime

2017-03-27 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld updated this revision to Diff 93213. Hahnfeld added a comment. Herald added a subscriber: rengolin. Rebase and ping. https://reviews.llvm.org/D30087 Files: lib/Driver/ToolChains/CommonArgs.cpp lib/Driver/ToolChains/CommonArgs.h lib/Driver/ToolChains/Darwin.cpp lib/Driver/ToolCh

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. In https://reviews.llvm.org/D31272#711877, @EricWF wrote: > In https://reviews.llvm.org/D31272#711876, @mehdi_amini wrote: > > > Strange. So installing the command line tools is not enough. It has to be > > that CMAKE_OSX_SYSROOT is only defined on Apple internal ins

[PATCH] D31334: [clang-format] Add options for indenting preprocessor directives

2017-03-27 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added a comment. Thank you for working on this. Unfortunately, this is done at the wrong level: - You are using a separate pass, which means that as soon as the preprocessor directives exceed the column limit, they won't be wrapped correctly. - You aren't using Clang's Lexer to separate

[PATCH] D31404: [OpenCL] Allow alloca return non-zero private pointer

2017-03-27 Thread Tony Tye via Phabricator via cfe-commits
t-tye added inline comments. Comment at: lib/AST/ASTContext.cpp:9547-9555 +unsigned ASTContext::getTargetAddressSpace(unsigned AS) const { + // For OpenCL, the address space qualifier is 0 in AST. + if (AS == 0 && LangOpts.OpenCL) +return getTargetInfo().getDataLayout().get

[PATCH] D28462: clang-format: Add new style option AlignConsecutiveMacros

2017-03-27 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added inline comments. Comment at: lib/Format/WhitespaceManager.cpp:413 + + while (Param && !Param->is(tok::l_paren)) { +if (!Param->is(tok::identifier) && !Param->is(tok::comma)) enyquist wrote: > djasper wrote: > > I think you should be able to use

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. In https://reviews.llvm.org/D31272#711876, @mehdi_amini wrote: > Strange. So installing the command line tools is not enough. It has to be > that CMAKE_OSX_SYSROOT is only defined on Apple internal install maybe? Are you sure you're starting with a clean CMake build dir

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. Strange. So installing the command line tools is not enough. It has to be that CMAKE_OSX_SYSROOT is only defined on Apple internal install maybe? Anyway, if you're exporting through the ABI list and have LIBCXX_ENABLE_NEW_DELETE_DEFINITIONS I expect the link to fail

[PATCH] D23796: [libcxx] Make it possible to test static builds of libc++ on OSX

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. Is this still needed? https://reviews.llvm.org/D23796 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D11781: Refactored pthread usage in libcxx

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF resigned from this revision. EricWF added a comment. This revision is no longer relevant after. The `__threading_support` changes have applied changes similar to this. Repository: rL LLVM https://reviews.llvm.org/D11781 ___ cfe-commits ma

[PATCH] D24371: Add diagnostics to require_constant_initialization

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. @rsmith ping. Repository: rL LLVM https://reviews.llvm.org/D24371 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26830: [libcxx] Add string_view literals

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. @AntonBikineev when will you be able to make he requested changes? I would like to land this ASAP. https://reviews.llvm.org/D26830 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman

[PATCH] D27387: [libc++] Add a key function for bad_function_call

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF accepted this revision. EricWF added a comment. This revision is now accepted and ready to land. This LGTM, but I have a question: Should we add these dylib definitions right away so that it's easier to adopt the ABI change in future? This will allow legacy dylibs to support this ABI chan

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. In https://reviews.llvm.org/D31272#711860, @mehdi_amini wrote: > In https://reviews.llvm.org/D31272#711804, @EricWF wrote: > > > I'm a bit confused by the description of this change. Libc++ has been > > enabling the new/delete definitions in its dylib since forever and I'

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. Not that I'm claiming to understand why we're changing strategy when we have the command line tools installed or not in this case ;) (CC @beanz if he know by any chance!) https://reviews.llvm.org/D31272 ___ cfe-commits

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. In https://reviews.llvm.org/D31272#711804, @EricWF wrote: > I'm a bit confused by the description of this change. Libc++ has been > enabling the new/delete definitions in its dylib since forever and I've never > experienced a link error. Did you mean to say the link

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. Woops. this patch also needed changes to `TreeTransform.h`. I'll add those tonight. Repository: rL LLVM https://reviews.llvm.org/D31399 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin

[PATCH] D31414: [NFC, Refactor] Modernize TemplateIdAnnotation using TrailingObjects

2017-03-27 Thread Faisal Vali via Phabricator via cfe-commits
faisalv updated this revision to Diff 93207. faisalv added a comment. Don't forget to destroy the trailing objects. https://reviews.llvm.org/D31414 Files: include/clang/Basic/TemplateKinds.h include/clang/Sema/ParsedTemplate.h lib/Parse/ParseExprCXX.cpp lib/Parse/ParseTemplate.cpp Inde

[PATCH] D31414: [NFC, Refactor] Modernize TemplateIdAnnotation using TrailingObjects

2017-03-27 Thread Faisal Vali via Phabricator via cfe-commits
faisalv created this revision. faisalv added a project: clang-c. Refactor TemplateIdAnnotation to use TrailingObjects and add assorted comments. Repository: rL LLVM https://reviews.llvm.org/D31414 Files: include/clang/Basic/TemplateKinds.h include/clang/Sema/ParsedTemplate.h lib/Parse/

[PATCH] D31375: Add docs for libunwind

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. In https://reviews.llvm.org/D31375#710897, @jroelofs wrote: > In https://reviews.llvm.org/D31375#710891, @compnerd wrote: > > > What happens when you try building it in tree? > > > The docs-libunwind-html target is missing, and the docs don't get built. Shouldn't that be

[PATCH] D31375: Add docs for libunwind

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF accepted this revision. EricWF added a comment. This revision is now accepted and ready to land. This LGTM. We should also get a bot setup to build it. https://reviews.llvm.org/D31375 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[PATCH] D31078: [libunwind] Clean up macro usage.

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF accepted this revision. EricWF added a comment. This revision is now accepted and ready to land. LGTM minus the suggested cleanup. Comment at: include/__libunwind_config.h:15 !defined(__ARM_DWARF_EH__) #define _LIBUNWIND_ARM_EHABI 1 #endif This sh

[PATCH] D29930: Add `__reference_binds_to_temporary` trait for checking safe reference initialization.

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. @rsmith gentle ping. https://reviews.llvm.org/D29930 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r298893 - Use BuildReturnStmt in SemaCoroutine to unbreak sanitizer tests.

2017-03-27 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon Mar 27 21:51:45 2017 New Revision: 298893 URL: http://llvm.org/viewvc/llvm-project?rev=298893&view=rev Log: Use BuildReturnStmt in SemaCoroutine to unbreak sanitizer tests. FIXME: ActOnReturnStmt expects a scope that is inside of the function, due to CheckJumpOutOf

[PATCH] D31413: [libc++] Use __attribute__((init_priority(101))) to ensure streams get initialized early

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF created this revision. This patch fixes http://llvm.org/PR28954 using the `init_priority` attribute. All supported compilers accept this attribute, including clang-cl. I'm only putting this up for review because IDK how to write a test for it. Can anybody suggest a way to test this? htt

[PATCH] D28462: clang-format: Add new style option AlignConsecutiveMacros

2017-03-27 Thread Erik Nyquist via Phabricator via cfe-commits
enyquist updated this revision to Diff 93204. enyquist marked 3 inline comments as done. enyquist added a comment. Addressed all comments, except for the one about FormatToken.MatchingParen (see reply comment) https://reviews.llvm.org/D28462 Files: docs/ClangFormatStyleOptions.rst include/

[PATCH] D30268: Avoid copy of __atoms when char_type is char

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. OK, so ABI wise this seems good. I'll need a fresh head to review the locale changes for correctness. I'll get around to that tomorrow. Comment at: libcxx/include/locale:891 +#ifndef _LIBCPP_ABI_OPTIMIZED_LOCALE // signed Would it be

[PATCH] D28462: clang-format: Add new style option AlignConsecutiveMacros

2017-03-27 Thread Erik Nyquist via Phabricator via cfe-commits
enyquist marked 8 inline comments as done. enyquist added inline comments. Comment at: lib/Format/WhitespaceManager.cpp:287 SmallVector &Changes, +bool ConsiderScope, bool ConsiderCommas, unsig

[PATCH] D31272: Do not pass an explicit reexported symbol list when building libc++ dylib if also defining new/delete

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. I'm a bit confused by the description of this change. Libc++ has been enabling the new/delete definitions in its dylib since forever and I've never experienced a link error. Did you mean to say the link error occurs only when libc++abi doesn't define them? https://revi

[PATCH] D31178: [libcxxabi] Fix exception address alignment test for EHABI

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. For the most part this LGTM other than the nits mentioned. Comment at: test/libcxxabi/test/config.py:34 +'libunwind_src', +os.path.join(self.libcxxabi_src_root, '/../libunwind/src')) I think the correct default

[PATCH] D29818: [libcxx] Threading support: Attempt to externalize system_clock::now() and steady_clock::now() implementations

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. I really dislike that `__libcpp_clock_monotonic` and `__libcpp_clock_realtime` are never declared, and are expected to be magically defined by the external threading header. This makes the configuration seem incorrect and unused. Also the previous threading support chang

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Aleksey Shlyapnikov via Phabricator via cfe-commits
alekseyshl added a comment. Seems like this bot is not happy about this change: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/3771 Repository: rL LLVM https://reviews.llvm.org/D31399 ___ cfe-commits mailing list cfe-commit

[PATCH] D31363: [libc++] Remove cmake glob for source files

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. Thanks for fixing this. Sucks that we have to manually enumerate source files but this is the correct solution according to CMake. Would it be easy to still use `glob` to verify that none of the source files have accidentally been forgotten? Comment a

[PATCH] D31003: [Objective-C] C++ Classes with __weak Members non-POD Types when using -fobjc-weak

2017-03-27 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D31003#711359, @bkelley wrote: > Thank you @rjmccall for the approval. I don't have commit access; would > someone be willing to commit this path for me please? Thanks! You have a lot of patches here. :) I would encourage you to just ask f

[PATCH] D30837: [libcxx] Support for shared_ptr

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added inline comments. Comment at: include/memory:3933 +typedef __shared_ptr_pointer<_Yp*, default_delete<_Yp>, _AllocT > _CntrlBlk; +__cntrl_ = new _CntrlBlk(__p, default_delete<_Yp>(), _AllocT()); __hold.release(); Quuxplusone wrote: > Eric

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Gor Nishanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. GorNishanov marked an inline comment as done. Closed by commit rL298891: [coroutines] Handle get_return_object_on_allocation_failure (authored by GorNishanov). Changed prior to commit: https://reviews.llvm.org/D31399?vs=9

r298891 - [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon Mar 27 18:36:59 2017 New Revision: 298891 URL: http://llvm.org/viewvc/llvm-project?rev=298891&view=rev Log: [coroutines] Handle get_return_object_on_allocation_failure Summary: If promise_type has get_return_object_on_allocation_failure defined, check if an allocatio

[PATCH] D31408: Add more examples to clang-format configuration

2017-03-27 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru updated this revision to Diff 93195. sylvestre.ledru added a comment. Thanks, indeed! :) https://reviews.llvm.org/D31408 Files: docs/ClangFormatStyleOptions.rst include/clang/Format/Format.h Index: include/clang/Format/Format.h ==

[PATCH] D31408: Add more examples to clang-format configuration

2017-03-27 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: docs/ClangFormatStyleOptions.rst:644 + .. code-block:: c++ + Shouldn't it be java? Comment at: docs/ClangFormatStyleOptions.rst:1293 + .. code-block:: c++ + Shouldn't it b

[PATCH] D31328: [clangd] Add code completion support

2017-03-27 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle-ericsson added a comment. Ideas/Observations: - One thing I has done in my version is to introduce "ASTUnitRunnable", a lambda function type that has an ASTUnit as parameter and is executed by the ASTManager. So the ASTManager takes care of locking the AST but the actual code using t

[PATCH] D31328: [clangd] Add code completion support

2017-03-27 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle-ericsson added inline comments. Comment at: test/clangd/formatting.test:14 +# CHECK: "codeActionProvider": true, +# CHECK: "completionProvider": {"resolveProvider": false, "triggerCharacters": [".",">"]} # CHECK: }}} It would be good eventually to

[PATCH] D29654: [OpenMP] Integrate OpenMP target region cubin into host binary

2017-03-27 Thread Justin Lebar via Phabricator via cfe-commits
jlebar added a comment. With your latest set of updates, I am not sure which, if any, patches you need me to take another look at. Unfortunately I don't have a ton of time for CUDA stuff these days, so where possible I'd prefer to shunt reviews over to hfinkel or chandlerc. But do let me know

[PATCH] D29654: [OpenMP] Integrate OpenMP target region cubin into host binary

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93192. gtbercea added a comment. Herald added a subscriber: rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29654 Files: lib/Driver/ToolChains/CommonArgs.cpp lib/Driver/ToolChains/CommonArg

[PATCH] D31408: Add more examples to clang-format configuration

2017-03-27 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru created this revision. Herald added a subscriber: klimek. https://reviews.llvm.org/D31408 Files: docs/ClangFormatStyleOptions.rst include/clang/Format/Format.h Index: include/clang/Format/Format.h === --- include

[PATCH] D29651: [OpenMP] Consider LIBRARY_PATH when selecting library paths for NVPTX targets in OpenMP mode.

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93188. gtbercea added a comment. Herald added a subscriber: rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29651 Files: lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index:

[PATCH] D23418: [analyzer] Added a reusable constraint system to the CloneDetector

2017-03-27 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor marked 7 inline comments as done. teemperor added a comment. Hey Leslie, regarding performance: Last time I checked we spend most of the time on the verification of the hash values. We can do some tricks to make this faster (like delaying the verification to the end of the constraints

[PATCH] D29647: [OpenMP] Extend CLANG target options with device offloading kind.

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: lib/Driver/Tools.cpp:12136 // Obtain architecture from the action. - CudaArch gpu_arch = StringToCudaArch(JA.getOffloadingArch()); assert(gpu_arch != CudaArch::UNKNOWN && jlebar wrote: > Why does JA.getOffloading

[PATCH] D29647: [OpenMP] Extend CLANG target options with device offloading kind.

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea added inline comments. Comment at: lib/Driver/ToolChains.cpp:4902 + DeviceOffloadingKind == Action::OFK_Cuda) && + "The offloading kind is not OpenMP or CUDA."); jlebar wrote: > Not sure this assertion message helps us much beyond what

[PATCH] D29647: [OpenMP] Extend CLANG target options with device offloading kind.

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93181. gtbercea marked 5 inline comments as done. gtbercea added a comment. Herald added subscribers: sbc100, dschuff, jfb, rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29647 Files: includ

[PATCH] D23418: [analyzer] Added a reusable constraint system to the CloneDetector

2017-03-27 Thread Raphael Isemann via Phabricator via cfe-commits
teemperor updated this revision to Diff 93180. teemperor added a comment. Herald added a subscriber: mgorny. Thanks for the review Artem! Changes: - No longer including the old LLVM hashing header. - Fixed the messed up comment formatting when i removed all the `\brief`s... - `CloneConstraint` i

[PATCH] D30837: [libcxx] Support for shared_ptr

2017-03-27 Thread Arthur O'Dwyer via Phabricator via cfe-commits
Quuxplusone added inline comments. Comment at: include/memory:3933 +typedef __shared_ptr_pointer<_Yp*, default_delete<_Yp>, _AllocT > _CntrlBlk; +__cntrl_ = new _CntrlBlk(__p, default_delete<_Yp>(), _AllocT()); __hold.release(); EricWF wrote: > Thi

Re: [PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-03-27 Thread David Blaikie via cfe-commits
On Mon, Mar 27, 2017 at 10:20 AM Aaron Ballman via Phabricator < revi...@reviews.llvm.org> wrote: > aaron.ballman added a comment. > > In https://reviews.llvm.org/D31153#711287, @dblaikie wrote: > > > As I mentioned to Craig Topper recently on another review, generally > when implementing const an

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 93177. GorNishanov added a comment. Added diagnostic test to SemaCXX/coroutines.cpp Preparing to Land https://reviews.llvm.org/D31399 Files: include/clang/AST/StmtCXX.h include/clang/Basic/DiagnosticSemaKinds.td lib/AST/StmtCXX.cpp lib/CodeGen/C

[PATCH] D29644: [OpenMP] Pass -v to PTXAS if it was passed to the driver.

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93176. gtbercea added a comment. Herald added a subscriber: rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29644 Files: lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index:

[PATCH] D29642: [OpenMP] Make OpenMP generated code for the NVIDIA device relocatable by default

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93172. gtbercea added a comment. Herald added a subscriber: rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29642 Files: lib/Driver/ToolChains/Cuda.cpp test/Driver/openmp-offload.c Index:

[PATCH] D29339: [OpenMP] Add support for auxiliary triple specification

2017-03-27 Thread Gheorghe-Teodor Bercea via Phabricator via cfe-commits
gtbercea updated this revision to Diff 93171. gtbercea added a comment. Herald added a subscriber: rengolin. Update patch to reflect latest source code changes. Repository: rL LLVM https://reviews.llvm.org/D29339 Files: lib/Driver/ToolChains/Clang.cpp lib/Frontend/CompilerInstance.cpp

[PATCH] D31130: B32239 clang-tidy should not warn about array to pointer decay on system macros

2017-03-27 Thread Matthias Gehre via Phabricator via cfe-commits
mgehre added inline comments. Comment at: clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp:83 + unless(hasSourceExpression(stringLiteral())), + unless(sysSymbolDecayInSysHeader())) .bind("cast"), --

[PATCH] D30837: [libcxx] Support for shared_ptr

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. This patch seems to support constructing a `shared_ptr` without providing a non-default deleter. I don't think this should work because the default deleter will attempt to free a function pointer, which is never valid. (Although I think this case will still cause a compi

[PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2017-03-27 Thread Matthias Gehre via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL298880: Add [[clang::suppress(rule, ...)]] attribute (authored by mgehre). Changed prior to commit: https://reviews.llvm.org/D24886?vs=93055&id=93168#toc Repository: rL LLVM https://reviews.llvm.org

r298880 - Add [[clang::suppress(rule, ...)]] attribute

2017-03-27 Thread Matthias Gehre via cfe-commits
Author: mgehre Date: Mon Mar 27 14:45:24 2017 New Revision: 298880 URL: http://llvm.org/viewvc/llvm-project?rev=298880&view=rev Log: Add [[clang::suppress(rule, ...)]] attribute Summary: This patch implements parsing of [[clang::suppress(rule, ...)]] and [[gsl::suppress(rule, ...)]] attributes.

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF accepted this revision. EricWF added a comment. This revision is now accepted and ready to land. This LGTM minus inline comments. Comment at: lib/Sema/SemaCoroutine.cpp:793 + LookupResult Found(S, DN, Loc, Sema::LookupMemberName); + // Suppress diagnostics when a priva

[PATCH] D31166: Encapsulate FPOptions and use it consistently

2017-03-27 Thread Adam Nemet via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL298877: Encapsulate FPOptions and use it consistently (authored by anemet). Changed prior to commit: https://reviews.llvm.org/D31166?vs=92898&id=93166#toc Repository: rL LLVM https://reviews.llvm.or

r298877 - Encapsulate FPOptions and use it consistently

2017-03-27 Thread Adam Nemet via cfe-commits
Author: anemet Date: Mon Mar 27 14:17:25 2017 New Revision: 298877 URL: http://llvm.org/viewvc/llvm-project?rev=298877&view=rev Log: Encapsulate FPOptions and use it consistently Sema holds the current FPOptions which is adjusted by 'pragma STDC FP_CONTRACT'. This then gets propagated into expre

[PATCH] D31404: [OpenCL] Allow alloca return non-zero private pointer

2017-03-27 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. Herald added subscribers: nhaehnle, wdng. There is an incoming change in LLVM allowing alloca to return a private pointer which does not pointing to address space 0: https://reviews.llvm.org/D31042#03b9d490 After this change is committed, alloca will return a point

[PATCH] D30415: Fix -mno-altivec cannot overwrite -maltivec option

2017-03-27 Thread Kuang He via Phabricator via cfe-commits
kuang_he abandoned this revision. kuang_he added a comment. In https://reviews.llvm.org/D30415#703652, @uweigand wrote: > In https://reviews.llvm.org/D30415#703442, @hfinkel wrote: > > > In https://reviews.llvm.org/D30415#703398, @echristo wrote: > > > > > Different suggestion: > > > > > > Remove

[PATCH] D31126: Do not run tests for crash recovery if libstdc++ safe mode is enabled

2017-03-27 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. Any feedback? https://reviews.llvm.org/D31126 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31269: [Modules] Allow modules specified by -fmodule-map-file to shadow implicitly found ones

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Ping! https://reviews.llvm.org/D31269 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D25866: [Sema] Support implicit scalar to vector conversions

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: test/Sema/vector-gcc-compat.c:61 + //match. + v2i64_r = v2i64_a == 1; // expected-warning {{incompatible vector types assigning to 'v2i64' (vector of 2 'long long' values) from 'long __attribute__((ext_vector_type(2)))' (vector

[PATCH] D30415: Fix -mno-altivec cannot overwrite -maltivec option

2017-03-27 Thread Sean Fertile via Phabricator via cfe-commits
sfertile added a comment. Thanks Eric. Kuang, commit r298449 contained this fix so you can close the review now. https://reviews.llvm.org/D30415 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo

[PATCH] D29923: PPCallbacks::MacroUndefined, change signature and add test.

2017-03-27 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM! https://reviews.llvm.org/D29923 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[PATCH] D29599: Clang Changes for alloc_align

2017-03-27 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 93158. erichkeane marked 2 inline comments as done. https://reviews.llvm.org/D29599 Files: include/clang/Basic/Attr.td include/clang/Basic/AttrDocs.td include/clang/Sema/Sema.h lib/CodeGen/CGCall.cpp lib/CodeGen/CodeGenFunction.h lib/Sema/SemaD

[PATCH] D29599: Clang Changes for alloc_align

2017-03-27 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 15 inline comments as done. erichkeane added a comment. Comments on 2 cases, otherwise a Patch incoming that fixes the rest of Aaron's comments. Comment at: include/clang/Basic/Attr.td:1224 +def AllocAlign : InheritableAttr { + let Spellings = [ GCC<"alloc_a

[PATCH] D31401: [clangd] Extract FsPath from file:// uri

2017-03-27 Thread Stanislav Ionascu via Phabricator via cfe-commits
stanionascu created this revision. rfc8089#appendix-E.2 specifies that paths can begin with a drive letter e.g. as file:///c:/. In this case just consuming front file:// is not enough and the 3rd slash must be consumed to produce a valid path on windows. The patch introduce a generic way of con

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-03-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D31153#711287, @dblaikie wrote: > As I mentioned to Craig Topper recently on another review, generally when > implementing const and non-const overloads the non-const is implemented in > terms of the const overload (& const_casts away c

[PATCH] D31397: [Bug 25404] Fix crash on typedef in OpenCL 2.0

2017-03-27 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added inline comments. Comment at: lib/Sema/SemaDecl.cpp:2157 if (getDiagnostics().getSuppressSystemWarnings() && - (Context.getSourceManager().isInSystemHeader(Old->getLocation()) || + // Some standard types are defined implicitly in Clang (e.g. OpenCL). +

[PATCH] D31140: [LLVMbugs] [Bug 18710] Only generate .ARM.exidx and .ARM.extab when needed in EHABI

2017-03-27 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Is it possible to enable cantunwind for one function and enable for another? If so, does this have to be a function attribute? https://reviews.llvm.org/D31140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://

[PATCH] D31308: [clang-tidy] new check readability-no-alternative-tokens

2017-03-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/OperatorsRepresentationCheck.cpp:34 + + if (const auto *B = Result.Nodes.getNodeAs("binary")) { +switch (B->getOpcode()) { alexfh wrote: > aaron.ballman wrote: > > I think this would mak

[PATCH] D31308: [clang-tidy] new check readability-no-alternative-tokens

2017-03-27 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh added inline comments. Comment at: clang-tidy/readability/OperatorsRepresentationCheck.cpp:34 + + if (const auto *B = Result.Nodes.getNodeAs("binary")) { +switch (B->getOpcode()) { aaron.ballman wrote: > I think this would make more sense lifted into

[PATCH] D31399: [coroutines] Handle get_return_object_on_allocation_failure

2017-03-27 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov created this revision. Herald added a subscriber: mehdi_amini. If promise_type has get_return_object_on_allocation_failure defined, check if an allocation function returns nullptr, and if so, return the result of get_return_object_on_allocation_failure(). https://reviews.llvm.org/D3

r298853 - Look through CXXBindTemporaryExprs when checking CXXFunctionCastExprs

2017-03-27 Thread Daniel Jasper via cfe-commits
Author: djasper Date: Mon Mar 27 11:29:41 2017 New Revision: 298853 URL: http://llvm.org/viewvc/llvm-project?rev=298853&view=rev Log: Look through CXXBindTemporaryExprs when checking CXXFunctionCastExprs for unused values. This fixes a regression caused by r298676, where constructor calls to clas

[PATCH] D31007: [Objective-C] Miscellaneous -fobjc-weak Fixes

2017-03-27 Thread Brian T. Kelley via Phabricator via cfe-commits
bkelley added a comment. Thank you @rjmccall for the approval. I don't have commit access; would someone be willing to commit this path for me please? Thanks! https://reviews.llvm.org/D31007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D31006: [Objective-C] Fix "weak-unavailable" warning with -fobjc-weak

2017-03-27 Thread Brian T. Kelley via Phabricator via cfe-commits
bkelley added a comment. Thank you @rjmccall for the approval. I don't have commit access; would someone be willing to commit this path for me please? Thanks! https://reviews.llvm.org/D31006 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D31005: [Objective-C] Fix "repeated use of weak" warning with -fobjc-weak

2017-03-27 Thread Brian T. Kelley via Phabricator via cfe-commits
bkelley added a comment. Thank you @rjmccall for the approval. I don't have commit access; would someone be willing to commit this path for me please? Thanks! https://reviews.llvm.org/D31005 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D31004: [Objective-C] Fix __weak type traits with -fobjc-weak

2017-03-27 Thread Brian T. Kelley via Phabricator via cfe-commits
bkelley added a comment. Thank you @rjmccall for the approval. I don't have commit access; would someone be willing to commit this path for me please? Thanks! https://reviews.llvm.org/D31004 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D31003: [Objective-C] C++ Classes with __weak Members non-POD Types when using -fobjc-weak

2017-03-27 Thread Brian T. Kelley via Phabricator via cfe-commits
bkelley added a comment. Thank you @rjmccall for the approval. I don't have commit access; would someone be willing to commit this path for me please? Thanks! https://reviews.llvm.org/D31003 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

r298850 - [ARM] Add a driver option for +no-neg-immediates

2017-03-27 Thread Sanne Wouda via cfe-commits
Author: sanwou01 Date: Mon Mar 27 10:34:52 2017 New Revision: 298850 URL: http://llvm.org/viewvc/llvm-project?rev=298850&view=rev Log: [ARM] Add a driver option for +no-neg-immediates Reviewers: olista01, rengolin, javed.absar, samparker Reviewed By: samparker Subscribers: samparker, llvm-commi

[PATCH] D18914: [clang-tidy] new readability-redundant-inline

2017-03-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/RedundantInlineCheck.cpp:24 +AST_MATCHER(FriendDecl, isInlineAndHasBody) { + NamedDecl *D = Node.getFriendDecl(); + if (!D) const NamedDecl (same for const auto * below).

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-03-27 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. As I mentioned to Craig Topper recently on another review, generally when implementing const and non-const overloads the non-const is implemented in terms of the const overload (& const_casts away const on the result). This ensures no UB if the const overload is called

[PATCH] D31308: [clang-tidy] new check readability-no-alternative-tokens

2017-03-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang-tidy/readability/OperatorsRepresentationCheck.cpp:34 + + if (const auto *B = Result.Nodes.getNodeAs("binary")) { +switch (B->getOpcode()) { I think this would make more sense lifted into an AST matcher -

[PATCH] D31166: Encapsulate FPOptions and use it consistently

2017-03-27 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! Comment at: lib/CodeGen/CGExprScalar.cpp:1712 BinOp.Opcode = IsInc ? BO_Add : BO_Sub; - BinOp.FPContractable = false; + // FIXME: once UnaryOperator

[PATCH] D31183: [OpenCL] Added parsing for OpenCL vector types.

2017-03-27 Thread Egor Churaev via Phabricator via cfe-commits
echuraev updated this revision to Diff 93132. echuraev marked an inline comment as done. https://reviews.llvm.org/D31183 Files: include/clang/Parse/Parser.h lib/Parse/ParseExpr.cpp test/Parser/vector-cast-define.cl Index: test/Parser/vector-cast-define.cl ==

[PATCH] D31397: [Bug 25404] Fix crash on typedef in OpenCL 2.0

2017-03-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia created this revision. Herald added a subscriber: yaxunl. Fixing the assertion due to absence of source location for implicitly defined types (using addImplicitTypedef()). During Sema checks the source location is being expected and therefore an assertion is triggered. The change is n

Re: r298676 - Fix handling of initialization from parenthesized initializer list.

2017-03-27 Thread Daniel Jasper via cfe-commits
-Wunused-value is always triggered if a constructor of an object with a non-trivial destructor has an initializer list as first parameter. So in the test, even "Used({});" triggers -Wunused-value. That seems inconsistent (replacing the init list with something else silences the warning) and also th

Re: r298676 - Fix handling of initialization from parenthesized initializer list.

2017-03-27 Thread Richard Smith via cfe-commits
What is the effect on that testcase? (Sorry, heading to vacation and can't easily check.) On 27 Mar 2017 6:33 am, "Daniel Jasper" wrote: > Hi Richard, > > this seems to have an unwanted side-effect on -Wunused-value (test case > attached). Could you take a look? > > Cheers, > Daniel > > On Fri,

[PATCH] D31183: [OpenCL] Added parsing for OpenCL vector types.

2017-03-27 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia added a comment. I don't think that diagnostics can always be very clear. This is not the case neither for C nor C++. As I said I don't see any issue to continue with this patch. I would just like to see the test simplified a bit. https://reviews.llvm.org/D31183

Re: r298676 - Fix handling of initialization from parenthesized initializer list.

2017-03-27 Thread Daniel Jasper via cfe-commits
Hi Richard, this seems to have an unwanted side-effect on -Wunused-value (test case attached). Could you take a look? Cheers, Daniel On Fri, Mar 24, 2017 at 2:14 AM, Richard Smith via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: rsmith > Date: Thu Mar 23 20:14:25 2017 > New Revisi

r298842 - Publish one more parser RAII for external use.

2017-03-27 Thread Vassil Vassilev via cfe-commits
Author: vvassilev Date: Mon Mar 27 08:11:32 2017 New Revision: 298842 URL: http://llvm.org/viewvc/llvm-project?rev=298842&view=rev Log: Publish one more parser RAII for external use. Modified: cfe/trunk/include/clang/Parse/RAIIObjectsForParser.h cfe/trunk/lib/Parse/Parser.cpp Modified: c

[PATCH] D31153: Add the ability to use the children() range API in a const-correct manner

2017-03-27 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. Ping. Because I expect this to be fairly uncontroversial, I'll give it a week in case folks have comments, then commit (and will handle anything in post-commit review). https://reviews.llvm.org/D31153 ___ cfe-commit

[PATCH] D30547: [clang-tidy] Forwarding reference overload in constructors

2017-03-27 Thread András Leitereg via Phabricator via cfe-commits
leanil marked 2 inline comments as done. leanil added inline comments. Comment at: clang-tidy/misc/ForwardingReferenceOverloadCheck.cpp:119 + DisabledMove = false; + for (const auto *OtherCtor : Ctor->getParent()->ctors()) { +if (OtherCtor->isCopyConstructor()) { -

[PATCH] D30547: [clang-tidy] Forwarding reference overload in constructors

2017-03-27 Thread András Leitereg via Phabricator via cfe-commits
leanil updated this revision to Diff 93114. leanil added a comment. Correct earlier diff issue with outdated master. Repository: rL LLVM https://reviews.llvm.org/D30547 Files: clang-tidy/misc/CMakeLists.txt clang-tidy/misc/ForwardingReferenceOverloadCheck.cpp clang-tidy/misc/Forwarding

[PATCH] D30547: [clang-tidy] Forwarding reference overload in constructors

2017-03-27 Thread Jonas Toth via Phabricator via cfe-commits
JonasToth added a comment. Why does diff contain so many files? Could you maybe merge the latest master into your branch? Repository: rL LLVM https://reviews.llvm.org/D30547 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llv

  1   2   >