Closed
Bug 716694
Opened 13 years ago
Closed 12 years ago
IonMonkey: Extend JSOP_MOD to work with float arguments
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: ejpbruel, Assigned: jandem)
References
Details
(Whiteboard: [ion:p1:fx18])
Attachments
(2 files, 1 obsolete file)
(deleted),
patch
|
dvander
:
review+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
dvander
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Reporter | ||
Updated•13 years ago
|
Reporter | ||
Comment 1•13 years ago
|
||
As a first step, this patch arranges for the result of an ABI call to be transferred from the x87 stack to the xmm0 register (if the result is a double, and we're on x86, the x64 ABI already puts the result in xmm0 by default).
Before I continue, can somebody take a look at this patch and see if it makes sense?
Attachment #587910 -
Flags: review?(dvander)
Comment on attachment 587910 [details] [diff] [review]
Move double result to xmm0 on x86
Review of attachment 587910 [details] [diff] [review]:
-----------------------------------------------------------------
::: js/src/ion/x86/MacroAssembler-x86.h
@@ +74,5 @@
> // callee. It returns the space which has to be allocated for calling the
> // function.
> //
> // arg Number of arguments of the function.
> + uint32 setupABICall(uint32 arg, bool resultIsDouble = false);
Two suggestions - could this be moved to callWithABI? then you don't have to save it locally, and don't need to change stack computation (you'd just reserve/free in the same place).
It'd also be nice to have an enum input instead of a boolean (it's hard to tell what a boolean means). Like Result_Normal, Result_Double or something.
Attachment #587910 -
Flags: review?(dvander) → review+
Comment 3•13 years ago
|
||
What is the status here?
Reporter | ||
Comment 4•13 years ago
|
||
(In reply to Paul Wright from comment #3)
> What is the status here?
I'm working on this bug. It's currently blocked on bug 709423: we want to use the fmod function to implement the floating-point version of JSOP_MOD, but for this to work, the callWithABI API needs to be able to pass double arguments to a function, and return a double result. I just filed a patch that does exactly that for x86 and x64. Once it gets r+'d, I intend to finish this the implementation of JSOP_MOD for those platforms. The plan is to open a separate bug for the ARM version.
Hopes that answers your question.
Comment 5•13 years ago
|
||
Yes, it does. Thank you!
Assignee | ||
Comment 6•12 years ago
|
||
Pretty straight-forward now that we can use doubles with callWithAbi. With --no-jm this wins about 5-10% on v8-raytrace.
Assignee | ||
Comment 7•12 years ago
|
||
Now marked as call instruction..
Attachment #645302 -
Attachment is obsolete: true
Attachment #645302 -
Flags: review?(dvander)
Attachment #646089 -
Flags: review?(dvander)
Updated•12 years ago
|
Attachment #646089 -
Flags: review?(dvander) → review+
Updated•12 years ago
|
Whiteboard: [ion:p1:fx18]
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•