define i1 @i32_cast_cmp_eq_int_0_sitofp_float(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_eq_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to float
define i1 @i32_cast_cmp_ne_int_0_sitofp_float(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_ne_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to float
define i1 @i32_cast_cmp_sgt_int_0_sitofp_float(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_sgt_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to float
define i1 @i32_cast_cmp_slt_int_1_sitofp_float(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to float
define <3 x i1> @i32_cast_cmp_slt_int_1_sitofp_float_vec(<3 x i32> %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_float_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i32> [[I:%.*]] to <3 x float>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x float> [[F]] to <3 x i32>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[B]], <i32 1, i32 undef, i32 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[I:%.*]], <i32 1, i32 1, i32 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i32> %i to <3 x float>
define i1 @i32_cast_cmp_eq_int_0_sitofp_double(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_eq_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to double
define i1 @i32_cast_cmp_ne_int_0_sitofp_double(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_ne_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to double
define i1 @i32_cast_cmp_sgt_int_0_sitofp_double(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_sgt_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to double
define i1 @i32_cast_cmp_slt_int_1_sitofp_double(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to double
define <3 x i1> @i32_cast_cmp_slt_int_1_sitofp_double_vec(<3 x i32> %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_double_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i32> [[I:%.*]] to <3 x double>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x double> [[F]] to <3 x i64>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[B]], <i64 1, i64 undef, i64 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[I:%.*]], <i32 1, i32 1, i32 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i32> %i to <3 x double>
define i1 @i32_cast_cmp_eq_int_0_sitofp_half(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_eq_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to half
define i1 @i32_cast_cmp_ne_int_0_sitofp_half(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_ne_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to half
define i1 @i32_cast_cmp_sgt_int_0_sitofp_half(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_sgt_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to half
define i1 @i32_cast_cmp_slt_int_1_sitofp_half(i32 %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i32 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i32 %i to half
define <3 x i1> @i32_cast_cmp_slt_int_1_sitofp_half_vec(<3 x i32> %i) {
; CHECK-LABEL: @i32_cast_cmp_slt_int_1_sitofp_half_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i32> [[I:%.*]] to <3 x half>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x half> [[F]] to <3 x i16>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[B]], <i16 1, i16 undef, i16 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[I:%.*]], <i32 1, i32 1, i32 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i32> %i to <3 x half>
define i1 @i64_cast_cmp_eq_int_0_sitofp_float(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_eq_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to float
define i1 @i64_cast_cmp_ne_int_0_sitofp_float(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_ne_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to float
define i1 @i64_cast_cmp_sgt_int_0_sitofp_float(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_sgt_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to float
define i1 @i64_cast_cmp_slt_int_1_sitofp_float(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to float
define <3 x i1> @i64_cast_cmp_slt_int_1_sitofp_float_vec(<3 x i64> %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_float_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i64> [[I:%.*]] to <3 x float>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x float> [[F]] to <3 x i32>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[B]], <i32 1, i32 undef, i32 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[I:%.*]], <i64 1, i64 1, i64 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i64> %i to <3 x float>
define i1 @i64_cast_cmp_eq_int_0_sitofp_double(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_eq_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to double
define i1 @i64_cast_cmp_ne_int_0_sitofp_double(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_ne_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to double
define i1 @i64_cast_cmp_sgt_int_0_sitofp_double(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_sgt_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to double
define i1 @i64_cast_cmp_slt_int_1_sitofp_double(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to double
define <3 x i1> @i64_cast_cmp_slt_int_1_sitofp_double_vec(<3 x i64> %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_double_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i64> [[I:%.*]] to <3 x double>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x double> [[F]] to <3 x i64>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[B]], <i64 1, i64 undef, i64 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[I:%.*]], <i64 1, i64 1, i64 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i64> %i to <3 x double>
define i1 @i64_cast_cmp_eq_int_0_sitofp_half(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_eq_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to half
define i1 @i64_cast_cmp_ne_int_0_sitofp_half(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_ne_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to half
define i1 @i64_cast_cmp_sgt_int_0_sitofp_half(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_sgt_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to half
define i1 @i64_cast_cmp_slt_int_1_sitofp_half(i64 %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i64 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i64 %i to half
define <3 x i1> @i64_cast_cmp_slt_int_1_sitofp_half_vec(<3 x i64> %i) {
; CHECK-LABEL: @i64_cast_cmp_slt_int_1_sitofp_half_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i64> [[I:%.*]] to <3 x half>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x half> [[F]] to <3 x i16>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[B]], <i16 1, i16 undef, i16 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[I:%.*]], <i64 1, i64 1, i64 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i64> %i to <3 x half>
define i1 @i16_cast_cmp_eq_int_0_sitofp_float(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_eq_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to float
define i1 @i16_cast_cmp_ne_int_0_sitofp_float(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_ne_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to float
define i1 @i16_cast_cmp_sgt_int_0_sitofp_float(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_sgt_int_0_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to float
define i1 @i16_cast_cmp_slt_int_1_sitofp_float(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_float(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to float
-; CHECK-NEXT: [[B:%.*]] = bitcast float [[F]] to i32
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to float
define <3 x i1> @i16_cast_cmp_slt_int_1_sitofp_float_vec(<3 x i16> %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_float_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i16> [[I:%.*]] to <3 x float>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x float> [[F]] to <3 x i32>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i32> [[B]], <i32 1, i32 undef, i32 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[I:%.*]], <i16 1, i16 1, i16 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i16> %i to <3 x float>
define i1 @i16_cast_cmp_eq_int_0_sitofp_double(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_eq_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to double
define i1 @i16_cast_cmp_ne_int_0_sitofp_double(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_ne_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to double
define i1 @i16_cast_cmp_sgt_int_0_sitofp_double(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_sgt_int_0_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i64 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to double
define i1 @i16_cast_cmp_slt_int_1_sitofp_double(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_double(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to double
-; CHECK-NEXT: [[B:%.*]] = bitcast double [[F]] to i64
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i64 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to double
define <3 x i1> @i16_cast_cmp_slt_int_1_sitofp_double_vec(<3 x i16> %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_double_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i16> [[I:%.*]] to <3 x double>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x double> [[F]] to <3 x i64>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i64> [[B]], <i64 1, i64 undef, i64 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[I:%.*]], <i16 1, i16 1, i16 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i16> %i to <3 x double>
define i1 @i16_cast_cmp_eq_int_0_sitofp_half(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_eq_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp eq i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to half
define i1 @i16_cast_cmp_ne_int_0_sitofp_half(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_ne_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp ne i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to half
define i1 @i16_cast_cmp_sgt_int_0_sitofp_half(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_sgt_int_0_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[B]], 0
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i16 [[I:%.*]], 0
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to half
define i1 @i16_cast_cmp_slt_int_1_sitofp_half(i16 %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_half(
-; CHECK-NEXT: [[F:%.*]] = sitofp i16 [[I:%.*]] to half
-; CHECK-NEXT: [[B:%.*]] = bitcast half [[F]] to i16
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[B]], 1
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt i16 [[I:%.*]], 1
; CHECK-NEXT: ret i1 [[CMP]]
;
%f = sitofp i16 %i to half
define <3 x i1> @i16_cast_cmp_slt_int_1_sitofp_half_vec(<3 x i16> %i) {
; CHECK-LABEL: @i16_cast_cmp_slt_int_1_sitofp_half_vec(
-; CHECK-NEXT: [[F:%.*]] = sitofp <3 x i16> [[I:%.*]] to <3 x half>
-; CHECK-NEXT: [[B:%.*]] = bitcast <3 x half> [[F]] to <3 x i16>
-; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[B]], <i16 1, i16 undef, i16 1>
+; CHECK-NEXT: [[CMP:%.*]] = icmp slt <3 x i16> [[I:%.*]], <i16 1, i16 1, i16 1>
; CHECK-NEXT: ret <3 x i1> [[CMP]]
;
%f = sitofp <3 x i16> %i to <3 x half>