1 ; RUN: opt -S -loop-unswitch -enable-new-pm=0 -verify-memoryssa < %s | FileCheck %s
2 target triple = "x86_64-pc-win32"
4 define void @f(i32 %doit, i1 %x, i1 %y) personality i32 (...)* @__CxxFrameHandler3 {
6 %tobool = icmp eq i32 %doit, 0
9 for.cond: ; preds = %for.inc, %entry
10 br i1 %x, label %for.body, label %for.end
12 for.body: ; preds = %for.cond
13 br i1 %tobool, label %if.then, label %for.inc
15 if.then: ; preds = %for.body
16 br i1 %y, label %for.inc, label %delete.notnull
18 delete.notnull: ; preds = %if.then
20 to label %invoke.cont unwind label %lpad
22 invoke.cont: ; preds = %delete.notnull
25 lpad: ; preds = %delete.notnull
26 %cp = cleanuppad within none []
27 cleanupret from %cp unwind to caller
29 for.inc: ; preds = %invoke.cont, %if.then, %for.body
32 for.end: ; preds = %for.cond
38 declare i32 @__CxxFrameHandler3(...)
40 ; CHECK-LABEL: define void @f(
41 ; CHECK: cleanuppad within none []
42 ; CHECK-NOT: cleanuppad
44 attributes #0 = { ssp uwtable }