From: Mark Kettenis <mark.kettenis@xs4all.nl>
To: guitton@adacore.com
Cc: gdb-patches@sourceware.org
Subject: Re: [RFA] sparc-solaris stack-checking - new prologue sequence
Date: Thu, 19 May 2011 09:44:00 -0000 [thread overview]
Message-ID: <201105190943.p4J9hkTv026774@glazunov.sibelius.xs4all.nl> (raw)
In-Reply-To: <20110519092016.GC64873@adacore.com> (message from Jerome Guitton on Thu, 19 May 2011 11:20:16 +0200)
> Date: Thu, 19 May 2011 11:20:16 +0200
> From: Jerome Guitton <guitton@adacore.com>
>
> Ping? I'm attaching a slightly different patch after having fixed
> a small style issue.
>
> I can now run the gdb-testsuite without crashing my sparc-solaris
> machine; not sure what have changed in the meantime. In any case, I
> had no new regressions and one new PASS (stack-checking.exp).
>
> OK to apply?
I had wanted to give this a spin on OpenBSD/sparc, but unfortunately
my SS20 seems to have hardware issues. Origionally I thought the
changes were restricted to 32-bit code. But it seems this code is use
for 64-bit code as well. So I'll give this a spin on an
OpenBSD/sparc64 machine tonight.
Some (very minor) turd shining nits:
> gdb/ChangeLog:
>
> * sparc-tdep.c (sparc_skip_stack_check): Recognize a new instruction
> sequence for probing loops.
>
> diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
> index 1039bd8..5f07827 100644
> --- a/gdb/sparc-tdep.c
> +++ b/gdb/sparc-tdep.c
> @@ -609,9 +609,28 @@ sparc_skip_stack_check (const CORE_ADDR start_pc)
> CORE_ADDR pc = start_pc;
> unsigned long insn;
> int offset_stack_checking_sequence = 0;
> + int probing_loop = 0;
>
> /* With GCC, all stack checking sequences begin with the same two
> - instructions. */
> + instructions, plus an optional one in the case of a probing loop:
> +
> + sethi <some immediate>,%g1
> + sub %sp, %g1, %g1
> +
> + or:
> +
> + sethi <some immediate>,%g1
> + sethi <some immediate>, %g4
> + sub %sp, %g1, %g1
> +
> + or:
> +
> + sethi <some immediate>,%g1
> + sub %sp, %g1, %g1
> + sethi <some immediate>, %g4
Spacing here is a tad bit inconsistent. Would be nice if you could
make sure there always is a space after a comma.
> + /* optional: sethi <some immediate>, %g4 */
And here there are two spaces after the sethi, where you use only a
single space before.
next prev parent reply other threads:[~2011-05-19 9:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-06 0:46 Jerome Guitton
2011-05-19 9:20 ` Jerome Guitton
2011-05-19 9:44 ` Mark Kettenis [this message]
2011-05-19 10:17 ` Jerome Guitton
2011-05-20 17:32 ` Mark Kettenis
2011-05-23 16:38 ` Jerome Guitton
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=201105190943.p4J9hkTv026774@glazunov.sibelius.xs4all.nl \
--to=mark.kettenis@xs4all.nl \
--cc=gdb-patches@sourceware.org \
--cc=guitton@adacore.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