mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-30 07:22:55 +01:00
4ce80b3f86
llvm-svn: 11352
25 lines
1.0 KiB
Plaintext
25 lines
1.0 KiB
Plaintext
; RUN: llvm-as < %s | llc -march=x86 | grep movs
|
|
declare sbyte* %llvm.memcpy(sbyte* %A, sbyte* %B, uint %amt, uint %align)
|
|
|
|
%A = global [1000 x int] zeroinitializer
|
|
%B = global [1000 x int] zeroinitializer
|
|
|
|
|
|
void %main() {
|
|
; dword copy
|
|
call sbyte* %llvm.memcpy(sbyte* cast (int* getelementptr ([1000 x int]* %A, long 0, long 0) to sbyte*),
|
|
sbyte* cast (int* getelementptr ([1000 x int]* %B, long 0, long 0) to sbyte*),
|
|
uint 4000, uint 4)
|
|
|
|
; word copy
|
|
call sbyte* %llvm.memcpy(sbyte* cast (int* getelementptr ([1000 x int]* %A, long 0, long 0) to sbyte*),
|
|
sbyte* cast (int* getelementptr ([1000 x int]* %B, long 0, long 0) to sbyte*),
|
|
uint 4000, uint 2)
|
|
|
|
; byte copy
|
|
call sbyte* %llvm.memcpy(sbyte* cast (int* getelementptr ([1000 x int]* %A, long 0, long 0) to sbyte*),
|
|
sbyte* cast (int* getelementptr ([1000 x int]* %B, long 0, long 0) to sbyte*),
|
|
uint 4000, uint 1)
|
|
ret void
|
|
}
|