mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-24 22:32:47 +00:00
d52e1b0dbe
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29927 91177308-0d34-0410-b5e6-96231b3b80d8
26 lines
703 B
LLVM
26 lines
703 B
LLVM
; RUN: llvm-as < %s | opt -analyze -datastructure-gc -dsgc-check-flags=Xn:SMR &&
|
|
; RUN: llvm-as < %s | opt -analyze -datastructure-gc -dsgc-check-flags=X:SMR
|
|
|
|
declare void %llvm.memcpy.i32(sbyte*, sbyte*, uint, uint)
|
|
declare void %llvm.memmove.i32(sbyte*, sbyte*, uint, uint)
|
|
|
|
void %test() {
|
|
%X = alloca int
|
|
%Y = alloca int
|
|
%x = cast int* %X to sbyte*
|
|
%y = cast int* %Y to sbyte*
|
|
store int 4, int* %X
|
|
call void %llvm.memcpy.i32(sbyte* %x, sbyte* %y, uint 4, uint 4)
|
|
ret void
|
|
}
|
|
|
|
void %test2() {
|
|
%Xn = alloca int
|
|
%Yn = alloca int
|
|
%xn = cast int* %Xn to sbyte*
|
|
%yn = cast int* %Yn to sbyte*
|
|
store int 4, int* %Xn
|
|
call void %llvm.memmove.i32(sbyte* %xn, sbyte* %yn, uint 4, uint 4)
|
|
ret void
|
|
}
|