public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: marcusd@cathcart.sysc.pdx.edu (Marcus G. Daniels)
To: Ovidiu Predescu <ovidiu@aracnet.com>
Cc: Scott Christley <scottc@net-community.com>, egcs@cygnus.com
Subject: Re: GCC/ObjC enhancements, comments requested
Date: Mon, 09 Feb 1998 11:31:00 -0000	[thread overview]
Message-ID: <rfira5cendy.fsf@cathcart.sysc.pdx.edu> (raw)
In-Reply-To: <199802090632.WAA09654@aracnet.com>

>>>>> "OP" == Ovidiu Predescu <ovidiu@aracnet.com> writes:

MD>  Hey, if worse came to worst, "gcc -g" generates this knowledge.
MD> Looks to me like "objdump --debugging" reports everything that's
MD> needed.  Link in GNU BFD and load up them reflection data
MD> structures!

OP> BFD can't help us here because it gives information only on the
OP> name of the functions contained in an object file, the argument
OP> types are lost (at least for C and C++ functions, ObjC does encode
OP> the argument and return value types of each method).

Nuhhhh-uhhhhh!  Lookie:

mgd@wijiji[~] $ cat hello.c
static void
twoargs (int val, const char *msg)
{
  printf ("%d %s\n", val, msg);
}

main ()
{
  twoargs (1, "Hello World");
}

mgd@wijiji[~] $ gcc -g hello.c -o hello
mgd@wijiji[~] $ objdump --debugging hello | less
[....CHOMP....]
static void twoargs (int val /* 0x44 */, char *msg /* 0x48 */)
{ /* 0x108e8 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 3 addr 0x108e8 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 4 addr 0x108f4 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 5 addr 0x1090c */
  /* file /net/pele/disk12/Users/mgd/hello.c line 5 addr 0x1090c */
} /* 0x10914 */
int main ()
{ /* 0x10914 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 8 addr 0x10914 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 9 addr 0x10918 */
  /* file /net/pele/disk12/Users/mgd/hello.c line 10 addr 0x1092c */
} /* 0x10934 */  
[....CHOMP....]


(Now requiring and loading up debugging information is probably much
to expensive a proposition, but clearly the compiler is setup to save
this stuff.)

  parent reply	other threads:[~1998-02-09 11:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-02-07 18:11 Scott Christley
1998-02-07 22:43 ` Richard Henderson
1998-02-08 10:21   ` Scott Christley
1998-02-10  3:34     ` Richard Henderson
1998-02-10 14:45   ` Anthony Green
1998-02-08 10:27 ` Ovidiu Predescu
1998-02-08 13:12   ` Marcus G. Daniels
1998-02-08 22:32     ` Ovidiu Predescu
1998-02-09  7:43       ` Bruno Haible
1998-02-09 15:33         ` Ovidiu Predescu
     [not found]           ` <199802092146.WAA04183@halles.ilog.fr>
1998-02-10 10:58             ` Ovidiu Predescu
1998-02-10 14:45               ` Joern Rennecke
1998-02-09 11:31       ` Marcus G. Daniels [this message]
1998-02-10  3:34       ` Richard Henderson
1998-02-10 10:58         ` Ovidiu Predescu
1998-02-09 14:46     ` Anthony Green

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=rfira5cendy.fsf@cathcart.sysc.pdx.edu \
    --to=marcusd@cathcart.sysc.pdx.edu \
    --cc=egcs@cygnus.com \
    --cc=ovidiu@aracnet.com \
    --cc=scottc@net-community.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).