mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-15 04:30:12 +00:00
c41ab22492
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4934 91177308-0d34-0410-b5e6-96231b3b80d8
14 lines
272 B
LLVM
14 lines
272 B
LLVM
; RUN: if as < %s | opt -instcombine | dis | grep add
|
|
; RUN: then exit 1
|
|
; RUN: else exit 0
|
|
; RUN: fi
|
|
|
|
int %test(int %A) {
|
|
%A.neg = sub int 0, %A
|
|
%.neg = sub int 0, 1
|
|
%X = add int %.neg, 1
|
|
%Y.neg.ra = add int %A, %X
|
|
%r = add int %A.neg, %Y.neg.ra
|
|
ret int %r
|
|
}
|