mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-30 02:32:08 +00:00
6feb333695
* merge two weak functions by making them both alias a third non-weak fn * don't reimplement CallSite::hasArgument * whitelist the safe linkage types git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58568 91177308-0d34-0410-b5e6-96231b3b80d8
12 lines
240 B
LLVM
12 lines
240 B
LLVM
; RUN: llvm-as < %s | opt -mergefunc | llvm-dis | grep {alias weak} | count 2
|
|
|
|
define weak i32 @sum(i32 %x, i32 %y) {
|
|
%sum = add i32 %x, %y
|
|
ret i32 %sum
|
|
}
|
|
|
|
define weak i32 @add(i32 %x, i32 %y) {
|
|
%sum = add i32 %x, %y
|
|
ret i32 %sum
|
|
}
|