Lines Matching full:lifetime
1 ; Test hanlding of llvm.lifetime intrinsics.
2 ; RUN: opt < %s -asan -asan-check-lifetime -S | FileCheck %s
7 declare void @llvm.lifetime.start(i64, i8* nocapture) nounwind
8 declare void @llvm.lifetime.end(i64, i8* nocapture) nounwind
14 call void @llvm.lifetime.start(i64 -1, i8* %i.ptr)
15 call void @llvm.lifetime.end(i64 -1, i8* %i.ptr)
17 ; Check that lifetime with no size are ignored.
25 ; Generic case of lifetime analysis.
26 define void @lifetime() sanitize_address {
27 ; CHECK: @lifetime
29 ; Regular variable lifetime intrinsics.
32 call void @llvm.lifetime.start(i64 3, i8* %i.ptr)
33 ; Memory is unpoisoned at llvm.lifetime.start
36 call void @llvm.lifetime.end(i64 4, i8* %i.ptr)
37 call void @llvm.lifetime.end(i64 2, i8* %i.ptr)
38 ; Memory is poisoned at every call to llvm.lifetime.end
42 ; Lifetime intrinsics for array.
45 call void @llvm.lifetime.start(i64 40, i8* %arr.ptr)
47 call void @llvm.lifetime.end(i64 40, i8* %arr.ptr)
50 ; One more lifetime start/end for the same variable %i.
51 call void @llvm.lifetime.start(i64 4, i8* %i.ptr)
53 call void @llvm.lifetime.end(i64 4, i8* %i.ptr)
63 ; Check that arguments of lifetime may come from phi nodes.
70 call void @llvm.lifetime.start(i64 8, i8* %i.ptr)
80 call void @llvm.lifetime.end(i64 8, i8* %i.phi)