mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Add a new testcase for folding an add into a switch
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14586 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c5f143b6e7
commit
80fc86a0b2
@ -135,3 +135,17 @@ bool %test21(uint %x) {
|
||||
%y = seteq uint %t, 123
|
||||
ret bool %y
|
||||
}
|
||||
|
||||
int %test22(uint %V) {
|
||||
%V2 = add uint %V, 10
|
||||
switch uint %V2, label %Default [
|
||||
uint 20, label %Lab1
|
||||
uint 30, label %Lab2
|
||||
]
|
||||
Default:
|
||||
ret int 123
|
||||
Lab1:
|
||||
ret int 12312
|
||||
Lab2:
|
||||
ret int 1231231
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user