[PATCH] D39673: Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-06 Thread Martell Malone via Phabricator via cfe-commits
martell added a comment. In https://reviews.llvm.org/D39673, @martell wrote: > Long term I would like the MinGW Driver to load a different libunwind > depending on the exception model but that discussion might still be a little > off. In https://reviews.llvm.org/D39673#917510, @mstorsjo wro

[PATCH] D39673: Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-06 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In https://reviews.llvm.org/D39673#917506, @martell wrote: > @mstorsjo I think this should help with issues like having to set the default > for ARM to DWARF. Btw, in addition to making setting `__SEH__` conditional, it should also instead set `__ARM_DWARF_EH__` on A

[PATCH] D39673: Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-06 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In https://reviews.llvm.org/D39673#917506, @martell wrote: > @mstorsjo I think this should help with issues like having to set the default > for ARM to DWARF. > If you can set it at run time then it should be a lot easier to just set > that in the clang wrapper script

[PATCH] D39673: Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-06 Thread Martell Malone via Phabricator via cfe-commits
martell added a comment. @mstorsjo I think this should help with issues like having to set the default for ARM to DWARF. If you can set it at run time then it should be a lot easier to just set that in the clang wrapper scripts. Long term I would like the MinGW Driver to load a different libunw

[PATCH] D38831: [libcxx] P0604, invoke_result and is_invocable

2017-11-06 Thread Agustín Bergé via Phabricator via cfe-commits
K-ballo added a comment. In https://reviews.llvm.org/D38831#917439, @EricWF wrote: > @K-ballo I always forget. Do you have commit access? I do not. It's all yours. https://reviews.llvm.org/D38831 ___ cfe-commits mailing list cfe-commits@lists.llv

[PATCH] D39711: [analyzer] ObjCGenerics: Don't warn on cast conversions involving explicit cast

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added inline comments. Comment at: lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp:587 if (TrackedType && + !isa(CE) && !ASTCtxt.canAssignObjCInterfaces(DestObjectPtrType, *TrackedType) && Should it check that we are actuall

[PATCH] D39050: Add index-while-building support to Clang

2017-11-06 Thread Nathan Hawes via Phabricator via cfe-commits
nathawes added inline comments. Comment at: lib/Index/IndexRecordHasher.cpp:103 + COMBINE_HASH(Hasher.hash(param->getType())); +} +return Hash; arphaman wrote: > Should you hash the return type as well? The return type doesn't affect the function's U

[PATCH] D39673: Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-06 Thread Martell Malone via Phabricator via cfe-commits
martell updated this revision to Diff 121832. martell added a comment. Add command line documentation references Repository: rL LLVM https://reviews.llvm.org/D39673 Files: docs/ClangCommandLineReference.rst include/clang/Basic/LangOptions.def include/clang/Driver/Options.td include/c

[PATCH] D38831: [libcxx] P0604, invoke_result and is_invocable

2017-11-06 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. @K-ballo I always forget. Do you have commit access? https://reviews.llvm.org/D38831 ___ cfe-commits mailing list cfe-commits@list

[PATCH] D39711: [analyzer] ObjCGenerics: Don't warn on cast conversions involving explicit cast

2017-11-06 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a comment. @xazax.hun Would you be willing to take a look? https://reviews.llvm.org/D39711 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39627: Fix vtable not receiving hidden visibility when using push(visibility)

2017-11-06 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D39627#917175, @efriedma wrote: > Adding cfe-commits. (In the future, please make sure to CC that list instead > of llvm-commits for clang changes.) > > > I'm missing some background lingo here. What is the meaning of "a > > declaration" an

[PATCH] D39711: [analyzer] ObjCGenerics: Don't warn on cast conversions involving explicit cast

2017-11-06 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin created this revision. Herald added a subscriber: szepet. The ObjCGenerics checker warns on a cast when there is no subtyping relationship between the tracked type of the value and the destination type of the cast. It does this even if the cast was explicitly written. This means the user

[PATCH] D39462: [Sema] Implement -Wmaybe-tautological-constant-compare for when the tautologicalness is data model dependent

2017-11-06 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. So, that change makes this very interesting, because I think the right way of looking at it is as the first in a larger family of warnings that attempt to treat typedefs as if they were a much stronger type-system feature, i.e. that warn about all sorts of conversions

[PATCH] D39080: [libcxx] [test] Tolerate even more [[nodiscard]] in the STL.

2017-11-06 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 think I would prefer if this patch "left an explicit trace" as to the reasons for all the `(void)` casts. Specifically I think a macro like `TEST_IGNORE_DISCARD ` might be nice. @BillyONeal

[PATCH] D39537: Rename identifiers named `__output`

2017-11-06 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 inline comments. Comment at: test/support/nasty_macros.hpp:55 +#define __output NASTY_MACRO +#define __input NASTY_MACRO Shouldn't these not be

[clang-tools-extra] r317538 - ClangdTests/JSONExprTests.cpp: Appease g++-4.8 to move raw string literal out of macro arg.

2017-11-06 Thread NAKAMURA Takumi via cfe-commits
Author: chapuni Date: Mon Nov 6 18:18:24 2017 New Revision: 317538 URL: http://llvm.org/viewvc/llvm-project?rev=317538&view=rev Log: ClangdTests/JSONExprTests.cpp: Appease g++-4.8 to move raw string literal out of macro arg. Modified: clang-tools-extra/trunk/unittests/clangd/JSONExprTests.c

[PATCH] D39620: [analyzer] [NFC] Remove unused typedef

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL317537: [analyzer] [NFC] Remove unused typedef from SVals.h (authored by george.karpenkov). Changed prior to commit: https://reviews.llvm.org/D39620?vs=121556&id=121827#toc Repository: rL LLVM https

r317537 - [analyzer] [NFC] Remove unused typedef from SVals.h

2017-11-06 Thread George Karpenkov via cfe-commits
Author: george.karpenkov Date: Mon Nov 6 18:02:10 2017 New Revision: 317537 URL: http://llvm.org/viewvc/llvm-project?rev=317537&view=rev Log: [analyzer] [NFC] Remove unused typedef from SVals.h Differential Revision: https://reviews.llvm.org/D39620 Modified: cfe/trunk/include/clang/StaticAn

[PATCH] D39709: [analyzer] [NFC] remove duplicated function

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov created this revision. Herald added subscribers: szepet, xazax.hun. Two copies of `getSymLERange` in `RangeConstraintManager` are virtually identical, which is clearly bad. This patch uses lambdas to call one from another (assuming that we would like to avoid getting ranges from

[PATCH] D39707: [analyzer] assume bitwise arithmetic axioms

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 121825. https://reviews.llvm.org/D39707 Files: lib/StaticAnalyzer/Core/RangeConstraintManager.cpp test/Analysis/constant-folding.c Index: test/Analysis/constant-folding.c === --- t

[PATCH] D39579: BuiltinOperatorOverloadBuilder: Don't consider types that are unavailable on the target (PR35174)

2017-11-06 Thread Hans Wennborg via Phabricator via cfe-commits
hans updated this revision to Diff 121824. hans edited the summary of this revision. hans added a comment. Addressing comments and changing the test to exercise Sema more directly. Please take another look. https://reviews.llvm.org/D39579 Files: lib/Sema/SemaOverload.cpp test/SemaCXX/micro

[PATCH] D39579: BuiltinOperatorOverloadBuilder: Don't consider types that are unavailable on the target (PR35174)

2017-11-06 Thread Hans Wennborg via Phabricator via cfe-commits
hans marked 2 inline comments as done. hans added inline comments. Comment at: test/CodeGenCXX/microsoft-cannot-mangle-float128.cpp:3-11 +template struct B; +template constexpr bool is_floating_point_v = false; + +struct StrictNumeric { + StrictNumeric(int); + template > = nu

[PATCH] D39708: [OMPT] Fix test cancel_parallel.c

2017-11-06 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld created this revision. If a parallel region is cancelled, execution resumes at the end of the structured block. That is why this test cannot use the "normal" macros that print right after inserting the label. Instead it previously printed the addresses before the pragma and swapped the ch

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu updated this revision to Diff 121822. steven_wu added a comment. Update testcase for CUDA driver https://reviews.llvm.org/D39502 Files: lib/Driver/Compilation.cpp test/Driver/cuda-bail-out.cu test/Driver/output-file-cleanup.c test/Driver/unix-conformance.c Index: test/Driver/

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu added inline comments. Comment at: test/Driver/cuda-bail-out.cu:47 +// CHECK-HOST-ERROR: Error during compilation for host +// CHECK-HOST-ERROR-NOT: Error during compilation for sm_35 tra wrote: > steven_wu wrote: > > tra wrote: > > > To make it more ro

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: test/Driver/cuda-bail-out.cu:47 +// CHECK-HOST-ERROR: Error during compilation for host +// CHECK-HOST-ERROR-NOT: Error during compilation for sm_35 steven_wu wrote: > tra wrote: > > To make it more robust, I'd add another c

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu added inline comments. Comment at: test/Driver/cuda-bail-out.cu:47 +// CHECK-HOST-ERROR: Error during compilation for host +// CHECK-HOST-ERROR-NOT: Error during compilation for sm_35 tra wrote: > To make it more robust, I'd add another copy of the last

[PATCH] D39584: [analyzer] [NFC] another very minor ExprEngineC refactoring

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov updated this revision to Diff 121814. george.karpenkov edited the summary of this revision. george.karpenkov added a comment. Addressed review comments. https://reviews.llvm.org/D39584 Files: lib/StaticAnalyzer/Core/ExprEngineC.cpp Index: lib/StaticAnalyzer/Core/ExprEngineC

r317532 - Clarify the error message for unsupported aliases on Darwin

2017-11-06 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Mon Nov 6 16:31:19 2017 New Revision: 317532 URL: http://llvm.org/viewvc/llvm-project?rev=317532&view=rev Log: Clarify the error message for unsupported aliases on Darwin rdar://35109556 Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td cfe/trunk/test

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In https://reviews.llvm.org/D39502#917267, @steven_wu wrote: > Improve testcase according to review feedback. > > In order to let compilation to be successful for one input, I need to use > -fsyntax-only because I don't have nvptx assembler. Enable -fsyntax-only > changes t

[PATCH] D39707: [analyzer] assume bitwise arithmetic axioms

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov created this revision. Herald added subscribers: szepet, xazax.hun. Patches the solver to assume that bitwise OR of an unsigned value with a constant always produces a value larger-or-equal than the constant, and bitwise AND with a constant always produces a value less-or-equal

[PATCH] D38708: [AST] Flag the typo-corrected nodes for better tooling

2017-11-06 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. ping Repository: rL LLVM https://reviews.llvm.org/D38708 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D39622: Fix type debug information generation for enum-based template specialization

2017-11-06 Thread David Blaikie via cfe-commits
Ping \/ On Fri, Nov 3, 2017 at 4:22 PM David Blaikie wrote: > When you say "symbols table" - what are you referring to? > > On Fri, Nov 3, 2017 at 4:20 PM Adrian Prantl via Phabricator < > revi...@reviews.llvm.org> wrote: > >> aprantl added a comment. >> >> Can you add a testcase? >> >> >> Repos

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu updated this revision to Diff 121807. steven_wu added a comment. Improve testcase according to review feedback. In order to let compilation to be successful for one input, I need to use -fsyntax-only because I don't have nvptx assembler. Enable -fsyntax-only changes the order of the com

[PATCH] D39706: [refactor][extract] Initial implementation of variable captures

2017-11-06 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. Herald added a subscriber: mgorny. This patch adds an initial rudimentary support for capturing variables that should be passed to the extracted function. The variables are passed to the extracted function if they're used in the extracted code. If they're defined

[PATCH] D39703: [CUDA] Remove implementations of nexttoward and nextafter.

2017-11-06 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. Libdevice does provide implementation for __nv_nextafterf() and __nv_nextafter() and it has corresponding wrappers in math_funct

[PATCH] D39702: [test-suite] [CUDA] Delete nexttoward and nextafter CUDA tests, because these functions have no implementations.

2017-11-06 Thread Justin Lebar via Phabricator via cfe-commits
jlebar created this revision. Herald added a subscriber: sanjoy. These functions never actually worked -- if you called them, you'd get a ptxas error when llvm tried to make a libcall to e.g. nexttowardf. This test only compiled because the calls were DCE'ed. Sadly my laziness in not checking th

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: test/Driver/cuda-bail-out.cu:31 +// CHECK-TWO-ARCHES-NOT: Error during compilation for sm_60 +// CHECK-TWO-ARCHES-NOT Error during host compilation Missing ':' after CHECK-TWO-ARCHES-NOT. You may want to include a compilati

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu added a comment. In https://reviews.llvm.org/D39502#917132, @tra wrote: > In https://reviews.llvm.org/D39502#917097, @steven_wu wrote: > > > Also, the reason I don't know how to craft a testcase is not because I have > > trouble with CUDA driver, but how to write a test to check when d

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu updated this revision to Diff 121795. steven_wu added a comment. Add testcase for CUDA driver https://reviews.llvm.org/D39502 Files: lib/Driver/Compilation.cpp test/Driver/cuda-bail-out.cu test/Driver/output-file-cleanup.c test/Driver/unix-conformance.c Index: test/Driver/uni

[PATCH] D39627: Fix vtable not receiving hidden visibility when using push(visibility)

2017-11-06 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added subscribers: cfe-commits, efriedma. efriedma added a comment. Adding cfe-commits. (In the future, please make sure to CC that list instead of llvm-commits for clang changes.) > I'm missing some background lingo here. What is the meaning of "a > declaration" and "a definition" he

[PATCH] D38680: [libunwind] Fix handling of DW_CFA_GNU_args_size

2017-11-06 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. In https://reviews.llvm.org/D38680#903203, @joerg wrote: > I've looked at this in some detail now. I'm not exactly sure yet why it is > broken. The patch seems quite wrong to me. DW_CFA_GNU_args_size should be > applied only when unwinding a call instruction and that regard

[PATCH] D39332: [clang-refactor] Introduce a new rename rule for qualified symbols

2017-11-06 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added inline comments. Comment at: lib/Tooling/Refactoring/Rename/RenamingAction.cpp:101 + std::string NewQualifiedName) { + return QualifiedRenameRule(std::move(OldQualifiedName), + std::move(NewQualifiedName));

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In https://reviews.llvm.org/D39502#917097, @steven_wu wrote: > Also, the reason I don't know how to craft a testcase is not because I have > trouble with CUDA driver, but how to write a test to check when did the > driver > bailed out. Let me know if you have any suggestio

[PATCH] D39676: [clangd] Add rename support.

2017-11-06 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Side-comment: will want to let the user know about the fact that global symbols aren't really renamed yet until global rename works? https://reviews.llvm.org/D39676 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D39691: [analyzer] Model correct dispatch_once() 'done' value in BodyFarm

2017-11-06 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a comment. Yeah, I'm not a fan of this style of testing for path diagnostics, either. https://reviews.llvm.org/D39691 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu updated this revision to Diff 121779. steven_wu added a comment. This seems to be the cleanest solution I can find for CUDA without touching the job configuration for CUDA. My proposed fix is to bail out of the jobs that are parts of CUDA offload if some command failed before that. Now i

[PATCH] D38680: [libunwind] Fix handling of DW_CFA_GNU_args_size

2017-11-06 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In https://reviews.llvm.org/D38680#903203, @joerg wrote: > I've looked at this in some detail now. I'm not exactly sure yet why it is > broken. The patch seems quite wrong to me. DW_CFA_GNU_args_size should be > applied only when unwinding a call instruction and that r

[PATCH] D39584: [analyzer] [NFC] another very minor ExprEngineC refactoring

2017-11-06 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added inline comments. Comment at: lib/StaticAnalyzer/Core/ExprEngineC.cpp:26 +/// results in an ElementRegion. +static void conjureOffsetSymbolOnLocation( +SVal &Symbol, SVal Other, Expr* Expression, SValBuilder &svalBuilder, I think it would be mo

[PATCH] D39509: Vary Windows toolchain selection by -fuse-ld

2017-11-06 Thread Dave Lee via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL317511: Vary Windows toolchain selection by -fuse-ld (authored by kastiglione). Repository: rL LLVM https://reviews.llvm.org/D39509 Files: cfe/trunk/lib/Driver/Driver.cpp cfe/trunk/test/Driver/Inp

r317511 - Vary Windows toolchain selection by -fuse-ld

2017-11-06 Thread Dave Lee via cfe-commits
Author: kastiglione Date: Mon Nov 6 13:18:05 2017 New Revision: 317511 URL: http://llvm.org/viewvc/llvm-project?rev=317511&view=rev Log: Vary Windows toolchain selection by -fuse-ld Summary: This change allows binutils to be used for linking with MSVC. Currently, when using an MSVC target and `-

[PATCH] D39611: [CodeGen] make cbrt and fma constant (never set errno); document complex calls as always constant

2017-11-06 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Currently, the clang driver supports three platforms which have errno-setting libc implementations: GNU/Linux (with glibc), Solaris, and Windows (with Visual Studio CRT). (BSD-based systems, including OS X, never set errno in libm, so they aren't relevant here.) As l

[PATCH] D39478: [clang-format] Handle leading comments in using declaration

2017-11-06 Thread Igor Sugak via Phabricator via cfe-commits
sugak added a comment. @djasper: ping :) https://reviews.llvm.org/D39478 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39620: [analyzer] [NFC] Remove unused typedef

2017-11-06 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. https://reviews.llvm.org/D39620 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mai

[PATCH] D39694: [VerifyDiagnosticConsumer] support -verify=PREFIX

2017-11-06 Thread Joel E. Denny via Phabricator via cfe-commits
jdenny created this revision. This mimic's FileCheck's --check-prefix option. The default PREFIX is "expected". That is, "-verify" is equivalent to "-verify=expected". The goal is to permit exercising a single test suite source file with different compiler options producing different sets of di

[PATCH] D39631: [X86] Fix the spelling of 3dnow and 3dnowa in isValidFeatureName

2017-11-06 Thread Martin Storsjö via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL317504: [X86] Add 3dnow and 3dnowa to the list of valid target features (authored by mstorsjo). Changed prior to commit: https://reviews.llvm.org/D39631?vs=121623&id=121766#toc Repository: rL LLVM h

r317504 - [X86] Add 3dnow and 3dnowa to the list of valid target features

2017-11-06 Thread Martin Storsjo via cfe-commits
Author: mstorsjo Date: Mon Nov 6 12:33:13 2017 New Revision: 317504 URL: http://llvm.org/viewvc/llvm-project?rev=317504&view=rev Log: [X86] Add 3dnow and 3dnowa to the list of valid target features These were missed in SVN r316783, which broke compiling mingw-w64 CRT. Differential Revision: htt

[PATCH] D39641: [CodeGen] make cbrt and fma constant (never set errno)

2017-11-06 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM, but wait a couple days before you commit to see if anyone else wants to comment. https://reviews.llvm.org/D39641 ___ cfe-commits maili

[PATCH] D33722: [clang-tidy] Add checker for undelegated copy of base classes

2017-11-06 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D33722#916540, @xazax.hun wrote: > Also, bugprone might be a better module to put this? I don't have strong opinions on misc vs bugprone (they're both effectively catch-alls for tidy checks, as best I can tell). https://reviews.llvm.

[PATCH] D39691: [analyzer] Model correct dispatch_once() 'done' value in BodyFarm

2017-11-06 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov accepted this revision. george.karpenkov added a comment. This revision is now accepted and ready to land. Looks good to me. I really don't think the test format chosen in `unix-fns.c` is a good idea, as it is very large, auto-generated, and tightly coupled to chosen formatting.

[PATCH] D38737: [X86] test/testn intrinsics lowering to IR. clang side

2017-11-06 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: lib/Headers/avx512vlbwintrin.h:2801 + return _mm_mask_cmp_epi8_mask (__U, _mm_and_si128 (__A, __B), + _mm_setzero_hi(), 4); } craig.topper wrote: > Sorry I didn't catch this before,

[PATCH] D38737: [X86] test/testn intrinsics lowering to IR. clang side

2017-11-06 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added inline comments. Comment at: lib/Headers/avx512vlbwintrin.h:2801 + return _mm_mask_cmp_epi8_mask (__U, _mm_and_si128 (__A, __B), + _mm_setzero_hi(), 4); } Sorry I didn't catch this before, but can you use _MM_C

[PATCH] D39505: [OpenMP] Show error if VLAs are not supported

2017-11-06 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: include/clang/Basic/TargetInfo.h:944 + /// \brief Whether target supports variable-length arrays. + bool isVLASupported() const { return VLASupported; } + ABataev wrote: > Hahnfeld wrote: > > rjmccall wrote: > > > Hahn

[PATCH] D39631: [X86] Fix the spelling of 3dnow and 3dnowa in isValidFeatureName

2017-11-06 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D39631 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D39676: [clangd] Add rename support.

2017-11-06 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Impl LG apart from error handling :-) Comment at: clangd/ClangdServer.cpp:338 +std::vector +ClangdServer::Rename(PathRef File, Position Pos, llvm::StringRef NewName) { I think you can split out a private method: Expected> Clan

[PATCH] D39430: [clangd] formatting: don't ignore style

2017-11-06 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Thanks! Mostly just comments around the IO (which I'm still learning about myself). Otherwise this LG. I'm afraid you're going to run into some merge conflicts with https://reviews.llvm.org/rL317486 - I think/hope not too bad, though. Comment at: c

[PATCH] D39438: [analyzer] Diagnose stack leaks via block captures

2017-11-06 Thread Alexander Shaposhnikov via Phabricator via cfe-commits
alexshap added a comment. ping @NoQ Repository: rL LLVM https://reviews.llvm.org/D39438 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D39419: Fix crash when parsing objective-c++ containing invalid lambda

2017-11-06 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL317493: [Parser] Fix TryParseLambdaIntroducer() error handling (authored by jkorous). Changed prior to commit: https://reviews.llvm.org/D39419?vs=121448&id=121748#toc Repository: rL LLVM https://rev

r317493 - [Parser] Fix TryParseLambdaIntroducer() error handling

2017-11-06 Thread Jan Korous via cfe-commits
Author: jkorous Date: Mon Nov 6 09:42:17 2017 New Revision: 317493 URL: http://llvm.org/viewvc/llvm-project?rev=317493&view=rev Log: [Parser] Fix TryParseLambdaIntroducer() error handling rdar://35066196 Differential Revision: https://reviews.llvm.org/D39419 Added: cfe/trunk/test/Parser/ob

[PATCH] D33722: [clang-tidy] Add checker for undelegated copy of base classes

2017-11-06 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D33722#916539, @xazax.hun wrote: > In https://reviews.llvm.org/D33722#915440, @aaron.ballman wrote: > > > I disagree. We should not be changing code to be incorrect, requiring the > > user to find that next incorrectness only through an

[PATCH] D39332: [clang-refactor] Introduce a new rename rule for qualified symbols

2017-11-06 Thread Sam McCall via Phabricator via cfe-commits
sammccall added inline comments. Comment at: lib/Tooling/Refactoring/Rename/RenamingAction.cpp:101 + std::string NewQualifiedName) { + return QualifiedRenameRule(std::move(OldQualifiedName), + std::move(NewQualifiedName));

[PATCH] D39462: [Sema] Implement -Wmaybe-tautological-constant-compare for when the tautologicalness is data model dependent

2017-11-06 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri updated this revision to Diff 121743. lebedev.ri edited the summary of this revision. lebedev.ri added a comment. In https://reviews.llvm.org/D39462#912011, @rjmccall wrote: > The actual choice of integer type is not stable across targets any more than > the size is. In practice, peo

[PATCH] D39502: [Driver] Make clang/cc conforms to UNIX standard

2017-11-06 Thread Steven Wu via Phabricator via cfe-commits
steven_wu added a comment. In https://reviews.llvm.org/D39502#916409, @jlebar wrote: > > Note the host clang side has the inputs "test.cu" and "test-c3378c.fatbin". > > Which means if the device side compilation failed, the host side will not > > compile because InputOk will return false in thi

r317489 - [CodeGen] match new fast-math-flag method: isFast()

2017-11-06 Thread Sanjay Patel via cfe-commits
Author: spatel Date: Mon Nov 6 08:27:36 2017 New Revision: 317489 URL: http://llvm.org/viewvc/llvm-project?rev=317489&view=rev Log: [CodeGen] match new fast-math-flag method: isFast() This corresponds to LLVM commiti r317488: If that commit is reverted, this commit will also need to be reverted

[PATCH] D38688: [clang-tidy] Misc redundant expressions checker updated for macros

2017-11-06 Thread Barancsuk Lilla via Phabricator via cfe-commits
barancsuk updated this revision to Diff 121740. barancsuk marked 2 inline comments as done. barancsuk added a comment. Address review comments: fix missing full stops at the end of comments https://reviews.llvm.org/D38688 Files: clang-tidy/misc/RedundantExpressionCheck.cpp clang-tidy/misc/R

[clang-tools-extra] r317487 - [clangd] Squash namespace warning

2017-11-06 Thread Sam McCall via cfe-commits
Author: sammccall Date: Mon Nov 6 07:50:35 2017 New Revision: 317487 URL: http://llvm.org/viewvc/llvm-project?rev=317487&view=rev Log: [clangd] Squash namespace warning Modified: clang-tools-extra/trunk/clangd/JSONExpr.cpp Modified: clang-tools-extra/trunk/clangd/JSONExpr.cpp URL: http://l

[PATCH] D39121: [clang-tidy] Misplaced Operator in Strlen in Alloc

2017-11-06 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: test/clang-tidy/bugprone-misplaced-operator-in-strlen-in-alloc.c:1 +// RUN: %check_clang_tidy %s bugprone-misplaced-operator-in-strlen-in-allo

[PATCH] D30691: [analyzer] Support for naive cross translational unit analysis

2017-11-06 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun updated this revision to Diff 121700. xazax.hun added a comment. - Rebased on ToT https://reviews.llvm.org/D30691 Files: include/clang/StaticAnalyzer/Core/AnalyzerOptions.h include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h lib/StaticAnalyzer/Core/AnalyzerOptions.cpp

[PATCH] D39505: [OpenMP] Show error if VLAs are not supported

2017-11-06 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: include/clang/Basic/TargetInfo.h:944 + /// \brief Whether target supports variable-length arrays. + bool isVLASupported() const { return VLASupported; } + Hahnfeld wrote: > rjmccall wrote: > > Hahnfeld wrote: > > > rjm

[PATCH] D39505: [OpenMP] Show error if VLAs are not supported

2017-11-06 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld marked an inline comment as done. Hahnfeld added a subscriber: gtbercea. Hahnfeld added inline comments. Comment at: include/clang/Basic/TargetInfo.h:944 + /// \brief Whether target supports variable-length arrays. + bool isVLASupported() const { return VLASupported; }

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-06 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In https://reviews.llvm.org/D35109#916617, @NoQ wrote: > A breakthrough with credit going to Devin: Note that whenever we're not > dealing with `>`/`<`/`<=`/`>=` (but only with additive ops and `==` and `!=`, > and we have everything of the same type) we can rearrange

[PATCH] D39121: [clang-tidy] Misplaced Operator in Strlen in Alloc

2017-11-06 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware marked 12 inline comments as done. baloghadamsoftware added inline comments. Comment at: test/clang-tidy/bugprone-misplaced-operator-in-strlen-in-alloc.c:1 +// RUN: %check_clang_tidy %s bugprone-misplaced-operator-in-strlen-in-alloc %t + aaron.

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-06 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. In https://reviews.llvm.org/D35109#916648, @NoQ wrote: > > How to find the N if we only use == or !=? > > Hence the difference between `==` and `is-the-same-symbol-as`. We can find > `N` by looking at the symbol. Sorry, if I misunderstand something, but if I

[PATCH] D36471: [StaticAnalyzer] Try to calculate arithmetic result when operand has a range of possible values

2017-11-06 Thread Daniel Marjamäki via Phabricator via cfe-commits
danielmarjamaki updated this revision to Diff 121726. danielmarjamaki added a comment. Herald added a subscriber: szepet. I have updated the patch so it uses evalBinOpNN. This seems to work properly. I have a number of TODOs in the test cases that should be fixed. Truncations are not handled pro

[PATCH] D39682: [analyzer] Fix a crash on logical operators with vectors.

2017-11-06 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 121725. NoQ added a comment. Yep, right! https://reviews.llvm.org/D39682 Files: lib/StaticAnalyzer/Core/ExprEngineC.cpp test/Analysis/vector.c Index: test/Analysis/vector.c === --- /dev/null

[PATCH] D39682: [analyzer] Fix a crash on logical operators with vectors.

2017-11-06 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added a comment. This revision is now accepted and ready to land. LGTM! Comment at: lib/StaticAnalyzer/Core/ExprEngineC.cpp:633 +// modeled as short-circuit in Clang CFG but this is incorrect. +StmtNodeBuilder Bldr(Pred, Dst,

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-06 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > How to find the N if we only use == or !=? Hence the difference between `==` and `is-the-same-symbol-as`. We can find `N` by looking at the symbol. We'd lose track of cases where, say, `i` and `.end()` were compared to each other for `>`/`<` before. The question is about

[PATCH] D39682: [analyzer] Fix a crash on logical operators with vectors.

2017-11-06 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. We crash whenever we try to compute `x && y` or `x || y` where `x` and `y` are of vector type. For now we do not seem to properly model operations with vectors. In particular, operations `&&` and `||` on two values of type `int __attribute__((ext_vector_type(2)))` ar

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-06 Thread Balogh , Ádám via Phabricator via cfe-commits
baloghadamsoftware added a comment. Thank you for your comment! Unfortunately, the iterator checkers depend very much on the >/>=/=C.end(), I cannot imagine this to be solved just with ==/!=. How to find the N if we only use == or !=? Furthermore, later parts also add invalidation check where w

[PATCH] D39587: [clang-format] Handle unary operator overload with arguments and specifiers

2017-11-06 Thread Daniel Jasper via Phabricator via cfe-commits
djasper added a comment. Submitted as r317473. Thank you! https://reviews.llvm.org/D39587 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r317473 - [clang-format] Handle unary operator overload with arguments and specifiers

2017-11-06 Thread Daniel Jasper via cfe-commits
Author: djasper Date: Mon Nov 6 04:11:51 2017 New Revision: 317473 URL: http://llvm.org/viewvc/llvm-project?rev=317473&view=rev Log: [clang-format] Handle unary operator overload with arguments and specifiers Before: int operator++(int)noexcept; After: int operator++(int) noexcept; Patch b

[PATCH] D38737: [X86] test/testn intrinsics lowering to IR. clang side

2017-11-06 Thread Uriel Korach via Phabricator via cfe-commits
uriel.k updated this revision to Diff 121716. https://reviews.llvm.org/D38737 Files: include/clang/Basic/BuiltinsX86.def lib/Headers/avx512bwintrin.h lib/Headers/avx512fintrin.h lib/Headers/avx512vlbwintrin.h lib/Headers/avx512vlintrin.h test/CodeGen/avx512bw-builtins.c test/CodeGen

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-06 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. A breakthrough with credit going to Devin: Note that whenever we're not dealing with `>`/`<`/`<=`/`>=` (but only with additive ops and `==` and `!=`, and we have everything of the same type) we can rearrange regardless of constraints, simply because Z/nZ is an abelian group

[PATCH] D39679: [C++11] Fix warning when dropping cv-qualifiers when assigning to a reference with a braced initializer list

2017-11-06 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 121712. https://reviews.llvm.org/D39679 Files: lib/Sema/SemaInit.cpp test/SemaCXX/references.cpp Index: test/SemaCXX/references.cpp === --- test/SemaCXX/references.cpp +++ test/SemaCXX/r

[PATCH] D39679: [C++11] Fix warning when dropping cv-qualifiers when assigning to a reference with a braced initializer list

2017-11-06 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete created this revision. Rakete added a project: clang. This fixes PR34912 :) https://reviews.llvm.org/D39679 Files: lib/Sema/SemaInit.cpp test/SemaCXX/references.cpp Index: test/SemaCXX/references.cpp

[PATCH] D39603: [clang-tidy] Support relative paths in run-clang-tidy.py

2017-11-06 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL317468: [clang-tidy] Support relative paths in run-clang-tidy.py (authored by xazax). Changed prior to commit: https://reviews.llvm.org/D39603?vs=121498&id=121705#toc Repository: rL LLVM https://rev

[clang-tools-extra] r317468 - [clang-tidy] Support relative paths in run-clang-tidy.py

2017-11-06 Thread Gabor Horvath via cfe-commits
Author: xazax Date: Mon Nov 6 02:36:02 2017 New Revision: 317468 URL: http://llvm.org/viewvc/llvm-project?rev=317468&view=rev Log: [clang-tidy] Support relative paths in run-clang-tidy.py Unfortunately, these python scripts are not tested currently. I did the testing manually on LLVM by editing

[PATCH] D39675: [clang-refactor] Use ClangTool more explicitly by making refaroing actions AST frontend actions.

2017-11-06 Thread Haojian Wu via Phabricator via cfe-commits
hokein accepted this revision. hokein added a comment. This revision is now accepted and ready to land. The code looks good to me. Comment at: tools/clang-refactor/ClangRefactor.cpp:317 RefactoringActionCommandLineOptions Options; + // Whether the selection is suppoted by a

[PATCH] D38737: [X86] test/testn intrinsics lowering to IR. clang side

2017-11-06 Thread Uriel Korach via Phabricator via cfe-commits
uriel.k updated this revision to Diff 121699. uriel.k marked an inline comment as done. https://reviews.llvm.org/D38737 Files: include/clang/Basic/BuiltinsX86.def lib/Headers/avx512bwintrin.h lib/Headers/avx512fintrin.h lib/Headers/avx512vlbwintrin.h lib/Headers/avx512vlintrin.h test/

[PATCH] D33722: [clang-tidy] Add checker for undelegated copy of base classes

2017-11-06 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Also, bugprone might be a better module to put this? https://reviews.llvm.org/D33722 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   >