1 ; RUN: opt < %s -instcombine -S | FileCheck %s
3 ;; This tests that the div is hoisted into the then block.
4 define i32 @foo(i1 %C, i32 %A, i32 %B) {
6 br i1 %C, label %then, label %endif
10 ; CHECK-NEXT: sdiv i32
13 endif: ; preds = %then, %entry
14 %X = phi i32 [ %A, %then ], [ 15, %entry ] ; <i32> [#uses=1]
15 %Y = sdiv i32 %X, 42 ; <i32> [#uses=1]