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

2016-11-30 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld added inline comments. Comment at: lib/Driver/ToolChain.cpp:721-724 + +const char *ToolChain::getDefaultLinker() const { + return CLANG_DEFAULT_LINKER; +} sfertile wrote: > Hahnfeld wrote: > > I think this could go into the header > The CLANG_DEFAULT_LI

[PATCH] D26691: [analyzer] Run clang-format and fix style

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. I am not a big fan of loosing svn blame only to fix formatting, but since you are modifying this code anyway, it's fine by me. Artem and Devin, what is your opinion on this? Comment at: lib/StaticAnalyzer/Core/RangeConstraintManager.cpp:459 // No

[PATCH] D26694: [analyzer] Drop explicit mention of range constraint solver

2016-11-30 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Approve! And probably `-analyzer-store=region` is worth dropping as well eventually. https://reviews.llvm.org/D26694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

[PATCH] D26694: [analyzer] Drop explicit mention of range constraint solver

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna accepted this revision. zaks.anna added a comment. This revision is now accepted and ready to land. Awesome!!! Thanks for the cleanup! https://reviews.llvm.org/D26694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llv

[PATCH] D26762: Add a method to obtain this SVal of a method that created given StackFrameCtx

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. I see. You are handling more types of calls with this API! However, Similarly to the comment in the related patch, I think we should reuse the logic from CallEvent. https://reviews.llvm.org/D26762 ___ cfe-commits mailing

[PATCH] D26837: [analyzer] Litter the SVal/SymExpr/MemRegion class hierarchy with asserts.

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added inline comments. Comment at: include/clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h:737 /// either a real region, a NULL pointer, etc. It essentially is used to /// map the concept of symbolic values into the domain of regions. Symbolic /// regions do

r288313 - Teach ConstantBuilder how to emit a reference to the current position

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 23:33:30 2016 New Revision: 288313 URL: http://llvm.org/viewvc/llvm-project?rev=288313&view=rev Log: Teach ConstantBuilder how to emit a reference to the current position that will be filled in when the initializer is set. Modified: cfe/trunk/lib/CodeGen/Cons

[PATCH] D26546: [PPC] Add vec_insert4b/vec_extract4b to altivec.h

2016-11-30 Thread Sean Fertile via Phabricator via cfe-commits
sfertile updated this revision to Diff 79860. sfertile marked an inline comment as done. sfertile added a comment. Changed all variable names to start with capitals, added description strings to the assertions, changed uses of '12' to MaxIndex and initialized the arrays in their definition. Re

[PATCH] D27251: [PPC] some bugs mainly about sign problem fixed in altivec.h

2016-11-30 Thread ZiXuan Wu via Phabricator via cfe-commits
Zeson updated this revision to Diff 79856. Zeson added a comment. Make vec_xst_be and vec_xl_be test cases put together seperately in `builtins-ppc-vsx.c` Move up macro `__VSX__` to make all vec_xst_be functions included https://reviews.llvm.org/D27251 Files: lib/Headers/altivec.h test/Cod

r288305 - P0012R1: add Itanium ABI support for throwing non-noexcept function pointers and catching as noexcept.

2016-11-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed Nov 30 21:32:42 2016 New Revision: 288305 URL: http://llvm.org/viewvc/llvm-project?rev=288305&view=rev Log: P0012R1: add Itanium ABI support for throwing non-noexcept function pointers and catching as noexcept. Added: cfe/trunk/test/CodeGenCXX/rtti-qualfn.cpp Modifie

r288304 - Revert r285664, cxx-abi-dev chose to go in a different direction for the ABI here.

2016-11-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed Nov 30 21:04:07 2016 New Revision: 288304 URL: http://llvm.org/viewvc/llvm-project?rev=288304&view=rev Log: Revert r285664, cxx-abi-dev chose to go in a different direction for the ABI here. Removed: cfe/trunk/test/CodeGenCXX/rtti-qualfn.cpp Modified: cfe/trunk/i

[PATCH] D26837: [analyzer] Litter the SVal/SymExpr/MemRegion class hierarchy with asserts.

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added inline comments. Comment at: include/clang/StaticAnalyzer/Core/PathSensitive/BasicValueFactory.h:23 #include "clang/StaticAnalyzer/Core/PathSensitive/StoreRef.h" +#include "clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h" It's a bit sad to

r288301 - PR31081: ignore exception specifications when deducing function template

2016-11-30 Thread Richard Smith via cfe-commits
Author: rsmith Date: Wed Nov 30 20:11:49 2016 New Revision: 288301 URL: http://llvm.org/viewvc/llvm-project?rev=288301&view=rev Log: PR31081: ignore exception specifications when deducing function template arguments from a declaration; despite what the standard says, this form of deduction should

Re: Crash in MallocChecker

2016-11-30 Thread Devin Coughlin via cfe-commits
+ Artem and Daniel, Thanks for the patch! This fix seems reasonable to me, although it would good to add the reproducer as test case! (tests/Analysis/malloc.cpp would be a fine place for it). Devin Index: lib/StaticAnalyzer/Checkers/MallocChecker.cpp ===

[PATCH] D27226: [MS ABI] Implement more of the Itanium mangling rules

2016-11-30 Thread David Majnemer via Phabricator via cfe-commits
majnemer updated this revision to Diff 79848. majnemer marked an inline comment as done. majnemer added a comment. - Address review comments https://reviews.llvm.org/D27226 Files: lib/AST/MicrosoftMangle.cpp test/CodeGenCXX/mangle-ms-cxx11.cpp Index: test/CodeGenCXX/mangle-ms-cxx11.cpp ===

[PATCH] D22862: [analyzer] Fix for PR15623: eliminate unwanted ProgramState checker data propagation.

2016-11-30 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added a comment. Overall, this looks good to me. Thanks for tackling this! One request, though. Could you move the tests into already existing test files? We're trying to avoid test files that only test a single issue. This makes it easier for people

[PATCH] D27214: [ObjC] Encode type arguments in property information string constants

2016-11-30 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Do you know whether this patch would have any effect on the objective-c runtime? I suspect it wouldn't cause the runtime to crash, but I don't know how the runtime uses the encoded type information. Other than that, the changes made in this patch look good to me. Rep

Re: r288269 - Finish adopting ConstantInitBuilder in CGObjCGNU. NFC.

2016-11-30 Thread John McCall via cfe-commits
> On Nov 30, 2016, at 3:27 PM, Reid Kleckner wrote: > > So, I always push for leading upper case variable names. Over time we've > gotten to the point where the majority of the code that I read in clang > follows this convention. You seem to be pushing the other direction. What do > you think

r288297 - [TableGen] Minor clean-ups. NFC.

2016-11-30 Thread George Burgess IV via cfe-commits
Author: gbiv Date: Wed Nov 30 18:13:18 2016 New Revision: 288297 URL: http://llvm.org/viewvc/llvm-project?rev=288297&view=rev Log: [TableGen] Minor clean-ups. NFC. Primarily: try to use DenseSet instead of std::set, and use pretty range algos where we can. Small sizes were arbitrarily chosen. M

[PATCH] D27226: [MS ABI] Implement more of the Itanium mangling rules

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: lib/AST/MicrosoftMangle.cpp:838 + if (Func) +LambdaId = Func->getNumParams() - Parm->getFunctionScopeIndex(); + else if (LambdaManglingNumber) Isn't this no good if I have two lambdas in one def

[PATCH] D25216: Improve error message when referencing a non-tag type with a tag

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:4556-4558 + "%0 is a %select{non-tag type|typedef|type alias|template|type alias " + "template|template template argument}1 that cannot be referenced with a " + "%select{struct|interface|union|cl

Crash in MallocChecker

2016-11-30 Thread Abramo Bagnara via cfe-commits
Please consider to review and apply the attached patch. This is how to reproduce the bug: abramo@tester:~$ cat bug.cpp void f(int a, int b) { new char[a * b]; } abramo@tester:~$ ~/llvm-build/bin/clang -cc1 -analyze -analyzer-checker=cplusplus.NewDeleteLeaks bug.cpp clang: /home/abramo/llvm/to

[PATCH] D27226: [MS ABI] Implement more of the Itanium mangling rules

2016-11-30 Thread David Majnemer via Phabricator via cfe-commits
majnemer updated this revision to Diff 79837. majnemer added a comment. - Address review comments https://reviews.llvm.org/D27226 Files: lib/AST/MicrosoftMangle.cpp test/CodeGenCXX/mangle-ms-cxx11.cpp Index: test/CodeGenCXX/mangle-ms-cxx11.cpp ==

r288295 - Clean up CGObjCMac's APIs for deriving class references. NFC.

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 17:54:50 2016 New Revision: 288295 URL: http://llvm.org/viewvc/llvm-project?rev=288295&view=rev Log: Clean up CGObjCMac's APIs for deriving class references. NFC. Modified: cfe/trunk/lib/CodeGen/CGObjCGNU.cpp cfe/trunk/lib/CodeGen/CGObjCMac.cpp cfe/t

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Justin Lebar via Phabricator via cfe-commits
jlebar updated this revision to Diff 79835. jlebar marked an inline comment as done. jlebar added a comment. Note that the relevant functions may come from . https://reviews.llvm.org/D27284 Files: clang-tools-extra/clang-tidy/performance/CMakeLists.txt clang-tools-extra/clang-tidy/performan

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/performance-type-promotion-in-math-fn.rst:6 + +Finds calls to math.h functions with implicit float to double promotions. + jlebar wrote: > Eugene.Zelenko wrote: > > Please

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Justin Lebar via Phabricator via cfe-commits
jlebar added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/performance-type-promotion-in-math-fn.rst:6 + +Finds calls to math.h functions with implicit float to double promotions. + Eugene.Zelenko wrote: > Please enclose math.h, float and

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Justin Lebar via Phabricator via cfe-commits
jlebar updated this revision to Diff 79829. jlebar marked 3 inline comments as done. jlebar added a comment. Formatting fixes in documentation. https://reviews.llvm.org/D27284 Files: clang-tools-extra/clang-tidy/performance/CMakeLists.txt clang-tools-extra/clang-tidy/performance/Performance

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please mention this check in docs/ReleaseNotes.rst (in alphabetical order). Comment at: clang-tools-extra/docs/clang-tidy/checks/performance-type-promotion-in-math-fn.rst:6 + +Finds calls to math.h functions with implicit float to double promoti

r288289 - Introduce a type-safe enum for ForDefinition.

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 17:25:13 2016 New Revision: 288289 URL: http://llvm.org/viewvc/llvm-project?rev=288289&view=rev Log: Introduce a type-safe enum for ForDefinition. Modified: cfe/trunk/lib/CodeGen/CGCXX.cpp cfe/trunk/lib/CodeGen/CodeGenModule.cpp cfe/trunk/lib/CodeGen/

[PATCH] D27066: Fix crash with unsupported architectures in Linux/Gnu target triples.

2016-11-30 Thread Joerg Sonnenberger via Phabricator via cfe-commits
joerg accepted this revision. joerg added a reviewer: joerg. joerg added a comment. LGTM with a small cleanup. Comment at: lib/Driver/Tools.cpp:10018 + const char *LDMOption = getLDMOption(ToolChain.getTriple(), Args); + if (!LDMOption) { +D.Diag(diag::err_target_unknown_

Re: r288269 - Finish adopting ConstantInitBuilder in CGObjCGNU. NFC.

2016-11-30 Thread Reid Kleckner via cfe-commits
So, I always push for leading upper case variable names. Over time we've gotten to the point where the majority of the code that I read in clang follows this convention. You seem to be pushing the other direction. What do you think we should be doing? I'll admit the LLVM naming conventions are dum

r288287 - Fix some layering violations where CGObjCMac's NSString emission was

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 17:15:55 2016 New Revision: 288287 URL: http://llvm.org/viewvc/llvm-project?rev=288287&view=rev Log: Fix some layering violations where CGObjCMac's NSString emission was performed at the CodeGenModule level. Would be NFC except we now also use a different uniquin

[PATCH] D27066: Fix crash with unsupported architectures in Linux/Gnu target triples.

2016-11-30 Thread Eric Christopher via Phabricator via cfe-commits
echristo accepted this revision. echristo added a comment. This revision is now accepted and ready to land. LGTM. Thanks! https://reviews.llvm.org/D27066 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/

[PATCH] D27284: [ClangTidy] Add new performance-type-promotion-in-math-fn check.

2016-11-30 Thread Justin Lebar via Phabricator via cfe-commits
jlebar created this revision. jlebar added a subscriber: cfe-commits. Herald added a subscriber: mgorny. This checks for calls to double-precision math.h with single-precision arguments. For example, it suggests replacing ::sin(0.f) with ::sinf(0.f). https://reviews.llvm.org/D27284 Files: cl

Request for review/commit

2016-11-30 Thread Eric van Gyzen via cfe-commits
I recently posted a few libc++ patches in Phabricator. I'm fairly new here, so I would be grateful if someone would review and eventually commit them. [libc++] Add validation to Stage 2 of num_get https://reviews.llvm.org/D26920 [libc++] Do not hard-code locale data in unit tests: get it from th

[PATCH] D27180: Testbed and skeleton of a new expression parser

2016-11-30 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Looks good. Apart from some nitpicks, I'm happy with this. This isn't really my area so it'd be good to get an explicit lgtm from one of the reviewers. Comment at: tools/clang-import-test/CMakeLists.txt:7 + clang-import-test.cpp + ) + @b

[PATCH] D25216: Improve error message when referencing a non-tag type with a tag

2016-11-30 Thread Richard Smith via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/Basic/DiagnosticSemaKinds.td:4556-4558 + "%0 is a %select{non-tag type|typedef|type alias|template|type alias " + "template|template template argument}1 that cannot be referenced with a " + "%select{struct|interface|union

[PATCH] D25475: [analyzer] Add a new SVal to support pointer-to-member operations.

2016-11-30 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin added a comment. PointerToMemberData looks like it is on the right track! One thing that is still missing is using the base specifier list to figure out the correct subobject field to read and write from. This is important when there is non-virtual multiple inheritance, as there will

[PATCH] D27180: Testbed and skeleton of a new expression parser

2016-11-30 Thread Sean Callanan via Phabricator via cfe-commits
spyffe updated this revision to Diff 79807. spyffe marked an inline comment as done. spyffe added a comment. Updated to reflect Vedant's comments. Also ensured 100% test coverage, by removing handling for errors that will never happen and by adding a few new tests. Repository: rL LLVM http

[PATCH] D25216: Improve error message when referencing a non-tag type with a tag

2016-11-30 Thread Bob Haarman via Phabricator via cfe-commits
inglorion added a comment. I like it. I'll give others a little time to respond, but if no objections are raised and nobody else accepts first, I'll accept it tomorrow. https://reviews.llvm.org/D25216 ___ cfe-commits mailing list cfe-commits@lists.

[PATCH] D25581: Implement __builtin_alloca_with_align for GCC compatibility

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk abandoned this revision. rnk added a subscriber: majnemer. rnk added a comment. @majnemer did this in https://reviews.llvm.org/rL285544 https://reviews.llvm.org/D25581 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org

[PATCH] D25216: Improve error message when referencing a non-tag type with a tag

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk updated this revision to Diff 79805. rnk added a comment. - rebase https://reviews.llvm.org/D25216 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaDecl.cpp lib/Sema/SemaTemplate.cpp lib/Sema/TreeTransform.h test/CXX/basic/basic.lookup/basic.lookup.elab/p2.cpp test

[PATCH] D25216: Improve error message when referencing a non-tag type with a tag

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Ping, found this in my tree. Maybe you weren't that excited about the wording change. https://reviews.llvm.org/D25216 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[PATCH] D27279: Store decls in prototypes on the declarator instead of in the AST

2016-11-30 Thread Reid Kleckner via Phabricator via cfe-commits
rnk created this revision. rnk added a reviewer: rsmith. rnk added subscribers: cfe-commits, jmolloy. This saves two pointers (!) from FunctionDecl that were being used for some rare and questionable C-only functionality. The DeclsInPrototypeScope ArrayRef was added in r151712 in order to parse t

r288272 - Prospective MSVC workaround.

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 14:46:55 2016 New Revision: 288272 URL: http://llvm.org/viewvc/llvm-project?rev=288272&view=rev Log: Prospective MSVC workaround. Modified: cfe/trunk/lib/CodeGen/CGObjCGNU.cpp Modified: cfe/trunk/lib/CodeGen/CGObjCGNU.cpp URL: http://llvm.org/viewvc/llvm-pr

[PATCH] D14274: Add alloc_size attribute to clang

2016-11-30 Thread George Burgess IV via Phabricator via cfe-commits
george.burgess.iv added a comment. Ping https://reviews.llvm.org/D14274 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r288269 - Finish adopting ConstantInitBuilder in CGObjCGNU. NFC.

2016-11-30 Thread John McCall via cfe-commits
Author: rjmccall Date: Wed Nov 30 14:19:46 2016 New Revision: 288269 URL: http://llvm.org/viewvc/llvm-project?rev=288269&view=rev Log: Finish adopting ConstantInitBuilder in CGObjCGNU. NFC. Modified: cfe/trunk/lib/CodeGen/CGObjCGNU.cpp cfe/trunk/lib/CodeGen/ConstantBuilder.h Modified: c

[PATCH] D27254: Protect optional test under libcpp-no-exceptions

2016-11-30 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists accepted this revision. mclow.lists added a comment. This revision is now accepted and ready to land. Looks good now - thanks. https://reviews.llvm.org/D27254 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/

[PATCH] D26454: Implement no_sanitize_address for global vars

2016-11-30 Thread Douglas Katzman via Phabricator via cfe-commits
dougk added a comment. Suppression of sanitizing is necessary if the variable is magically a memory-mapped device I/O address. The linker can arrange for this to be the case using fancy scripts, or even just as simple as a section attribute that requires that you take up exactly a certain numbe

[PATCH] D27277: Make _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR user-settable

2016-11-30 Thread Dimitry Andric via Phabricator via cfe-commits
dim created this revision. dim added reviewers: EricWF, emaste, mclow.lists, theraven. dim added a subscriber: cfe-commits. In https://reviews.llvm.org/rL275749 the old _LIBCPP_TRIVIAL_PAIR_COPY_CTOR define was replaced by _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR, which is also auto-

r288267 - [Sema] Teach -Wcast-align to look at the aligned attribute of the

2016-11-30 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Wed Nov 30 13:42:03 2016 New Revision: 288267 URL: http://llvm.org/viewvc/llvm-project?rev=288267&view=rev Log: [Sema] Teach -Wcast-align to look at the aligned attribute of the declared variables. Teach Sema to check the aligned attribute attached to variable declarations

[PATCH] D21099: [Sema] Teach -Wcast-align to look at the aligned attribute of the declared variables

2016-11-30 Thread Akira Hatanaka via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL288267: [Sema] Teach -Wcast-align to look at the aligned attribute of the (authored by ahatanak). Changed prior to commit: https://reviews.llvm.org/D21099?vs=78594&id=79792#toc Repository: rL LLVM h

Re: [PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-11-30 Thread Richard Smith via cfe-commits
On 30 November 2016 at 11:08, Bruno Cardoso Lopes via Phabricator via cfe-commits wrote: > > I suspect the problem is instead that #import just doesn't work properly > with modules > > (specifically, either with local submodule visibility or with modules > that do not export *), > > because it do

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

2016-11-30 Thread Sean Fertile via Phabricator via cfe-commits
sfertile added inline comments. Comment at: lib/Driver/ToolChain.cpp:721-724 + +const char *ToolChain::getDefaultLinker() const { + return CLANG_DEFAULT_LINKER; +} Hahnfeld wrote: > I think this could go into the header The CLANG_DEFAULT_LINKER macro is getting

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

2016-11-30 Thread Mads Ravn via Phabricator via cfe-commits
madsravn updated this revision to Diff 79788. madsravn added a comment. Trimmed down the ast matcher a little. https://reviews.llvm.org/D27210 Files: clang-tidy/misc/CMakeLists.txt clang-tidy/misc/MiscTidyModule.cpp clang-tidy/misc/StringCompareCheck.cpp clang-tidy/misc/StringCompareChe

[PATCH] D26267: [Modules] Include builtins with #include instead of #import for ObjC

2016-11-30 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added inline comments. Comment at: lib/Frontend/FrontendActions.cpp:227 +IsBuiltin = true; + addHeaderInclude(H.NameAsWritten, Includes, LangOpts, Module->IsExternC, + IsBuiltin /*AlwaysInclude*/); rsmith wrote: > I don't

[PATCH] D26836: [analyzer] SValExplainer: Support ObjC ivars and __block variables.

2016-11-30 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ abandoned this revision. NoQ added a comment. Decided to go ahead and commit as r288260. https://reviews.llvm.org/D26836 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D26839: [analyzer] An attempt to fix pr19539 - crashes on temporaries life-extended via members

2016-11-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL288263: [analyzer] Construct temporary objects of correct types, destroy them properly. (authored by dergachev). Changed prior to commit: https://reviews.llvm.org/D26839?vs=79540&id=79783#toc Repositor

r288263 - [analyzer] Construct temporary objects of correct types, destroy them properly.

2016-11-30 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Nov 30 13:02:44 2016 New Revision: 288263 URL: http://llvm.org/viewvc/llvm-project?rev=288263&view=rev Log: [analyzer] Construct temporary objects of correct types, destroy them properly. When constructing a temporary object region, which represents the result of Mater

[PATCH] D27180: Testbed and skeleton of a new expression parser

2016-11-30 Thread Sean Callanan via Phabricator via cfe-commits
spyffe marked 3 inline comments as done. spyffe added a comment. Thank you for your review, Vedant! I will update the patch to reflect your comments in a moment. > I'm concerned about the amount of covered-but-untested code this patch > introduces. Since there are no CHECK lines, it's hard for

[PATCH] D26753: ASTImporter: improve support for C++ templates

2016-11-30 Thread Kareem Khazem via Phabricator via cfe-commits
khazem added a comment. Sorry for the late comment, but one of the tests that this introduces is breaking on my end: /usr/local/google/home/khazem/doc/llvm/tools/clang/test/ASTMerge/class-template-partial-spec.cpp:9:11: error: expected string not found in input // CHECK: /media/build/smrc

[PATCH] D27043: Remove assertion on analysis of rvalue vector

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. Thank you! The assert definitely needs to be relaxed. Would be great to add test cases that check if the analyzer models the vector types correctly, not just that we do not crash. (Not a blocker, but would be very useful.) https://reviews.llvm.org/D27043

[PATCH] D27090: Add LocationContext as a parameter to checkRegionChanges

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. Thank you for doing this!!! Artem, do you want to disallow the creation of successors from checkRegionChanges callback or can this go in as is? Anna. Comment at: lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp:240 - /// #checkRegionChanges wh

r288260 - [analyzer] SValExplainer: Support ObjC ivars and __block variables.

2016-11-30 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Nov 30 12:26:43 2016 New Revision: 288260 URL: http://llvm.org/viewvc/llvm-project?rev=288260&view=rev Log: [analyzer] SValExplainer: Support ObjC ivars and __block variables. Additionally, explain the difference between normal and heap-based symbolic regions. Added:

[PATCH] D27091: Add the way to extract SVals of arguments used in a call for a given StackFrameCtx

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. Artem just pointed out that I have "Smalls" instead of "SVals" in my first comment. https://reviews.llvm.org/D27091 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cf

[PATCH] D26657: [Sema] Respect DLL attributes more faithfully

2016-11-30 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: lib/Sema/SemaTemplate.cpp:7439 +void Sema::ActOnDLLAttr(ClassTemplateSpecializationDecl *Def, +InheritableAttr *Attr) { + // We reject explicit instantiations in class scope, so there should smeenai

[clang-tools-extra] r288258 - [clang-tidy] Make format style customizable

2016-11-30 Thread Jonas Devlieghere via cfe-commits
Author: jdevlieghere Date: Wed Nov 30 12:06:42 2016 New Revision: 288258 URL: http://llvm.org/viewvc/llvm-project?rev=288258&view=rev Log: [clang-tidy] Make format style customizable Summary: I came across an outstanding FIXME to make the format style customizable. Inspired by the include fixer,

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

2016-11-30 Thread Mads Ravn via cfe-commits
I think I got it. I will throw a new diff up within the hour. Thanks for the ideas :) On Wed, Nov 30, 2016 at 6:48 PM Malcolm Parsons wrote: > On 30 November 2016 at 17:18, Mads Ravn wrote: > > So remove the ifStmt from the third and fourth case? > > I was thinking all cases. > Can the first c

[PATCH] D26835: [analyzer] Minor fixes and improvements to debug.ExprInspection

2016-11-30 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL288257: [analyzer] Minor fixes and improvements to debug.ExprInspection (authored by dergachev). Changed prior to commit: https://reviews.llvm.org/D26835?vs=78468&id=79776#toc Repository: rL LLVM ht

r288257 - [analyzer] Minor fixes and improvements to debug.ExprInspection

2016-11-30 Thread Artem Dergachev via cfe-commits
Author: dergachev Date: Wed Nov 30 11:57:18 2016 New Revision: 288257 URL: http://llvm.org/viewvc/llvm-project?rev=288257&view=rev Log: [analyzer] Minor fixes and improvements to debug.ExprInspection - Fix the bug with transition handling in ExprInspectionChecker's checkDeadSymbols implementati

[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-11-30 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits. [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 4/4. Change a few allocators' size_type/differe

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

2016-11-30 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits. [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 3/4. test/std/containers/sequences/vector.bool/

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

2016-11-30 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits. [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 2/4. Use static_cast when storing size_t in int

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

2016-11-30 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits. [libcxx] [test] Fix MSVC x64 warning C4267 "conversion from 'size_t' to 'int' [or 'unsigned int'], possible loss of data", part 1/4. Replace "int n = str_.size();" with "int n

[PATCH] D27266: [libcxx] [test] Remove spurious semicolons.

2016-11-30 Thread Stephan T. Lavavej via Phabricator via cfe-commits
STL_MSFT created this revision. STL_MSFT added reviewers: EricWF, mclow.lists. STL_MSFT added a subscriber: cfe-commits. [libcxx] [test] Remove spurious semicolons. https://reviews.llvm.org/D27266 Files: test/std/containers/unord/unord.multimap/unord.multimap.cnstr/range_size_hash_equal_allo

[PATCH] D27091: Add the way to extract SVals of arguments used in a call for a given StackFrameCtx

2016-11-30 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. > Hmm, i'm thinking of just the opposite - refactor the CallEvent methods to > use the respective new ProgramState methods. > > This way we'd avoid touching the CallEvent allocator for a simple Environment > lookup, while still avoiding code duplication. I see what

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

2016-11-30 Thread Dehao Chen via Phabricator via cfe-commits
danielcdh updated this revision to Diff 79770. danielcdh added a comment. change the flag name to -fprofile-debug https://reviews.llvm.org/D25435 Files: include/clang/Driver/Options.td include/clang/Frontend/CodeGenOptions.def lib/CodeGen/BackendUtil.cpp lib/CodeGen/CGDebugInfo.cpp li

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

2016-11-30 Thread Malcolm Parsons via cfe-commits
On 30 November 2016 at 17:18, Mads Ravn wrote: > So remove the ifStmt from the third and fourth case? I was thinking all cases. Can the first case be restricted to casts to bool? If not, keep the cast to int case with an ifStmt and add a cast to bool case. Does it matter whether the cast is impli

Re: [RFC] Embedded bitcode and related upstream (Part II)

2016-11-30 Thread Alex L via cfe-commits
On 30 November 2016 at 15:46, Nico Weber via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Hi Steven, > > On Fri, Jun 3, 2016 at 2:36 PM, Steven Wu via cfe-commits < > cfe-commits@lists.llvm.org> wrote: > >> Hi everyone >> >> I am still in the process of upstreaming some improvements to the e

[PATCH] D27263: Address of bitfield in anonymous struct doesn't error.

2016-11-30 Thread Jacob Young via Phabricator via cfe-commits
jacobly created this revision. jacobly added a subscriber: cfe-commits. struct A { struct { int B : 1; } } int A::*addr_anon_bitfield() { return &A::B; } This code does not error, but instead returns a member pointer to a full int that starts at the beginning of the b

[PATCH] D27254: Protect optional test under libcpp-no-exceptions

2016-11-30 Thread Roger Ferrer Ibanez via Phabricator via cfe-commits
rogfer01 updated this revision to Diff 79765. rogfer01 added a comment. Protect the right set of tests. https://reviews.llvm.org/D27254 Files: test/std/experimental/optional/optional.specalg/swap.pass.cpp Index: test/std/experimental/optional/optional.specalg/swap.pass.cpp =

[PATCH] D27254: Protect optional test under libcpp-no-exceptions

2016-11-30 Thread Roger Ferrer Ibanez via Phabricator via cfe-commits
rogfer01 added inline comments. Comment at: test/std/experimental/optional/optional.specalg/swap.pass.cpp:225 } +#ifndef TEST_HAS_NO_EXCEPTIONS { mclow.lists wrote: > Why is this here, and not before line L#236? Yep, I'm wrong here. Probably a fallout o

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

2016-11-30 Thread Mads Ravn via cfe-commits
So remove the ifStmt from the third and fourth case? So that I keep if(str1.compare(str2)) and if(!str1.compare(str2)), and change the other two to str1.compare(str2) == 0 and str1.compare(str2) != 0 ? That makes good sense. Then I could also add some of the test cases you mentioned earlier. On

[PATCH] D27251: [PPC] some bugs mainly about sign problem fixed in altivec.h

2016-11-30 Thread Tony Jiang via Phabricator via cfe-commits
jtony added inline comments. Comment at: lib/Headers/altivec.h:16456 #ifdef __VSX__ static __inline__ vector signed long long __ATTRS_o_ai Thanks a lot for your good catch for the macro issue in vec_xst_be, that's a good catch. BTW, Can you move this up als

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

2016-11-30 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added a comment. I don't know why you're restricting this check to only match within the condition of an if statement. https://reviews.llvm.org/D27210 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi

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

2016-11-30 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists accepted this revision. mclow.lists added a comment. This revision is now accepted and ready to land. This looks good to me. https://reviews.llvm.org/D27199 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cg

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

2016-11-30 Thread Mads Ravn via Phabricator via cfe-commits
madsravn updated this revision to Diff 79747. madsravn marked 2 inline comments as done. madsravn added a comment. Added integerLiteral on both sides of the == operator. https://reviews.llvm.org/D27210 Files: clang-tidy/misc/CMakeLists.txt clang-tidy/misc/MiscTidyModule.cpp clang-tidy/mis

[PATCH] D26137: [clang-tidy] Add check name to YAML export

2016-11-30 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh requested changes to this revision. alexfh added a comment. This revision now requires changes to proceed. Looks mostly good. A few more nits. Comment at: include/clang/Tooling/Core/Diagnostic.h:68-71 + /// A freeform chunk of text to describe the context of the replace

[PATCH] D27066: Fix crash with unsupported architectures in Linux/Gnu target triples.

2016-11-30 Thread Florian Hahn via Phabricator via cfe-commits
fhahn added a comment. Ping. https://reviews.llvm.org/D27066 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D27142: [clang-tidy] Make format style customizable

2016-11-30 Thread Alexander Kornienko via Phabricator via cfe-commits
alexfh accepted this revision. alexfh added a comment. This revision is now accepted and ready to land. LG. Thanks! Repository: rL LLVM https://reviews.llvm.org/D27142 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/

[PATCH] D26979: Do not hard-code locale data in unit tests: get it from the OS instead

2016-11-30 Thread Eric van Gyzen via Phabricator via cfe-commits
vangyzen added a comment. > @EricWF Do you have time and interest to review this again? I should ask, do you have time and interest to //commit// this? https://reviews.llvm.org/D26979 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://l

[PATCH] D27109: [OpenCL] Prevent generation of globals in non-constant address space for OpenCL

2016-11-30 Thread Anastasia Stulova via Phabricator via cfe-commits
Anastasia closed this revision. Anastasia added a comment. Committed in r288163. https://reviews.llvm.org/D27109 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [RFC] Embedded bitcode and related upstream (Part II)

2016-11-30 Thread Nico Weber via cfe-commits
Hi Steven, On Fri, Jun 3, 2016 at 2:36 PM, Steven Wu via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Hi everyone > > I am still in the process of upstreaming some improvements to the embed > bitcode option. If you want more background, you can read the previous RFC ( > http://lists.llvm.or

[PATCH] D27250: [OpenMP] TargetLibraryInfo from "declare simd".

2016-11-30 Thread Francesco Petrogalli via Phabricator via cfe-commits
fpetrogalli added a comment. In https://reviews.llvm.org/D27250#609063, @ABataev wrote: > You did just some minor changes. The main questions are still unanswered. Hopefully now they are! :) Francesco https://reviews.llvm.org/D27250 ___ cfe-comm

[PATCH] D27250: [OpenMP] TargetLibraryInfo from "declare simd".

2016-11-30 Thread Francesco Petrogalli via Phabricator via cfe-commits
fpetrogalli added a comment. In https://reviews.llvm.org/D27250#609006, @ABataev wrote: > Hi! Thanks for your review! > 1. Please provide full context for your changes (check this document how to > do this http://llvm.org/docs/Phabricator.html). I missed that out, should be done now. > 2. U

[PATCH] D27054: Introducing clang::tooling::EditList for refactoring tools.

2016-11-30 Thread Eric Liu via Phabricator via cfe-commits
ioeric updated this revision to Diff 79736. ioeric added a comment. - Added replace() and insert() to replace current replacement interfaces. https://reviews.llvm.org/D27054 Files: include/clang/Tooling/Refactoring/EditList.h lib/Tooling/CMakeLists.txt lib/Tooling/Refactoring/CMakeLists.t

[PATCH] D27253: Protect futures test under libcpp-no-exceptions

2016-11-30 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists accepted this revision. mclow.lists added a comment. This revision is now accepted and ready to land. LGTM. https://reviews.llvm.org/D27253 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/lis

[PATCH] D27254: Protect optional test under libcpp-no-exceptions

2016-11-30 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists added inline comments. Comment at: test/std/experimental/optional/optional.specalg/swap.pass.cpp:225 } +#ifndef TEST_HAS_NO_EXCEPTIONS { Why is this here, and not before line L#236? https://reviews.llvm.org/D27254 __

[PATCH] D27255: Protect std::ostream::sentry test under libcpp-no-exceptions

2016-11-30 Thread Marshall Clow via Phabricator via cfe-commits
mclow.lists accepted this revision. mclow.lists added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D27255 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/list

  1   2   >