2005-07-30 James A. Morrison <phython@gcc.gnu.org>
* fold-const.c (tree_expr_nonnegative_p): Always return true for
non-integral types.
From-SVN: r102587
+2005-07-30 James A. Morrison <phython@gcc.gnu.org>
+
+ * fold-const.c (tree_expr_nonnegative_p): Always return true for
+ non-integral types.
+
2005-07-29 Wolfgang Bangerth <bangerth@dealii.org>
PR target/22582
case ABS_EXPR:
/* We can't return 1 if flag_wrapv is set because
ABS_EXPR<INT_MIN> = INT_MIN. */
- if (!flag_wrapv)
+ if (!(flag_wrapv && INTEGRAL_TYPE_P (TREE_TYPE (t))))
return 1;
break;
-2005-07-30 Paul Thomas <pault@gcc.gnu.org>
+2005-07-30 James A. Morrison <phython@gcc.gnu.org>
+
+ * gcc.dg/fold-abs-4.c: new test.
+
+2005-07-30 Paul Thomas <pault@gcc.gnu.org>
PR fortran/22570 an related issues.
* gfortran.dg/x_slash_1.f: New test.
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-fdump-tree-gimple -fwrapv" } */
+extern float fabsf (float);
+extern float cabsf (_Complex float);
+
+int f (float a) {
+ return fabsf(a) < 0.0;
+}
+
+int g (_Complex float a) {
+ return cabsf (a) < 0.0;
+}
+
+/* { dg-final { scan-tree-dump-times "ABS" 0 "gimple" } } */
+/* { dg-final { cleanup-tree-dump "gimple" } } */