Bug 115215 - Use push and pop for iOS math function thunks
Summary: Use push and pop for iOS math function thunks
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Benjamin Poulain
URL:
Keywords:
Depends on: 115144
Blocks:
  Show dependency treegraph
 
Reported: 2013-04-25 17:58 PDT by Benjamin Poulain
Modified: 2013-04-29 16:53 PDT (History)
2 users (show)

See Also:


Attachments
Patch (1.84 KB, patch)
2013-04-25 18:00 PDT, Benjamin Poulain
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Poulain 2013-04-25 17:58:07 PDT
Use push and pop for iOS math function thunks
Comment 1 Benjamin Poulain 2013-04-25 18:00:36 PDT
Created attachment 199770 [details]
Patch
Comment 2 Filip Pizlo 2013-04-27 15:17:00 PDT
Comment on attachment 199770 [details]
Patch

Did you test that calling printf() or similar from jsRound() for example, and then calling Math.round(), works without crashing?
Comment 3 Benjamin Poulain 2013-04-27 15:20:10 PDT
(In reply to comment #2)
> (From update of attachment 199770 [details])
> Did you test that calling printf() or similar from jsRound() for example, and then calling Math.round(), works without crashing?

I'll try that on Monday.

I am pretty sure of the alignment on 4 bytes because I already accidentally ran into that when I wrote TransformationMatrix's optimizations. I assumed the stack would be at least aligned to 8 bytes when writing the VFP code, and that happily crashed in the tests.
Comment 4 Filip Pizlo 2013-04-27 15:21:08 PDT
Comment on attachment 199770 [details]
Patch

Would be good to do that test before landing.  Otherwise, r=me.
Comment 5 Benjamin Poulain 2013-04-29 16:49:50 PDT
(In reply to comment #4)
> (From update of attachment 199770 [details])
> Would be good to do that test before landing.  Otherwise, r=me.

I just tried on an Apple A5, no problem with printf called from jsRound.
Comment 6 Benjamin Poulain 2013-04-29 16:53:27 PDT
Comment on attachment 199770 [details]
Patch

Clearing flags on attachment: 199770

Committed r149331: <http://trac.webkit.org/changeset/149331>
Comment 7 Benjamin Poulain 2013-04-29 16:53:29 PDT
All reviewed patches have been landed.  Closing bug.