[LLVMbugs] [Bug 11402] New: The attached file causes clang to SEGV

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Nov 18 11:50:06 PST 2011


http://llvm.org/bugs/show_bug.cgi?id=11402

             Bug #: 11402
           Summary: The attached file causes clang to SEGV
           Product: clang
           Version: unspecified
          Platform: Macintosh
        OS/Version: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: rhl at astro.princeton.edu
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified


$ uname -a 
Darwin ast1112.astro.princeton.edu 11.2.0 Darwin Kernel Version 11.2.0: Tue Aug
 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 x86_64
$ clang++ --version
Apple clang version 3.0 (tags/Apple/clang-211.10.1) (based on LLVM 3.0svn)
Target: x86_64-apple-darwin11.2.0
Thread model: posix
$ clang++ -Wparentheses Frame_pp.cc -c
In file included from src/definition/Frame.cc:1:
In file included from src/definition/Frame.cc:1:
In file included from include/lsst/meas/multifit/definition/Frame.h:28:
In file included from include/lsst/meas/multifit/constants.h:28:
In file included from /Users/rhl/LSST/afw/include/lsst/afw/image/Wcs.h:34:
In file included from /Users/rhl/LSST/afw/include/lsst/afw/image/Image.h:45:
In file included from /Users/rhl/LSST/afw/include/lsst/afw/image/Utils.h:47:
In file included from
/Users/rhl/LSST/afw/include/lsst/afw/formatters/ImageFormatter.h:47:
In file included from
/u/lsst/products/DarwinX86/daf_persistence/4.6.0.2/include/lsst/daf/persistence.h:39:
In file included from
/u/lsst/products/DarwinX86/daf_persistence/4.6.0.2/include/lsst/daf/persistence/BoostStorage.h:48:
In file included from
/u/lsst/products/DarwinX86/daf_persistence/4.6.0.2/include/lsst/daf/persistence/Storage.h:53:
In file included from
/u/lsst/products/DarwinX86/pex_policy/4.6.0.1+1/include/lsst/pex/policy.h:29:
In file included from
/u/lsst/products/DarwinX86/pex_policy/4.6.0.1+1/include/lsst/pex/policy/Dictionary.h:38:
In file included from
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex.hpp:31:
In file included from
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/regex.hpp:70:
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1027:34:
warning: 
      equality comparison with extraneous parentheses [-Wparentheses]
            else if((state->type == syntax_element_long_set_rep))
                     ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1027:34:
note: 
      remove extraneous parentheses around the comparison to silence this
warning
            else if((state->type == syntax_element_long_set_rep))
                    ~            ^                             ~
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1027:34:
note: 
      use '=' to turn this equality comparison into an assignment
            else if((state->type == syntax_element_long_set_rep))
                                 ^~
                                 =
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1328:28:
warning: 
      equality comparison with extraneous parentheses [-Wparentheses]
               if((p->type == syntax_element_recurse))
                   ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1328:28:
note: 
      remove extraneous parentheses around the comparison to silence this
warning
               if((p->type == syntax_element_recurse))
                  ~        ^                        ~
/u/lsst/products/DarwinX86/external/boost/1.47.0+3/include/boost/regex/v4/basic_regex_creator.hpp:1328:28:
note: 
      use '=' to turn this equality comparison into an assignment
               if((p->type == syntax_element_recurse))
                           ^~
                           =
In file included from src/definition/Frame.cc:1:
src/definition/Frame.cc:91:37: error: no member named 'sqrt' in
'Eigen::Matrix<double, -1, 1, 0, -1,
      1>'
        Eigen::VectorXd tmp2 = tmp. sqrt().inverse().matrix();
                               ~~~  ^
src/definition/Frame.cc:94:17: error: 'operator+=' is a protected member of
      'Eigen::ArrayBase<lsst::ndarray::EigenView<double, 1, 1, Eigen::ArrayXpr,
-1, 1> >'
        weights += tmp2;
        ~~~~~~~ ^  ~~~~
/u/lsst/products/DarwinX86/eigen/3.0.2+1/include/Eigen/src/Core/ArrayBase.h:176:46:
note: declared
      protected here
    template<typename OtherDerived> Derived& operator+=(const
MatrixBase<OtherDerived>& )
                                             ^
In file included from src/definition/Frame.cc:1:
src/definition/Frame.cc:94:17: error: 'operator+=' is a private member of
      'Eigen::ArrayBase<lsst::ndarray::EigenView<double, 1, 1, Eigen::ArrayXpr,
-1, 1> >'
        weights += tmp2;
        ~~~~~~~ ^  ~~~~
src/definition/Frame.cc:111:23: note: in instantiation of function template
specialization
      'lsst::meas::multifit::definition::Frame::make<float>' requested here
template Frame Frame::make<float>(
                      ^
0  clang             0x000000010556e312 _ZL15PrintStackTracePv + 34
1  clang             0x000000010556e7e9 _ZL13SignalHandleri + 633
2  libsystem_c.dylib 0x00007fff91cd3cfa _sigtramp + 26
3  libsystem_c.dylib 000000000000000000 _sigtramp + 18446603338070016800
4  clang             0x0000000104c318fa
_ZL20CheckEffectiveAccessRN5clang4SemaERKN12_GLOBAL__N_116EffectiveContextENS_14SourceLocationERNS2_12AccessTargetE
+ 1802
5  clang             0x0000000104c31000
_ZL11CheckAccessRN5clang4SemaENS_14SourceLocationERN12_GLOBAL__N_112AccessTargetE
+ 240
6  clang             0x0000000104c69ae4
clang::Sema::CheckMemberOperatorAccess(clang::SourceLocation, clang::Expr*,
clang::Expr*, clang::DeclAccessPair) + 500
7  clang             0x0000000104c329c0
clang::Sema::CreateOverloadedBinOp(clang::SourceLocation, unsigned int,
clang::UnresolvedSetImpl const&, clang::Expr*, clang::Expr*) + 1792
8  clang             0x0000000104c563b7 clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformExpr(clang::Expr*) + 11959
9  clang             0x0000000104c8b952 clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformStmt(clang::Stmt*) + 8018
10 clang             0x0000000104c8bc43 clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformCompoundStmt(clang::CompoundStmt*,
bool) + 195
11 clang             0x0000000104c8a48f clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformStmt(clang::Stmt*) + 2703
12 clang             0x0000000104c8bc43 clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformCompoundStmt(clang::CompoundStmt*,
bool) + 195
13 clang             0x0000000104c8a48f clang::TreeTransform<(anonymous
namespace)::TemplateInstantiator>::TransformStmt(clang::Stmt*) + 2703
14 clang             0x0000000104c899f3 clang::Sema::SubstStmt(clang::Stmt*,
clang::MultiLevelTemplateArgumentList const&) + 51
15 clang             0x0000000104c89343
clang::Sema::InstantiateFunctionDefinition(clang::SourceLocation,
clang::FunctionDecl*, bool, bool) + 1955
16 clang             0x0000000104c515cd
clang::Sema::ActOnExplicitInstantiation(clang::Scope*, clang::SourceLocation,
clang::SourceLocation, clang::Declarator&) + 3885
17 clang             0x00000001047f71a6
clang::Parser::ParseDeclarationAfterDeclaratorAndAttributes(clang::Declarator&,
clang::Parser::ParsedTemplateInfo const&) + 102
18 clang             0x0000000104e351eb
clang::Parser::ParseSingleDeclarationAfterTemplate(unsigned int,
clang::Parser::ParsedTemplateInfo const&,
clang::Parser::ParsingDeclRAIIObject&, clang::SourceLocation&,
clang::AccessSpecifier) + 1307
19 clang             0x0000000104c20651
clang::Parser::ParseDeclarationStartingWithTemplate(unsigned int,
clang::SourceLocation&, clang::AccessSpecifier) + 257
20 clang             0x0000000104e22c24
clang::Parser::ParseDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&) + 404
21 clang             0x00000001047ed46b
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::Parser::ParsingDeclSpec*) + 1403
22 clang             0x0000000104e25e38
clang::Parser::ParseInnerNamespace(std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, std::vector<clang::IdentifierInfo*,
std::allocator<clang::IdentifierInfo*> >&, std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, unsigned int, clang::SourceLocation&,
clang::SourceLocation&, clang::ParsedAttributes&, clang::SourceLocation&) + 200
23 clang             0x0000000104c0644e clang::Parser::ParseNamespace(unsigned
int, clang::SourceLocation&, clang::SourceLocation) + 3198
24 clang             0x0000000104e22d66
clang::Parser::ParseDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&) + 726
25 clang             0x00000001047ed46b
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::Parser::ParsingDeclSpec*) + 1403
26 clang             0x0000000104e25e38
clang::Parser::ParseInnerNamespace(std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, std::vector<clang::IdentifierInfo*,
std::allocator<clang::IdentifierInfo*> >&, std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, unsigned int, clang::SourceLocation&,
clang::SourceLocation&, clang::ParsedAttributes&, clang::SourceLocation&) + 200
27 clang             0x0000000104c0644e clang::Parser::ParseNamespace(unsigned
int, clang::SourceLocation&, clang::SourceLocation) + 3198
28 clang             0x0000000104e22d66
clang::Parser::ParseDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&) + 726
29 clang             0x00000001047ed46b
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::Parser::ParsingDeclSpec*) + 1403
30 clang             0x0000000104e25e38
clang::Parser::ParseInnerNamespace(std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, std::vector<clang::IdentifierInfo*,
std::allocator<clang::IdentifierInfo*> >&, std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, unsigned int, clang::SourceLocation&,
clang::SourceLocation&, clang::ParsedAttributes&, clang::SourceLocation&) + 200
31 clang             0x0000000104c0644e clang::Parser::ParseNamespace(unsigned
int, clang::SourceLocation&, clang::SourceLocation) + 3198
32 clang             0x0000000104e22d66
clang::Parser::ParseDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&) + 726
33 clang             0x00000001047ed46b
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::Parser::ParsingDeclSpec*) + 1403
34 clang             0x0000000104e25e38
clang::Parser::ParseInnerNamespace(std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, std::vector<clang::IdentifierInfo*,
std::allocator<clang::IdentifierInfo*> >&, std::vector<clang::SourceLocation,
std::allocator<clang::SourceLocation> >&, unsigned int, clang::SourceLocation&,
clang::SourceLocation&, clang::ParsedAttributes&, clang::SourceLocation&) + 200
35 clang             0x0000000104c0644e clang::Parser::ParseNamespace(unsigned
int, clang::SourceLocation&, clang::SourceLocation) + 3198
36 clang             0x0000000104e22d66
clang::Parser::ParseDeclaration(clang::ASTOwningVector<clang::Stmt*, 32u>&,
unsigned int, clang::SourceLocation&,
clang::Parser::ParsedAttributesWithRange&) + 726
37 clang             0x00000001047ed46b
clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&,
clang::Parser::ParsingDeclSpec*) + 1403
38 clang             0x00000001047ece7d
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 237
39 clang             0x00000001047cf1fd clang::ParseAST(clang::Sema&, bool) +
301
40 clang             0x00000001047cdcaf clang::CodeGenAction::ExecuteAction() +
671
41 clang             0x00000001047b9a9b
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 875
42 clang             0x00000001047b7b18
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 2696
43 clang             0x00000001047ac315 cc1_main(char const**, char const**,
char const*, void*) + 5333
44 clang             0x000000010478f47b main + 667
45 clang             0x000000010478f1d4 start + 52
46 clang             0x000000000000002a start + 18446744069339549322
Stack dump:
0.      Program arguments: /usr/bin/clang -cc1 -triple
x86_64-apple-macosx10.7.2 -emit-obj -mrelax-all -disable-free
-disable-llvm-verifier -main-file-name Frame_pp.cc -pic-level 1
-mdisable-fp-elim -relaxed-aliasing -masm-verbose -munwind-tables -target-cpu
core2 -target-linker-version 127.2 -coverage-file Frame_pp.o -resource-dir
/usr/bin/../lib/clang/3.0 -Wparentheses -fdeprecated-macro -ferror-limit 19
-fmessage-length 100 -stack-protector 1 -fblocks -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fcolor-diagnostics -o Frame_pp.o -x c++ Frame_pp.cc 
1.      src/definition/Frame.cc:115:2: current parser token ';'
2.      src/definition/Frame.cc:7:1: parsing namespace 'lsst'
3.      src/definition/Frame.cc:7:18: parsing namespace 'meas'
4.      src/definition/Frame.cc:7:35: parsing namespace 'multifit'
5.      src/definition/Frame.cc:27:1: parsing namespace 'definition'
clang: error: unable to execute command: Segmentation fault: 11
clang: error: clang frontend command failed due to signal 2 (use -v to see
invocation)

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list