public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@cygnus.com>
To: Scott Christley <scottc@net-community.com>
Cc: Richard Henderson <rth@cygnus.com>, egcs@cygnus.com
Subject: Re: GCC/ObjC enhancements, comments requested
Date: Tue, 10 Feb 1998 03:34:00 -0000	[thread overview]
Message-ID: <19980209223400.05888@dot.cygnus.com> (raw)
In-Reply-To: <Pine.LNX.3.95.980208122344.32402A-100000@duncan.net-community.com>

On Sun, Feb 08, 1998 at 12:28:47PM -0800, Scott Christley wrote:
> > I guess I don't understand why you don't just pass everything by
> > reference if you don't know their types.
> 
> We do know the types, the issue is that we don't know the types until
> runtime ...

Which from my point of view counts as not knowing the types.

> ... so we must be able to perform the same logic at runtime that GCC
> at compile time.

Which can be arbitrarily complex for any given target.  Sorry to
rain on your parade, but the calling conventions for Sparc v9 and
MIPS n64, to name two examples, are quite nasty (but efficient)
when it comes to passing structs by value.  

It is sitting in my home directory at the moment, but for a sense
of scope the Sparc v9 function argument and return value macros
are implemented with 12 functions spanning 900 lines -- and I have
yet to add the bits to properly handle C++ nested classes.

> How can this be?  GCC somehow must decide how to pass this information; it
> is obviously doing it when you compile.  The issue is that we need access
> to this logic at runtime.

How?  I can't think of any way at all for you to give direct access
to the backing functions in any coherent fashion.

> I'm afraid I haven't explained the task clearly enough.

The task is clear enough, the reason is not. 

Why is there a requirement that you be able to call arbitrary functions
in the native calling convention?  Why can you not simply pass everything
by reference?  Loading up all pointer registers is a much simpler task.


r~

  reply	other threads:[~1998-02-10  3:34 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 [this message]
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
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=19980209223400.05888@dot.cygnus.com \
    --to=rth@cygnus.com \
    --cc=egcs@cygnus.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).