This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH], PowerPC PR 61431, Fix little endian word swapping for 128-bit types


On Fri, Jun 6, 2014 at 3:02 PM, Michael Meissner
<meissner@linux.vnet.ibm.com> wrote:
> The pack01.c test fails on GCC 4.8 on little endian power8 systems. In looking
> at it, it is a bug where the V1TI memory operations do not have the word
> swapping define_split support.  GCC 4.9 and trunk can optimize the union to
> stay in a register, so the test case passes on those systems, but it is still a
> bug that would be exposed if you ever need to store vector __int128 values.
> The test p8vector-int128-2.c is such a case, and it needs the fix.
>
> I've tested this via bootstrap and make check on power8 big and little endian
> systems, and there were no regressions.  The test p8vector-int128-2.c now
> passes on the little endian power8 with this fix.
>
> Are these patches ok to check into the trunk, and 4.9/4.8 branches?
>
> 2014-06-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
>
>         PR target/61431
>         * config/rs6000/vsx.md (VSX_LE): Split VSX_D into 2 separate
>         iterators, VSX_D that handles 64-bit types, and VSX_LE that
>         handles swapping the two 64-bit double words on little endian
>         systems.  Include V1TImode and optionally TImode in VSX_LE so that
>         these types are properly swapped.  Change all of the insns and
>         splits that do the 64-bit swaps to use VSX_LE.
>         (vsx_le_perm_load_<mode>): Likewise.
>         (vsx_le_perm_store_<mode>): Likewise.
>         (splitters for little endian memory operations): Likewise.
>         (vsx_xxpermdi2_le_<mode>): Likewise.
>         (vsx_lxvd2x2_le_<mode>): Likewise.
>         (vsx_stxvd2x2_le_<mode>): Likewise.

okay.

Thanks, David


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]