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

Issue 189693002: [Android] Cache additional MotionEvent bits in MotionEventAndroid (Closed)

Created:
6 years, 9 months ago by jdduke (slow)
Modified:
6 years, 9 months ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

[Android] Cache additional MotionEvent bits in MotionEventAndroid Closer inspection of MotionEventAndroid usage revealed that several uncached properties were being accessed on average 2x or more times per event, incurring significant JNI costs. Address this by caching these properties (pointer id, touch size and touch position) for the most common touch scenarios (scroll and pinch). This reduces the time spent processing touch events in the browser by ~20% (.1ms) during scrolling, and ~40% (.2ms) during pinching on a typical Android device. BUG=341613 NOTRY=true Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=255789

Patch Set 1 #

Patch Set 2 : Pass all values on initial JNI call #

Patch Set 3 : Cleanup #

Patch Set 4 : Final cleanup #

Unified diffs Side-by-side diffs Delta from patch set Stats (+149 lines, -20 lines) Patch
M content/browser/android/content_view_core_impl.h View 1 1 chunk +14 lines, -1 line 0 comments Download
M content/browser/android/content_view_core_impl.cc View 1 2 1 chunk +29 lines, -2 lines 0 comments Download
M content/browser/renderer_host/input/motion_event_android.h View 1 2 3 3 chunks +27 lines, -3 lines 0 comments Download
M content/browser/renderer_host/input/motion_event_android.cc View 1 2 4 chunks +64 lines, -12 lines 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/ContentViewCore.java View 1 2 chunks +15 lines, -2 lines 0 comments Download

Messages

Total messages: 21 (0 generated)
jdduke (slow)
aelias@: PTAL. I always suspected we might not be caching all the necessary bits, and ...
6 years, 9 months ago (2014-03-07 01:09:24 UTC) #1
aelias_OOO_until_Jul13
lgtm Hmm, this raises the question of if we could do better with a "push ...
6 years, 9 months ago (2014-03-07 01:18:16 UTC) #2
jdduke (slow)
On 2014/03/07 01:18:16, aelias wrote: > lgtm > > Hmm, this raises the question of ...
6 years, 9 months ago (2014-03-07 03:23:26 UTC) #3
jdduke (slow)
I uploaded a version that provides all cached values along with the touch event injection. ...
6 years, 9 months ago (2014-03-07 20:30:33 UTC) #4
aelias_OOO_until_Jul13
It's more verbose but it's not more complex: in some ways it's simpler since all ...
6 years, 9 months ago (2014-03-07 20:35:20 UTC) #5
jdduke (slow)
The CQ bit was checked by jdduke@chromium.org
6 years, 9 months ago (2014-03-07 21:36:15 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/189693002/60001
6 years, 9 months ago (2014-03-07 21:37:19 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/189693002/60001
6 years, 9 months ago (2014-03-08 11:00:47 UTC) #8
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-08 12:47:00 UTC) #9
commit-bot: I haz the power
Retried try job too often on win for step(s) compile http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win&number=157457
6 years, 9 months ago (2014-03-08 12:47:01 UTC) #10
jdduke (slow)
The CQ bit was checked by jdduke@chromium.org
6 years, 9 months ago (2014-03-08 13:46:21 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/189693002/60001
6 years, 9 months ago (2014-03-08 13:46:59 UTC) #12
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-08 14:43:11 UTC) #13
commit-bot: I haz the power
Retried try job too often on mac_rel for step(s) telemetry_perf_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=mac_rel&number=234391
6 years, 9 months ago (2014-03-08 14:43:11 UTC) #14
jdduke (slow)
The CQ bit was checked by jdduke@chromium.org
6 years, 9 months ago (2014-03-08 15:17:59 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/189693002/60001
6 years, 9 months ago (2014-03-08 15:18:11 UTC) #16
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-08 15:56:13 UTC) #17
commit-bot: I haz the power
Retried try job too often on mac_rel for step(s) telemetry_perf_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=mac_rel&number=234429
6 years, 9 months ago (2014-03-08 15:56:14 UTC) #18
jdduke (slow)
The CQ bit was checked by jdduke@chromium.org
6 years, 9 months ago (2014-03-08 16:24:12 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jdduke@chromium.org/189693002/60001
6 years, 9 months ago (2014-03-08 16:24:24 UTC) #20
commit-bot: I haz the power
6 years, 9 months ago (2014-03-08 18:08:53 UTC) #21
Message was sent while issue was closed.
Change committed as 255789

Powered by Google App Engine
This is Rietveld 408576698