[patch rfc] PUSH_ARGUMENTS() -> push_dummy_call()

Andrew Cagney ac131313@redhat.com
Mon Mar 24 17:04:00 GMT 2003


> While you're rearranging this code,

Think of it as `shuffling deck chairs'.  It is still the same Titanic.

 >  I'd like your thoughts on
> something.  I was working on an old project last week - "catch catch"
> and "catch throw".  A basic implementation is easy.  A more interesting
> implementation, however, requires being able to extract the arguments
> to __cxa_throw (one of the arguments is the object being thrown,
> another is the typeinfo for it).

Have a look at objc-lang.c:FETCH_ARGUMENTS().  I suspect it should be 
called FETCH_POINTER_ARGUMENT(frame, i).

> This requires being able to figure out where a function which takes two
> pointers expects them to be.  __cxa_throw will generally not have any
> debug info.  This logic already exists in the push argument code.

While that method contains the relevant logic, I don't think it is 
easily accessible.

> Is it too much overhead/PITA to restructure it so that we can use that
> information?  If so I'll probably need to add a new architecture method
> to get ths sort of information.

It is definitly beyond the scope of these cleanups.  The interface is 
going to be sufficiently different to need a new architecture method anyway.

Would a FETCH_POINTER_ARGUMENT() method be sufficient for your immediate 
needs?

Andrew




More information about the Gdb-patches mailing list