1 ; RUN: opt -aa-pipeline=basic-aa -passes='print<memoryssa>,verify<memoryssa>' -disable-output < %s 2>&1 | FileCheck %s
3 ; Ensures that assumes are treated as not reading or writing memory.
5 declare void @llvm.assume(i1)
7 define i32 @foo(ptr %a, ptr %b, i1 %c) {
8 ; CHECK: 1 = MemoryDef(liveOnEntry)
9 ; CHECK-NEXT: store i32 4
10 store i32 4, ptr %a, align 4
11 ; CHECK-NOT: MemoryDef
12 ; CHECK: call void @llvm.assume
13 call void @llvm.assume(i1 %c)
15 ; CHECK-NEXT: %1 = load i32
16 %1 = load i32, ptr %a, align 4