mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-29 10:32:47 +00:00
ec9a35a6f9
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47793 91177308-0d34-0410-b5e6-96231b3b80d8
18 lines
468 B
LLVM
18 lines
468 B
LLVM
; RUN: llvm-as < %s | opt -adce | llvm-dis | not grep call
|
|
|
|
; The call is not live just because the PHI uses the call retval!
|
|
|
|
define i32 @test(i32 %X) {
|
|
; <label>:0
|
|
br label %Done
|
|
|
|
DeadBlock: ; No predecessors!
|
|
%Y = call i32 @test( i32 0 ) ; <i32> [#uses=1]
|
|
br label %Done
|
|
|
|
Done: ; preds = %DeadBlock, %0
|
|
%Z = phi i32 [ %X, %0 ], [ %Y, %DeadBlock ] ; <i32> [#uses=1]
|
|
ret i32 %Z
|
|
}
|
|
|