mizvekov wrote:

> I'm trying to reduce a crash that only reproduces w/ in module builds. Does 
> this sound familiar?
> 
> ```
> assertion failed at clang/lib/AST/RecordLayoutBuilder.cpp:3380 in const 
> ASTRecordLayout &clang::ASTContext::getASTRecordLayout(const RecordDecl *) 
> const: D && "Cannot get layout of forward declarations!"
> *** Check failure stack trace: ***
>     @     0x557b3889784f  clang::ASTContext::getASTRecordLayout()
>     @     0x557b3823cd68  clang::ASTContext::getTypeInfoImpl()
>     @     0x557b3823e25c  clang::ASTContext::getTypeInfo()
>     @     0x557b3823d855  clang::ASTContext::getPreferredTypeAlign()
>     @     0x557b3823bf01  clang::ASTContext::getDeclAlign()
>     @     0x557b366c6a06  clang::CodeGen::CodeGenFunction::EmitAutoVarAlloca()
>     @     0x557b366c165c  clang::CodeGen::CodeGenFunction::EmitVarDecl()
>     @     0x557b366c1120  clang::CodeGen::CodeGenFunction::EmitDecl()
>     @     0x557b36760580  clang::CodeGen::CodeGenFunction::EmitDeclStmt()
>     @     0x557b36754d50  clang::CodeGen::CodeGenFunction::EmitSimpleStmt()
>     @     0x557b3675403e  clang::CodeGen::CodeGenFunction::EmitStmt()
>     @     0x557b36761891  
> clang::CodeGen::CodeGenFunction::EmitCompoundStmtWithoutScope()
>     @     0x557b368c47d5  clang::CodeGen::CodeGenFunction::GenerateCode()
>     @     0x557b368ef9f6  
> clang::CodeGen::CodeGenModule::EmitGlobalFunctionDefinition()
>     @     0x557b368e6bc8  
> clang::CodeGen::CodeGenModule::EmitGlobalDefinition()
>     @     0x557b368d7786  clang::CodeGen::CodeGenModule::EmitDeferred()
>     @     0x557b368d77a2  clang::CodeGen::CodeGenModule::EmitDeferred()
> ...
>     @     0x557b368d77a2  clang::CodeGen::CodeGenModule::EmitDeferred()
>     @     0x557b368d77a2  clang::CodeGen::CodeGenModule::EmitDeferred()
>     @     0x557b368d41ae  clang::CodeGen::CodeGenModule::Release()
>     @     0x557b36a1e14e  (anonymous 
> namespace)::CodeGeneratorImpl::HandleTranslationUnit()
> ```

Haven't seen this one yet. That may have something to do with demoted 
definitions, a repro would be helpful.

https://github.com/llvm/llvm-project/pull/147835
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to