1 ; RUN: opt < %s -simplifycfg -simplifycfg-require-and-preserve-domtree=1 -S | FileCheck %s
3 ; Checks that the SimplifyCFG pass won't duplicate a call to a function marked
6 ; CHECK: call void @barrier
7 ; CHECK-NOT: call void @barrier
8 define void @check(i1 %cond, i32* %out) {
10 br i1 %cond, label %if.then, label %if.end
13 store i32 5, i32* %out
17 %x = phi i1 [ true, %entry ], [ false, %if.then ]
19 br i1 %x, label %cond.end, label %cond.false
28 declare void @barrier() convergent