[PATCH] D25263: [Driver] Allow setting the default linker during build

2016-12-11 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld accepted this revision. Hahnfeld added a comment. This revision is now accepted and ready to land. LGTM with one nit Comment at: lib/Driver/ToolChain.cpp:362 + return UseLinker; + } else if (UseLinker == "ld") { +// If we're passed the argument ld, then use

[PATCH] D27669: [clang-move] Use appendArgumentsAdjuster for adding extra arguments

2016-12-11 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexshap created this revision. alexshap added reviewers: hokein, klimek. alexshap added a subscriber: cfe-commits. alexshap set the repository for this revision to rL LLVM. 1. Remove some boilerplate plate code for appending -fparse-all-comments to the list of arguments. 2. Run clang-format -i

[PATCH] D25435: Add -femit-accurate-debug-info to emit more debug info for sample pgo profile collection

2016-12-11 Thread Dehao Chen via Phabricator via cfe-commits
danielcdh added a comment. In https://reviews.llvm.org/D25435#619169, @hfinkel wrote: > In https://reviews.llvm.org/D25435#609320, @danielcdh wrote: > > > change the flag name to -fprofile-debug > > > I don't really like this name because it sounds like it might be enabling > some kind of

[libcxx] r289418 - [libcxx][CMake] Move the warning to HandleOutOfTreeLLVM

2016-12-11 Thread Petr Hosek via cfe-commits
Author: phosek Date: Sun Dec 11 23:05:46 2016 New Revision: 289418 URL: http://llvm.org/viewvc/llvm-project?rev=289418=rev Log: [libcxx][CMake] Move the warning to HandleOutOfTreeLLVM This currently gives a warning when building libcxx under runtimes. Differential Revision:

r289413 - Add two new AST nodes to represent initialization of an array in terms of

2016-12-11 Thread Richard Smith via cfe-commits
Author: rsmith Date: Sun Dec 11 20:53:20 2016 New Revision: 289413 URL: http://llvm.org/viewvc/llvm-project?rev=289413=rev Log: Add two new AST nodes to represent initialization of an array in terms of initialization of each array element: * ArrayInitLoopExpr is a prvalue of array type with two

[PATCH] D27529: Correct Vectorcall Register passing and HVA Behavior

2016-12-11 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. FWIW, the LLVM side of this patch seems to have been committed: https://reviews.llvm.org/D27148 https://reviews.llvm.org/D27529 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81039. firolino added a comment. A few namespace cleanups - Removed explicit llvm::'s, since the used names are already introduced into the clang namespace by llvm.h https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2016-12-11 Thread Howard Hinnant via Phabricator via cfe-commits
howard.hinnant added a comment. Thanks Eric. Fwiw `CLOCK_MONOTONIC` won't meet the requirements of the standard either. The standard appears to require `steady_clock` to be a perfect clock and there is no such thing. The wording used to only require monotonic, but the committee got a little

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino added inline comments. Comment at: clang-tidy/readability/OneNamePerDeclarationCheck.cpp:246 + +static std::string getCurrentLineIndent(SourceLocation Loc, +const SourceManager ) { malcolm.parsons wrote: > Should

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81029. firolino marked an inline comment as done. firolino added a comment. Little typo fix. https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/OneNamePerDeclarationCheck.cpp

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81023. firolino added a comment. typdef -> typedef https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/OneNamePerDeclarationCheck.cpp clang-tidy/readability/OneNamePerDeclarationCheck.h

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81022. firolino marked 7 inline comments as done. firolino added a comment. Applied suggestions from malcolm. https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/OneNamePerDeclarationCheck.cpp

[PATCH] D27655: Fix modernize-deprecated-headers clang-tidy warnings

2016-12-11 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Did you enable analysis of headers in Clang-tidy? Comment at: lib/Frontend/CompilerInstance.cpp:51 #include -#include +#include #include Will be good idea to run Clang-format or sort headers manually.

[PATCH] D26830: [libcxx] Add string_view literals

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. Please ping this once the Clang changes have been accepted. I'm just waiting on those to give this the final OK. https://reviews.llvm.org/D26830 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27658: [libcxx] Fix all occurrences of -Wsign-compare in the headers

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF created this revision. EricWF added a reviewer: mclow.lists. EricWF added subscribers: cfe-commits, STL_MSFT. The title says it all. Thanks to STL for cleaning up all occurrences in the tests so we can find these. https://reviews.llvm.org/D27658 Files: include/__bit_reference

[PATCH] D26896: [libcxx] Make constexpr char_traits and char_traits

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF requested changes to this revision. EricWF added a comment. This revision now requires changes to proceed. Marking as "Changes requested". I'll take a look at this again once the if-def hell around `find` and `compare` are cleaned up. https://reviews.llvm.org/D26896

[PATCH] D27576: [libcxx] libc++ changes necessary for the externally threaded libcxxabi variant

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. This bit LGTM. Comment at: include/__threading_support:193 +// Execute once +int __libcpp_execute_once(__libcpp_exec_once_flag *flag, + void (*init_routine)(void)) { These should have `inline`. In fact all of

[PATCH] D26623: [libcxx] [test] Swapping non-equal non-POCS allocators is UB.

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. I hope you don't mind but I committed by own version of this change as r289358. I was concerned about testing that the container didn't actually perform a swap, so I modified test_allocator to take an "id" parameter that does not participate in equality. I then changed

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

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF requested changes to this revision. EricWF added a comment. This revision now requires changes to proceed. OK. I would like to see this change introduced under a `_LIBCPP_ABI` flag. I'll take a look at this again after that. https://reviews.llvm.org/D27387

[PATCH] D27270: [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 4/4.

2016-12-11 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 change looks OK to me. As mentioned above I think the reason the test allocators used int/unsigned is so they could detect if the container actually propagated their typedefs. However

[PATCH] D26814: [libcxx] [test] Change ifstream constructor tests to handle read-only files.

2016-12-11 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. Thanks for working on this. https://reviews.llvm.org/D26814 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D27575: [libcxxabi] Introduce an externally threaded libc++abi variant (take-2)

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. This LGTM. I'll approve after the inline comments are addressed. Comment at: CMakeLists.txt:121 option(LIBCXXABI_HAS_PTHREAD_API "Ignore auto-detection and force use of pthread API" OFF) +option(LIBCXXABI_HAS_EXTERNAL_THREAD_API + "Build libc++abi

[PATCH] D27270: [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 4/4.

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF requested changes to this revision. EricWF added a comment. This revision now requires changes to proceed. Actually I've changed my mind on this patch. While attempting to clean up `-Wconversion` errors in libc++ I found many of them were caused by these custom allocators providing a

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. Howard Thank you for your excellent analysis. Although I still don't think that `CLOCK_UPTIME_RAW` meets the requirements of `steady_clock` but I would rather relax the standard here than provide a poor implementation. In https://reviews.llvm.org/D27429#618998,

[PATCH] D26626: [libcxx] [test] Fix an improper assumption about Null Forward Iterators.

2016-12-11 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. Go ahead and remove the tests. I filed a libc++ bug reminding me to diagnose those comparisons in debug mode (https://llvm.org/bugs/show_bug.cgi?id=31343).

[PATCH] D27555: [libcxx] [test] Fix MSVC warning C6001 "Using uninitialized memory".

2016-12-11 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. I'm happy to work around this one issue but in general I dislike initializing memory to avoid compile-time warnings. Doing so prevents the sanitizers from catching actual uninitialized memory

[PATCH] D27199: [libcxx] Make std::ignore constexpr

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF added a comment. @AntonBikineev Do you need somebody to commit this for you? https://reviews.llvm.org/D27199 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added inline comments. Comment at: clang-tidy/readability/OneNamePerDeclarationCheck.cpp:48 + // Single declarations and macros will be ignored + if (DeclStmt->isSingleDecl() || DeclStmt->getLocStart().isMacroID()) +return; Can you reject

[PATCH] D27655: Fix modernize-deprecated-headers clang-tidy warnings

2016-12-11 Thread Michael Sharpe via Phabricator via cfe-commits
michael.sharpe created this revision. michael.sharpe added a reviewer: rsmith. michael.sharpe added a subscriber: cfe-commits. Herald added subscribers: JDevlieghere, klimek. https://reviews.llvm.org/D27655 Files: lib/CodeGen/CGOpenCLRuntime.cpp lib/Driver/Types.cpp

[PATCH] D24218: [libc++] Fix support for multibyte thousands_sep and decimal_point in moneypunct_byname and numpunct_byname.

2016-12-11 Thread Eric Fiselier via Phabricator via cfe-commits
EricWF updated this revision to Diff 81010. EricWF added a comment. Address inline comments. https://reviews.llvm.org/D24218 Files: src/locale.cpp test/std/localization/locale.categories/category.monetary/locale.moneypunct.byname/decimal_point.pass.cpp

[PATCH] D26530: Fix the spelling of 'bitfield' in diagnostics to be consistently 'bit-field'.

2016-12-11 Thread Chandler Carruth via Phabricator via cfe-commits
chandlerc updated this revision to Diff 81008. chandlerc added a comment. Rebase and ping? It'd be awesome to land this minor patch, its been out for a month now. https://reviews.llvm.org/D26530 Files: include/clang/Basic/DiagnosticParseKinds.td include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D26768: [analyzer] Improve VirtualCallChecker diagnostics and move to optin package.

2016-12-11 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added a comment. In https://reviews.llvm.org/D26768#618651, @dcoughlin wrote: > The definite false positives were cases where the programmer seemed aware of > the semantics of virtual calls during construction/destruction and had each > subclass explicitly call its own version

[PATCH] D27210: [clang-tidy] misc-string-compare. Adding a new check to clang-tidy

2016-12-11 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added inline comments. Comment at: clang-tidy/misc/StringCompareCheck.cpp:25 + callee(cxxMethodDecl(hasName("compare"), + ofClass(classTemplateSpecializationDecl( + hasName("::std::basic_string"),

[PATCH] D27557: Update the default of the Mozilla coding style

2016-12-11 Thread Sylvestre Ledru via Phabricator via cfe-commits
sylvestre.ledru updated this revision to Diff 81004. sylvestre.ledru added a comment. Keep SpaceAfterTemplateKeyword to true https://reviews.llvm.org/D27557 Files: lib/Format/Format.cpp Index: lib/Format/Format.cpp === ---

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81001. firolino added a comment. Added test case with struct keyword: struct StructOne cs1, cs2( 42 ); https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/OneNamePerDeclarationCheck.cpp

[PATCH] D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC

2016-12-11 Thread Howard Hinnant via Phabricator via cfe-commits
howard.hinnant added a comment. One more comment: `steady_clock::now()` is not allowed to throw an exception because it shall satisfy the requirements of `TrivialClock` ([time.clock]/p1). And [time.clock.req]/p4/b4 says that a `TrivialClock::now()` does not throw exceptions.

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino added a comment. @Eugene.Zelenko No modernize-* check was reported. I applied //most// of the readability-* checks. For example, I did not put braces around: if (DeclStmt == nullptr) return; if (DeclStmt->isSingleDecl() || DeclStmt->getLocStart().isMacroID()) return;

[PATCH] D27621: [clang-tidy] check to find declarations declaring more than one name

2016-12-11 Thread Firat Kasmis via Phabricator via cfe-commits
firolino updated this revision to Diff 81000. firolino marked 9 inline comments as done. firolino added a comment. Applied readability-* checks. https://reviews.llvm.org/D27621 Files: clang-tidy/readability/CMakeLists.txt clang-tidy/readability/OneNamePerDeclarationCheck.cpp

[PATCH] D25435: Add -femit-accurate-debug-info to emit more debug info for sample pgo profile collection

2016-12-11 Thread Hal Finkel via Phabricator via cfe-commits
hfinkel added a comment. In https://reviews.llvm.org/D25435#609320, @danielcdh wrote: > change the flag name to -fprofile-debug I don't really like this name because it sounds like it might be enabling some kind of debugging of the profiling. How about -fdebug-info-for-profiling. Another