blob: 11f706e5662d0fddb3a99237d06bf8835d9c7125 [file] [log] [blame]
Chris Lattner16ea43b2004-06-09 05:07:01 +00001; This is the sequence of stuff that the Java front-end expands for a single
2; <= comparison. Check to make sure we turn it into a <= (only)
3
Reid Spencere4d87aa2006-12-23 06:05:41 +00004; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | grep -v 'icmp sle'| not grep '#uses'
Chris Lattner16ea43b2004-06-09 05:07:01 +00005
6bool %le(int %A, int %B) {
7 %c1 = setgt int %A, %B;
8 %tmp = select bool %c1, int 1, int 0;
9 %c2 = setlt int %A, %B;
10 %result = select bool %c2, int -1, int %tmp;
11 %c3 = setle int %result, 0;
12 ret bool %c3;
13}
14