Bug?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Bug?

Gary Benson
Hi all,

I'm looking at hotspot/src/share/vm/runtime/signature.hpp from b22.
Is line 285 really correct?

Cheers,
Gary
Reply | Threaded
Open this post in threaded view
|

Re: Bug?

Sunil Soman-2
Hi Gary,

I suppose that you mean the call to "pass_int" instead of "pass_float" when LP64 is undefd? Not entirely sure about intel, but from interpreter_sparc.cpp:

"   301 // LP64 passes floating point arguments in F1, F3, F5, etc. instead of
    302 // O0, O1, O2 etc..
    303 // Doubles are passed in D0, D2, D4
    304 // We store the signature of the first 16 arguments in the first argument
    305 // slot because it will be overwritten prior to calling the native
    306 // function, with the pointer to the JNIEnv.
    307 // If LP64 there can be up to 16 floating point arguments in registers
    308 // or 6 integer registers."


Hope that helps.
Sunil

On Oct 16, 2007, at 2:29 AM, Gary Benson wrote:

Hi all,

I'm looking at hotspot/src/share/vm/runtime/signature.hpp from b22.
Is line 285 really correct?

Cheers,
Gary


Reply | Threaded
Open this post in threaded view
|

Re: Bug?

steve.goldman
In reply to this post by Gary Benson
Gary Benson wrote:
> Hi all,
>
> I'm looking at hotspot/src/share/vm/runtime/signature.hpp from b22.
> Is line 285 really correct?
>

for the current platforms, yes. On 32bit sparc and any x86 floats aren't
passed in registers so they can be treated like int (I refuse to go look
at the ia64 abi). No doubt it would be cleaner here to make the abstract
code here use float/double to let the implemenation decide what to do.

--
Steve
Reply | Threaded
Open this post in threaded view
|

Re: Bug?

Gary Benson
steve goldman wrote:
> Gary Benson wrote:
> > I'm looking at hotspot/src/share/vm/runtime/signature.hpp from b22.
> > Is line 285 really correct?
>
> for the current platforms, yes. On 32bit sparc and any x86 floats
> aren't passed in registers so they can be treated like int (I
> refuse to go look at the ia64 abi). No doubt it would be cleaner
> here to make the abstract code here use float/double to let the
> implemenation decide what to do.

I had to change this for PPC32 as they're passed in registers there.
I guess I'll end up patching the other platforms once my stuff goes
into IcedTea or wherever.

Cheers,
Gary