[LLVMbugs] [Bug 22035] New: Crash when build iostream.cpp from libc++ on Windows

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Dec 26 22:58:30 PST 2014


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

            Bug ID: 22035
           Summary: Crash when build iostream.cpp from libc++ on Windows
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Windows 2000
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: abyss.7 at gmail.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Initially, I try to build libc++ on Windows. But it doesn't show any
stacktrace, so I took generated cpp+sh and rerun on Linux to get stacktrace.
The only difference in a command-line is the path to clang++.

Clang++ crashes with a following output:

#0 0x23edc58 llvm::sys::PrintStackTrace(_IO_FILE*)
(/home/ilezhankin/.local/bin/clang+0x23edc58)
#1 0x23ef14b (/home/ilezhankin/.local/bin/clang+0x23ef14b)
#2 0x7f3dc4f4c0d0 __restore_rt (/lib64/libpthread.so.0+0x100d0)
#3 0x22d91e1 llvm::Constant::isNullValue() const
(/home/ilezhankin/.local/bin/clang+0x22d91e1)
#4 0x22015b9 llvm::TargetLoweringObjectFile::getKindForGlobal(llvm::GlobalValue
const*, llvm::TargetMachine const&)
(/home/ilezhankin/.local/bin/clang+0x22015b9)
#5 0x2202252
llvm::TargetMachine::getNameWithPrefix(llvm::SmallVectorImpl<char>&,
llvm::GlobalValue const*, llvm::Mangler&, bool) const
(/home/ilezhankin/.local/bin/clang+0x2202252)
#6 0x22022fa llvm::TargetMachine::getSymbol(llvm::GlobalValue const*,
llvm::Mangler&) const (/home/ilezhankin/.local/bin/clang+0x22022fa)
#7 0x1e01df6 llvm::AsmPrinter::EmitGlobalVariable(llvm::GlobalVariable const*)
(/home/ilezhankin/.local/bin/clang+0x1e01df6)
#8 0x1e05320 llvm::AsmPrinter::doFinalization(llvm::Module&)
(/home/ilezhankin/.local/bin/clang+0x1e05320)
#9 0x238db19 llvm::FPPassManager::doFinalization(llvm::Module&)
(/home/ilezhankin/.local/bin/clang+0x238db19)
#10 0x238df65 llvm::legacy::PassManagerImpl::run(llvm::Module&)
(/home/ilezhankin/.local/bin/clang+0x238df65)
#11 0x8ee28d clang::EmitBackendOutput(clang::DiagnosticsEngine&,
clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions
const&, llvm::StringRef, llvm::Module*, clang::BackendAction,
llvm::raw_ostream*) (/home/ilezhankin/.local/bin/clang+0x8ee28d)
#12 0x8e442e (/home/ilezhankin/.local/bin/clang+0x8e442e)
#13 0xa8a023 clang::ParseAST(clang::Sema&, bool, bool)
(/home/ilezhankin/.local/bin/clang+0xa8a023)
#14 0x8e32fc clang::CodeGenAction::ExecuteAction()
(/home/ilezhankin/.local/bin/clang+0x8e32fc)
#15 0x714aa9 clang::FrontendAction::Execute()
(/home/ilezhankin/.local/bin/clang+0x714aa9)
#16 0x6e9143 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(/home/ilezhankin/.local/bin/clang+0x6e9143)
#17 0x6cf75a clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
(/home/ilezhankin/.local/bin/clang+0x6cf75a)
#18 0x6c6be6 cc1_main(llvm::ArrayRef<char const*>, char const*, void*)
(/home/ilezhankin/.local/bin/clang+0x6c6be6)
#19 0x6ce2ad main (/home/ilezhankin/.local/bin/clang+0x6ce2ad)
#20 0x7f3dc416cfe0 __libc_start_main
/usr/src/debug/glibc-2.20/csu/libc-start.c:323:0
#21 0x6c6871 _start (/home/ilezhankin/.local/bin/clang+0x6c6871)
Stack dump:
0.      Program arguments: clang++ -cc1 -triple i686-pc-windows-msvc -emit-obj
-disable-free -disable-llvm-verifier -main-file-name iostream.cpp
-mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim
-fmath-errno -masm-verbose -mconstructor-aliases -target-cpu pentium4
-dwarf-column-info -nostdinc++ -D _LIBCPP_DLL -D cxx_EXPORTS -D
_CRT_SECURE_NO_WARNINGS -D _HAS_CHAR16_T_LANGUAGE_SUPPORT -D _HAS_EXCEPTIONS=0
-O3 -Wall -Wno-unused-parameter -Wwrite-strings -Wno-long-long -Wno-error
-pedantic -std=c++1y -fdeprecated-macro -ferror-limit 19 -fmessage-length 0
-mstackrealign -fms-extensions -fms-compatibility-version=17.00
-fdelayed-template-parsing -fobjc-runtime=gcc -fdiagnostics-show-option
-vectorize-loops -vectorize-slp -x c++ iostream-837ead.cpp 
1.      <eof> parser at end of file
2.      Code generation
iostream-837ead.sh: line 1:  8222 Segmentation fault      (core dumped)
"clang++" "-cc1" "-triple" "i686-pc-windows-msvc" "-emit-obj" "-disable-free"
"-disable-llvm-verifier" "-main-file-name" "iostream.cpp" "-mrelocation-model"
"pic" "-pic-level" "2" "-mthread-model" "posix" "-mdisable-fp-elim"
"-fmath-errno" "-masm-verbose" "-mconstructor-aliases" "-target-cpu" "pentium4"
"-dwarf-column-info" "-nostdinc++" "-D" "_LIBCPP_DLL" "-D" "cxx_EXPORTS" "-D"
"_CRT_SECURE_NO_WARNINGS" "-D" "_HAS_CHAR16_T_LANGUAGE_SUPPORT" "-D"
"_HAS_EXCEPTIONS=0" "-O3" "-Wall" "-Wno-unused-parameter" "-Wwrite-strings"
"-Wno-long-long" "-Wno-error" "-pedantic" "-std=c++1y" "-fdeprecated-macro"
"-ferror-limit" "19" "-fmessage-length" "0" "-mstackrealign" "-fms-extensions"
"-fms-compatibility-version=17.00" "-fdelayed-template-parsing"
"-fobjc-runtime=gcc" "-fdiagnostics-show-option" "-vectorize-loops"
"-vectorize-slp" "-x" "c++" "iostream-837ead.cpp"

-- 
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/20141227/4b720e91/attachment.html>


More information about the llvm-bugs mailing list