1 ; Check that various LLVM idioms get lowered to NVPTX as expected.
3 ; RUN: llc < %s -march=nvptx -mcpu=sm_20 | FileCheck %s
4 ; RUN: llc < %s -march=nvptx64 -mcpu=sm_20 | FileCheck %s
6 ; CHECK-LABEL: abs_i16(
7 define i16 @abs_i16(i16 %a) {
10 %abs.cond = icmp sge i16 %a, 0
11 %abs = select i1 %abs.cond, i16 %a, i16 %neg
15 ; CHECK-LABEL: abs_i32(
16 define i32 @abs_i32(i32 %a) {
19 %abs.cond = icmp sge i32 %a, 0
20 %abs = select i1 %abs.cond, i32 %a, i32 %neg
24 ; CHECK-LABEL: abs_i64(
25 define i64 @abs_i64(i64 %a) {
28 %abs.cond = icmp sge i64 %a, 0
29 %abs = select i1 %abs.cond, i64 %a, i64 %neg