Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@cygnus.com>
To: gdb-patches@sources.redhat.com
Subject: [rfc/rfa:arm] rewrite arm_push_arguments() as a single  two pass loop
Date: Wed, 29 May 2002 20:32:00 -0000	[thread overview]
Message-ID: <3CF59820.10009@cygnus.com> (raw)

Hello,

The code to push arguments onto the stack, for many ABI's, involves two 
passes:

1. iterate over the arguments. compute the location/offset of each, 
accumulate results (to compute the size of the stack frame).

2. iterate over the arguments, compute the location/offset of each, 
store accordingly

The attached patch rewrites arm_push_arguments() so that the two passes 
are combined into a single two-pass for-loop.  The only difference 
between the first and second pass of the loop is that the second pass 
stores values.  The intent is to make the maintenance of the function 
easier - e.g. adding FP support would now involve one addition 
(currently it involves two).

Thoughts, on the general approach?

It also adds the command ``set debug arm'' which will cause the code to 
print out the arguments as they are pushed.

Ok for arm?
Andrew


             reply	other threads:[~2002-05-30  3:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-29 20:32 Andrew Cagney [this message]
2002-05-30  8:07 ` Andrew Cagney
2002-05-30 11:15   ` Kevin Buettner
2002-06-12  6:12   ` Richard Earnshaw
2002-06-12 14:48     ` Andrew Cagney

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=3CF59820.10009@cygnus.com \
    --to=ac131313@cygnus.com \
    --cc=gdb-patches@sources.redhat.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