reverted r21775: too restrictive because ieee 754 uses binary representation for...
authorMichael Beck <beck@ipd.info.uni-karlsruhe.de>
Fri, 12 Sep 2008 00:14:14 +0000 (00:14 +0000)
committerMichael Beck <beck@ipd.info.uni-karlsruhe.de>
Fri, 12 Sep 2008 00:14:14 +0000 (00:14 +0000)
[r21867]

ir/ir/iropt.c

index 16d006d..2bfb87c 100644 (file)
@@ -1259,8 +1259,7 @@ restart:
                                        }
                                }
                        }
-                       if (get_mode_arithmetic(n_mode) == irma_twos_complement &&
-                           get_mode_arithmetic(a_mode) == irma_ieee754) {
+                       if (mode_is_int(n_mode) && get_mode_arithmetic(a_mode) == irma_ieee754) {
                                /* ConvI(ConvF(I)) -> I, iff float mantissa >= int mode */
                                unsigned int_mantissa   = get_mode_size_bits(n_mode) - (mode_is_signed(n_mode) ? 1 : 0);
                                unsigned float_mantissa = tarval_ieee754_get_mantissa_size(a_mode);