llvm.org GIT mirror llvm / 44cb0f3 test / tools / lto / opt-level.ll
44cb0f3

Tree @44cb0f3 (Download .tar.gz)

opt-level.ll @44cb0f3

aa01400
7e6adbe
aa01400
7e6adbe
aa01400
44cb0f3
aa01400
 
 
 
 
 
 
 
 
 
 
 
 
 
 
; RUN: llvm-as %s -o %t.o
; RUN: %ld64 -lto_library %llvmshlibdir/libLTO.dylib -arch x86_64 -dylib -mllvm -O0 -o %t.dylib %t.o
; RUN: llvm-nm -no-llvm-bc %t.dylib | FileCheck --check-prefix=CHECK-O0 %s
; RUN: %ld64 -lto_library %llvmshlibdir/libLTO.dylib -arch x86_64 -dylib -mllvm -O2 -o %t.dylib %t.o
; RUN: llvm-nm -no-llvm-bc %t.dylib | FileCheck --check-prefix=CHECK-O2 %s
; REQUIRES: X86

target triple = "x86_64-apple-macosx10.8.0"

; CHECK-O0: t _f1
; CHECK-O2-NOT: _f1
define internal void @f1() {
  ret void
}

; CHECK-O0: T _f2
; CHECK-O2: T _f2
define void @f2() {
  call void @f1()
  ret void
}