http://llvm.org/bugs/show_bug.cgi?id=6469
Summary: llvm-as asserts on invalid IR involving trailing comma
with a misleading message
Product: new-bugs
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: minor
Priority: P5
Component: new bugs
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
The invalid IR below causes llvm-as from trunkish (r97475) to assert with the
following message:
While deleting: i32 %x
Use still stuck around after Def is destroyed: <badref> = add i32 %x, %x
; <i32> [#uses=0]
Use still stuck around after Def is destroyed: <badref> = add i32 %x, %x
; <i32> [#uses=0]
llvm-as: src/llvm/trunk/lib/VMCore/Value.cpp:75: virtual llvm::Value::~Value():
Assertion `use_empty() && "Uses remain when a value is destroyed!"' failed.
Stack dump:
0. Program arguments: llvm-as
0
define void @f() {
%x = add i32 undef, undef
%y = add i32 %x, %x,
ret void
}
The problem is obviously the trailing comma on the %y line.
Appending an extraneous comma to other kinds of instructions will cause the
same assertion to fire. The following causes it to print just "llvm-as:" before
exiting:
define void @f() {
%x = load i32* undef,
ret void
}
--
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs