[llvm-bugs] [Bug 26152] New: Linker wronlgy renames an external function
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Jan 14 17:15:22 PST 2016
https://llvm.org/bugs/show_bug.cgi?id=26152
Bug ID: 26152
Summary: Linker wronlgy renames an external function
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Linker
Assignee: unassignedbugs at nondot.org
Reporter: eugeni.stepanov at gmail.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
I'm linking 2 modules, where the first calls an external function A(), and the
second defines A() and also an alias for it.
The resulting module does not export A(). Instead it exports A.1().
The behavior depends on the order of modules in the link command line.
$ cat 1.ll
define void @B() {
call void @A()
ret void
}
declare void @A()
$ cat 2.ll
@C = alias void (), void ()* @A
define void @D() {
call void @C()
ret void
}
define void @A() {
ret void
}
$ llvm-link 1.ll 2.ll -S -o -
; ModuleID = 'llvm-link'
@C = alias void (), void ()* @A.1
define void @B() {
call void @A.1()
ret void
}
define void @D() {
call void @C()
ret void
}
define void @A.1() {
ret void
}
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160115/17d6a93b/attachment.html>
More information about the llvm-bugs
mailing list