[LLVMbugs] [Bug 11202] New: Block addresses can refer to non-existent symbols
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Fri Oct 21 09:43:57 PDT 2011
http://llvm.org/bugs/show_bug.cgi?id=11202
Summary: Block addresses can refer to non-existent symbols
Product: libraries
Version: trunk
Platform: PC
OS/Version: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: Common Code Generator Code
AssignedTo: unassignedbugs at nondot.org
ReportedBy: Pidgeot18 at gmail.com
CC: llvmbugs at cs.uiuc.edu
This is a minimized test case:
@bb = constant [1 x i8*] [i8* blockaddress(@main, %mid)]
define void @main() {
entry:
br label %l1
l1:
%a = zext i1 0 to i32
br label %mid
mid:
br label %l2
l2:
%b = zext i1 0 to i32
br label %l1
}
If you run this with llc, the output assembly/object file will refuse to
compile with an undefined reference to '.Ltmp3'. Remove any instruction, or
change any branch, and the code will assemble properly.
It seems that the cases where this problem occurs are when an empty basic
block:
1. Has its address taken
2. Is sandwiched between two non-empty basic blocks
3. The outer two basic blocks get optimized into nothing.
--
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