Arguments to native functions (?) [a bit long]

Andrew Haley aph@pasanda.cygnus.co.uk
Mon Jun 28 09:37:00 GMT 1999


> Date: Mon, 28 Jun 1999 09:28:24 -0700
> From: Tom Tromey <tromey@cygnus.com>
> 
> >>>>> "Simon" == Simon Gornall <simon@unique-id.com> writes:
> 
> Simon> Anyway, if I call a native function with more than 3 arguments
> Simon> I get a compile-time error saying the linker can't find the
> Simon> native function.
> 
> I see this too.  (And, Andrew, using -fvtable-thunks doesn't help.)

Yeah, I know.  Simon and I have been running through this offline.

> Here is what I see when I run nm on your failing test (modified to
> have 4 arguments and not 5):
> 
>     creche. nm nTest.o | grep calltest
>     00000000 T calltest__4testPQ34java4lang6StringiT1T1
>     creche. nm test.o | grep calltest
>     00000096 d _Utf7calltest
>              U calltest__4testPQ34java4lang6StringiN21
> 
> To me it looks like there is some kind of bug in name mangling.

That's the conclusion I was coming towards.  We tried comparing the
mangled names in the two .o files (via objdump --demangle) and they
seemed identical.  Simon had to leave, so we didn't get any further.

Strange.  I find it amazing that this problem has only just arisen.

Andrew.


More information about the Java mailing list