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

Issue 1850793002: Suppress SparseArray lint warning in Mojo RouterImpl (Closed)

Created:
4 years, 8 months ago by johnme
Modified:
4 years, 8 months ago
Reviewers:
yzshen1
CC:
chromium-reviews, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, darin (slow to review), ben+mojo_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Suppress SparseArray lint warning in Mojo RouterImpl org.chromium.mojo.bindings.RouterImpl uses a HashMap<Long, MessageReceiver> to store the callbacks for all Mojo method calls. Lint complains that this causes unnecessary garbage collection thrashing due to boxing/unboxing of the long map keys, and instead recommends to use an android.util.LongSparseArray. But LongSparseArray is probably not suitable either, since the documentation says it's "not intended to be appropriate for data structures that may contain large numbers of items". This patch suppresses the warning for now. BUG=600699 Committed: https://crrev.com/4d8bdcdeae1ffd4e969e65c8cc87b4491c4d3d1f Cr-Commit-Position: refs/heads/master@{#385201}

Patch Set 1 #

Total comments: 1

Patch Set 2 : Suppress instead #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -0 lines) Patch
M mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java View 1 2 chunks +3 lines, -0 lines 0 comments Download

Messages

Total messages: 15 (5 generated)
johnme
4 years, 8 months ago (2016-03-31 17:51:44 UTC) #2
yzshen1
https://codereview.chromium.org/1850793002/diff/1/mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java File mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java (right): https://codereview.chromium.org/1850793002/diff/1/mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java#newcode99 mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java:99: private LongSparseArray<MessageReceiver> mResponders = new LongSparseArray<MessageReceiver>(); Would you please ...
4 years, 8 months ago (2016-04-04 15:31:42 UTC) #3
agrieve
On 2016/04/04 15:31:42, yzshen1 wrote: > https://codereview.chromium.org/1850793002/diff/1/mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java > File mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java > (right): > > https://codereview.chromium.org/1850793002/diff/1/mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java#newcode99 ...
4 years, 8 months ago (2016-04-04 19:42:39 UTC) #4
yzshen1
On 2016/04/04 19:42:39, agrieve wrote: > On 2016/04/04 15:31:42, yzshen1 wrote: > > > https://codereview.chromium.org/1850793002/diff/1/mojo/public/java/bindings/src/org/chromium/mojo/bindings/RouterImpl.java ...
4 years, 8 months ago (2016-04-04 20:37:00 UTC) #5
yzshen1
On 2016/04/04 20:37:00, yzshen1 wrote: > On 2016/04/04 19:42:39, agrieve wrote: > > On 2016/04/04 ...
4 years, 8 months ago (2016-04-04 20:38:05 UTC) #6
johnme
On 2016/04/04 20:37:00, yzshen1 wrote: > On 2016/04/04 19:42:39, agrieve wrote: > > On 2016/04/04 ...
4 years, 8 months ago (2016-04-05 13:21:27 UTC) #8
yzshen1
lgtm
4 years, 8 months ago (2016-04-05 15:39:10 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1850793002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1850793002/20001
4 years, 8 months ago (2016-04-05 16:06:01 UTC) #11
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 8 months ago (2016-04-05 17:12:53 UTC) #13
commit-bot: I haz the power
4 years, 8 months ago (2016-04-05 17:13:53 UTC) #15
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/4d8bdcdeae1ffd4e969e65c8cc87b4491c4d3d1f
Cr-Commit-Position: refs/heads/master@{#385201}

Powered by Google App Engine
This is Rietveld 408576698