WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 15617
improve speed of integer conversions
https://bugs.webkit.org/show_bug.cgi?id=15617
Summary
improve speed of integer conversions
Darin Adler
Reported
2007-10-22 07:31:19 PDT
I was able to get a 1% speedup on SunSpider by eliminating an unnecessary float/double conversion.
Attachments
patch with change log
(4.45 KB, patch)
2007-10-22 07:36 PDT
,
Darin Adler
no flags
Details
Formatted Diff
Diff
patch with change log
(14.77 KB, patch)
2007-10-22 10:15 PDT
,
Darin Adler
no flags
Details
Formatted Diff
Diff
patch with change log (newer version with fixed .exp file)
(14.77 KB, patch)
2007-10-22 10:26 PDT
,
Darin Adler
eric
: review+
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Darin Adler
Comment 1
2007-10-22 07:36:43 PDT
Created
attachment 16798
[details]
patch with change log
Mark Rowe (bdash)
Comment 2
2007-10-22 07:51:49 PDT
This looks nearly identical to Eric's patch on
bug 15607
.
Darin Adler
Comment 3
2007-10-22 10:05:00 PDT
I have a better version in the works.
Darin Adler
Comment 4
2007-10-22 10:15:39 PDT
Created
attachment 16802
[details]
patch with change log
Darin Adler
Comment 5
2007-10-22 10:26:42 PDT
Created
attachment 16803
[details]
patch with change log (newer version with fixed .exp file)
Eric Seidel (no email)
Comment 6
2007-10-22 10:49:28 PDT
Comment on
attachment 16803
[details]
patch with change log (newer version with fixed .exp file) Looks great. I assume you ran the tests. Also, (pot calling the kettle black here) I think it would be nice to replace all your float special values 4294967296.0, etc with some nice names (to make the code make sense to someone who didn't just hack on it for a couple hours. :) (Also, nice catch with toInt32SlowCase calling toUInt32. I'm curious if that would ever be "wrong" (such that we could build a test). I guess it just changes what values could be stored in the float, since it's just doing the sign wrap at a different time.
Darin Adler
Comment 7
2007-10-22 10:57:10 PDT
(In reply to
comment #6
)
> (Also, nice catch with > toInt32SlowCase calling toUInt32. I'm curious if that would ever be "wrong" > (such that we could build a test).
It wasn't wrong in the sense of "buggy". It was just inefficient for negative numbers.
Darin Adler
Comment 8
2007-10-22 10:58:40 PDT
(In reply to
comment #6
)
> I think it would be nice to replace all your float special values > 4294967296.0, etc with some nice names (to make the code make sense to someone > who didn't just hack on it for a couple hours. :)
I'll consider that. I'm worried that if I use const double or const float that it will generate different code, so it's a change I need to make carefully with measurements.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug