2009-08-25 17:38:29 +02:00
|
|
|
; RUN: llvm-as %s -o /dev/null
|
2006-03-03 00:56:23 +01:00
|
|
|
|
2008-02-17 01:13:09 +01:00
|
|
|
define void @test(i32* %P, i32* %Q) {
|
2006-03-03 00:56:23 +01:00
|
|
|
entry:
|
2008-02-17 01:13:09 +01:00
|
|
|
%tmp.1 = bitcast i32* %P to i8* ; <i8*> [#uses=3]
|
|
|
|
%tmp.3 = bitcast i32* %Q to i8* ; <i8*> [#uses=4]
|
|
|
|
tail call void @llvm.memcpy.i32( i8* %tmp.1, i8* %tmp.3, i32 100000, i32 1 )
|
|
|
|
tail call void @llvm.memcpy.i64( i8* %tmp.1, i8* %tmp.3, i64 100000, i32 1 )
|
|
|
|
tail call void @llvm.memset.i32( i8* %tmp.3, i8 14, i32 10000, i32 0 )
|
|
|
|
tail call void @llvm.memmove.i32( i8* %tmp.1, i8* %tmp.3, i32 123124, i32 1 )
|
Reapply address space patch after fixing an issue in MemCopyOptimizer.
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)
llvm-svn: 100304
2010-04-04 05:10:48 +02:00
|
|
|
tail call void @llvm.memmove.i64( i8* %tmp.1, i8* %tmp.3, i64 123124, i32 1 )
|
2008-02-17 01:13:09 +01:00
|
|
|
ret void
|
2006-03-03 00:56:23 +01:00
|
|
|
}
|
|
|
|
|
2008-02-17 01:13:09 +01:00
|
|
|
declare void @llvm.memcpy.i32(i8*, i8*, i32, i32)
|
|
|
|
|
|
|
|
declare void @llvm.memcpy.i64(i8*, i8*, i64, i32)
|
|
|
|
|
|
|
|
declare void @llvm.memset.i32(i8*, i8, i32, i32)
|
|
|
|
|
|
|
|
declare void @llvm.memmove.i32(i8*, i8*, i32, i32)
|
|
|
|
|
2010-04-20 06:49:11 +02:00
|
|
|
declare void @llvm.memmove.i64(i8*, i8*, i64, i32)
|