mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-20 14:29:27 +00:00
Modernize testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5590 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e14e50d76b
commit
b19fa8d3d6
@ -10,25 +10,22 @@
|
|||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
int %test1(int %A)
|
int %test1(int %A) {
|
||||||
begin
|
|
||||||
%B = add int %A, 0
|
%B = add int %A, 0
|
||||||
ret int %B
|
ret int %B
|
||||||
end
|
}
|
||||||
|
|
||||||
int %test2(int %A)
|
int %test2(int %A) {
|
||||||
begin
|
|
||||||
%B = add int %A, 5
|
%B = add int %A, 5
|
||||||
%C = add int %B, -5
|
%C = add int %B, -5
|
||||||
ret int %C
|
ret int %C
|
||||||
end
|
}
|
||||||
|
|
||||||
int %test3(int %A)
|
int %test3(int %A) {
|
||||||
begin
|
|
||||||
%B = add int %A, 5
|
%B = add int %A, 5
|
||||||
%C = sub int %B, 5 ;; This should get converted to an add
|
%C = sub int %B, 5 ;; This should get converted to an add
|
||||||
ret int %C
|
ret int %C
|
||||||
end
|
}
|
||||||
|
|
||||||
int %test4(int %A, int %B) {
|
int %test4(int %A, int %B) {
|
||||||
%C = sub int 0, %A
|
%C = sub int 0, %A
|
||||||
|
Loading…
x
Reference in New Issue
Block a user