diff options
author | Dan Gohman <gohman@apple.com> | 2010-05-28 17:44:00 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2010-05-28 17:44:00 +0000 |
commit | c575ec61ea6dd1d70fea61991830679b9a65aff4 (patch) | |
tree | a64dadd55a72a92dd937a3cf8637d5eab7dff4c7 /llvm/test/Other | |
parent | 37eb2c24b932a875049574f7bcd32925aa1cb083 (diff) | |
download | bcm5719-llvm-c575ec61ea6dd1d70fea61991830679b9a65aff4.tar.gz bcm5719-llvm-c575ec61ea6dd1d70fea61991830679b9a65aff4.zip |
Fix lint's memcpy and memmove checks, and its basic block traversal.
llvm-svn: 104970
Diffstat (limited to 'llvm/test/Other')
-rw-r--r-- | llvm/test/Other/lint.ll | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/test/Other/lint.ll b/llvm/test/Other/lint.ll index ea02d431ffd..bed3dba3a59 100644 --- a/llvm/test/Other/lint.ll +++ b/llvm/test/Other/lint.ll @@ -3,6 +3,7 @@ target datalayout = "e-p:64:64:64" declare fastcc void @bar() declare void @llvm.stackrestore(i8*) +declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture, i64, i32, i1) nounwind @CG = constant i32 7 @@ -54,6 +55,9 @@ define i32 @foo() noreturn { ; CHECK: Undefined behavior: Null pointer dereference call void @llvm.stackrestore(i8* null) +; CHECK: Write to read-only memory + call void @llvm.memcpy.p0i8.p0i8.i64(i8* bitcast (i32* @CG to i8*), i8* bitcast (i32* @CG to i8*), i64 1, i32 1, i1 0) + br label %next next: |