This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libffi: new typedef for return value


>>>>> "Jeff" == Jeff Sturm <jsturm@one-point.com> writes:

Jeff> Back in _Jv_CallAnyMethodA, I think we can get by allocating a
Jeff> union of
Jeff> union {
Jeff>   float f;
Jeff>   double d;
Jeff>   long long l;
Jeff>   ffi_arg a;
Jeff> }

This seems reasonable.

Jeff> but I can't see how we can avoid a switch statement for each
Jeff> possible return type.  At least we can avoid specific target
Jeff> macros as in ffitest.c.

This problem is why I had thought about having ffi tell us the
promoted type.  The idea is then the ABI difficulties are isolated in
libffi.  If there is a weird platform, it won't affect libgcj, which
can simply switch based on the promoted type.

Anthony told me today he'd have some hacking time this weekend, so
hopefully this issue will get resolved soon.  This is one of the two
"must fix" bugs I have listed for 3.1.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]