summaryrefslogtreecommitdiff
path: root/gcc/genrecog.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2001-05-21 23:46:20 -0700
committerRichard Henderson <rth@gcc.gnu.org>2001-05-21 23:46:20 -0700
commitb4fbaca7cb5c6ff5fb5e24e554d510257cb488eb (patch)
treec78f15a05fa13284aee7f9acc312bbd22411818a /gcc/genrecog.c
parent47816305fecfece2a4ae647638622371e4933076 (diff)
downloadgcc-b4fbaca7cb5c6ff5fb5e24e554d510257cb488eb.tar.gz
combine.c (simplify_comparison): Update op1 after constant extension.
* combine.c (simplify_comparison): Update op1 after constant extension. * recog.c (const_int_operand): Accept only constants valid for the given mode. * genrecog.c: Update comments wrt const_int_operand. From-SVN: r42427
Diffstat (limited to 'gcc/genrecog.c')
-rw-r--r--gcc/genrecog.c22
1 files changed, 10 insertions, 12 deletions
diff --git a/gcc/genrecog.c b/gcc/genrecog.c
index 228a5701eb4..00f425bc822 100644
--- a/gcc/genrecog.c
+++ b/gcc/genrecog.c
@@ -842,18 +842,16 @@ add_to_sequence (pattern, last, position, insn_type, top)
test->u.pred.name = pred_name;
test->u.pred.mode = mode;
- /* See if we know about this predicate and save its number. If
- we do, and it only accepts one code, note that fact. The
- predicate `const_int_operand' only tests for a CONST_INT, so
- if we do so we can avoid calling it at all.
-
- Finally, if we know that the predicate does not allow
- CONST_INT, we know that the only way the predicate can match
- is if the modes match (here we use the kludge of relying on
- the fact that "address_operand" accepts CONST_INT; otherwise,
- it would have to be a special case), so we can test the mode
- (but we need not). This fact should considerably simplify the
- generated code. */
+ /* See if we know about this predicate and save its number.
+ If we do, and it only accepts one code, note that fact.
+
+ If we know that the predicate does not allow CONST_INT,
+ we know that the only way the predicate can match is if
+ the modes match (here we use the kludge of relying on the
+ fact that "address_operand" accepts CONST_INT; otherwise,
+ it would have to be a special case), so we can test the
+ mode (but we need not). This fact should considerably
+ simplify the generated code. */
for (i = 0; i < NUM_KNOWN_PREDS; i++)
if (! strcmp (preds[i].name, pred_name))