mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-18 13:34:04 +00:00
Add new testcases for instcombine
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3477 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
0712d55512
commit
b81258c278
@ -26,3 +26,23 @@ BB2:
|
|||||||
ret int %B
|
ret int %B
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int %test3(int %A, bool %b) {
|
||||||
|
BB0: br label %Loop
|
||||||
|
|
||||||
|
Loop:
|
||||||
|
%B = phi int [%A, %BB0], [%B, %Loop] ; PHI has same value always.
|
||||||
|
br bool %b, label %Loop, label %Exit
|
||||||
|
Exit:
|
||||||
|
ret int %B
|
||||||
|
}
|
||||||
|
|
||||||
|
int %test3(bool %b) {
|
||||||
|
BB0: ret int 7 ; Loop is unreachable
|
||||||
|
|
||||||
|
Loop:
|
||||||
|
%B = phi int [%B, %L2], [%B, %Loop] ; PHI has same value always.
|
||||||
|
br bool %b, label %L2, label %Loop
|
||||||
|
L2:
|
||||||
|
br label %Loop
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user