Mercurial > hg > CbC > CbC_llvm
view test/Other/extract-linkonce.ll @ 35:503e14e069e4
update to LLVM 3.5
author | Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 12 Dec 2013 23:38:21 +0900 |
parents | 95c75e76d11b |
children |
line wrap: on
line source
; RUN: llvm-extract -func foo -S < %s | FileCheck %s ; RUN: llvm-extract -delete -func foo -S < %s | FileCheck --check-prefix=DELETE %s ; Test that linkonce definitions are mapped to weak so that they are not ; dropped. ; CHECK: @bar = external global i32 ; CHECK: define weak i32* @foo() { ; CHECK-NEXT: ret i32* @bar ; CHECK-NEXT: } ; DELETE: @bar = weak global i32 42 ; DELETE: declare i32* @foo() @bar = linkonce global i32 42 define linkonce i32* @foo() { ret i32* @bar } define void @g() { call i32* @foo() ret void }