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

2016-11-29 Thread David Majnemer via Phabricator via cfe-commits
majnemer created this revision. majnemer added a reviewer: rnk. majnemer added a subscriber: cfe-commits. We didn't implement one of the corner cases: a lambda which belongs to an initializer for a field. In this case, we need to mangle the field name into the lambda. This fixes PR31197. https

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

2016-11-29 Thread Greg Bedwell via Phabricator via cfe-commits
gbedwell added a comment. In https://reviews.llvm.org/D25435#608348, @danielcdh wrote: > Change the flag to -fprof-debug, which is more concise. The flag name is > still open for discussion. Well, since I have permission to bikeshed... :) I'd prefer to have 'profile' rather than 'prof' in the

Re: Embedded Bitcode in Object Files

2016-11-29 Thread Steven Wu via cfe-commits
Thanks for reviewing the patches. And yes, 3 and 4 are no longer useful. I am seeking better alternatives to achieve them. Steven > On Nov 30, 2016, at 1:35 AM, Nico Weber wrote: > > It looks like patches 1 and 2 made it but 3 and 4 didn't. Do you no longer > need them? > >> On Mon, Feb 29

[PATCH] D27104: Unify and simplify the behavior of the hasDeclaration matcher.

2016-11-29 Thread Łukasz Anforowicz via Phabricator via cfe-commits
lukasza added a comment. Do we also need to update the documentation (e.g. to say that ElaboratedType is covered by hasDeclaration)? Other than that, I think this CL LGTM, although I would like to have a specific, working equivalent of the old, deep-maching hasDeclaration (at least when the in

r288203 - getObjCEncodingForMethodDecl cannot fail. Simplify. NFC.

2016-11-29 Thread John McCall via cfe-commits
Author: rjmccall Date: Tue Nov 29 15:57:00 2016 New Revision: 288203 URL: http://llvm.org/viewvc/llvm-project?rev=288203&view=rev Log: getObjCEncodingForMethodDecl cannot fail. Simplify. NFC. Modified: cfe/trunk/include/clang/AST/ASTContext.h cfe/trunk/lib/AST/ASTContext.cpp cfe/tru

[PATCH] D27207: Adds hasUnqualifiedDesugaredType to allow matching through type sugar.

2016-11-29 Thread Łukasz Anforowicz via Phabricator via cfe-commits
lukasza added a comment. I've tried replicating the deep-matching by saying qualType(hasType(hasUnqualifiedDesugaredType(hasDeclaration(... but this doesn't work because hasDeclaration only returns a matcher for a specific type from a subset of subclasses of Type - this is incompatible with exp

[PATCH] D27207: Adds hasUnqualifiedDesugaredType to allow matching through type sugar.

2016-11-29 Thread Malcolm Parsons via Phabricator via cfe-commits
malcolm.parsons added a comment. In https://reviews.llvm.org/D27207#608433, @lukasza wrote: > I think the above will work for my tool - thank you for providing the matcher > example (for some reason I incorrectly thought that desugaring would only be > done one step a time - this made me think

[PATCH] D27207: Adds hasUnqualifiedDesugaredType to allow matching through type sugar.

2016-11-29 Thread Łukasz Anforowicz via Phabricator via cfe-commits
lukasza added inline comments. Comment at: unittests/ASTMatchers/ASTMatchersTraversalTest.cpp:253 + matches("struct A {}; using B = A; B b;", + varDecl(hasType(hasUnqualifiedDesugaredType(recordType()); +} # deep testing suggestion If we do

r288207 - Don't try to merge DLL attributes on redeclaration of invalid decl (PR31069)

2016-11-29 Thread Hans Wennborg via cfe-commits
Author: hans Date: Tue Nov 29 16:31:00 2016 New Revision: 288207 URL: http://llvm.org/viewvc/llvm-project?rev=288207&view=rev Log: Don't try to merge DLL attributes on redeclaration of invalid decl (PR31069) Modified: cfe/trunk/lib/Sema/SemaDecl.cpp cfe/trunk/test/Sema/dllimport.c Modifi

r288208 - [c++1z] PR31210: ignore exception specification when matching the type of a

2016-11-29 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Nov 29 16:32:05 2016 New Revision: 288208 URL: http://llvm.org/viewvc/llvm-project?rev=288208&view=rev Log: [c++1z] PR31210: ignore exception specification when matching the type of a builtin with the type of an explicit declaration of the same function. Modified: cfe

r288213 - Fix some Clang-tidy and Include What You Use warnings; other minor fixes (NFC).

2016-11-29 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Tue Nov 29 16:44:24 2016 New Revision: 288213 URL: http://llvm.org/viewvc/llvm-project?rev=288213&view=rev Log: Fix some Clang-tidy and Include What You Use warnings; other minor fixes (NFC). This preparation to remove SetVector.h dependency on SmallSet.h. Modified:

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

2016-11-29 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. Apologies for the delay. I was out last week. In https://reviews.llvm.org/D26657#602083, @smeenai wrote: > General coding style question. Over here, I'm creating a local helper > function. However, that helper needs to access member functions of Sema, > which is why I mad

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

2016-11-29 Thread Hans Wennborg via Phabricator via cfe-commits
hans added inline comments. Comment at: include/clang/Sema/Sema.h:7495 + /// \brief Make an existing DLL attribute on a class take effect. + void ActOnDLLAttr(ClassTemplateSpecializationDecl *Def, +InheritableAttr *Attr); hans wrote: > I'd s

r288220 - [c++1z] Improve support for -fno-exceptions: we can't just ignore exception

2016-11-29 Thread Richard Smith via cfe-commits
Author: rsmith Date: Tue Nov 29 18:13:55 2016 New Revision: 288220 URL: http://llvm.org/viewvc/llvm-project?rev=288220&view=rev Log: [c++1z] Improve support for -fno-exceptions: we can't just ignore exception specifications in this mode in C++17, since they're part of the function type, so check a

r288221 - Stop handling interesting deserialized decls after HandleTranslationUnit

2016-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Nov 29 18:25:36 2016 New Revision: 288221 URL: http://llvm.org/viewvc/llvm-project?rev=288221&view=rev Log: Stop handling interesting deserialized decls after HandleTranslationUnit Other AST consumers can deserialize interesting decls that we might codegen, but they won't ma

Re: r288207 - Don't try to merge DLL attributes on redeclaration of invalid decl (PR31069)

2016-11-29 Thread David Majnemer via cfe-commits
On Tue, Nov 29, 2016 at 2:31 PM, Hans Wennborg via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: hans > Date: Tue Nov 29 16:31:00 2016 > New Revision: 288207 > > URL: http://llvm.org/viewvc/llvm-project?rev=288207&view=rev > Log: > Don't try to merge DLL attributes on redeclaration of

r288222 - Give this test that uses Itanium mangling a triple

2016-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Nov 29 18:31:16 2016 New Revision: 288222 URL: http://llvm.org/viewvc/llvm-project?rev=288222&view=rev Log: Give this test that uses Itanium mangling a triple Modified: cfe/trunk/test/Frontend/plugin-vs-debug-info.cpp Modified: cfe/trunk/test/Frontend/plugin-vs-debug-in

r288223 - Fix formatting issue from r288207

2016-11-29 Thread Hans Wennborg via cfe-commits
Author: hans Date: Tue Nov 29 18:31:39 2016 New Revision: 288223 URL: http://llvm.org/viewvc/llvm-project?rev=288223&view=rev Log: Fix formatting issue from r288207 Modified: cfe/trunk/lib/Sema/SemaDecl.cpp Modified: cfe/trunk/lib/Sema/SemaDecl.cpp URL: http://llvm.org/viewvc/llvm-project/c

Re: r288207 - Don't try to merge DLL attributes on redeclaration of invalid decl (PR31069)

2016-11-29 Thread Hans Wennborg via cfe-commits
On Tue, Nov 29, 2016 at 4:37 PM, David Majnemer via cfe-commits wrote: > > > On Tue, Nov 29, 2016 at 2:31 PM, Hans Wennborg via cfe-commits > wrote: >> >> Author: hans >> Date: Tue Nov 29 16:31:00 2016 >> New Revision: 288207 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=288207&view=rev >> L

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

2016-11-29 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: test/CodeGenCXX/mangle-ms-cxx11.cpp:337 +A a; +} This machinery is also supposed to kick in for lambdas in default arguments, right? Can you add that test case? https://reviews.llvm.org/D27226 _

r288227 - Fix -Winconsistent-missing-override in CodeGenAction.cpp

2016-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Tue Nov 29 19:32:53 2016 New Revision: 288227 URL: http://llvm.org/viewvc/llvm-project?rev=288227&view=rev Log: Fix -Winconsistent-missing-override in CodeGenAction.cpp Modified: cfe/trunk/lib/CodeGen/CodeGenAction.cpp Modified: cfe/trunk/lib/CodeGen/CodeGenAction.cpp URL:

[PATCH] D27084: [OpenMP] Sema and parsing for 'teams distribute parallel for simd' pragma

2016-11-29 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 marked 2 inline comments as done. kkwli0 added inline comments. Comment at: test/OpenMP/nesting_of_regions.cpp:3326 } -#pragma omp ordered { ABataev wrote: > what about teams distribute parallel for simd inside the ordered directive? > Why this one

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

2016-11-29 Thread Anna Zaks via Phabricator via cfe-commits
zaks.anna added a comment. Hi! Looks like this this is used by the Infinite recursion checker. Specifically, the checker not only needs to get Smalls for arguments of the current CallEvent, but it also looks for arguments of other calls on the stack. The checker walks the LocationContext and u

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

2016-11-29 Thread Vedant Kumar via Phabricator via cfe-commits
vsk added a comment. Thanks for working on this! I'm happy with the direction of this patch. It makes sense that clang would have a tool to help test AST reconstruction from 'external' sources. As you pointed out, it provides a good avenue for clients of the clang AST's to get better test cover

r288230 - make -fprofile-instr-generate and -fprofile-instr-use work with clang-cl

2016-11-29 Thread Bob Haarman via cfe-commits
Author: inglorion Date: Tue Nov 29 21:25:36 2016 New Revision: 288230 URL: http://llvm.org/viewvc/llvm-project?rev=288230&view=rev Log: make -fprofile-instr-generate and -fprofile-instr-use work with clang-cl Summary: Makes -fprofile-instr-generate and -fprofile-instr-use work with clang-cl so th

r288231 - Prospective GCC build fix: the unelaborated form of this friend

2016-11-29 Thread John McCall via cfe-commits
Author: rjmccall Date: Tue Nov 29 22:18:19 2016 New Revision: 288231 URL: http://llvm.org/viewvc/llvm-project?rev=288231&view=rev Log: Prospective GCC build fix: the unelaborated form of this friend declaration should find the right type, assuming it's supported evenly across all our hosts. Modif

[PATCH] D27248: [clang-tidy] Do not trigger unnecessary-value-param check on methods marked as final

2016-11-29 Thread Felix Berger via Phabricator via cfe-commits
flx created this revision. flx added reviewers: sbenza, alexfh, hokein. flx added a subscriber: cfe-commits. flx set the repository for this revision to rL LLVM. flx added a project: clang-tools-extra. Herald added a subscriber: JDevlieghere. Virtual method overrides of dependent types cannot be r

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

2016-11-29 Thread Shoaib Meenai via Phabricator via cfe-commits
smeenai added inline comments. Comment at: include/clang/Sema/Sema.h:7494 + /// \brief Make an existing DLL attribute on a class take effect. + void ActOnDLLAttr(ClassTemplateSpecializationDecl *Def, hans wrote: > Nit: I think `///` implies `\brief`, so we do

[PATCH] D27207: Adds hasUnqualifiedDesugaredType to allow matching through type sugar.

2016-11-29 Thread Manuel Klimek via Phabricator via cfe-commits
klimek added a comment. hasUnqualifiedDesugaredType(hasDeclaration( How about using hasUnqualifiedDesugaredType(recordType(hasDeclaration instead? https://reviews.llvm.org/D27207 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.

[PATCH] D26922: [ObjC++] Don't enter a C++ declarator context when the current context is an Objective-C declaration

2016-11-29 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Yes, I meant ParseDecl:5266. Reading the comment in ShouldEnterDeclaratorScope, it seemed to me that it shouldn't return true in this context (when parsing an objective-c). Also, the following code (which is not valid) crashes with ToT trunk, @property (nonatomic) i

<    1   2