summaryrefslogtreecommitdiff
path: root/gcc/genpreds.c
diff options
context:
space:
mode:
authorPaolo Bonzini <bonzini@gnu.org>2005-02-23 09:09:17 +0000
committerPaolo Bonzini <bonzini@gcc.gnu.org>2005-02-23 09:09:17 +0000
commitbb56fc3933231b44dc310671911e1c73138fb753 (patch)
tree249a35b893096b2eca9d69131904d3e421ac92a5 /gcc/genpreds.c
parent40205a3638f2491a454823de6d69b453b8834233 (diff)
downloadgcc-bb56fc3933231b44dc310671911e1c73138fb753.tar.gz
genpreds.c (mark_mode_tests): Handle non-VOIDmode match_operands.
2005-02-23 Paolo Bonzini <bonzini@gnu.org> * genpreds.c (mark_mode_tests): Handle non-VOIDmode match_operands. (write_predicate_expr): Likewise. From-SVN: r95447
Diffstat (limited to 'gcc/genpreds.c')
-rw-r--r--gcc/genpreds.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/genpreds.c b/gcc/genpreds.c
index 874925de998..cb22908fb56 100644
--- a/gcc/genpreds.c
+++ b/gcc/genpreds.c
@@ -167,7 +167,7 @@ mark_mode_tests (rtx exp)
struct pred_data *p = lookup_predicate (XSTR (exp, 1));
if (!p)
error ("reference to undefined predicate '%s'", XSTR (exp, 1));
- else if (p->special)
+ else if (p->special || GET_MODE (exp) != VOIDmode)
NO_MODE_TEST (exp) = 1;
}
break;
@@ -366,7 +366,10 @@ write_predicate_expr (const char *name, rtx exp)
break;
case MATCH_OPERAND:
- printf ("%s (op, mode)", XSTR (exp, 1));
+ if (GET_MODE (exp) == VOIDmode)
+ printf ("%s (op, mode)", XSTR (exp, 1));
+ else
+ printf ("%s (op, %smode)", XSTR (exp, 1), mode_name[GET_MODE (exp)]);
break;
case MATCH_CODE: