mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-21 16:31:16 +00:00
f44809c898
There were transforms whose *intent* was to downgrade the linkage of external objects to have internal linkage. However, it fired on things with private linkage as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212104 91177308-0d34-0410-b5e6-96231b3b80d8
24 lines
341 B
LLVM
24 lines
341 B
LLVM
; RUN: opt < %s -globalopt -S | FileCheck %s
|
|
|
|
global i32 0
|
|
; CHECK-DAG: @0 = internal global i32 0
|
|
|
|
private global i32 0
|
|
; CHECK-DAG: @1 = private global i32 0
|
|
|
|
define i32* @2() {
|
|
ret i32* @0
|
|
}
|
|
; CHECK-DAG: define internal fastcc i32* @2()
|
|
|
|
define i32* @f() {
|
|
entry:
|
|
call i32* @2()
|
|
ret i32* %0
|
|
}
|
|
|
|
define i32* @g() {
|
|
entry:
|
|
ret i32* @1
|
|
}
|