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

Issue 1031443002: remove meaningless matrix benches, add mapPts() and add new benches (Closed)

Created:
5 years, 9 months ago by reed2
Modified:
5 years, 9 months ago
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

remove meaningless matrix benches, add mapPts() and add new benches mapPts definitely faster than mapPoints (identity and perspective same speed). Up to 3x for large values of N. abandoned for https://codereview.chromium.org/1030653002

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+192 lines, -205 lines) Patch
M bench/MatrixBench.cpp View 4 chunks +46 lines, -205 lines 0 comments Download
M include/core/SkMatrix.h View 1 chunk +2 lines, -0 lines 0 comments Download
M src/core/SkMatrix.cpp View 1 chunk +100 lines, -0 lines 0 comments Download
M tests/MatrixTest.cpp View 2 chunks +44 lines, -0 lines 0 comments Download

Messages

Total messages: 13 (4 generated)
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1031443002/1
5 years, 9 months ago (2015-03-22 02:57:01 UTC) #2
commit-bot: I haz the power
Note for Reviewers: The CQ is waiting for an approval. If you believe that the ...
5 years, 9 months ago (2015-03-22 02:57:01 UTC) #3
reed2
Two ideas: 1. I think I need a swizzle of ABCD -> BADC to handle ...
5 years, 9 months ago (2015-03-22 02:58:44 UTC) #5
reed2
Another question (looking ahead to mapXY ... Is there a faster way to convert int ...
5 years, 9 months ago (2015-03-22 03:02:55 UTC) #6
reed2
5 years, 9 months ago (2015-03-22 03:03:33 UTC) #8
commit-bot: I haz the power
No LGTM from a valid reviewer yet. Please ask for an LGTM from a full ...
5 years, 9 months ago (2015-03-22 08:57:06 UTC) #10
mtklein
On 2015/03/22 03:02:55, reed2 wrote: > Another question (looking ahead to mapXY ... > > ...
5 years, 9 months ago (2015-03-23 14:57:08 UTC) #11
mtklein
On 2015/03/22 02:58:44, reed2 wrote: > Two ideas: > > 1. I think I need ...
5 years, 9 months ago (2015-03-23 15:00:17 UTC) #12
mtklein
5 years, 9 months ago (2015-03-23 15:17:49 UTC) #13
Message was sent while issue was closed.
On 2015/03/22 02:58:44, reed2 wrote:
> Two ideas:
> 
> 1. I think I need a swizzle of ABCD -> BADC to handle the affine case, unless
> you guys see how to do it differently.

This is an interesting one.   I've been meaning to look into which swizzles we
can support efficiently on both platforms.

I think this is the list of swizzles that are fast on both SSE and NEON:
   zip on two registers: ABCD, XYZW -> AXBY and/or CZDW
   zip on one register:  ABCD -> AABB and/or CCDD 
  unzip on two registers: ABCD, XYZW -> ACXZ and/or BDYW
  unzip on one register: ABCD -> AACC and/or BBDD

On SSE, the "and" is more expensive than "or", but on NEON you generally get
both together.

We can do ABCD -> BADC by unzip(ABCD) -> AACC,BBDD , then zip(BBDD, AACC) ->
BADC.  I think that'd be 2 ops on NEON, 3 on SSE.

There is another "transpose" swizzle on NEON I need to figure out.  That may be
what we want in fewer steps.

Powered by Google App Engine
This is Rietveld 408576698