1 ; Test the Test Data Class instruction logic operation conversion from
4 ; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
8 define i32 @f1(float %x) {
10 ; CHECK: tceb %f0, 1365
11 %cast = bitcast float %x to i32
12 %res = icmp slt i32 %cast, 0
13 %xres = zext i1 %res to i32
17 ; Extract negated sign bit.
18 define i32 @f2(float %x) {
20 ; CHECK: tceb %f0, 2730
21 %cast = bitcast float %x to i32
22 %res = icmp sgt i32 %cast, -1
23 %xres = zext i1 %res to i32
28 define i32 @f3(double %x) {
30 ; CHECK: tcdb %f0, 1365
31 %cast = bitcast double %x to i64
32 %res = icmp slt i64 %cast, 0
33 %xres = zext i1 %res to i32
37 ; Extract negated sign bit.
38 define i32 @f4(double %x) {
40 ; CHECK: tcdb %f0, 2730
41 %cast = bitcast double %x to i64
42 %res = icmp sgt i64 %cast, -1
43 %xres = zext i1 %res to i32
48 define i32 @f5(fp128 %x) {
50 ; CHECK: tcxb %f0, 1365
51 %cast = bitcast fp128 %x to i128
52 %res = icmp slt i128 %cast, 0
53 %xres = zext i1 %res to i32
57 ; Extract negated sign bit.
58 define i32 @f6(fp128 %x) {
60 ; CHECK: tcxb %f0, 2730
61 %cast = bitcast fp128 %x to i128
62 %res = icmp sgt i128 %cast, -1
63 %xres = zext i1 %res to i32
68 define i32 @f7(float %x) {
71 %cast = bitcast float %x to i32
72 %res = icmp slt i32 %cast, -1
73 %xres = zext i1 %res to i32
78 define i32 @f8(float %x) {
81 %cast = bitcast float %x to i32
82 %res = icmp eq i32 %cast, 0
83 %xres = zext i1 %res to i32