diff mbox series

s390: Fix unresolved iterators bhfgq and xdee

Message ID 20240716145028.3944115-2-stefansf@gcc.gnu.org
State New
Headers show
Series s390: Fix unresolved iterators bhfgq and xdee | expand

Commit Message

Stefan Schulze Frielinghaus July 16, 2024, 2:50 p.m. UTC
Code attribute bhfgq is missing a mapping for TF.  This results in
unresolved iterators in assembler templates for *bswaptf.

With the TF mapping added the base mnemonics vlbr and vstbr are not
"used" anymore but only the extended mnemonics (vlbr<bhfgq> was
interpreted as vlbr; likewise for vstbr).  Therefore, remove the base
mnemonics from the scheduling description, otherwise, genattrtab would
error about unknown mnemonics.

Likewise, for movtf_vr only the extended mnemonics for vrepi are used,
now, which means the base mnemonic is "unused" and has to be removed
from the scheduling description.

Similarly, we end up with unresolved iterators in assembler templates
for mulfprx23 since code attribute xdee is missing a mapping for FPRX2.

Note, this is basically a cherry pick of commit r15-2060-ga4abda934aa426
with the addition that vrepi is removed from the scheduling description,
too.

Bootstrapped on s390.  Ok for release branches 12, 13, and 14?

gcc/ChangeLog:

	* config/s390/3931.md (vlbr, vstbr, vrepi): Remove.
	* config/s390/s390.md (xdee): Add FPRX2 mapping.
	* config/s390/vector.md (bhfgq): Add TF mapping.
---
 gcc/config/s390/3931.md   | 7 -------
 gcc/config/s390/s390.md   | 2 +-
 gcc/config/s390/vector.md | 2 +-
 3 files changed, 2 insertions(+), 9 deletions(-)

Comments

Stefan Schulze Frielinghaus July 20, 2024, 6:39 a.m. UTC | #1
I'm pinging this early since I would like to make sure that it gets into
14.2 RC which is about to be done on Tuesday 23rd July.

On Tue, Jul 16, 2024 at 04:50:29PM +0200, Stefan Schulze Frielinghaus wrote:
> Code attribute bhfgq is missing a mapping for TF.  This results in
> unresolved iterators in assembler templates for *bswaptf.
> 
> With the TF mapping added the base mnemonics vlbr and vstbr are not
> "used" anymore but only the extended mnemonics (vlbr<bhfgq> was
> interpreted as vlbr; likewise for vstbr).  Therefore, remove the base
> mnemonics from the scheduling description, otherwise, genattrtab would
> error about unknown mnemonics.
> 
> Likewise, for movtf_vr only the extended mnemonics for vrepi are used,
> now, which means the base mnemonic is "unused" and has to be removed
> from the scheduling description.
> 
> Similarly, we end up with unresolved iterators in assembler templates
> for mulfprx23 since code attribute xdee is missing a mapping for FPRX2.
> 
> Note, this is basically a cherry pick of commit r15-2060-ga4abda934aa426
> with the addition that vrepi is removed from the scheduling description,
> too.
> 
> Bootstrapped on s390.  Ok for release branches 12, 13, and 14?
> 
> gcc/ChangeLog:
> 
> 	* config/s390/3931.md (vlbr, vstbr, vrepi): Remove.
> 	* config/s390/s390.md (xdee): Add FPRX2 mapping.
> 	* config/s390/vector.md (bhfgq): Add TF mapping.
> ---
>  gcc/config/s390/3931.md   | 7 -------
>  gcc/config/s390/s390.md   | 2 +-
>  gcc/config/s390/vector.md | 2 +-
>  3 files changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/gcc/config/s390/3931.md b/gcc/config/s390/3931.md
> index bed1f6c21f1..9cb11b72bba 100644
> --- a/gcc/config/s390/3931.md
> +++ b/gcc/config/s390/3931.md
> @@ -404,7 +404,6 @@ vlvgg,
>  vlvgh,
>  vlvgp,
>  vst,
> -vstbr,
>  vstbrf,
>  vstbrg,
>  vstbrh,
> @@ -627,7 +626,6 @@ tm,
>  tmy,
>  vl,
>  vlbb,
> -vlbr,
>  vlbrf,
>  vlbrg,
>  vlbrh,
> @@ -661,7 +659,6 @@ vlreph,
>  vlrl,
>  vlrlr,
>  vst,
> -vstbr,
>  vstbrf,
>  vstbrg,
>  vstbrh,
> @@ -1077,7 +1074,6 @@ vrepb,
>  vrepf,
>  vrepg,
>  vreph,
> -vrepi,
>  vrepib,
>  vrepif,
>  vrepig,
> @@ -1930,7 +1926,6 @@ vrepb,
>  vrepf,
>  vrepg,
>  vreph,
> -vrepi,
>  vrepib,
>  vrepif,
>  vrepig,
> @@ -2156,7 +2151,6 @@ vistrfs,
>  vistrhs,
>  vl,
>  vlbb,
> -vlbr,
>  vlbrf,
>  vlbrg,
>  vlbrh,
> @@ -2248,7 +2242,6 @@ tbegin,
>  tbeginc,
>  tend,
>  vst,
> -vstbr,
>  vstbrf,
>  vstbrg,
>  vstbrh,
> diff --git a/gcc/config/s390/s390.md b/gcc/config/s390/s390.md
> index 50a828f2bbb..8edc1261c38 100644
> --- a/gcc/config/s390/s390.md
> +++ b/gcc/config/s390/s390.md
> @@ -744,7 +744,7 @@
>  ;; In FP templates, a <dee> in "m<dee><bt>r" will expand to "mx<bt>r" in
>  ;; TF/TDmode, "md<bt>r" in DF/DDmode, "mee<bt>r" in SFmode and "me<bt>r in
>  ;; SDmode.
> -(define_mode_attr xdee [(TF "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
> +(define_mode_attr xdee [(TF "x") (FPRX2 "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
>  
>  ;; The decimal floating point variants of add, sub, div and mul support 3
>  ;; fp register operands.  The following attributes allow to merge the bfp and
> diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md
> index 1bae1056951..f88e8b655fa 100644
> --- a/gcc/config/s390/vector.md
> +++ b/gcc/config/s390/vector.md
> @@ -134,7 +134,7 @@
>  			(V1TI "q") (TI "q")
>  			(V1SF "f") (V2SF "f") (V4SF "f")
>  			(V1DF "g") (V2DF "g")
> -			(V1TF "q")])
> +			(V1TF "q") (TF "q")])
>  
>  ; This is for vmalhw. It gets an 'w' attached to avoid confusion with
>  ; multiply and add logical high vmalh.
> -- 
> 2.45.0
>
Andreas Krebbel July 20, 2024, 9:35 a.m. UTC | #2
On 7/20/24 08:39, Stefan Schulze Frielinghaus wrote:
> I'm pinging this early since I would like to make sure that it gets into
> 14.2 RC which is about to be done on Tuesday 23rd July.
>
> On Tue, Jul 16, 2024 at 04:50:29PM +0200, Stefan Schulze Frielinghaus wrote:
>> Code attribute bhfgq is missing a mapping for TF.  This results in
>> unresolved iterators in assembler templates for *bswaptf.
>>
>> With the TF mapping added the base mnemonics vlbr and vstbr are not
>> "used" anymore but only the extended mnemonics (vlbr<bhfgq> was
>> interpreted as vlbr; likewise for vstbr).  Therefore, remove the base
>> mnemonics from the scheduling description, otherwise, genattrtab would
>> error about unknown mnemonics.
>>
>> Likewise, for movtf_vr only the extended mnemonics for vrepi are used,
>> now, which means the base mnemonic is "unused" and has to be removed
>> from the scheduling description.
>>
>> Similarly, we end up with unresolved iterators in assembler templates
>> for mulfprx23 since code attribute xdee is missing a mapping for FPRX2.
>>
>> Note, this is basically a cherry pick of commit r15-2060-ga4abda934aa426
>> with the addition that vrepi is removed from the scheduling description,
>> too.
>>
>> Bootstrapped on s390.  Ok for release branches 12, 13, and 14?

Ok, Thanks!

Andreas


>>
>> gcc/ChangeLog:
>>
>> 	* config/s390/3931.md (vlbr, vstbr, vrepi): Remove.
>> 	* config/s390/s390.md (xdee): Add FPRX2 mapping.
>> 	* config/s390/vector.md (bhfgq): Add TF mapping.



>> ---
>>   gcc/config/s390/3931.md   | 7 -------
>>   gcc/config/s390/s390.md   | 2 +-
>>   gcc/config/s390/vector.md | 2 +-
>>   3 files changed, 2 insertions(+), 9 deletions(-)
>>
>> diff --git a/gcc/config/s390/3931.md b/gcc/config/s390/3931.md
>> index bed1f6c21f1..9cb11b72bba 100644
>> --- a/gcc/config/s390/3931.md
>> +++ b/gcc/config/s390/3931.md
>> @@ -404,7 +404,6 @@ vlvgg,
>>   vlvgh,
>>   vlvgp,
>>   vst,
>> -vstbr,
>>   vstbrf,
>>   vstbrg,
>>   vstbrh,
>> @@ -627,7 +626,6 @@ tm,
>>   tmy,
>>   vl,
>>   vlbb,
>> -vlbr,
>>   vlbrf,
>>   vlbrg,
>>   vlbrh,
>> @@ -661,7 +659,6 @@ vlreph,
>>   vlrl,
>>   vlrlr,
>>   vst,
>> -vstbr,
>>   vstbrf,
>>   vstbrg,
>>   vstbrh,
>> @@ -1077,7 +1074,6 @@ vrepb,
>>   vrepf,
>>   vrepg,
>>   vreph,
>> -vrepi,
>>   vrepib,
>>   vrepif,
>>   vrepig,
>> @@ -1930,7 +1926,6 @@ vrepb,
>>   vrepf,
>>   vrepg,
>>   vreph,
>> -vrepi,
>>   vrepib,
>>   vrepif,
>>   vrepig,
>> @@ -2156,7 +2151,6 @@ vistrfs,
>>   vistrhs,
>>   vl,
>>   vlbb,
>> -vlbr,
>>   vlbrf,
>>   vlbrg,
>>   vlbrh,
>> @@ -2248,7 +2242,6 @@ tbegin,
>>   tbeginc,
>>   tend,
>>   vst,
>> -vstbr,
>>   vstbrf,
>>   vstbrg,
>>   vstbrh,
>> diff --git a/gcc/config/s390/s390.md b/gcc/config/s390/s390.md
>> index 50a828f2bbb..8edc1261c38 100644
>> --- a/gcc/config/s390/s390.md
>> +++ b/gcc/config/s390/s390.md
>> @@ -744,7 +744,7 @@
>>   ;; In FP templates, a <dee> in "m<dee><bt>r" will expand to "mx<bt>r" in
>>   ;; TF/TDmode, "md<bt>r" in DF/DDmode, "mee<bt>r" in SFmode and "me<bt>r in
>>   ;; SDmode.
>> -(define_mode_attr xdee [(TF "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
>> +(define_mode_attr xdee [(TF "x") (FPRX2 "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
>>   
>>   ;; The decimal floating point variants of add, sub, div and mul support 3
>>   ;; fp register operands.  The following attributes allow to merge the bfp and
>> diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md
>> index 1bae1056951..f88e8b655fa 100644
>> --- a/gcc/config/s390/vector.md
>> +++ b/gcc/config/s390/vector.md
>> @@ -134,7 +134,7 @@
>>   			(V1TI "q") (TI "q")
>>   			(V1SF "f") (V2SF "f") (V4SF "f")
>>   			(V1DF "g") (V2DF "g")
>> -			(V1TF "q")])
>> +			(V1TF "q") (TF "q")])
>>   
>>   ; This is for vmalhw. It gets an 'w' attached to avoid confusion with
>>   ; multiply and add logical high vmalh.
>> -- 
>> 2.45.0
>>
diff mbox series

Patch

diff --git a/gcc/config/s390/3931.md b/gcc/config/s390/3931.md
index bed1f6c21f1..9cb11b72bba 100644
--- a/gcc/config/s390/3931.md
+++ b/gcc/config/s390/3931.md
@@ -404,7 +404,6 @@  vlvgg,
 vlvgh,
 vlvgp,
 vst,
-vstbr,
 vstbrf,
 vstbrg,
 vstbrh,
@@ -627,7 +626,6 @@  tm,
 tmy,
 vl,
 vlbb,
-vlbr,
 vlbrf,
 vlbrg,
 vlbrh,
@@ -661,7 +659,6 @@  vlreph,
 vlrl,
 vlrlr,
 vst,
-vstbr,
 vstbrf,
 vstbrg,
 vstbrh,
@@ -1077,7 +1074,6 @@  vrepb,
 vrepf,
 vrepg,
 vreph,
-vrepi,
 vrepib,
 vrepif,
 vrepig,
@@ -1930,7 +1926,6 @@  vrepb,
 vrepf,
 vrepg,
 vreph,
-vrepi,
 vrepib,
 vrepif,
 vrepig,
@@ -2156,7 +2151,6 @@  vistrfs,
 vistrhs,
 vl,
 vlbb,
-vlbr,
 vlbrf,
 vlbrg,
 vlbrh,
@@ -2248,7 +2242,6 @@  tbegin,
 tbeginc,
 tend,
 vst,
-vstbr,
 vstbrf,
 vstbrg,
 vstbrh,
diff --git a/gcc/config/s390/s390.md b/gcc/config/s390/s390.md
index 50a828f2bbb..8edc1261c38 100644
--- a/gcc/config/s390/s390.md
+++ b/gcc/config/s390/s390.md
@@ -744,7 +744,7 @@ 
 ;; In FP templates, a <dee> in "m<dee><bt>r" will expand to "mx<bt>r" in
 ;; TF/TDmode, "md<bt>r" in DF/DDmode, "mee<bt>r" in SFmode and "me<bt>r in
 ;; SDmode.
-(define_mode_attr xdee [(TF "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
+(define_mode_attr xdee [(TF "x") (FPRX2 "x") (DF "d") (SF "ee") (TD "x") (DD "d") (SD "e")])
 
 ;; The decimal floating point variants of add, sub, div and mul support 3
 ;; fp register operands.  The following attributes allow to merge the bfp and
diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md
index 1bae1056951..f88e8b655fa 100644
--- a/gcc/config/s390/vector.md
+++ b/gcc/config/s390/vector.md
@@ -134,7 +134,7 @@ 
 			(V1TI "q") (TI "q")
 			(V1SF "f") (V2SF "f") (V4SF "f")
 			(V1DF "g") (V2DF "g")
-			(V1TF "q")])
+			(V1TF "q") (TF "q")])
 
 ; This is for vmalhw. It gets an 'w' attached to avoid confusion with
 ; multiply and add logical high vmalh.