From: Mark Kettenis <mark.kettenis@xs4all.nl>
To: joseph@codesourcery.com
Cc: gdb-patches@sourceware.org
Subject: Re: x86 _Decimal128 return value alignment
Date: Fri, 23 Sep 2011 08:31:00 -0000 [thread overview]
Message-ID: <201109230810.p8N8Ajst014183@glazunov.sibelius.xs4all.nl> (raw)
In-Reply-To: <Pine.LNX.4.64.1109222246110.1198@digraph.polyomino.org.uk> (joseph@codesourcery.com)
> Date: Thu, 22 Sep 2011 22:48:57 +0000 (UTC)
> From: "Joseph S. Myers" <joseph@codesourcery.com>
>
> On 32-bit x86, _Decimal128 function return values are stored in a
> location whose address is passed as a hidden parameter. This location
> must be 16-byte aligned. Although GDB knows about 16-byte alignment
> for parameters, it fails to achieve this for this stack slot,
> resulting in problems if, for example, the function called from GDB
> with a _Decimal128 return value uses an SSE store instruction to
> store the return value.
>
> This patch fixes this with an appropriate frame_align function, since
> that's the setting used to control alignment of return value slots.
> Tested on i686-pc-linux-gnu. OK to commit?
Interesting how the ultimate unaligned architecture is slowly turning
into a "strict alignment" architecture.
Anyway, there is no harm in this besides wasting a few bytes on
systems without _Decimal128 support, so sure, go ahead.
> 2011-09-22 Joseph Myers <joseph@codesourcery.com>
>
> * i386-tdep.c (i386_frame_align): New.
> (i386_gdbarch_init): Use i386_frame_align.
next prev parent reply other threads:[~2011-09-23 8:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-22 23:32 Joseph S. Myers
2011-09-23 8:31 ` Mark Kettenis [this message]
2011-09-23 9:50 ` Jan Kratochvil
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201109230810.p8N8Ajst014183@glazunov.sibelius.xs4all.nl \
--to=mark.kettenis@xs4all.nl \
--cc=gdb-patches@sourceware.org \
--cc=joseph@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox