[kaffe] NEED_sysdepCallMethod

Dalibor Topic robilad at kaffe.org
Wed Apr 14 00:38:03 PDT 2004


Hi Kiyo,

Kiyo Inaba wrote:
> While trying to get the latest kaffe for m68k, I become wondering what is the
> purpose of 'NEED_sysdepCallMethod' macro defined in several machine dependent
> codes. That means, this macro is not needed to compile m68k-linux (CVS head)
> and it WAS needed for 1.1.4, but still several other ports have this macro
> defined.

As far as I can tell by looking at kaffe/kaffevm/support.c, it's used to 
  signal that the code is not using libffi, so it should use kaffe's own 
call interface.

Not every platform supported by kaffe is supported (or was supported at 
the time of porting) by libffi, so I assume that's the reason why some 
platforms don't have explicit NEED_sysdepCallMethod checks. I haven't 
looked at 1.1.4's source to see if there was such a check in config/m68k 
yet.

> So, my understanding is the 'ifdef' which surrounded definition for inline
> function 'sysdepCallMethod' should not be needed.
> 
> Am I right?

I think having the libffi option is a good thing. Renaming the 
NEED_sysdepCallMethod preprocessor symbol to something more 
self-explanatory like 'USE_KAFFE_TRAMPOLINES', or USE_LIBFFI_TRAMPOLINES 
or even USE_FFCALL_TRAMPOLINES [1]

> BTW, one more question.
> For m68k-linux, gcc complains that sysdepCallMethod can not be inlined
> because of alloca. When the compilation finished, I will test whether
> this kaffe works or not.

[1] If someone gets around to make kaffe work with ffcall. [2]
[2] http://www.haible.de/bruno/packages-ffcall.html




More information about the kaffe mailing list