Bug 15703 - fix numeric functions -- improve correctness and speed
Summary: fix numeric functions -- improve correctness and speed
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Darin Adler
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-10-25 23:24 PDT by Darin Adler
Modified: 2007-10-26 01:04 PDT (History)
0 users

See Also:


Attachments
patch with detailed change log (21.41 KB, patch)
2007-10-26 00:05 PDT, Darin Adler
mjs: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Darin Adler 2007-10-25 23:24:43 PDT
I noticed that our toInteger function was not doing what the specification said it should. And that toInt32 wasn't optimizing enough. So I went and optimized both.
Comment 1 Darin Adler 2007-10-26 00:05:35 PDT
Created attachment 16873 [details]
patch with detailed change log
Comment 2 Maciej Stachowiak 2007-10-26 00:33:18 PDT
Comment on attachment 16873 [details]
patch with detailed change log

r=me with one comment:

please consider using trunc(d) instead of copysign(floor(fabs(d))). 

They should do the same thing.
Comment 3 Darin Adler 2007-10-26 01:04:03 PDT
Committed revision 27095.