YouCompleteMe/cpp/llvm/test/Transforms/IPConstantProp/2008-06-09-WeakProp.ll

16 lines
278 B
LLVM
Raw Normal View History

2012-07-05 20:51:06 -04:00
; RUN: opt < %s -ipconstprop -S | grep {ret i32 %r}
; Should not propagate the result of a weak function.
; PR2411
define weak i32 @foo() nounwind {
entry:
ret i32 1
}
define i32 @main() nounwind {
entry:
%r = call i32 @foo( ) nounwind
ret i32 %r
}