[llvm-bugs] [Bug 30727] New: clang-cl StmtProfiler::VisitCXXOperatorCallExpr crashes on a null pointer when compiling Firefox

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Oct 18 06:44:33 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=30727

            Bug ID: 30727
           Summary: clang-cl StmtProfiler::VisitCXXOperatorCallExpr
                    crashes on a null pointer when compiling Firefox
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: froydnj at gmail.com
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

Created attachment 17458
  --> https://llvm.org/bugs/attachment.cgi?id=17458&action=edit
preprocessed source and runscript for crash

While compiling Firefox with r284471, I get:

 7:19.95 Wrote crash dump file
"C:\Users\NATHAN~1\AppData\Local\Temp\clang-cl.EXE-ee59db.dmp"
 7:19.95 #0 0x00000000
 7:19.95 #1 0x01f5b5da `anonymous
namespace'::StmtProfiler::VisitCXXOperatorCallExpr c:\users\nathan
froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:1197:0
 7:19.95 #2 0x01f5ec70 `anonymous namespace'::StmtProfiler::VisitStmt
c:\users\nathan froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:77:0
 7:19.95 #3 0x01f5c691 `anonymous namespace'::StmtProfiler::VisitMemberExpr
c:\users\nathan froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:846:0
 7:19.95 #4 0x01f5ec70 `anonymous namespace'::StmtProfiler::VisitStmt
c:\users\nathan froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:77:0
 7:19.95 #5 0x01f5b60d `anonymous
namespace'::StmtProfiler::VisitCXXOperatorCallExpr c:\users\nathan
froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:1199:0
 7:19.95 #6 0x01f5b60d `anonymous
namespace'::StmtProfiler::VisitCXXOperatorCallExpr c:\users\nathan
froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:1199:0
 7:19.95 #7 0x01f59f24 clang::Stmt::Profile(class llvm::FoldingSetNodeID
&,class clang::ASTContext const &,bool)const  c:\users\nathan
froyd\llvm\tools\clang\lib\ast\stmtprofile.cpp:1768:0
 7:19.95 #8 0x01dc6d03 clang::DependentDecltypeType::Profile(class
llvm::FoldingSetNodeID &,class clang::ASTContext const &,class clang::Expr *)
c:\users\nathan froyd\llvm\tools\clang\lib\ast\type.cpp:2966:0
 7:19.95 #9 0x01e31de8 clang::ASTContext::getDecltypeType(class clang::Expr
*,class clang::QualType)const  c:\users\nathan
froyd\llvm\tools\clang\lib\ast\astcontext.cpp:4258:0
 7:19.95 #10 0x0194706e clang::Sema::BuildDecltypeType(class clang::Expr
*,class clang::SourceLocation,bool) c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematype.cpp:7338:0
 7:19.95 #11 0x019496bc ConvertDeclSpecToType c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematype.cpp:1538:0
 7:19.96 #12 0x0194a915 GetDeclSpecTypeForDeclarator c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematype.cpp:2789:0
 7:19.96 #13 0x0194ef24 clang::Sema::GetTypeForDeclarator(class
clang::Declarator &,class clang::Scope *) c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematype.cpp:4589:0
 7:19.96 #14 0x01945e74 clang::Sema::ActOnTypeName(class clang::Scope *,class
clang::Declarator &) c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematype.cpp:5219:0
 7:19.96 #15 0x0155dbd4 clang::Parser::ParseTypeName(class clang::SourceRange
*,enum clang::Declarator::TheContext,enum clang::AccessSpecifier,class
clang::Decl * *,class clang::ParsedAttributes *) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsedecl.cpp:70:0
 7:19.96 #16 0x01566594 clang::Parser::ParseTemplateArgument(void)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:1195:0
 7:19.96 #17 0x015667f4 clang::Parser::ParseTemplateArgumentList(class
llvm::SmallVector<class clang::ParsedTemplateArgument,16> &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:1272:0
 7:19.96 #18 0x01566f08 clang::Parser::ParseTemplateIdAfterTemplateName(class
clang::OpaquePtr<class clang::TemplateName>,class clang::SourceLocation,class
clang::CXXScopeSpec const &,bool,class clang::SourceLocation &,class
llvm::SmallVector<class clang::ParsedTemplateArgument,16> &,class
clang::SourceLocation &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:917:0
 7:19.96 #19 0x015641ef clang::Parser::AnnotateTemplateIdToken(class
clang::OpaquePtr<class clang::TemplateName>,enum clang::TemplateNameKind,class
clang::CXXScopeSpec &,class clang::SourceLocation,class clang::UnqualifiedId
&,bool) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:989:0
 7:19.96 #20 0x0158964d clang::Parser::ParseOptionalCXXScopeSpecifier(class
clang::CXXScopeSpec &,class clang::OpaquePtr<class clang::QualType>,bool,bool
*,bool,class clang::IdentifierInfo * *) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parseexprcxx.cpp:539:0
 7:19.96 #21 0x0153fc47 clang::Parser::TryAnnotateTypeOrScopeToken(bool,bool)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parser.cpp:1730:0
 7:19.96 #22 0x0157bef8 clang::Parser::ParseCastExpression(bool,bool,bool
&,enum clang::Parser::TypeCastState) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parseexpr.cpp:870:0
 7:19.96 #23 0x0157d622 clang::Parser::ParseCastExpression(bool,bool,enum
clang::Parser::TypeCastState) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parseexpr.cpp:482:0
 7:19.96 #24 0x0157d789 clang::Parser::ParseConstantExpression(enum
clang::Parser::TypeCastState) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parseexpr.cpp:205:0
 7:19.96 #25 0x015a5e16 clang::Parser::ParseStaticAssertDeclaration(class
clang::SourceLocation &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsedeclcxx.cpp:758:0
 7:19.96 #26 0x015501f7 clang::Parser::ParseDeclaration(unsigned int,class
clang::SourceLocation &,struct clang::Parser::ParsedAttributesWithRange &)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsedecl.cpp:1542:0
 7:19.96 #27 0x01594239
clang::Parser::ParseStatementOrDeclarationAfterAttributes(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *,struct
clang::Parser::ParsedAttributesWithRange &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:215:0
 7:19.96 #28 0x01593a02 clang::Parser::ParseStatementOrDeclaration(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:116:0
 7:19.96 #29 0x0158f518 clang::Parser::ParseCompoundStatementBody(bool)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:987:0
 7:19.96 #30 0x0158f0bd clang::Parser::ParseCompoundStatement(bool,unsigned
int) c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:866:0
 7:19.96 #31 0x0158f08f clang::Parser::ParseCompoundStatement(bool)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:832:0
 7:19.96 #32 0x01593ce7
clang::Parser::ParseStatementOrDeclarationAfterAttributes(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *,struct
clang::Parser::ParsedAttributesWithRange &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:232:0
 7:19.96 #33 0x01593a02 clang::Parser::ParseStatementOrDeclaration(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:116:0
 7:19.96 #34 0x015938da clang::Parser::ParseStatement(class
clang::SourceLocation *,bool) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:44:0
 7:19.96 #35 0x01590003 clang::Parser::ParseDoStatement(void) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:1438:0
 7:19.96 #36 0x01593d85
clang::Parser::ParseStatementOrDeclarationAfterAttributes(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *,struct
clang::Parser::ParsedAttributesWithRange &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:247:0
 7:19.96 #37 0x01593a02 clang::Parser::ParseStatementOrDeclaration(class
llvm::SmallVector<class clang::Stmt *,32> &,enum
clang::Parser::AllowedContsructsKind,class clang::SourceLocation *)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:116:0
 7:19.96 #38 0x0158f518 clang::Parser::ParseCompoundStatementBody(bool)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:987:0
 7:19.96 #39 0x0159139f clang::Parser::ParseFunctionStatementBody(class
clang::Decl *,class clang::Parser::ParseScope &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsestmt.cpp:1954:0
 7:19.96 #40 0x0156571a clang::Parser::ParseLateTemplatedFuncDef(struct
clang::LateParsedTemplate &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:1406:0
 7:19.96 #41 0x01564add clang::Parser::LateTemplateParserCallback(void *,struct
clang::LateParsedTemplate &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parsetemplate.cpp:1327:0
 7:19.96 #42 0x01aac445 clang::Sema::InstantiateFunctionDefinition(class
clang::SourceLocation,class clang::FunctionDecl *,bool,bool,bool)
c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematemplateinstantiatedecl.cpp:3629:0
 7:19.96 #43 0x01aae5ca clang::Sema::PerformPendingInstantiations(bool)
c:\users\nathan
froyd\llvm\tools\clang\lib\sema\sematemplateinstantiatedecl.cpp:4925:0
 7:20.38 #44 0x016bd387 clang::Sema::ActOnEndOfTranslationUnit(void)
c:\users\nathan froyd\llvm\tools\clang\lib\sema\sema.cpp:686:0
 7:21.33 #45 0x0153e75b clang::Parser::ParseTopLevelDecl(class
clang::OpaquePtr<class clang::DeclGroupRef> &) c:\users\nathan
froyd\llvm\tools\clang\lib\parse\parser.cpp:629:0
 7:21.33 #46 0x01538376 clang::ParseAST(class clang::Sema &,bool,bool)
c:\users\nathan froyd\llvm\tools\clang\lib\parse\parseast.cpp:147:0
 7:21.33 #47 0x00f17bff clang::ASTFrontendAction::ExecuteAction(void)
c:\users\nathan froyd\llvm\tools\clang\lib\frontend\frontendaction.cpp:557:0
 7:21.33 #48 0x02115166 clang::CodeGenAction::ExecuteAction(void)
c:\users\nathan froyd\llvm\tools\clang\lib\codegen\codegenaction.cpp:893:0
 7:21.33 #49 0x00f17aef clang::FrontendAction::Execute(void) c:\users\nathan
froyd\llvm\tools\clang\lib\frontend\frontendaction.cpp:462:0
 7:21.33 #50 0x00eef108 clang::CompilerInstance::ExecuteAction(class
clang::FrontendAction &) c:\users\nathan
froyd\llvm\tools\clang\lib\frontend\compilerinstance.cpp:872:0
 7:21.33 #51 0x00f82d4d clang::ExecuteCompilerInvocation(class
clang::CompilerInstance *) c:\users\nathan
froyd\llvm\tools\clang\lib\frontendtool\executecompilerinvocation.cpp:249:0
 7:21.33 #52 0x0032433c cc1_main(class llvm::ArrayRef<char const *>,char const
*,void *) c:\users\nathan
froyd\llvm\tools\clang\tools\driver\cc1_main.cpp:221:0
 7:21.33 #53 0x0031f727 ExecuteCC1Tool c:\users\nathan
froyd\llvm\tools\clang\tools\driver\driver.cpp:299:0
 7:21.33 #54 0x00321a4c main c:\users\nathan
froyd\llvm\tools\clang\tools\driver\driver.cpp:380:0
 7:21.33 #55 0x01fe55cc _scrt_common_main_seh
f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:255:0
 7:21.33 #56 0x76f57c04 BaseThreadInitThunk
(C:\windows\SYSTEM32\KERNEL32.DLL+0x17c04)
 7:21.33 #57 0x77a8ab8f __RtlUserThreadStart
(C:\windows\SYSTEM32\ntdll.dll+0x5ab8f)
 7:21.33 #58 0x77a8ab5a _RtlUserThreadStart
(C:\windows\SYSTEM32\ntdll.dll+0x5ab5a)

Attached is a tarball of the runscript and preprocessed source from the crash
message.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20161018/37c47b9c/attachment-0001.html>


More information about the llvm-bugs mailing list