diff options
Diffstat (limited to 'test/Other/lint.ll')
-rw-r--r-- | test/Other/lint.ll | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/Other/lint.ll b/test/Other/lint.ll index ea02d431ff..bed3dba3a5 100644 --- a/test/Other/lint.ll +++ b/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: |