llvm-6502/test/Analysis/ScalarEvolution/smax.ll
Bill Wendling ac838d1c14 FileCheckize some of the testcases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187756 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-05 23:43:18 +00:00

15 lines
330 B
LLVM

; RUN: opt < %s -analyze -scalar-evolution | FileCheck %s
; PR1614
; CHECK: --> (%a smax %b)
; CHECK: --> (%a smax %b smax %c)
; CHECK-NOT: smax
define i32 @x(i32 %a, i32 %b, i32 %c) {
%A = icmp sgt i32 %a, %b
%B = select i1 %A, i32 %a, i32 %b
%C = icmp sle i32 %c, %B
%D = select i1 %C, i32 %B, i32 %c
ret i32 %D
}