Quuxplusone / LLVMBugzillaTest

0 stars 0 forks source link

Assertion while building compiler-rt #12963

Open Quuxplusone opened 12 years ago

Quuxplusone commented 12 years ago
Bugzilla Link PR12860
Status NEW
Importance P enhancement
Reported by Csaba Ráduly (csaba_22@yahoo.co.uk)
Reported on 2012-05-17 05:55:24 -0700
Last modified on 2012-09-27 07:54:34 -0700
Version trunk
Hardware PC Linux
CC alexander.mai@msg-gillardon.de, chandlerc@gmail.com, efriedma@quicinc.com, llvm-bugs@lists.llvm.org
Fixed by commit(s)
Attachments absvdi2-UeZ17f.i (4862 bytes, text/plain)
absvdi2-UeZ17f.sh (877 bytes, text/plain)
Blocks
Blocked by
See also
Created attachment 8577
preprocessed file

make[5]: Entering directory `/local/csaba/LLVM/llvm/projects/compiler-rt'
  COMPILE:   clang_linux/full-i386/i386: /local/csaba/LLVM/llvm/projects/compiler-rt/lib/absvdi2.c
clang: /local/csaba/LLVM/llvm/include/llvm/ADT/DenseMap.h:126: void
llvm::DenseMap<KeyT, ValueT, KeyInfoT>::clear() [with KeyT =
llvm::MachineBasicBlock*, ValueT = <unnamed>::BlockChain*, KeyInfoT =
llvm::DenseMapInfo<llvm::MachineBasicBlock*>]: Assertion `NumEntries == 0 &&
"Node count imbalance!"' failed.
0  clang           0x0000000001f7164f
1  clang           0x0000000001f7360e
2  libpthread.so.0 0x00002b3910f71a90
3  libc.so.6       0x00002b3911b31645 gsignal + 53
4  libc.so.6       0x00002b3911b32c33 abort + 387
5  libc.so.6       0x00002b3911b2a329 __assert_fail + 233
6  clang           0x0000000001b01c25
7  clang           0x0000000001eb64df
llvm::FPPassManager::runOnFunction(llvm::Function&) + 623
8  clang           0x0000000001eb6583
llvm::FPPassManager::runOnModule(llvm::Module&) + 51
9  clang           0x0000000001eb6024
llvm::MPPassManager::runOnModule(llvm::Module&) + 564
10 clang           0x0000000001eb6180 llvm::PassManagerImpl::run(llvm::Module&)
+ 160
11 clang           0x0000000000819fb1
clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::CodeGenOptions
const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::Module*,
clang::BackendAction, llvm::raw_ostream*) + 1889
12 clang           0x0000000000817227
13 clang           0x000000000097db6c clang::ParseAST(clang::Sema&, bool, bool)
+ 460
14 clang           0x00000000008158b4 clang::CodeGenAction::ExecuteAction() + 68
15 clang           0x00000000006b2ac2
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 338
16 clang           0x0000000000696246
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1366
17 clang           0x000000000068ad88 cc1_main(char const**, char const**, char
const*, void*) + 1608
18 clang           0x0000000000695630 main + 7024
19 libc.so.6       0x00002b3911b1d586 __libc_start_main + 230
20 clang           0x00000000006885a9
Stack dump:
0.      Program arguments: /local/csaba/LLVM/build-
release/Release+Asserts/bin/clang -cc1 -triple i386-unknown-linux-gnu -emit-obj
-disable-free -main-file-name absvdi2.c -pic-level 2 -fmath-errno -masm-verbose
-mconstructor-aliases -target-cpu pentium4 -target-linker-version 11 -momit-
leaf-frame-pointer -coverage-file /local/ecsardu/LLVM/build-
release/tools/clang/runtime/compiler-rt/clang_linux/full-
i386/i386/SubDir.lib/absvdi2.o -resource-dir /local/ecsardu/LLVM/build-
release/Release+Asserts/bin/../lib/clang/3.2 -isysroot
/local/ecsardu/LLVM/llvm/projects/compiler-rt/SDKs/linux -fmodule-cache-path
/var/tmp/clang-module-cache -internal-isystem
/local/ecsardu/LLVM/llvm/projects/compiler-rt/SDKs/linux/usr/local/include -
internal-isystem /local/ecsardu/LLVM/build-
release/Release+Asserts/bin/../lib/clang/3.2/include -internal-externc-isystem
/local/ecsardu/LLVM/llvm/projects/compiler-rt/SDKs/linux/include -internal-
externc-isystem /local/ecsardu/LLVM/llvm/projects/compiler-
rt/SDKs/linux/usr/include -O3 -Wall -Werror -fdebug-compilation-dir
/local/ecsardu/LLVM/build-release/tools/clang/runtime/compiler-rt -ferror-limit
19 -fmessage-length 184 -mstackrealign -fgnu-runtime -fobjc-runtime-has-arc -
fobjc-runtime-has-weak -fobjc-fragile-abi -fdiagnostics-show-option -fcolor-
diagnostics -o /local/ecsardu/LLVM/build-release/tools/clang/runtime/compiler-
rt/clang_linux/full-i386/i386/SubDir.lib/absvdi2.o -x c
/local/ecsardu/LLVM/llvm/projects/compiler-rt/lib/absvdi2.c
1.      <eof> parser at end of file
2.      Code generation
3.      Running pass 'Function Pass Manager' on module
'/local/csaba/LLVM/llvm/projects/compiler-rt/lib/absvdi2.c'.
4.      Running pass 'Branch Probability Basic Block Placement' on function
'@__absvdi2'
clang: error: unable to execute command: Aborted
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
clang: note: diagnostic msg: Please submit a bug report to
http://llvm.org/bugs/ and include command line arguments and all diagnostic
information.
clang: note: diagnostic msg: Preprocessed source(s) and associated run
script(s) are located at:
clang: note: diagnostic msg: /tmp/absvdi2-UeZ17f.i
clang: note: diagnostic msg: /tmp/absvdi2-UeZ17f.sh
make[5]: *** [/local/csaba/LLVM/build-release/tools/clang/runtime/compiler-
rt/clang_linux/full-i386/i386/SubDir.lib/absvdi2.o] Error 254
make[5]: Leaving directory `/local/csaba/LLVM/llvm/projects/compiler-rt'
make[4]: *** [BuildRuntimeLibraries] Error 2
make[4]: Leaving directory `/local/csaba/LLVM/build-
release/tools/clang/runtime/compiler-rt'
make[3]: *** [compiler-rt/.makeall] Error 2
make[3]: Leaving directory `/local/csaba/LLVM/build-release/tools/clang/runtime'
make[2]: *** [all] Error 1
make[2]: Leaving directory `/local/csaba/LLVM/build-release/tools/clang'
make[1]: *** [clang/.makeall] Error 2
make[1]: Leaving directory `/local/csaba/LLVM/build-release/tools'
make: *** [all] Error 1

This is on SUSE Linux Enterprise Desktop 11.
clang (--enable-optimize --enable-assertions) was built by gcc version 4.3.2
[gcc-4_3-branch revision 141291] (SUSE Linux)
Quuxplusone commented 12 years ago

Attached absvdi2-UeZ17f.i (4862 bytes, text/plain): preprocessed file

Quuxplusone commented 12 years ago

Attached absvdi2-UeZ17f.sh (877 bytes, text/plain): invocation?

Quuxplusone commented 12 years ago
Doh. This looks suspiciously similar to
http://llvm.org/bugs/show_bug.cgi?id=11971
although the line numbers differ slightly.
Quuxplusone commented 12 years ago
This was r157047, and the solution appears to be:
change -O3 into -O2 in Makefile.config
Quuxplusone commented 12 years ago
Well, that -O2 cured the problem for me also.
SuSe Enterprise 11.1 also.