[PATCH] D33393: [PATCH] Libcxxabi Demangler PR32890

2017-05-22 Thread Marcel Boehme via Phabricator via cfe-commits
marcel added a comment. In https://reviews.llvm.org/D33393#761679, @erik.pilkington wrote: > Do you agree that this is the right approach here? Sure. As long as it fixes PR32890. You could append my test case as a quick-check. So, I'll go ahead and abandon this revision? https://reviews.llvm

[PATCH] D33393: [PATCH] Libcxxabi Demangler PR32890

2017-05-22 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. Could you please add more context lines in any future patches? Makes it easier to review! I think we fixed the same problem at the same time, I have https://reviews.llvm.org/D33368 that also fixes this! The reason that inserting into db.names.back() sometimes r

[PATCH] D33393: [PATCH] Libcxxabi Demangler PR32890

2017-05-22 Thread Marcel Boehme via Phabricator via cfe-commits
marcel updated this revision to Diff 99850. marcel added a comment. Fixing off-by-one. Passes `make check-cxxabi` for LLVM in trunk on my machine (x86-64, Ubuntu 16.04). https://reviews.llvm.org/D33393 Files: CREDITS.TXT src/cxa_demangle.cpp test/test_demangle.pass.cpp Index: test/test

[PATCH] D33393: [PATCH] Libcxxabi Demangler PR32890

2017-05-22 Thread Marcel Boehme via Phabricator via cfe-commits
marcel added inline comments. Comment at: src/cxa_demangle.cpp:3078-3079 ++t1; -db.names.back().first.insert(db.names.back().first.begin()+7, t0, t1); +if (db.names.back().first.length() > 7) + db.names.back()

[PATCH] D33393: [PATCH] Libcxxabi Demangler PR32890

2017-05-22 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a reviewer: erik.pilkington. dexonsmith added inline comments. Comment at: src/cxa_demangle.cpp:3078-3079 ++t1; -db.names.back().first.insert(db.names.back().first.begin()+7, t0, t1); +if (db.names.back().firs

[PATCH] D31627: [coroutines] Skip over passthrough operator co_await

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov closed this revision. GorNishanov added a comment. r303605 = b026b234d55d6b9fab849389b2085204f530af5d https://reviews.llvm.org/D31627 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/

r303605 - [coroutines] Skip over passthrough operator co_await

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Tue May 23 00:25:31 2017 New Revision: 303605 URL: http://llvm.org/viewvc/llvm-project?rev=303605&view=rev Log: [coroutines] Skip over passthrough operator co_await https://reviews.llvm.org/D31627 Modified: cfe/trunk/lib/CodeGen/CGCoroutine.cpp cfe/trunk/test/Co

r303604 - Added LLVM_FALLTHROUGH to address gcc warning: this statement may fall through.

2017-05-22 Thread Galina Kistanova via cfe-commits
Author: gkistanova Date: Tue May 23 00:17:49 2017 New Revision: 303604 URL: http://llvm.org/viewvc/llvm-project?rev=303604&view=rev Log: Added LLVM_FALLTHROUGH to address gcc warning: this statement may fall through. Modified: cfe/trunk/lib/Driver/ToolChains/Myriad.cpp Modified: cfe/trunk/li

[PATCH] D31608: [coroutines] Add emission of initial and final suspends

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov closed this revision. GorNishanov added a comment. r303603 = 12cdab350043e7ff931af5f13d3e3afe85b76628 https://reviews.llvm.org/D31608 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/

r303603 - [coroutines] Add emission of initial and final suspends

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Tue May 23 00:04:01 2017 New Revision: 303603 URL: http://llvm.org/viewvc/llvm-project?rev=303603&view=rev Log: [coroutines] Add emission of initial and final suspends https://reviews.llvm.org/D31608 Modified: cfe/trunk/lib/CodeGen/CGCoroutine.cpp cfe/trunk/test

[PATCH] D31590: [coroutines] Add support for deallocation elision

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov added a comment. Commited: r303599 = abbd4f85db96b0ed1478e2ee52e9f1eec7404131 https://reviews.llvm.org/D31590 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r303599 - [coroutines] Add support for deallocation elision

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 23:21:27 2017 New Revision: 303599 URL: http://llvm.org/viewvc/llvm-project?rev=303599&view=rev Log: [coroutines] Add support for deallocation elision Wrap deallocation code with: if (auto *mem = coro.free()) Deallocate When backend decides to elide alloca

[PATCH] D31590: [coroutines] Add support for deallocation elision

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov accepted this revision. GorNishanov added a comment. LGTM https://reviews.llvm.org/D31590 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D33368: [libcxxabi][demangler] Fix a crash in the demangler

2017-05-22 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: src/cxa_demangle.cpp:3036 break; -if (db.names.size() < 2) +if (k1 <= k0) return first; erik.pilkington wrote: > compnerd wrote:

[PATCH] D33259: Don't defer to the GCC driver for linking arm-baremetal

2017-05-22 Thread Saleem Abdulrasool via Phabricator via cfe-commits
compnerd added inline comments. Comment at: lib/Driver/ToolChains/BareMetal.cpp:68 + SmallString<128> Dir(getDriver().ResourceDir); + llvm::sys::path::append(Dir, "lib", "baremetal"); + return Dir.str(); jroelofs wrote: > compnerd wrote: > > jroelofs wrote: >

[PATCH] D31586: [coroutines] Replace all coro.frame builtins with an SSA value of coro.begin

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov accepted this revision. GorNishanov added a comment. This revision is now accepted and ready to land. Committed: r303598 = cd8cc3ea48a887f846b3cbfc6dcb546a7b4de3af https://reviews.llvm.org/D31586 ___ cfe-commits mailing list cfe-commits@

r303598 - [coroutines] Replace all coro.frame builtins with an SSA value of coro.begin

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 22:46:59 2017 New Revision: 303598 URL: http://llvm.org/viewvc/llvm-project?rev=303598&view=rev Log: [coroutines] Replace all coro.frame builtins with an SSA value of coro.begin SemaCoroutine forms expressions referring to the coroutine frame of the enclosing

[PATCH] D31586: [coroutines] Replace all coro.frame builtins with an SSA value of coro.begin

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 99843. GorNishanov added a comment. merged with top of the trunk. preparing to land https://reviews.llvm.org/D31586 Files: lib/CodeGen/CGCoroutine.cpp test/CodeGenCoroutines/coro-alloc.cpp test/CodeGenCoroutines/coro-await.cpp test/CodeGenCorout

[PATCH] D33430: [clang-tidy] Do not dereference a null BaseType

2017-05-22 Thread Chih-Hung Hsieh via Phabricator via cfe-commits
chh created this revision. Herald added a subscriber: xazax.hun. Check BaseType before dereference. Simplified test case is derived from Android Open Source code. https://reviews.llvm.org/D33430 Files: clang-tidy/misc/ForwardingReferenceOverloadCheck.cpp test/clang-tidy/misc-forwarding-refe

[PATCH] D31584: [coroutines] Add support for allocation elision

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL303596: [coroutines] Add support for allocation elision (authored by GorNishanov). Changed prior to commit: https://reviews.llvm.org/D31584?vs=93805&id=99838#toc Repository: rL LLVM https://reviews.

r303596 - [coroutines] Add support for allocation elision

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 20:13:17 2017 New Revision: 303596 URL: http://llvm.org/viewvc/llvm-project?rev=303596&view=rev Log: [coroutines] Add support for allocation elision Summary: We wrap allocation code so that backend can elide it if necessary. llvm.coro.alloc intrinsic returns t

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

2017-05-22 Thread Faisal Vali via Phabricator via cfe-commits
faisalv closed this revision. faisalv added a comment. Committed as https://reviews.llvm.org/rL303594 https://reviews.llvm.org/D31414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r303594 - [NFC, Refactor] Modernize TemplateIdAnnotation using TrailingObjects

2017-05-22 Thread Faisal Vali via cfe-commits
Author: faisalv Date: Mon May 22 20:07:12 2017 New Revision: 303594 URL: http://llvm.org/viewvc/llvm-project?rev=303594&view=rev Log: [NFC, Refactor] Modernize TemplateIdAnnotation using TrailingObjects A refactoring of TemplateIdAnnotation that uses TrailingObjects to create a variably-sized ob

[PATCH] D31670: [coroutines] Implement correct GRO lifetime

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov marked an inline comment as done. GorNishanov added a comment. @rsmith, better now? :) https://reviews.llvm.org/D31670 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D31670: [coroutines] Implement correct GRO lifetime

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 99837. GorNishanov added a comment. Remember old_top before emitting the cleanup and walk set Active on all emitted cleanups. I tried to add Active flag to Emission, but it ended up being very hairy, so I went with the first option suggested. https://r

r303593 - Adjust clang test for r303590

2017-05-22 Thread Teresa Johnson via cfe-commits
Author: tejohnson Date: Mon May 22 19:35:09 2017 New Revision: 303593 URL: http://llvm.org/viewvc/llvm-project?rev=303593&view=rev Log: Adjust clang test for r303590 Forgot to commit this separately from the llvm change to use a new module flag type for pic and pie levels. Should fix the bot erro

[PATCH] D33424: Lexer: allow imaginary constants in GNU mode (only).

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith added a comment. Counterproposal: in `-std=*++14` onwards, treat this construct as a user-defined literal, but fall back on the built-in interpretation if name lookup doesn't find an `operator""i` function. (The two interpretations only conflict if the source code explicitly does somethi

r303589 - Add option to include multiple lines in snippets.

2017-05-22 Thread Richard Smith via cfe-commits
Author: rsmith Date: Mon May 22 18:51:40 2017 New Revision: 303589 URL: http://llvm.org/viewvc/llvm-project?rev=303589&view=rev Log: Add option to include multiple lines in snippets. When a diagnostic includes a highlighted range spanning multiple lines, clang now supports printing out multiple l

Re: r303582 - Give files from #line the characteristics of the current file

2017-05-22 Thread Richard Smith via cfe-commits
On 22 May 2017 at 15:22, Reid Kleckner via cfe-commits < cfe-commits@lists.llvm.org> wrote: > On Mon, May 22, 2017 at 3:17 PM, Richard Smith > wrote: > >>// If the StrTok is "eod", then it wasn't present. Otherwise, it must >>> be a >>>// string followed by eod. >>> - if (StrTok.is(tok:

[PATCH] D30837: [libcxx] Support for shared_ptr

2017-05-22 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. Ping! https://reviews.llvm.org/D30837 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r303584 - [coroutines] Fix coro-eh-cleanup.cpp test

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 17:41:28 2017 New Revision: 303584 URL: http://llvm.org/viewvc/llvm-project?rev=303584&view=rev Log: [coroutines] Fix coro-eh-cleanup.cpp test Modified: cfe/trunk/test/CodeGenCoroutines/coro-eh-cleanup.cpp Modified: cfe/trunk/test/CodeGenCoroutines/coro-e

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL303583: [coroutines] Wrap the body of the coroutine in try-catch (authored by GorNishanov). Changed prior to commit: https://reviews.llvm.org/D31692?vs=99815&id=99827#toc Repository: rL LLVM https:/

r303583 - [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 17:33:17 2017 New Revision: 303583 URL: http://llvm.org/viewvc/llvm-project?rev=303583&view=rev Log: [coroutines] Wrap the body of the coroutine in try-catch Summary: If unhandled_exception member function is present in the coroutine promise, wrap the body of

[PATCH] D33424: Lexer: allow imaginary constants in GNU mode (only).

2017-05-22 Thread Tim Northover via Phabricator via cfe-commits
t.p.northover created this revision. Herald added a subscriber: mcrosier. While looking into the regression tests' compatibility with C++14, many of the failures were because that specification defined UDLs for imaginary constants, specifically ones ending in 'i' and 'il'. This conflicted with t

Re: r303582 - Give files from #line the characteristics of the current file

2017-05-22 Thread Reid Kleckner via cfe-commits
On Mon, May 22, 2017 at 3:17 PM, Richard Smith wrote: >// If the StrTok is "eod", then it wasn't present. Otherwise, it must >> be a >>// string followed by eod. >> - if (StrTok.is(tok::eod)) >> -; // ok >> - else if (StrTok.isNot(tok::string_literal)) { >> + if (StrTok.is(tok::eo

Re: r303582 - Give files from #line the characteristics of the current file

2017-05-22 Thread Richard Smith via cfe-commits
On 22 May 2017 at 14:42, Reid Kleckner via cfe-commits < cfe-commits@lists.llvm.org> wrote: > Author: rnk > Date: Mon May 22 16:42:58 2017 > New Revision: 303582 > > URL: http://llvm.org/viewvc/llvm-project?rev=303582&view=rev > Log: > Give files from #line the characteristics of the current file

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D31692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[PATCH] D33398: Remove __unaligned preventively when mangling types in Itanium ABI

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/AST/ItaniumMangle.cpp:2329-2333 + // __unaligned is not currently mangled in any way. This implies that it is + // not a relevant qualifier for substitutions (while CVR and maybe others + // are). This triggers an assertion when th

r303582 - Give files from #line the characteristics of the current file

2017-05-22 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Mon May 22 16:42:58 2017 New Revision: 303582 URL: http://llvm.org/viewvc/llvm-project?rev=303582&view=rev Log: Give files from #line the characteristics of the current file This allows #line directives to appear in system headers that have code that clang would normally warn on

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 99815. GorNishanov added a comment. Fix misspelling in a comment. @rsmith, Looks good now? https://reviews.llvm.org/D31692 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/CodeGen/CGCoroutine.cpp lib/Sema/SemaCoroutine.cpp test/CodeGenCorou

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 99814. GorNishanov added a comment. 1. Heap allocate CxxTryStmt in CGCoroutine. 2. Merge with trunk https://reviews.llvm.org/D31692 Files: include/clang/Basic/DiagnosticSemaKinds.td lib/CodeGen/CGCoroutine.cpp lib/Sema/SemaCoroutine.cpp test/Cod

[PATCH] D33357: Avoid calling report_fatal_error in the destructor of raw_fd_ostream when saving a module timestamp file

2017-05-22 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Any idea why we're hitting this issue in the first place? The error that gets cleaned up is reported at some point before? Seems to me that we're going to fail to update the timestamp but continue as nothing happened, I wonder how many other issues this might trigger...

[PATCH] D33259: Don't defer to the GCC driver for linking arm-baremetal

2017-05-22 Thread Rui Ueyama via Phabricator via cfe-commits
ruiu added inline comments. Comment at: lib/Driver/ToolChains/BareMetal.h:42 + + const char *getDefaultLinker() const override { return "ld.lld"; } + jroelofs wrote: > compnerd wrote: > > jroelofs wrote: > > > compnerd wrote: > > > > I think that this really sho

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 updated this revision to Diff 99802. jyu2 added a comment. This is new version should address all @Aaron's commands, but CFG part. I would not think we should go that far in the compiler for this. Thanks. https://reviews.llvm.org/D3 Files: include/clang/Basic/DiagnosticSemaKinds.td

[PATCH] D33259: Don't defer to the GCC driver for linking arm-baremetal

2017-05-22 Thread Jonathan Roelofs via Phabricator via cfe-commits
jroelofs added inline comments. Comment at: cmake/caches/BaremetalARM.cmake:1 +set(LLVM_TARGETS_TO_BUILD ARM CACHE STRING "") + compnerd wrote: > jroelofs wrote: > > compnerd wrote: > > > Please rename this file to `BareMetalARMv6.cmake`. (I'm interested in > >

[PATCH] D30170: Function definition may have uninstantiated body

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith added a comment. Do we really need two different notions of "definition" and "odr definition" here? What goes wrong if we always treat the "instantiation of a friend function definition" case as being a definition? Comment at: include/clang/AST/Decl.h:1789 + // fu

[PATCH] D31646: [coroutines] Build GRO declaration and return GRO statement

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. GorNishanov marked an inline comment as done. Closed by commit rL303573: [coroutines] Build GRO declaration and return GRO statement (authored by GorNishanov). Changed prior to commit: https://reviews.llvm.org/D31646?vs=9

r303573 - [coroutines] Build GRO declaration and return GRO statement

2017-05-22 Thread Gor Nishanov via cfe-commits
Author: gornishanov Date: Mon May 22 15:22:23 2017 New Revision: 303573 URL: http://llvm.org/viewvc/llvm-project?rev=303573&view=rev Log: [coroutines] Build GRO declaration and return GRO statement Summary: 1. build declaration of the gro local variable that keeps the result of get_return_object

[PATCH] D31627: [coroutines] Skip over passthrough operator co_await

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov added a comment. In https://reviews.llvm.org/D31627#761320, @rsmith wrote: > Does it still make sense for us to have a `UO_Coawait` at all? As I recall, > the only purpose it ever had was to represent a dependent `co_await` > expression that couldn't yet be resolved to a `CoawaitExp

[PATCH] D31646: [coroutines] Build GRO declaration and return GRO statement

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov updated this revision to Diff 99796. GorNishanov added a comment. Thank you very much for the review! Merged with top of the trunk, implemented suggested changes, preparing to land https://reviews.llvm.org/D31646 Files: include/clang/AST/StmtCXX.h include/clang/Basic/Diagnostic

[PATCH] D31627: [coroutines] Skip over passthrough operator co_await

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Does it still make sense for us to have a `UO_Coawait` at all? As I recall, the only purpose it ever had was to represent a dependent `co_await` expression that couldn't yet be resolved to a `

[PATCH] D32449: Modifying PthreadLockChecker.cpp to reduce false positives.

2017-05-22 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. Thanks, this is great! Two more things: - You have touched other code, unrelated to your patch, with clang-format; we're usually trying to avoid that, because it creates merge conflicts out of nowhere, and because some of that code actually seems formatted by hand intentio

[PATCH] D31608: [coroutines] Add emission of initial and final suspends

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D31608 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[PATCH] D31692: [coroutines] Wrap the body of the coroutine in try-catch

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/AST/StmtCXX.h:128 +struct CXXTryStmt::OnStack : CXXTryStmt { + alignas(CXXTryStmt) Stmt *Stmts[2]; + OnStack(SourceLocation tryLoc, Stmt *tryBlock, Stmt *handler) This makes more assumptions about record l

[PATCH] D31670: [coroutines] Implement correct GRO lifetime

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/CodeGen/CGCoroutine.cpp:273 + +// FIXME: There must be a cleaner way to do this! +if (auto *Cleanup = dyn_cast_or_null(&*CGF.EHStack.begin())) { It doesn't seem safe to assume that a prior `EHCleanupScope` wo

[PATCH] D21508: Make friend function template definition available if class is instantiated.

2017-05-22 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 99789. sepavloff edited the summary of this revision. sepavloff added a comment. Updated patch https://reviews.llvm.org/D21508 Files: include/clang/AST/DeclTemplate.h lib/AST/Decl.cpp lib/AST/DeclTemplate.cpp lib/Sema/SemaDecl.cpp lib/Sema/SemaT

[PATCH] D21508: Make friend function template definition available if class is instantiated.

2017-05-22 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff marked an inline comment as done. sepavloff added inline comments. Comment at: lib/AST/DeclTemplate.cpp:292-311 +FunctionTemplateDecl *FunctionTemplateDecl::getDefinition() const { + for (auto *R : redecls()) { +FunctionTemplateDecl *F = cast(R); +if (F->isThis

[PATCH] D31646: [coroutines] Build GRO declaration and return GRO statement

2017-05-22 Thread Richard Smith via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. LGTM Comment at: lib/Sema/AnalysisBasedWarnings.cpp:338 + // In a coroutine, only co_return statements count as normal returns. Remember + // if we are processing the coro

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

2017-05-22 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! https://reviews.llvm.org/D31414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In https://reviews.llvm.org/D3#761233, @aaron.ballman wrote: > In https://reviews.llvm.org/D3#761224, @rnk wrote: > > > Re: clang-tidy, I would rather implement this as a traditional compiler > > warning. > > > > In https://reviews.llvm.org/D3#761208, @aaron.bal

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D3#761224, @rnk wrote: > Re: clang-tidy, I would rather implement this as a traditional compiler > warning. > > In https://reviews.llvm.org/D3#761208, @aaron.ballman wrote: > > > In https://reviews.llvm.org/D3#761126, @jyu2 w

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

2017-05-22 Thread Faisal Vali via Phabricator via cfe-commits
faisalv marked 2 inline comments as done. faisalv added a comment. mark aaron's feedback as done. https://reviews.llvm.org/D31414 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2017-05-22 Thread Faisal Vali via Phabricator via cfe-commits
faisalv updated this revision to Diff 99787. faisalv added a comment. Incorporated Aaron's feedback - thanks Aaron! https://reviews.llvm.org/D31414 Files: include/clang/Basic/TemplateKinds.h include/clang/Sema/ParsedTemplate.h lib/Parse/ParseExprCXX.cpp lib/Parse/ParseTemplate.cpp Inde

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. Re: clang-tidy, I would rather implement this as a traditional compiler warning. In https://reviews.llvm.org/D3#761208, @aaron.ballman wrote: > In https://reviews.llvm.org/D3#761126, @jyu2 wrote: > > > As I said, I don't think checking throw type matching catch handl

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D3#761126, @jyu2 wrote: > In https://reviews.llvm.org/D3#760431, @aaron.ballman wrote: > > > In https://reviews.llvm.org/D3#760419, @jyu2 wrote: > > > > > In https://reviews.llvm.org/D3#760149, @aaron.ballman wrote: > > >

Re: r303546 - [mips] Support `micromips` attribute

2017-05-22 Thread Aaron Ballman via cfe-commits
On Mon, May 22, 2017 at 12:00 PM, Simon Atanasyan wrote: > On Mon, May 22, 2017 at 3:57 PM, Aaron Ballman wrote: >> On Mon, May 22, 2017 at 8:47 AM, Simon Atanasyan via cfe-commits >> wrote: >>> Author: atanasyan >>> Date: Mon May 22 07:47:43 2017 >>> New Revision: 303546 >>> >>> URL: http://llv

[PATCH] D33272: Method loadFromCommandLine should be able to report errors

2017-05-22 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. Thank you! I put updated fix here. If it is OK, I'll commit it tomorrow. Comment at: lib/Tooling/CompilationDatabase.cpp:292 + if (Argc == 0) { +ErrorMsg = "error: no arguments specified\n"; +return nullptr; alexfh wrote: >

[PATCH] D33272: Method loadFromCommandLine should be able to report errors

2017-05-22 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 99786. sepavloff marked an inline comment as done. sepavloff added a comment. Addressed reviewer's notes. https://reviews.llvm.org/D33272 Files: include/clang/Tooling/CompilationDatabase.h lib/Frontend/CreateInvocationFromCommandLine.cpp lib/Tooling

[PATCH] D33170: [X86] Adding avx512_vpopcntdq feature set and its intrinsics

2017-05-22 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 Comment at: lib/CodeGen/CGBuiltin.cpp:7526 +llvm::Type *ResultType = ConvertType(E->getType()); +llvm::Function *F = CGM.getIntrinsic(Intrinsic::ctpo

[PATCH] D33277: [Clang][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: lib/Sema/SemaStmtAsm.cpp:674 + Expr::EvalResult EvlResult; + // Try to evaluate the identifier as enum constant + if (isa(Res->getType()) && Res->EvaluateAsRValue(EvlResult, Please add a comment explaining that non-enum

[PATCH] D33278: [LLVM][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: include/llvm/MC/MCParser/MCAsmParser.h:64 unsigned &Offset) = 0; + virtual bool EvaluateLookupAsEnum(void *LookupResult,int64_t &Result) = 0; }; mharoush wrote: > rnk wrote: > > It woul

r303568 - [index] Index the default template parameter values

2017-05-22 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Mon May 22 11:50:54 2017 New Revision: 303568 URL: http://llvm.org/viewvc/llvm-project?rev=303568&view=rev Log: [index] Index the default template parameter values rdar://32323724 Modified: cfe/trunk/lib/Index/IndexDecl.cpp cfe/trunk/test/Index/Core/index-source.cp

[PATCH] D33368: [libcxxabi][demangler] Fix a crash in the demangler

2017-05-22 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added inline comments. Comment at: src/cxa_demangle.cpp:3036 break; -if (db.names.size() < 2) +if (k1 <= k0) return first; compnerd wrote: > I'm not sure how

[PATCH] D33277: [Clang][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Matan via Phabricator via cfe-commits
mharoush marked an inline comment as done. mharoush added inline comments. Comment at: lib/Parse/ParseStmtAsm.cpp:100 + // result of a call to LookupInlineAsmIdentifier. + bool EvaluateLookupAsEnum(void *LookupResult, int64_t &Result) { +if (!LookupResult) return false; ---

[PATCH] D33395: [clangd] Split clangd into library+executable (mainly for unit tests).

2017-05-22 Thread Benjamin Kramer via Phabricator via cfe-commits
bkramer accepted this revision. bkramer added a comment. This revision is now accepted and ready to land. looks good to me https://reviews.llvm.org/D33395 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/

[PATCH] D33277: [Clang][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Matan via Phabricator via cfe-commits
mharoush updated this revision to Diff 99780. mharoush added a comment. removed functions and dropped an irrelevant test case. Repository: rL LLVM https://reviews.llvm.org/D33277 Files: lib/Sema/SemaStmtAsm.cpp test/CodeGen/x86-ms-inline-asm-enum_feature.cpp Index: lib/Sema/SemaStmtAsm

[PATCH] D32896: [OpenCL] Make CLK_NULL_RESERVE_ID invalid reserve id.

2017-05-22 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: lib/Headers/opencl-c.h:16020 +// The macro CLK_NULL_RESERVE_ID refers to an invalid reservation ID. +#define CLK_NULL_RESERVE_ID (__builtin_astype((void *)0, reserve_id_t)) bool __ovld is_valid_reserve_id(reserve_id_t reserve_id); --

[PATCH] D33278: [LLVM][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Matan via Phabricator via cfe-commits
mharoush updated this revision to Diff 99778. mharoush added a comment. Using identifier info to pass enum information. Repository: rL LLVM https://reviews.llvm.org/D33278 Files: include/llvm/MC/MCParser/MCAsmParser.h lib/Target/X86/AsmParser/X86AsmParser.cpp Index: lib/Target/X86/AsmPa

[PATCH] D33278: [LLVM][x86][Inline Asm] - Enum support for MS syntax

2017-05-22 Thread Matan via Phabricator via cfe-commits
mharoush marked an inline comment as done. mharoush added inline comments. Comment at: include/llvm/MC/MCParser/MCAsmParser.h:64 unsigned &Offset) = 0; + virtual bool EvaluateLookupAsEnum(void *LookupResult,int64_t &Result) = 0; }; -

[PATCH] D33333: Emit warning when throw exception in destruct or dealloc functions which has a (possible implicit) noexcept specifier

2017-05-22 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 added a comment. In https://reviews.llvm.org/D3#760431, @aaron.ballman wrote: > In https://reviews.llvm.org/D3#760419, @jyu2 wrote: > > > In https://reviews.llvm.org/D3#760149, @aaron.ballman wrote: > > > > > As an FYI, there is a related check currently under development in > >

[PATCH] D33395: [clangd] Split clangd into library+executable (mainly for unit tests).

2017-05-22 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov marked an inline comment as done. ilya-biryukov added inline comments. Comment at: clangd/tool/ClangdMain.cpp:11 +#include "../ClangdLSPServer.h" +#include "../JSONRPCDispatcher.h" #include "llvm/Support/CommandLine.h" krasimir wrote: > I'd suggest

[PATCH] D31646: [coroutines] Build GRO declaration and return GRO statement

2017-05-22 Thread Gor Nishanov via Phabricator via cfe-commits
GorNishanov added a comment. @rsmith barely audible ping https://reviews.llvm.org/D31646 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D33416: [clangd] Allow to use vfs::FileSystem for file accesses.

2017-05-22 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. Herald added a subscriber: mgorny. Custom vfs::FileSystem is currently used for unit tests. This revision depends on https://reviews.llvm.org/D33397. https://reviews.llvm.org/D33416 Files: clangd/ClangdLSPServer.cpp clangd/ClangdServer.cpp clangd/Clang

Re: r303546 - [mips] Support `micromips` attribute

2017-05-22 Thread Simon Atanasyan via cfe-commits
On Mon, May 22, 2017 at 3:57 PM, Aaron Ballman wrote: > On Mon, May 22, 2017 at 8:47 AM, Simon Atanasyan via cfe-commits > wrote: >> Author: atanasyan >> Date: Mon May 22 07:47:43 2017 >> New Revision: 303546 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=303546&view=rev >> Log: >> [mips] Sup

[PATCH] D33395: [clangd] Split clangd into library+executable (mainly for unit tests).

2017-05-22 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov updated this revision to Diff 99774. ilya-biryukov added a comment. Got rid of relative includes from parent dir in ClangdMain.cpp. (Addressed krasimir's comments) https://reviews.llvm.org/D33395 Files: clangd/CMakeLists.txt clangd/ClangdMain.cpp clangd/tool/CMakeLists.txt

r303565 - [mips] Add one more check to the micromips attribute test case. NFC

2017-05-22 Thread Simon Atanasyan via cfe-commits
Author: atanasyan Date: Mon May 22 10:53:34 2017 New Revision: 303565 URL: http://llvm.org/viewvc/llvm-project?rev=303565&view=rev Log: [mips] Add one more check to the micromips attribute test case. NFC Modified: cfe/trunk/test/Sema/attr-micromips.c Modified: cfe/trunk/test/Sema/attr-microm

r303564 - [mips] Quote command line options with `` in the micromips attribute description. NFC

2017-05-22 Thread Simon Atanasyan via cfe-commits
Author: atanasyan Date: Mon May 22 10:53:31 2017 New Revision: 303564 URL: http://llvm.org/viewvc/llvm-project?rev=303564&view=rev Log: [mips] Quote command line options with `` in the micromips attribute description. NFC Modified: cfe/trunk/include/clang/Basic/AttrDocs.td Modified: cfe/tru

[PATCH] D33415: Replaced WorkerRequest with std::function...

2017-05-22 Thread Ilya Biryukov via Phabricator via cfe-commits
ilya-biryukov created this revision. And implemented a helper function to dump an AST of a file for testing/debugging purposes. https://reviews.llvm.org/D33415 Files: clangd/ClangdServer.cpp clangd/ClangdServer.h clangd/ClangdUnit.cpp clangd/ClangdUnit.h clangd/ClangdUnitStore.h Inde

r303563 - [index] Index the deleted functions

2017-05-22 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Mon May 22 10:42:45 2017 New Revision: 303563 URL: http://llvm.org/viewvc/llvm-project?rev=303563&view=rev Log: [index] Index the deleted functions rdar://32323386 Modified: cfe/trunk/lib/Index/IndexDecl.cpp cfe/trunk/test/Index/Core/index-source.cpp Modified: cfe

[PATCH] D33250: [Sema][ObjC] Fix a bug where -Wunguarded-availability was emitted at the wrong location

2017-05-22 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL303562: [Sema][ObjC] Fix a bug where -Wunguarded-availability was emitted at the wrong… (authored by epilk). Changed prior to commit: https://reviews.llvm.org/D33250?vs=99605&id=99772#toc Repository:

r303562 - [Sema][ObjC] Fix a bug where -Wunguarded-availability was emitted at the wrong location

2017-05-22 Thread Erik Pilkington via cfe-commits
Author: epilk Date: Mon May 22 10:41:12 2017 New Revision: 303562 URL: http://llvm.org/viewvc/llvm-project?rev=303562&view=rev Log: [Sema][ObjC] Fix a bug where -Wunguarded-availability was emitted at the wrong location Differential revision: https://reviews.llvm.org/D33250 Modified: cfe/tr

[PATCH] D33304: [WIP][clang-tidy] Add a new module Android and a new check for file descriptors.

2017-05-22 Thread Yan Wang via Phabricator via cfe-commits
yawanng added a comment. I will make some major changes to this CL based on the current suggestions from reviewers and update it for further review later. Thank you for the valuable advice. Repository: rL LLVM https://reviews.llvm.org/D33304 __

[PATCH] D33412: Add support for #pragma clang section

2017-05-22 Thread Javed Absar via Phabricator via cfe-commits
javed.absar created this revision. Herald added a subscriber: aemerson. This patch adds support for a '#pragma clang section' directive in clang. An RFC was sent out earlier by my colleague James Molloy: http://lists.llvm.org/pipermail/cfe-dev/2017-March/053100.html Purpose: The pur

r303559 - [index] Visit the default argument values in function definitions

2017-05-22 Thread Alex Lorenz via cfe-commits
Author: arphaman Date: Mon May 22 10:17:44 2017 New Revision: 303559 URL: http://llvm.org/viewvc/llvm-project?rev=303559&view=rev Log: [index] Visit the default argument values in function definitions rdar://32323315 Modified: cfe/trunk/lib/Index/IndexDecl.cpp cfe/trunk/test/Index/Core/i

[PATCH] D32896: [OpenCL] Make CLK_NULL_RESERVE_ID invalid reserve id.

2017-05-22 Thread Alexey Bader via Phabricator via cfe-commits
bader added inline comments. Comment at: lib/Headers/opencl-c.h:16020 +// The macro CLK_NULL_RESERVE_ID refers to an invalid reservation ID. +#define CLK_NULL_RESERVE_ID (__builtin_astype((void *)0, reserve_id_t)) bool __ovld is_valid_reserve_id(reserve_id_t reserve_id); ---

r303557 - clang-format: [JS] avoid line breaks before unindented r_parens.

2017-05-22 Thread Martin Probst via cfe-commits
Author: mprobst Date: Mon May 22 09:58:26 2017 New Revision: 303557 URL: http://llvm.org/viewvc/llvm-project?rev=303557&view=rev Log: clang-format: [JS] avoid line breaks before unindented r_parens. The change that enabled wrapping at the previous scope's indentation had unintended side-effects i

[PATCH] D33285: clang-format: do not reflow bullet lists

2017-05-22 Thread Francois Ferrand via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL303556: clang-format: do not reflow bullet lists (authored by Typz). Changed prior to commit: https://reviews.llvm.org/D33285?vs=99436&id=99764#toc Repository: rL LLVM https://reviews.llvm.org/D3328

r303556 - clang-format: do not reflow bullet lists

2017-05-22 Thread Francois Ferrand via cfe-commits
Author: typz Date: Mon May 22 09:47:17 2017 New Revision: 303556 URL: http://llvm.org/viewvc/llvm-project?rev=303556&view=rev Log: clang-format: do not reflow bullet lists Summary: This patch prevents reflowing bullet lists in block comments. It handles all lists supported by doxygen and markdow

[PATCH] D32896: [OpenCL] Make CLK_NULL_RESERVE_ID invalid reserve id.

2017-05-22 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl added inline comments. Comment at: lib/Headers/opencl-c.h:16020 +// The macro CLK_NULL_RESERVE_ID refers to an invalid reservation ID. +#define CLK_NULL_RESERVE_ID (__builtin_astype((void *)0, reserve_id_t)) bool __ovld is_valid_reserve_id(reserve_id_t reserve_id); --

[PATCH] D32480: clang-format: Add CompactNamespaces option

2017-05-22 Thread Francois Ferrand via Phabricator via cfe-commits
Typz updated this revision to Diff 99763. Typz added a comment. Remove dependency on https://reviews.llvm.org/D33314 https://reviews.llvm.org/D32480 Files: include/clang/Format/Format.h lib/Format/Format.cpp lib/Format/NamespaceEndCommentsFixer.cpp lib/Format/UnwrappedLineFormatter.cpp

  1   2   >