Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(149)

Issue 2433233003: Make SkFixedRound/Ceil/FloorToFixed as inline func (Closed)

Created:
4 years, 2 months ago by liyuqian
Modified:
4 years, 2 months ago
Reviewers:
mtklein, mtklein_C, reed1
CC:
reviews_skia.org
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

Make SkFixedRound/Ceil/FloorToFixed as inline func The macros that we were using will return unsigned int32 instead of signed int32 because of the last 0xFFFF0000 mask. That may bring problems if we right shift that result. Special thanks to mtklein@google.com for helping me find out this issue. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2433233003 Committed: https://skia.googlesource.com/skia/+/3f490cc642202c8ab3d51a8ffbd1782c63b9e6a0

Patch Set 1 #

Total comments: 2

Patch Set 2 : Unit tests #

Total comments: 1

Patch Set 3 : Remove one more bracket #

Unified diffs Side-by-side diffs Delta from patch set Stats (+15 lines, -3 lines) Patch
M include/private/SkFixed.h View 1 2 1 chunk +9 lines, -3 lines 0 comments Download
M tests/MathTest.cpp View 1 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 15 (7 generated)
liyuqian
4 years, 2 months ago (2016-10-20 17:28:04 UTC) #4
reed1
easy to write a unit-test that would have failed before? We have a bunch around ...
4 years, 2 months ago (2016-10-20 17:39:53 UTC) #5
liyuqian
On 2016/10/20 17:39:53, reed1 wrote: > easy to write a unit-test that would have failed ...
4 years, 2 months ago (2016-10-20 17:55:14 UTC) #6
liyuqian
Nit fixed and unit tests added :) https://codereview.chromium.org/2433233003/diff/1/include/private/SkFixed.h File include/private/SkFixed.h (right): https://codereview.chromium.org/2433233003/diff/1/include/private/SkFixed.h#newcode76 include/private/SkFixed.h:76: return (((x) ...
4 years, 2 months ago (2016-10-20 17:55:36 UTC) #7
reed1
lgtm https://codereview.chromium.org/2433233003/diff/20001/include/private/SkFixed.h File include/private/SkFixed.h (right): https://codereview.chromium.org/2433233003/diff/20001/include/private/SkFixed.h#newcode79 include/private/SkFixed.h:79: return (x & 0xFFFF0000); can remove one more ...
4 years, 2 months ago (2016-10-20 17:56:35 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2433233003/40001
4 years, 2 months ago (2016-10-20 18:00:54 UTC) #11
mtklein_C
lgtm
4 years, 2 months ago (2016-10-20 18:06:54 UTC) #13
commit-bot: I haz the power
4 years, 2 months ago (2016-10-20 18:23:12 UTC) #15
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://skia.googlesource.com/skia/+/3f490cc642202c8ab3d51a8ffbd1782c63b9e6a0

Powered by Google App Engine
This is Rietveld 408576698