Bug 139888 - Saturated arithmetics: Incorrect float/double clamping.
Summary: Saturated arithmetics: Incorrect float/double clamping.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: zalan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-12-22 17:25 PST by zalan
Modified: 2015-01-01 00:32 PST (History)
2 users (show)

See Also:


Attachments
Patch (3.68 KB, patch)
2014-12-22 17:29 PST, zalan
no flags Details | Formatted Diff | Diff
Patch (3.50 KB, patch)
2014-12-31 22:56 PST, zalan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description zalan 2014-12-22 17:25:28 PST
#if ENABLE(SATURATED_LAYOUT_ARITHMETIC)
-        m_value = clampTo<float>(value * kFixedPointDenominator, static_cast<float>(INT_MIN), static_cast<float>(INT_MAX));
+        m_value = clampToInteger(value * kFixedPointDenominator);
 #else
Comment 1 zalan 2014-12-22 17:28:02 PST
rdar://problem/19330885
Comment 2 zalan 2014-12-22 17:29:55 PST
Created attachment 243653 [details]
Patch
Comment 3 zalan 2014-12-31 22:56:07 PST
Created attachment 243858 [details]
Patch
Comment 4 WebKit Commit Bot 2015-01-01 00:32:29 PST
Comment on attachment 243858 [details]
Patch

Clearing flags on attachment: 243858

Committed r177845: <http://trac.webkit.org/changeset/177845>
Comment 5 WebKit Commit Bot 2015-01-01 00:32:33 PST
All reviewed patches have been landed.  Closing bug.