8e12397d70
Former-commit-id: 7f59f7e792705db773f1caecdaa823092f4e2927
16 lines
278 B
LLVM
16 lines
278 B
LLVM
; 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
|
|
}
|
|
|