67401 Commits

Author SHA1 Message Date
Jeff Brown
6b31449e5d am a17032ee: Merge "Accurately track the sequence numbers of batched events."
* commit 'a17032eeb91f709360b6271b71b85e67f729bcc1':
  Accurately track the sequence numbers of batched events.
2012-02-13 14:05:29 -08:00
Fabrice Di Meglio
8e987bb6ee am 7a29d84f: Merge "Fix bug #5904777 GridLayout should be RTL aware"
* commit '7a29d84f0150b49215726d08a69d343df74e02bc':
  Fix bug #5904777 GridLayout should be RTL aware
2012-02-13 14:02:57 -08:00
Jeff Brown
a17032eeb9 Merge "Accurately track the sequence numbers of batched events." 2012-02-13 14:02:51 -08:00
Fabrice Di Meglio
7a29d84f01 Merge "Fix bug #5904777 GridLayout should be RTL aware" 2012-02-13 14:01:28 -08:00
Jeff Brown
2d34e0cfe7 Accurately track the sequence numbers of batched events.
Instead of sending finished signals immediately when appending to
a batch, record the chain of sequence numbers that were part of
the batch and then send finished signals all at once when done.
This change helps the dispatcher keep track of the true state
of the application and can improve ANR detection slightly.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420
Change-Id: I463c2221e2aa8fdf1c3d670c18e39e59ab69b0db
2012-02-13 13:59:32 -08:00
Jeff Brown
11ffe521b5 am 27b51987: Merge "Enable deferred input messages to be batched."
* commit '27b51987dd3fa7e18703aab45fa10625a56d8c98':
  Enable deferred input messages to be batched.
2012-02-13 13:58:34 -08:00
Jeff Brown
27b51987dd Merge "Enable deferred input messages to be batched." 2012-02-13 13:55:41 -08:00
Fabrice Di Meglio
47d248eb43 Fix bug #5904777 GridLayout should be RTL aware
- update also DEBUG mode for taking care about RTL
- one minor issue remaining: left alignment is not properly honored in RTL

Change-Id: I9a4c8413cb1189a032649472016994642418637b
2012-02-13 13:52:47 -08:00
Tsu Chiang Chuang
a85c4a8333 am 298b8004: am 5f5ea91f: am eb56ad18: am 08eb7dd6: Merge "extending timeout to stabilize tests" into ics-mr1
* commit '298b8004ad1c2cff00676473c702bb4fc98a80a7':
  extending timeout to stabilize tests
2012-02-13 13:50:17 -08:00
Tsu Chiang Chuang
298b8004ad am 5f5ea91f: am eb56ad18: am 08eb7dd6: Merge "extending timeout to stabilize tests" into ics-mr1
* commit '5f5ea91f60b4b7d2fcf3da3603cd745a53cba48f':
  extending timeout to stabilize tests
2012-02-13 13:47:45 -08:00
Tsu Chiang Chuang
5f5ea91f60 am eb56ad18: am 08eb7dd6: Merge "extending timeout to stabilize tests" into ics-mr1
* commit 'eb56ad183af8a9833ff22a22b97f174f05266c58':
  extending timeout to stabilize tests
2012-02-13 13:45:06 -08:00
Tsu Chiang Chuang
eb56ad183a am 08eb7dd6: Merge "extending timeout to stabilize tests" into ics-mr1
* commit '08eb7dd630a2de8dd51a988a747da26ff9d3f8fb':
  extending timeout to stabilize tests
2012-02-13 13:42:45 -08:00
Tsu Chiang Chuang
08eb7dd630 Merge "extending timeout to stabilize tests" into ics-mr1 2012-02-13 13:41:37 -08:00
Dianne Hackborn
55ba110d2f am ec5b5156: Merge "Fix issue where screen rotations would stop animating."
* commit 'ec5b5156e7a6f46cb90f1b3e980b70a11384f43c':
  Fix issue where screen rotations would stop animating.
2012-02-13 13:32:52 -08:00
Dianne Hackborn
ec5b5156e7 Merge "Fix issue where screen rotations would stop animating." 2012-02-13 13:30:53 -08:00
Dianne Hackborn
47960677c0 am 0bbd872e: am d1f88de2: am c1496d2d: Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
* commit '0bbd872ea806470fd007b8ea35f953380a8b4162':
  Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
2012-02-13 12:44:54 -08:00
Jeff Brown
90fde93c47 Enable deferred input messages to be batched.
This is part of a series of changes to improve input system pipelining.

Bug: 5963420
Change-Id: I6874d2128e880a35c6c33890c858cc6ee22af0fd
2012-02-13 12:44:01 -08:00
Dianne Hackborn
0bbd872ea8 am d1f88de2: am c1496d2d: Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
* commit 'd1f88de2c496423e483760654a4381b563dc1e1d':
  Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
2012-02-13 12:41:27 -08:00
Dianne Hackborn
d1f88de2c4 am c1496d2d: Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
* commit 'c1496d2d9a496e4aba817a58ecb9e07fe55cdba5':
  Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
2012-02-13 12:38:37 -08:00
Eric Laurent
69fa5daa4c am 65b8bbd3: Merge "Fix audio preprocessing library wrapper"
* commit '65b8bbd3c9842588702ac3a7860851f0496ed33c':
  Fix audio preprocessing library wrapper
2012-02-13 12:28:38 -08:00
Eric Laurent
65b8bbd3c9 Merge "Fix audio preprocessing library wrapper" 2012-02-13 12:27:27 -08:00
Dianne Hackborn
c1496d2d9a Add xxhdpi; fix ActivityManager.getLauncherLargeIconSize() etc.
Change-Id: I519d6cdc527a402d93b98df17a64fc1da52ad598
2012-02-13 12:01:56 -08:00
Stephen Hines
1bb1178490 am 3be5c856: Revert "Test initialization of constant array exports."
* commit '3be5c8565154c9a6aa7abf0a0d61eaecf114b450':
  Revert "Test initialization of constant array exports."
2012-02-13 12:00:20 -08:00
Stephen Hines
3be5c85651 Revert "Test initialization of constant array exports."
This reverts commit f7c4ce0b6afae9ace59879d625bb9be6bc14899c.
2012-02-13 11:56:29 -08:00
Stephen Hines
f6c233a218 am dfb64e8c: Merge "Test initialization of constant array exports."
* commit 'dfb64e8c805dcb371c747e675bf58b4c9a10e49f':
  Test initialization of constant array exports.
2012-02-13 11:14:58 -08:00
Stephen Hines
dfb64e8c80 Merge "Test initialization of constant array exports." 2012-02-13 11:13:21 -08:00
Dianne Hackborn
4dcece8e50 Fix issue where screen rotations would stop animating.
If we went through the update loop multiple times, and had finished
animating the first time, we would blow away that information the
second time and never kill the animation.

Also moved killing the animation back up to the animation step --
this involves destroying surfaces and such, and so really should
be done as part of the surface transaction.  We can also consider
the screen rotation animation object to be owned by the animation,
so it can destroy it when done.

Change-Id: If24356c509c66d046f2ddfd9ad5bfe12504d7716
2012-02-13 10:37:08 -08:00
Glenn Kasten
b9215280ad am 760a36f2: Merge "Factor out and speed up permission-checking code"
* commit '760a36f20702351f64863e14b2ae15ad1199fdcf':
  Factor out and speed up permission-checking code
2012-02-13 10:34:14 -08:00
Jeff Brown
684f4443d7 am 072ec96a: Implement batching of input events on the consumer side.
* commit '072ec96a4900d4616574733646ee46311cb5d2cb':
  Implement batching of input events on the consumer side.
2012-02-13 10:34:12 -08:00
Jeff Brown
eae4f92828 am 1adee11b: Optimize dispatcher for back-to-back finished signals.
* commit '1adee11b5e644c74a2ed40344f4836de3bd3ac56':
  Optimize dispatcher for back-to-back finished signals.
2012-02-13 10:34:09 -08:00
Jeff Brown
877f352b84 am d1c48a05: Dispatch multiple touch events in parallel.
* commit 'd1c48a0525d05021036d4b14e937e221c0ae1318':
  Dispatch multiple touch events in parallel.
2012-02-13 10:34:07 -08:00
Jeff Brown
477f82dc9a am 8b4be560: Delete premature optimization.
* commit '8b4be56030c3b8c93dfa45bccac7365f90f377ce':
  Delete premature optimization.
2012-02-13 10:33:59 -08:00
Glenn Kasten
760a36f207 Merge "Factor out and speed up permission-checking code" 2012-02-13 10:31:44 -08:00
Jeff Brown
dead32ccc1 am 28b5cf1c: Delete dead code.
* commit '28b5cf1c33df847d667b8974ba07c4157a49b48a':
  Delete dead code.
2012-02-13 10:31:21 -08:00
Jeff Brown
1863d69da8 am 59f1ff99: Delete latency tracking information in the Connection.
* commit '59f1ff99786e9d4a94270d6752aa3ca61e10f0a6':
  Delete latency tracking information in the Connection.
2012-02-13 10:31:19 -08:00
Jeff Brown
9ea6e4d291 am 9831d90d: Remove active connection tracking.
* commit '9831d90db8fba7e967d22b1f86eea1d6ac831541':
  Remove active connection tracking.
2012-02-13 10:31:11 -08:00
Jeff Brown
8eefb07925 am e9bb9be9: Simplify input target handling in the dispatcher.
* commit 'e9bb9be9e46523ed901e38cfa83f4630f6496418':
  Simplify input target handling in the dispatcher.
2012-02-13 10:31:08 -08:00
Jeff Brown
52acea839c am cbee6d6e: Rewrite input transport using sockets.
* commit 'cbee6d6ede0499fb4a2c00bfc00d5db8d9ed5139':
  Rewrite input transport using sockets.
2012-02-13 10:31:06 -08:00
Jeff Brown
efa35663ec am 3241b6b7: Remove batching and streaming from the input dispatcher.
* commit '3241b6b7bd7eff64f0118ba2d636030e505a98f9':
  Remove batching and streaming from the input dispatcher.
2012-02-13 10:31:03 -08:00
Glenn Kasten
81211143c3 Factor out and speed up permission-checking code
Use the caching permission check for dump to save IPC.

Cache getpid() to save kernel call for other permission checks.

The C runtime library getpid() can't cache due to a fork
race condition, but we know that mediaserver doesn't fork.

Don't construct String16 on the stack.

Change-Id: I6be6161dae5155d39ba6ed6228e7683e67be34ed
2012-02-13 10:30:23 -08:00
Jeff Brown
4ea576477f am d4762334: Merge "Process input events immediately when received."
* commit 'd4762334f103055b3aa59d97d027ace7c5950b6e':
  Process input events immediately when received.
2012-02-13 10:28:49 -08:00
Jeff Brown
485e4ae32c am 62d1058c: Merge "Remove the input dispatcher throttle."
* commit '62d1058cc972a8fcb7739547abd3298f5d98a9b1':
  Remove the input dispatcher throttle.
2012-02-13 10:28:47 -08:00
Jeff Brown
072ec96a49 Implement batching of input events on the consumer side.
To support this feature, the input dispatcher now allows input
events to be acknowledged out-of-order.  As a result, the
consumer can choose to defer handling an input event from one
device (because it is building a big batch) while continuing
to handle input events from other devices.

The InputEventReceiver now sends a notification when a batch
is pending.  The ViewRoot handles this notification by scheduling
a draw on the next sync.  When the draw happens, the InputEventReceiver
is instructed to consume all pending batched input events, the
input event queue is fully processed (as much as possible),
and then the ViewRoot performs traversals as usual.

With these changes in place, the input dispatch latency is
consistently less than one frame as long as the application itself
isn't stalled.  Input events are delivered to the application
as soon as possible and are handled as soon as possible.  In practice,
it is no longer possible for an application to build up a huge
backlog of touch events.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I42c01117eca78f12d66d49a736c1c122346ccd1d
2012-02-13 10:28:41 -08:00
Jeff Brown
1adee11b5e Optimize dispatcher for back-to-back finished signals.
Minor tweak to the dispatcher to handle as many finished signals
in a receive callback as possible instead of going back to
the Looper and waiting for the next poll() to hit the callback
again.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I8471107371693e21ce8ce7cca1e8d79ba4ca2351
2012-02-13 10:28:41 -08:00
Jeff Brown
d1c48a0525 Dispatch multiple touch events in parallel.
This change enables the input dispatcher to send multiple touch
events to an application without waiting for them to be acknowledged.
Essentially this is a variation on the old streaming optimization
but it is much more comprehensive.  Event dispatch will stall as
soon as 0.5sec of unacknowledged events are accumulated or a
focused event (such as a key event) needs to be delivered.

Streaming input events makes a tremendous difference in application
performance.  The next step will be to enable batching of input
events on the client side once again.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420
Change-Id: I025df90c06165d719fcca7f63eed322a5cce4a78
2012-02-13 10:28:41 -08:00
Jeff Brown
8b4be56030 Delete premature optimization.
This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I5c182f6e17d468bf3033125b2094b2baa5b94e81
2012-02-13 10:28:41 -08:00
Jeff Brown
28b5cf1c33 Delete dead code.
This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I9f8b93f6a25ddd872f993366b57bab404c93bede
2012-02-13 10:28:40 -08:00
Jeff Brown
59f1ff9978 Delete latency tracking information in the Connection.
The information gathered here will no longer be valid once we
start dispatching multiple events at a time to the same connection.
Moreover, we are more concerned with end-to-end latency, which we
can measure with sufficiently high accuracy in other ways.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I49a0c9876b64af56b40e96e0d98c45f325da2a73
2012-02-13 10:28:40 -08:00
Jeff Brown
9831d90db8 Remove active connection tracking.
The dispatcher no longer needs to track which connections are
active except perhaps for diagnostic purposes, so we might as well
remove this code.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: Ibadc830b7b792a59b9244d0a6e85f320c4947109
2012-02-13 10:28:40 -08:00
Jeff Brown
e9bb9be9e4 Simplify input target handling in the dispatcher.
Since we no longer stream events to the application, we don't need to
keep the current list of input targets around longer than it takes
to begin the dispatch cycle.

This is part of a series of changes to improve input system pipelining.

Bug: 5963420

Change-Id: I5824b04e564c8a4dec991598292441e46c331905
2012-02-13 10:28:40 -08:00