mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-28 07:05:03 +00:00
2e7e4f2e01
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32137 91177308-0d34-0410-b5e6-96231b3b80d8
25 lines
1.1 KiB
Plaintext
25 lines
1.1 KiB
Plaintext
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep movs
|
|
declare void %llvm.memcpy.i32(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 void %llvm.memcpy.i32(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 void %llvm.memcpy.i32(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 void %llvm.memcpy.i32(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
|
|
}
|