WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
105216
Optimize LayoutUnit::boundedMultiply
https://bugs.webkit.org/show_bug.cgi?id=105216
Summary
Optimize LayoutUnit::boundedMultiply
Emil A Eklund
Reported
2012-12-17 14:16:23 PST
LayoutUnit::boundedMultiply is used for multiplication that's prone to overflow and for all LayoutUnit multiplication if SATURATED_LAYOUT_ARITHMETIC is enabled. The current approach is quite inefficient. Change it to use a more efficient saturated multiplication implementation.
Attachments
Patch
(2.42 KB, patch)
2012-12-17 14:18 PST
,
Emil A Eklund
no flags
Details
Formatted Diff
Diff
Patch
(2.62 KB, patch)
2012-12-17 14:32 PST
,
Emil A Eklund
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Emil A Eklund
Comment 1
2012-12-17 14:18:45 PST
Created
attachment 179801
[details]
Patch
Levi Weintraub
Comment 2
2012-12-17 14:23:09 PST
Comment on
attachment 179801
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=179801&action=review
> Source/WebCore/platform/LayoutUnit.h:490 > + if (high != low >> 31)
It wouldn't hurt to have a comment about the significance of this compare.
> Source/WebCore/platform/LayoutUnit.h:497 > + // FIXME: Should be bounded even in the non-subpixel case.
Thank you :)
Emil A Eklund
Comment 3
2012-12-17 14:32:37 PST
Created
attachment 179803
[details]
Patch
Levi Weintraub
Comment 4
2012-12-17 14:36:41 PST
Comment on
attachment 179803
[details]
Patch LGTM.
Emil A Eklund
Comment 5
2012-12-18 10:47:13 PST
Committed
r138041
: <
http://trac.webkit.org/changeset/138041
>
Tim Horton
Comment 6
2012-12-18 11:44:01 PST
Hopefully-ok follow up build fix:
http://trac.webkit.org/changeset/138046
.
Levi Weintraub
Comment 7
2012-12-18 12:13:33 PST
(In reply to
comment #6
)
> Hopefully-ok follow up build fix:
http://trac.webkit.org/changeset/138046
.
Thanks Tim!
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