* (no subject)
@ 2021-05-16 14:25 Joern Rennecke
2021-05-16 14:33 ` RFA: Fix match_dup numbering bug in define_cond_exec Joern Rennecke
2021-05-27 12:11 ` none Richard Sandiford
0 siblings, 2 replies; 3+ messages in thread
From: Joern Rennecke @ 2021-05-16 14:25 UTC (permalink / raw)
To: GCC Patches
[-- Attachment #1: Type: text/plain, Size: 355 bytes --]
At the moment, for a match_dup in a define_cond_exec, you'd have to
give the number in the
resulting pattern(s) rather than in the substitute pattern. That's
not only wrong, but can also
be impossible when the pattern should apply to multiple patterns with
different operand numbers.
The attached patch fixes this.
Bootstrapped on x86_64-pc-linux-gnu.
[-- Attachment #2: define_cond_exec_patch.txt --]
[-- Type: text/plain, Size: 527 bytes --]
2020-12-12 Joern Rennecke <joern.rennecke@embecosm.com>
Fix match_dup bug of define_cond_exec.
* gensupport.c (alter_predicate_for_insn): Handle MATCH_DUP.
diff --git a/gcc/gensupport.c b/gcc/gensupport.c
index e1ca06dbc1e..92275358078 100644
--- a/gcc/gensupport.c
+++ b/gcc/gensupport.c
@@ -1230,6 +1230,7 @@ alter_predicate_for_insn (rtx pattern, int alt, int max_op,
case MATCH_OPERATOR:
case MATCH_SCRATCH:
case MATCH_PARALLEL:
+ case MATCH_DUP:
XINT (pattern, 0) += max_op;
break;
^ permalink raw reply [flat|nested] 3+ messages in thread
* RFA: Fix match_dup numbering bug in define_cond_exec
2021-05-16 14:25 Joern Rennecke
@ 2021-05-16 14:33 ` Joern Rennecke
2021-05-27 12:11 ` none Richard Sandiford
1 sibling, 0 replies; 3+ messages in thread
From: Joern Rennecke @ 2021-05-16 14:33 UTC (permalink / raw)
To: GCC Patches
[-- Attachment #1: Type: text/plain, Size: 494 bytes --]
(Sorry about re-sending - I accidentally forgot to add a subject in
the last post, which would make it hard to have a meaningful thread.)
At the moment, for a match_dup in a define_cond_exec, you'd have to
give the number in the
resulting pattern(s) rather than in the substitute pattern. That's
not only wrong, but can also
be impossible when the pattern should apply to multiple patterns with
different operand numbers.
The attached patch fixes this.
Bootstrapped on x86_64-pc-linux-gnu.
[-- Attachment #2: define_cond_exec_patch.txt --]
[-- Type: text/plain, Size: 527 bytes --]
2020-12-12 Joern Rennecke <joern.rennecke@embecosm.com>
Fix match_dup bug of define_cond_exec.
* gensupport.c (alter_predicate_for_insn): Handle MATCH_DUP.
diff --git a/gcc/gensupport.c b/gcc/gensupport.c
index e1ca06dbc1e..92275358078 100644
--- a/gcc/gensupport.c
+++ b/gcc/gensupport.c
@@ -1230,6 +1230,7 @@ alter_predicate_for_insn (rtx pattern, int alt, int max_op,
case MATCH_OPERATOR:
case MATCH_SCRATCH:
case MATCH_PARALLEL:
+ case MATCH_DUP:
XINT (pattern, 0) += max_op;
break;
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: none
2021-05-16 14:25 Joern Rennecke
2021-05-16 14:33 ` RFA: Fix match_dup numbering bug in define_cond_exec Joern Rennecke
@ 2021-05-27 12:11 ` Richard Sandiford
1 sibling, 0 replies; 3+ messages in thread
From: Richard Sandiford @ 2021-05-27 12:11 UTC (permalink / raw)
To: Joern Rennecke; +Cc: GCC Patches
Joern Rennecke <joern.rennecke@embecosm.com> writes:
> At the moment, for a match_dup in a define_cond_exec, you'd have to
> give the number in the
> resulting pattern(s) rather than in the substitute pattern. That's
> not only wrong, but can also
> be impossible when the pattern should apply to multiple patterns with
> different operand numbers.
>
> The attached patch fixes this.
>
> Bootstrapped on x86_64-pc-linux-gnu.
>
> 2020-12-12 Joern Rennecke <joern.rennecke@embecosm.com>
>
> Fix match_dup bug of define_cond_exec.
> * gensupport.c (alter_predicate_for_insn): Handle MATCH_DUP.
The “Fix match_dup …” should come before the changelog in the commit message.
OK otherwise, thanks.
Richard
> diff --git a/gcc/gensupport.c b/gcc/gensupport.c
> index e1ca06dbc1e..92275358078 100644
> --- a/gcc/gensupport.c
> +++ b/gcc/gensupport.c
> @@ -1230,6 +1230,7 @@ alter_predicate_for_insn (rtx pattern, int alt, int max_op,
> case MATCH_OPERATOR:
> case MATCH_SCRATCH:
> case MATCH_PARALLEL:
> + case MATCH_DUP:
> XINT (pattern, 0) += max_op;
> break;
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-05-27 12:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-16 14:25 Joern Rennecke
2021-05-16 14:33 ` RFA: Fix match_dup numbering bug in define_cond_exec Joern Rennecke
2021-05-27 12:11 ` none Richard Sandiford
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).