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

Issue 1452903004: div255(x) as ((x+128)*257)>>16 with SSE (Closed)

Created:
5 years, 1 month ago by mtklein_C
Modified:
5 years, 1 month ago
Reviewers:
mtklein, reed1
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

div255(x) as ((x+128)*257)>>16 with SSE _mm_mulhi_epu16 makes the (...*257)>>16 part simple. This seems to speed up every transfermode that uses div255(), in the 7-25% range. It even appears to obviate the need for approxMulDiv255() on SSE. I'm not sure about NEON yet, so I'll keep approxMulDiv255() for now. Should be no pixels change: https://gold.skia.org/search2?issue=1452903004&unt=true&query=source_type%3Dgm&master=false BUG=skia: CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Committed: https://skia.googlesource.com/skia/+/cbf4fba43933302a846872e4c5ce8f1adb8b325e

Patch Set 1 #

Patch Set 2 : rest #

Patch Set 3 : notes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -5 lines) Patch
M src/core/Sk4px.h View 1 chunk +1 line, -5 lines 0 comments Download
M src/opts/Sk4px_NEON.h View 1 1 chunk +6 lines, -0 lines 0 comments Download
M src/opts/Sk4px_SSE2.h View 1 2 1 chunk +9 lines, -0 lines 0 comments Download
M src/opts/Sk4px_none.h View 1 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 14 (8 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1452903004/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1452903004/40001
5 years, 1 month ago (2015-11-17 21:46:48 UTC) #3
mtklein_C
This is a follow up from that unit test CL from this morning.
5 years, 1 month ago (2015-11-17 21:56:07 UTC) #8
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 1 month ago (2015-11-17 21:58:39 UTC) #10
reed1
wow wow wow lgtm
5 years, 1 month ago (2015-11-17 22:12:21 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1452903004/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1452903004/40001
5 years, 1 month ago (2015-11-17 22:19:15 UTC) #13
commit-bot: I haz the power
5 years, 1 month ago (2015-11-17 22:19:56 UTC) #14
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://skia.googlesource.com/skia/+/cbf4fba43933302a846872e4c5ce8f1adb8b325e

Powered by Google App Engine
This is Rietveld 408576698