1 ; RUN: opt < %s -S -passes=licm | FileCheck %s
3 ; Check that we do not hoist convergent functions out of loop
4 ; CHECK: define i32 @test
8 define i32 @test(ptr nocapture noalias %x, ptr nocapture %y) {
13 %a = call i32 @f() nounwind readnone convergent
14 %exitcond = icmp ne i32 %a, 0
15 br i1 %exitcond, label %end, label %loop
21 declare i32 @f() nounwind readnone convergent