[cxx-abi-dev] IA-64... and GCC 3

Mark Mitchell mark at codesourcery.com
Fri Jul 13 17:04:51 UTC 2001



--On Friday, July 13, 2001 09:12:45 PM +0200 "Peter R. Torpman" 
<peter.torpman at ericsson.com> wrote:

> Hi!
>
> I'm using GCC 3 now and earlier we used the following for defining
> a virtual function table for use when calling functions in C++ from C.

It is extremely difficult to do this with the C++ ABI, in general.
If there are virtual bases, I would say that it becomes nearly impossible. 
If there are not virtual bases, then you should be able to do something
like:

  struct vtbl {
    void *dummy;
    void (*fn1) ();
  };

However, this will *not* work on IA64 in the long-term because
it will use function-descriptors, not function-pointers, in the
vtable.  (GCC doesn't do this, yet.)

-- 
Mark Mitchell                mark at codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com



More information about the cxx-abi-dev mailing list