This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, rs6000] Fix little-endian access to sdmode_stack_slot
- From: David Edelsohn <dje dot gcc at gmail dot com>
- To: Ulrich Weigand <uweigand at de dot ibm dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Sun, 17 Nov 2013 18:26:48 -0500
- Subject: Re: [PATCH, rs6000] Fix little-endian access to sdmode_stack_slot
- Authentication-results: sourceware.org; auth=none
- References: <201311172112 dot rAHLCxOp003742 at d06av02 dot portsmouth dot uk dot ibm dot com>
On Sun, Nov 17, 2013 at 4:12 PM, Ulrich Weigand <uweigand@de.ibm.com> wrote:
> Hello,
>
> when accessing the sdmode_stack_slot, code in rs6000_emit_move would
> unconditionally use
> rtx mem = adjust_address_nv (operands[0], mode, 4);
>
> This is wrong in little-endian mode; we always need to access the
> low word there too.
>
> Fixed by the patch below, which fixes a large number of DFP test
> suite failures in little-endian.
>
> Tested on powerpc64-linux and powerpc64le-linux.
>
> OK for mainline?
> ChangeLog:
>
> * config/rs6000/rs6000.c (rs6000_emit_move): Use low word of
> sdmode_stack_slot also in little-endian mode.
Okay.
Thanks, David