[LLVMbugs] [Bug 11879] New: Internal compiler error (assertion) during per-module optimization pass while building libc++

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Jan 28 18:34:43 PST 2012


             Bug #: 11879
           Summary: Internal compiler error (assertion) during per-module
                    optimization pass while building libc++
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: hivemaster at hotmail.de
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

With Clang revision 148703, compiling r148629 of libc++ results in an assertion
during the opimization pass of locale.cpp. The preprocessed source is attached.

Crash report:
clang: /home/xeo/llvm/include/llvm/ADT/OwningPtr.h:34:
llvm::OwningPtr<T>::OwningPtr(const llvm::OwningPtr<T>&) [with T =
llvm::UndefValue]: Assertion `RHS.Ptr == 0 && "Only null OwningPtr's are
copyable!"' failed.
0  clang           0x00000000027a882e
1  clang           0x00000000027a8621
2  libpthread.so.0 0x00007f142eaa5f60
3  libc.so.6       0x00007f142ddb8165 gsignal + 53
4  libc.so.6       0x00007f142ddbaf70 abort + 384
5  libc.so.6       0x00007f142ddb12b1 __assert_fail + 241
6  clang           0x000000000264ee0a
7  clang           0x000000000264ed6c
8  clang           0x000000000264af58
9  clang           0x0000000002648b07
10 clang           0x0000000002646877
11 clang           0x000000000263e13c llvm::UndefValue::get(llvm::Type*) + 50
12 clang           0x00000000023535e4
13 clang           0x0000000002731d68
llvm::MPPassManager::runOnModule(llvm::Module&) + 456
14 clang           0x000000000273227e llvm::PassManagerImpl::run(llvm::Module&)
+ 130
15 clang           0x00000000027327b9 llvm::PassManager::run(llvm::Module&) +
16 clang           0x0000000000cd8257
17 clang           0x0000000000cd8377
clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::CodeGenOptions
const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::Module*,
clang::BackendAction, llvm::raw_ostream*) + 140
18 clang           0x0000000000cd4444
19 clang           0x0000000000e7fc31 clang::ParseAST(clang::Sema&, bool) + 761
20 clang           0x0000000000b43733 clang::ASTFrontendAction::ExecuteAction()
+ 265
21 clang           0x0000000000cd2fb4 clang::CodeGenAction::ExecuteAction() +
22 clang           0x0000000000b4338f clang::FrontendAction::Execute() + 213
23 clang           0x0000000000b1cd2b
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 679
24 clang           0x0000000000aeebc7
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1002
25 clang           0x0000000000addb67 cc1_main(char const**, char const**, char
const*, void*) + 990
26 clang           0x0000000000aea209 main + 484
27 libc.so.6       0x00007f142dda4c4d __libc_start_main + 253
28 clang           0x0000000000adcde9
Stack dump:
0.    Program arguments: /usr/local/bin/clang -cc1 -triple
x86_64-unknown-linux-gnu -emit-obj -disable-free -main-file-name locale.cpp
-pic-level 2 -masm-verbose -mconstructor-aliases -munwind-tables -target-cpu
x86-64 -target-linker-version 2.20.1 -momit-leaf-frame-pointer -g
-coverage-file locale.o -nostdinc++ -resource-dir
/usr/local/bin/../lib/clang/3.1 -I ../include -fmodule-cache-path
/var/tmp/clang-module-cache -internal-isystem /usr/local/include
-internal-isystem /usr/local/bin/../lib/clang/3.1/include
-internal-externc-isystem /include -internal-externc-isystem /usr/include -Os
-Wall -Wextra -Wshadow -Wconversion -Wnewline-eof -Wpadded -Wmissing-prototypes
-Wstrict-aliasing=2 -Wstrict-overflow=4 -std=c++0x -fdeprecated-macro
-fdebug-compilation-dir /home/xeo/libcxx/lib -ferror-limit 19 -fmessage-length
80 -mstackrealign -fgnu-runtime -fobjc-runtime-has-arc -fobjc-runtime-has-weak
-fobjc-fragile-abi -fcxx-exceptions -fexceptions -fdiagnostics-show-option
-fcolor-diagnostics -o locale.o -x c++ ../src/locale.cpp 
1.    <eof> parser at end of file
2.    Per-module optimization passes
3.    Running pass 'Interprocedural Sparse Conditional Constant Propagation' on
module '../src/locale.cpp'.
clang: error: unable to execute command: Aborted
clang: error: clang frontend command failed due to signal (use -v to see
clang: note: diagnostic msg: Please submit a bug report to
http://llvm.org/bugs/ and include command line arguments and all diagnostic
clang: note: diagnostic msg: Preprocessed source(s) and associated run
script(s) are located at:
clang: note: diagnostic msg: /tmp/locale-dkWoca.ii
clang: note: diagnostic msg: /tmp/locale-dkWoca.sh

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