diff mbox

[rs6000] Add support for vector element-reversal built-ins

Message ID 1461593344.29088.25.camel@oc8801110288.ibm.com
State New
Headers show

Commit Message

Bill Schmidt April 25, 2016, 2:09 p.m. UTC
Hi Segher,

Here's the fix for the obvious pasto separated out.  CCing Richi and
Jakub as I'd appreciate release manager approval to include this in
gcc-6-branch.  This fixes some cases where built-in functions are
connected to the wrong expanders because of copy-paste issues.  These
tend not to be used anyway because the vec_st interface is friendlier,
but we should clean this up.  Is that ok?

Thanks,
Bill


2016-04-25  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>

	* rs6000-builtin.def: Correct pasto error for stxvd2x and stxvw4x
	built-in functions.




On Sun, 2016-04-24 at 15:52 -0500, Segher Boessenkool wrote:
> On Sun, Apr 24, 2016 at 02:06:47PM -0500, Bill Schmidt wrote:
> > ISA 3.0 adds the lvxh8x, lvxb16x, stvxh8x, and stvxb16x instructions,
> 
> lxvh8x etc.  It looks like you only swapped things in this message,
> not in the actual patch :-)
> 
> > (While working on this patch, I happened to notice that the existing
> > entries in rs6000-builtin.def for STXVD2X_<MODE> and STXVW4X_<MODE> are
> > mapped to stxsdx instead of stxvd2x/stxvw4x.  I took the opportunity to
> > correct that as an obvious bug.)
> 
> Does that part need backporting?
> 
> Should the new builtins be documented?
> 
> Looks fine otherwise.
> 
> 
> Segher
>

Comments

Segher Boessenkool April 25, 2016, 2:40 p.m. UTC | #1
On Mon, Apr 25, 2016 at 09:09:03AM -0500, Bill Schmidt wrote:
> Here's the fix for the obvious pasto separated out.  CCing Richi and
> Jakub as I'd appreciate release manager approval to include this in
> gcc-6-branch.  This fixes some cases where built-in functions are
> connected to the wrong expanders because of copy-paste issues.  These
> tend not to be used anyway because the vec_st interface is friendlier,
> but we should clean this up.  Is that ok?

> 2016-04-25  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
> 
> 	* rs6000-builtin.def: Correct pasto error for stxvd2x and stxvw4x
> 	built-in functions.

Hi Bill,

Approved for trunk.  Thanks!


Segher
Jakub Jelinek April 25, 2016, 3:06 p.m. UTC | #2
On Mon, Apr 25, 2016 at 09:09:03AM -0500, Bill Schmidt wrote:
> Hi Segher,
> 
> Here's the fix for the obvious pasto separated out.  CCing Richi and
> Jakub as I'd appreciate release manager approval to include this in
> gcc-6-branch.  This fixes some cases where built-in functions are
> connected to the wrong expanders because of copy-paste issues.  These
> tend not to be used anyway because the vec_st interface is friendlier,
> but we should clean this up.  Is that ok?

Ok for 6.2 (i.e. after 6.1 is released), from what I can see, already 5.x
has the same bug.

	Jakub
Bill Schmidt April 25, 2016, 3:09 p.m. UTC | #3
On Mon, 2016-04-25 at 17:06 +0200, Jakub Jelinek wrote:
> On Mon, Apr 25, 2016 at 09:09:03AM -0500, Bill Schmidt wrote:
> > Hi Segher,
> > 
> > Here's the fix for the obvious pasto separated out.  CCing Richi and
> > Jakub as I'd appreciate release manager approval to include this in
> > gcc-6-branch.  This fixes some cases where built-in functions are
> > connected to the wrong expanders because of copy-paste issues.  These
> > tend not to be used anyway because the vec_st interface is friendlier,
> > but we should clean this up.  Is that ok?
> 
> Ok for 6.2 (i.e. after 6.1 is released), from what I can see, already 5.x
> has the same bug.

Makes sense, thanks!  Yes, 5.x and 4.9.x are both borked as well.
Preparing backports for them also.

Bill

> 
> 	Jakub
>
Segher Boessenkool April 29, 2016, 1:44 p.m. UTC | #4
Hi Bill,

On Mon, Apr 25, 2016 at 09:09:03AM -0500, Bill Schmidt wrote:
> Here's the fix for the obvious pasto separated out.  CCing Richi and
> Jakub as I'd appreciate release manager approval to include this in
> gcc-6-branch.  This fixes some cases where built-in functions are
> connected to the wrong expanders because of copy-paste issues.  These
> tend not to be used anyway because the vec_st interface is friendlier,
> but we should clean this up.  Is that ok?

This is fine for trunk, thanks!


Segher
diff mbox

Patch

Index: gcc/config/rs6000/rs6000-builtin.def
===================================================================
--- gcc/config/rs6000/rs6000-builtin.def	(revision 235411)
+++ gcc/config/rs6000/rs6000-builtin.def	(working copy)
@@ -1391,13 +1391,13 @@  BU_VSX_X (LXVW4X_V4SI,        "lxvw4x_v4si",	MEM)
 BU_VSX_X (LXVW4X_V8HI,        "lxvw4x_v8hi",	MEM)
 BU_VSX_X (LXVW4X_V16QI,	      "lxvw4x_v16qi",	MEM)
 BU_VSX_X (STXSDX,	      "stxsdx",		MEM)
-BU_VSX_X (STXVD2X_V1TI,	      "stxsdx_v1ti",	MEM)
-BU_VSX_X (STXVD2X_V2DF,	      "stxsdx_v2df",	MEM)
-BU_VSX_X (STXVD2X_V2DI,	      "stxsdx_v2di",	MEM)
-BU_VSX_X (STXVW4X_V4SF,	      "stxsdx_v4sf",	MEM)
-BU_VSX_X (STXVW4X_V4SI,	      "stxsdx_v4si",	MEM)
-BU_VSX_X (STXVW4X_V8HI,	      "stxsdx_v8hi",	MEM)
-BU_VSX_X (STXVW4X_V16QI,      "stxsdx_v16qi",	MEM)
+BU_VSX_X (STXVD2X_V1TI,	      "stxvd2x_v1ti",	MEM)
+BU_VSX_X (STXVD2X_V2DF,	      "stxvd2x_v2df",	MEM)
+BU_VSX_X (STXVD2X_V2DI,	      "stxvd2x_v2di",	MEM)
+BU_VSX_X (STXVW4X_V4SF,	      "stxvw4x_v4sf",	MEM)
+BU_VSX_X (STXVW4X_V4SI,	      "stxvw4x_v4si",	MEM)
+BU_VSX_X (STXVW4X_V8HI,	      "stxvw4x_v8hi",	MEM)
+BU_VSX_X (STXVW4X_V16QI,      "stxvw4x_v16qi",	MEM)
 BU_VSX_X (XSABSDP,	      "xsabsdp",	CONST)
 BU_VSX_X (XSADDDP,	      "xsadddp",	FP)
 BU_VSX_X (XSCMPODP,	      "xscmpodp",	FP)