[LLVMbugs] [Bug 7015] New: Assertion: Uses remain when a value is destroyed

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sun May 2 06:16:17 PDT 2010


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

           Summary: Assertion: Uses remain when a value is destroyed
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: chris at bubblescope.net
                CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com


Created an attachment (id=4797)
 --> (http://llvm.org/bugs/attachment.cgi?id=4797)
Asserting test case

The attached file, reduced from boost, causes an assertion. This file is, I
believe, fairly minimal.

There are other bugs with this error reported, but this test case is smaller.
It may fix the other problems at the same time.

t.cc:27:1: warning: control may reach end of non-void function [-Wreturn-type]
}
^
While deleting: label %init.check                                               
Use still stuck around after Def is destroyed:  br i1 %tobool, label
%init.check, label %init.end
clang: Value.cpp:75: virtual llvm::Value::~Value(): Assertion `use_empty() &&
"Uses remain when a value is destroyed!"' failed.
0  clang           0x000000000149c282
1  clang           0x000000000149c169
2  libpthread.so.0 0x00007fd05bc3e8f0
3  libc.so.6       0x00007fd05af2ea75 gsignal + 53
4  libc.so.6       0x00007fd05af325c0 abort + 384
5  libc.so.6       0x00007fd05af27941 __assert_fail + 241
6  clang           0x000000000142954e
7  clang           0x0000000001367c5d
8  clang           0x00000000011db740
9  clang           0x00000000011dae2b
10 clang           0x0000000001367d92
11 clang           0x00000000010f7222
12 clang           0x000000000140479f
13 clang           0x0000000001404469
14 clang           0x0000000001404119
15 clang           0x000000000041bdb0
16 clang           0x000000000041ab09
17 clang           0x000000000068f722
18 clang           0x0000000000437014
19 clang           0x0000000000436c7f
20 clang           0x00000000004212ff
21 clang           0x0000000000409172
22 clang           0x000000000040dce2 main + 259
23 libc.so.6       0x00007fd05af19c4d __libc_start_main + 253
24 clang           0x0000000000407b49
Stack dump:
0.      Program arguments: /usr/local/bin/clang -cc1 -triple
x86_64-unknown-linux-gnu -S -disable-free -main-file-name t.cc
-mrelocation-model static -mdisable-fp-elim -mconstructor-aliases
-munwind-tables -target-cpu x86-64 -resource-dir /usr/local/lib/clang/2.0
-ferror-limit 19 -ftemplate-backtrace-limit 10 -fmessage-length 120
-fexceptions -fgnu-runtime -fdiagnostics-show-option -fcolor-diagnostics -o
/tmp/cc-V3NHHe.s -x c++ t.cc 
1.      <eof> parser at end of file
2.      Code generation
3.      Running pass 'Remove unreachable blocks from the CFG' on function
'@_ZN5arrayI12basic_stringE2atEv'
clang: error: compiler command failed due to signal 6 (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