clang-omp / clang

clang with OpenMP 3.1 and some elements of OpenMP 4.0 support
clang-omp.github.com
Other
91 stars 15 forks source link

Assertion `oldBlock->capturesCXXThis() == blockScope->isCXXThisCaptured()' failed. #75

Closed benjamin-engel closed 9 years ago

benjamin-engel commented 9 years ago

clang: /scratch/mflehmig/llvm/llvm/tools/clang/lib/Sema/TreeTransform.h:10641: clang::ExprResult clang::TreeTransform::TransformBlockExpr(clang::BlockExpr) [with Derived = {anonymous}::TemplateInstantiator; clang::ExprResult = clang::ActionResult<clang::Expr>]: Assertion oldBlock->capturesCXXThis() == blockScope->isCXXThisCaptured()' failed. clang: /scratch/mflehmig/llvm/llvm/tools/clang/lib/Sema/TreeTransform.h:10641: clang::ExprResult clang::TreeTransform<Derived>::TransformBlockExpr(clang::BlockExpr*) [with Derived = {anonymous}::TemplateInstantiator; clang::ExprResult = clang::ActionResult<clang::Expr*>]: AssertionoldBlock->capturesCXXThis() == blockScope->isCXXThisCaptured()' failed. 0 clang 0x000000000253b432 llvm::sys::PrintStackTrace(_IOFILE) + 34 1 clang 0x000000000253b019 2 libpthread.so.0 0x00002af6556d25d0 3 libc.so.6 0x00002af6566d5945 gsignal + 53 4 libc.so.6 0x00002af6566d6f21 abort + 385 5 libc.so.6 0x00002af6566ce810 __assertfail + 240 6 clang 0x0000000000f70953 7 clang 0x0000000000f70ab5 8 clang 0x0000000000f816b5 9 clang 0x0000000000f81308 10 clang 0x0000000000f8e34e 11 clang 0x0000000000f8e47a 12 clang 0x0000000000f70e55 13 clang 0x0000000000f86de5 14 clang 0x0000000000f88d5f 15 clang 0x0000000000f88e9b 16 clang 0x0000000000f86db6 17 clang 0x0000000000f8bf3f clang::Sema::SubstStmt(clang::Stmt, clang::MultiLevelTemplateArgumentList const&) + 79 18 clang 0x0000000000fac7bc clang::Sema::InstantiateFunctionDefinition(clang::SourceLocation, clang::FunctionDecl, bool, bool) + 2684 19 clang 0x0000000000faba3c clang::Sema::PerformPendingInstantiations(bool) + 364 20 clang 0x0000000000c77b0b clang::Sema::ActOnEndOfTranslationUnit() + 315 21 clang 0x0000000000be60ca clang::Parser::ParseTopLevelDecl(clang::OpaquePtrclang::DeclGroupRef&) + 314 22 clang 0x0000000000be14ca clang::ParseAST(clang::Sema&, bool, bool) + 266 23 clang 0x0000000000a2382e clang::CodeGenAction::ExecuteAction() + 78 24 clang 0x0000000000889b29 clang::FrontendAction::Execute() + 265 25 clang 0x0000000000867a45 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 341 26 clang 0x000000000084f44e clang::ExecuteCompilerInvocation(clang::CompilerInstance) + 1886 27 clang 0x00000000008490a8 cc1main(char const, char const, char const, void_) + 1160 28 clang 0x0000000000834ac5 main + 693 29 libc.so.6 0x00002af6566c1bc6 __libc_start_main + 230 30 clang 0x0000000000847f61

sfantao commented 9 years ago

Can you share the code pattern that is causing the problem so we can reproduce the issue?

Thanks, Samuel

benjamin-engel commented 9 years ago

Hi Samuel,

Can you share the code pattern that is causing the problem so we can reproduce the issue? Of course, please find attachted the cpp and the sh file. It's a benchmark from the parsec-3.0 suit, rather big I have to admit. Maybe you want to have a look at the function ParticleFilterOMP::CalcWeights. There is a static object Dispatch_for in the function taking a closure when invoking its member function run(). Removing those lines prevents the assertion.

adios - Benjamin

Dear NSA, thank you for keeping backups of all my mails.

On Fri, Jul 10, 2015 at 08:39:50AM -0700, Samuel F Antao wrote:

Can you share the code pattern that is causing the problem so we can reproduce the issue?

Thanks, Samuel


Reply to this email directly or view it on GitHub: https://github.com/clang-omp/clang/issues/75#issuecomment-120438703

benjamin-engel commented 9 years ago

Closed and moved to llvm.org/bugs, since it turned out not to be only omp-specific.