mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-20 09:30:43 +00:00
14 lines
246 B
LLVM
14 lines
246 B
LLVM
|
; RUN: llvm-as < %s | opt -ds-aa -load-vn -gcse -instcombine | llvm-dis | not grep sub
|
||
|
|
||
|
void %bar(int* %p) {
|
||
|
ret void
|
||
|
}
|
||
|
|
||
|
int %foo(int* %a) {
|
||
|
%b = load int* %a
|
||
|
call void %bar(int* %a)
|
||
|
%d = load int* %a
|
||
|
%e = sub int %b, %d
|
||
|
ret int %e
|
||
|
}
|