summaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorsayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-26 03:05:40 +0000
committersayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-26 03:05:40 +0000
commita4589b78d83eb7b27997a5fe5afd8eaab902ec2e (patch)
tree528ae78f7e10b37399d1b8ddea63ecb542811b27 /gcc
parent982c684c016e0427146888f7c01b59f8dc3aeb26 (diff)
downloadgcc-a4589b78d83eb7b27997a5fe5afd8eaab902ec2e.tar.gz
* combine.c (combine_simplify_rtx, simplfy_comparison): Use CC0_P.
* cse.c (invalidate_skipped_set): Likewise. * integrate.c (subst_constants): Likewise. * jump.c (reversed_comparison_code_parts): Likewise. * loop.c (canonicalize_condition): Likewise. * simplify-rtx.c (simplify_relational_operation): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@63446 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog9
-rw-r--r--gcc/combine.c9
-rw-r--r--gcc/cse.c4
-rw-r--r--gcc/integrate.c18
-rw-r--r--gcc/jump.c6
-rw-r--r--gcc/loop.c6
-rw-r--r--gcc/simplify-rtx.c6
7 files changed, 21 insertions, 37 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 8d0407b5e1d..a227392c543 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,14 @@
2003-02-25 Roger Sayle <roger@eyesopen.com>
+ * combine.c (combine_simplify_rtx, simplfy_comparison): Use CC0_P.
+ * cse.c (invalidate_skipped_set): Likewise.
+ * integrate.c (subst_constants): Likewise.
+ * jump.c (reversed_comparison_code_parts): Likewise.
+ * loop.c (canonicalize_condition): Likewise.
+ * simplify-rtx.c (simplify_relational_operation): Likewise.
+
+2003-02-25 Roger Sayle <roger@eyesopen.com>
+
* builtins.def (DEF_LIB_ALWAYS_BUILTIN, DEF_UNUSED_BUILTIN): Delete.
(abs, labs, fabs, fabsf, fabsl, abort, exit, _exit, _Exit): Use
the appropriate macro to define built-in function.
diff --git a/gcc/combine.c b/gcc/combine.c
index 126f90040df..fe5cce50f24 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -4494,10 +4494,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
with it. */
if (GET_CODE (XEXP (x, 0)) == COMPARE
|| (GET_MODE_CLASS (GET_MODE (XEXP (x, 0))) != MODE_CC
-#ifdef HAVE_cc0
- && XEXP (x, 0) != cc0_rtx
-#endif
- ))
+ && ! CC0_P (XEXP (x, 0))))
{
rtx op0 = XEXP (x, 0);
rtx op1 = XEXP (x, 1);
@@ -11010,9 +11007,7 @@ simplify_comparison (code, pop0, pop1)
/* We can't do anything if OP0 is a condition code value, rather
than an actual data value. */
if (const_op != 0
-#ifdef HAVE_cc0
- || XEXP (op0, 0) == cc0_rtx
-#endif
+ || CC0_P (XEXP (op0, 0))
|| GET_MODE_CLASS (GET_MODE (XEXP (op0, 0))) == MODE_CC)
break;
diff --git a/gcc/cse.c b/gcc/cse.c
index d9e9fadaf67..6c763f48792 100644
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -6658,9 +6658,7 @@ invalidate_skipped_set (dest, set, data)
}
if (GET_CODE (set) == CLOBBER
-#ifdef HAVE_cc0
- || dest == cc0_rtx
-#endif
+ || CC0_P (dest)
|| dest == pc_rtx)
return;
diff --git a/gcc/integrate.c b/gcc/integrate.c
index 5f050ff21c9..576d8240c65 100644
--- a/gcc/integrate.c
+++ b/gcc/integrate.c
@@ -1,6 +1,6 @@
/* Procedure integration for GCC.
- Copyright (C) 1988, 1991, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1988, 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
+ 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by Michael Tiemann (tiemann@cygnus.com)
This file is part of GCC.
@@ -2611,10 +2611,7 @@ subst_constants (loc, insn, map, memonly)
{
src = SET_SRC (x);
if (GET_MODE_CLASS (GET_MODE (src)) == MODE_CC
-#ifdef HAVE_cc0
- || dest == cc0_rtx
-#endif
- )
+ || CC0_P (dest))
{
compare_mode = GET_MODE (XEXP (src, 0));
if (compare_mode == VOIDmode)
@@ -2666,9 +2663,7 @@ subst_constants (loc, insn, map, memonly)
|| REGNO (XEXP (src, 0)) == VIRTUAL_STACK_VARS_REGNUM)
&& CONSTANT_P (XEXP (src, 1)))
|| GET_CODE (src) == COMPARE
-#ifdef HAVE_cc0
- || dest == cc0_rtx
-#endif
+ || CC0_P (dest)
|| (dest == pc_rtx
&& (src == pc_rtx || GET_CODE (src) == RETURN
|| GET_CODE (src) == LABEL_REF))))
@@ -2682,10 +2677,7 @@ subst_constants (loc, insn, map, memonly)
if (compare_mode != VOIDmode
&& GET_CODE (src) == COMPARE
&& (GET_MODE_CLASS (GET_MODE (src)) == MODE_CC
-#ifdef HAVE_cc0
- || dest == cc0_rtx
-#endif
- )
+ || CC0_P (dest))
&& GET_MODE (XEXP (src, 0)) == VOIDmode
&& GET_MODE (XEXP (src, 1)) == VOIDmode)
{
diff --git a/gcc/jump.c b/gcc/jump.c
index b4e0d1c043f..e18abef51a7 100644
--- a/gcc/jump.c
+++ b/gcc/jump.c
@@ -701,11 +701,7 @@ reversed_comparison_code_parts (code, arg0, arg1, insn)
break;
}
- if (GET_MODE_CLASS (mode) == MODE_CC
-#ifdef HAVE_cc0
- || arg0 == cc0_rtx
-#endif
- )
+ if (GET_MODE_CLASS (mode) == MODE_CC || CC0_P (arg0))
{
rtx prev;
/* Try to search for the comparison to determine the real mode.
diff --git a/gcc/loop.c b/gcc/loop.c
index 4bdef2d0af7..1b2acec67af 100644
--- a/gcc/loop.c
+++ b/gcc/loop.c
@@ -1,6 +1,6 @@
/* Perform various loop optimizations, including strength reduction.
Copyright (C) 1987, 1988, 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
- 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GCC.
@@ -9442,11 +9442,9 @@ canonicalize_condition (insn, cond, reverse, earliest, want_reg)
}
}
-#ifdef HAVE_cc0
/* Never return CC0; return zero instead. */
- if (op0 == cc0_rtx)
+ if (CC0_P (op0))
return 0;
-#endif
return gen_rtx_fmt_ee (code, VOIDmode, op0, op1);
}
diff --git a/gcc/simplify-rtx.c b/gcc/simplify-rtx.c
index 9d3b2138784..0bd9b6055b6 100644
--- a/gcc/simplify-rtx.c
+++ b/gcc/simplify-rtx.c
@@ -2177,11 +2177,7 @@ simplify_relational_operation (code, mode, op0, op1)
/* We can't simplify MODE_CC values since we don't know what the
actual comparison is. */
- if (GET_MODE_CLASS (GET_MODE (op0)) == MODE_CC
-#ifdef HAVE_cc0
- || op0 == cc0_rtx
-#endif
- )
+ if (GET_MODE_CLASS (GET_MODE (op0)) == MODE_CC || CC0_P (op0))
return 0;
/* Make sure the constant is second. */