From 25238622ec79cceb912a1382ff9afffb680aea0a Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Thu, 14 Oct 1999 02:58:41 -0700 Subject: [PATCH] genrecog.c (validate_pattern): Typo last change. * genrecog.c (validate_pattern): Typo last change. Verify that output operands have output reloads. From-SVN: r29968 --- gcc/ChangeLog | 5 +++++ gcc/genrecog.c | 15 ++++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 82d762ad9d5..f1266075d50 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Thu Oct 14 02:57:05 1999 Richard Henderson + + * genrecog.c (validate_pattern): Typo last change. Verify + that output operands have output reloads. + Thu Oct 14 01:49:54 1999 Richard Henderson * genrecog.c (special_mode_pred_table): New. diff --git a/gcc/genrecog.c b/gcc/genrecog.c index f36e8796576..36362151176 100644 --- a/gcc/genrecog.c +++ b/gcc/genrecog.c @@ -525,7 +525,7 @@ validate_pattern (pattern, insn, set_dest) && pred_name[0] != '\0' && allows_non_const && ! special_mode_pred - && strstr (c_test, "operands") != NULL + && strstr (c_test, "operands") == NULL && GET_CODE (insn) == DEFINE_INSN) { message_with_line (pattern_lineno, @@ -533,6 +533,19 @@ validate_pattern (pattern, insn, set_dest) XINT (pattern, 0)); } + /* A MATCH_OPERAND that is a SET should have an output reload. */ + if (set_dest + && code == MATCH_OPERAND + && XSTR (pattern, 2)[0] != '\0' + && XSTR (pattern, 2)[0] != '=' + && XSTR (pattern, 2)[0] != '+') + { + message_with_line (pattern_lineno, + "operand %d missing output reload", + XINT (pattern, 0)); + error_count++; + } + return; } -- 2.30.2