diff mbox series

[rs6000] Backport of stxvl instruction fix to GCC 7

Message ID 1531180203.4606.16.camel@us.ibm.com
State New
Headers show
Series [rs6000] Backport of stxvl instruction fix to GCC 7 | expand

Commit Message

Carl Love July 9, 2018, 11:50 p.m. UTC
GCC Maintainers:

The following patch is a back port for a commit to mainline prior to
GCC 8 release.  Note, the code fixed by this patch was later modified
in commit 256798 as part of adding vec_xst_len support.  The sldi
instruction gets replaced by an ashift of the operand for the stxvl
instruction.  Commit 256798 adds additional functionality and does not
fix any functional issues.  Hence it is not being back ported, just the
original bug fix given below.

The patch has been tested on 

    powerpc64le-unknown-linux-gnu (Power 8 LE)  

With no regressions.

Please let me know if the patch looks OK for GCC 7.

                         Carl Love
-----------------------------------------------------------------------
2018-07-09  Carl Love  <cel@us.ibm.com>

	Backport from mainline
	2017-09-07  Carl Love  <cel@us.ibm.com>

	* config/rs6000/vsx.md (define_insn "*stxvl"): Add missing argument to
	the sldi instruction.
---
 gcc/config/rs6000/vsx.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
2.7.4

Comments

Segher Boessenkool July 10, 2018, 5:16 p.m. UTC | #1
On Mon, Jul 09, 2018 at 04:50:03PM -0700, Carl Love wrote:
> The following patch is a back port for a commit to mainline prior to
> GCC 8 release.  Note, the code fixed by this patch was later modified
> in commit 256798 as part of adding vec_xst_len support.  The sldi
> instruction gets replaced by an ashift of the operand for the stxvl
> instruction.  Commit 256798 adds additional functionality and does not
> fix any functional issues.  Hence it is not being back ported, just the
> original bug fix given below.
> 
> The patch has been tested on 
> 
>     powerpc64le-unknown-linux-gnu (Power 8 LE)  
> 
> With no regressions.
> 
> Please let me know if the patch looks OK for GCC 7.

This is fine.  Thanks!


Segher


> 	Backport from mainline
> 	2017-09-07  Carl Love  <cel@us.ibm.com>
> 
> 	* config/rs6000/vsx.md (define_insn "*stxvl"): Add missing argument to
> 	the sldi instruction.
diff mbox series

Patch

diff --git a/gcc/config/rs6000/vsx.md b/gcc/config/rs6000/vsx.md
index eef5357..37d768f 100644
--- a/gcc/config/rs6000/vsx.md
+++ b/gcc/config/rs6000/vsx.md
@@ -3946,7 +3946,7 @@ 
 	  (match_operand:DI 2 "register_operand" "+r")]
 	 UNSPEC_STXVL))]
   "TARGET_P9_VECTOR && TARGET_64BIT"
-  "sldi %2,%2\;stxvl %x0,%1,%2"
+  "sldi %2,%2,56\;stxvl %x0,%1,%2"
   [(set_attr "length" "8")
    (set_attr "type" "vecstore")])