+2005-04-14 Uros Bizjak <uros@kss-loka.si>
+
+ * convert.c (convert_to_integer): Convert (long int)trunc{,f,l},
+ and (long long int)ceil{,f,l} into FIX_TRUNC_EXPR.
+
2005-04-14 Ulrich Weigand <uweigand@de.ibm.com>
PR target/20927
else
fn = mathfn_built_in (s_intype, BUILT_IN_LRINT);
break;
+
+ case BUILT_IN_TRUNC: case BUILT_IN_TRUNCF: case BUILT_IN_TRUNCL:
+ {
+ tree arglist = TREE_OPERAND (s_expr, 1);
+ return convert_to_integer (type, TREE_VALUE (arglist));
+ }
+
default:
break;
}
+2005-04-14 Uros Bizjak <uros@kss-loka.si>
+
+ * gcc.dg/builtins-53.c: Also check (int)trunc* and
+ (long long int)trunc*.
+
2005-04-14 Ulrich Weigand <uweigand@de.ibm.com>
PR target/20927
extern double floor(double);
extern double ceil(double);
+extern double trunc(double);
extern float floorf(float);
extern float ceilf(float);
+extern float truncf(float);
extern long double floorl(long double);
extern long double ceill(long double);
+extern long double truncl(long double);
long int test1(double x)
return ceil(x);
}
+long int test5(double x)
+{
+ return trunc(x);
+}
+
+long long int test6(double x)
+{
+ return trunc(x);
+}
+
long int test1f(float x)
{
return floorf(x);
return ceilf(x);
}
+long int test5f(float x)
+{
+ return truncf(x);
+}
+
+long long int test6f(float x)
+{
+ return truncf(x);
+}
+
long int test1l(long double x)
{
return floorl(x);
{
return ceill(x);
}
+
+long int test5l(long double x)
+{
+ return truncl(x);
+}
+
+long long int test6l(long double x)
+{
+ return truncl(x);
+}