Hrvoje Varga | 2db00ce | 2016-07-22 07:18:33 +0000 | [diff] [blame] | 1 | ; RUN: llc -march=mips -mcpu=mips32r3 -mattr=micromips -relocation-model=pic < %s | FileCheck %s |
| 2 | |
| 3 | define i32 @slt(i32 signext %a) nounwind readnone { |
| 4 | %1 = icmp slt i32 %a, 7 |
| 5 | ; CHECK-LABEL: slt: |
| 6 | ; CHECK: slt ${{[0-9]+}}, ${{[0-9]+}}, $4 |
| 7 | %2 = select i1 %1, i32 3, i32 4 |
| 8 | ret i32 %2 |
| 9 | } |
| 10 | |
| 11 | define i32 @sgt(i32 signext %a) { |
| 12 | entry: |
| 13 | ; CHECK-LABEL: sgt: |
| 14 | %cmp = icmp sgt i32 %a, 32767 |
| 15 | ; CHECK: slt ${{[0-9]+}}, ${{[0-9]+}}, $4 |
| 16 | %cond = select i1 %cmp, i32 7, i32 5 |
| 17 | ret i32 %cond |
| 18 | } |