1 ; RUN: opt -S -memoryssa %s | FileCheck %s
3 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
4 target triple = "x86_64-unknown-linux-gnu"
7 ; Function Attrs: noinline
8 define dso_local void @func() unnamed_addr #0 align 2 {
10 %NoFinalize.addr = alloca i8, align 1
17 %call8 = call zeroext i1 @foo()
18 br i1 %call8, label %if.then9, label %while.cond
20 if.then9: ; preds = %entry
30 while.cond: ; preds = %cleanup, %if.then9, %entry
31 %call34 = call zeroext i1 @foo()
33 br i1 %call34, label %while.body, label %while.end
35 while.body: ; preds = %while.cond
36 %call35 = call zeroext i1 @foo()
37 br i1 %call35, label %if.end37, label %if.then36
39 if.then36: ; preds = %while.body
40 store i32 2, i32* undef, align 4
43 if.end37: ; preds = %while.body
44 %call38 = call zeroext i1 @foo()
45 br i1 %call38, label %if.end46, label %land.lhs.true
47 land.lhs.true: ; preds = %if.end37
49 %call41 = call zeroext i1 @foo()
50 br i1 %call41, label %if.then42, label %if.end46
52 if.then42: ; preds = %land.lhs.true
56 if.end46: ; preds = %if.then42, %land.lhs.true, %if.end37
63 cleanup: ; preds = %if.end46, %if.then36
67 while.end: ; preds = %while.cond
83 %call93 = call zeroext i1 @foo()
84 br i1 %call93, label %if.end120, label %if.then94
86 if.then94: ; preds = %while.end
87 store i32 0, i32* undef, align 4
99 for.cond: ; preds = %for.body, %if.then94
100 br i1 undef, label %for.body, label %if.end120
102 for.body: ; preds = %for.cond
119 if.end120: ; preds = %for.cond, %while.end
120 %val = load i8, i8* %NoFinalize.addr, align 1
124 ; Function Attrs: noinline
125 declare hidden void @blah() unnamed_addr #0 align 2
127 ; Function Attrs: noinline
128 declare hidden i1 @foo() local_unnamed_addr #0 align 2
130 attributes #0 = { noinline }