diff options
author | rdivacky <rdivacky@FreeBSD.org> | 2010-03-06 09:22:29 +0000 |
---|---|---|
committer | rdivacky <rdivacky@FreeBSD.org> | 2010-03-06 09:22:29 +0000 |
commit | 9bef28eb9e224d641ce31a423e215ccf82bf1d43 (patch) | |
tree | 542734eaa7870f95912cbaebccb87dbec0c20b4f /test/Transforms/SimplifyLibCalls/memset_chk.ll | |
parent | 8230c40430a1325b5cc5bc0221931487b4bd573c (diff) | |
download | FreeBSD-src-9bef28eb9e224d641ce31a423e215ccf82bf1d43.zip FreeBSD-src-9bef28eb9e224d641ce31a423e215ccf82bf1d43.tar.gz |
Update LLVM to r97873.
Diffstat (limited to 'test/Transforms/SimplifyLibCalls/memset_chk.ll')
-rw-r--r-- | test/Transforms/SimplifyLibCalls/memset_chk.ll | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/Transforms/SimplifyLibCalls/memset_chk.ll b/test/Transforms/SimplifyLibCalls/memset_chk.ll new file mode 100644 index 0000000..c4ef60e --- /dev/null +++ b/test/Transforms/SimplifyLibCalls/memset_chk.ll @@ -0,0 +1,18 @@ +; RUN: opt < %s -simplify-libcalls -S | FileCheck %s +; rdar://7719085 + +target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" + +%struct.data = type { [100 x i32], [100 x i32], [1024 x i8] } + +define i32 @t() nounwind ssp { +; CHECK: @t +; CHECK: @llvm.memset.i64 +entry: + %0 = alloca %struct.data, align 8 ; <%struct.data*> [#uses=1] + %1 = bitcast %struct.data* %0 to i8* ; <i8*> [#uses=1] + %2 = call i8* @__memset_chk(i8* %1, i32 0, i64 1824, i64 1824) nounwind ; <i8*> [#uses=0] + ret i32 0 +} + +declare i8* @__memset_chk(i8*, i32, i64, i64) nounwind |