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

Issue 1465623002: ipc: Add basic memory usage tests for attachment brokering. (Closed)

Created:
5 years, 1 month ago by erikchen
Modified:
5 years, 1 month ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ipc: Add basic memory usage tests for attachment brokering. I added two tests for memory leaks in the attachment brokering process. The first checks memory usage after brokering a single, large, shared memory object. The second checks memory usage after brokering a thousand, smaller memory objects. BUG=557387 Committed: https://crrev.com/a519e56d03e1f6d69b7475bdd006f5e47b4f581e Cr-Commit-Position: refs/heads/master@{#360935}

Patch Set 1 #

Total comments: 7

Patch Set 2 : Comments from mark. #

Total comments: 2

Patch Set 3 : Comments from tsepez. #

Patch Set 4 : Comments from tsepez. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+169 lines, -3 lines) Patch
M ipc/attachment_broker_mac_unittest.cc View 1 2 3 9 chunks +169 lines, -3 lines 0 comments Download

Messages

Total messages: 18 (5 generated)
erikchen
tsepez: Please review.
5 years, 1 month ago (2015-11-19 21:37:00 UTC) #2
Tom Sepez
https://codereview.chromium.org/1465623002/diff/1/ipc/attachment_broker_mac_unittest.cc File ipc/attachment_broker_mac_unittest.cc (right): https://codereview.chromium.org/1465623002/diff/1/ipc/attachment_broker_mac_unittest.cc#newcode1205 ipc/attachment_broker_mac_unittest.cc:1205: EXPECT_LE(GetResidentSize(), globals->initial_resident_size + message_size); I worry about these kinds ...
5 years, 1 month ago (2015-11-19 22:17:58 UTC) #3
erikchen
mark: Please review.
5 years, 1 month ago (2015-11-19 22:42:22 UTC) #5
Mark Mentovai
Seems like it might be flaky, but if it’s in fact not flaky practically speaking, ...
5 years, 1 month ago (2015-11-19 22:54:34 UTC) #6
erikchen
tsepez: PTAL https://codereview.chromium.org/1465623002/diff/1/ipc/attachment_broker_mac_unittest.cc File ipc/attachment_broker_mac_unittest.cc (right): https://codereview.chromium.org/1465623002/diff/1/ipc/attachment_broker_mac_unittest.cc#newcode50 ipc/attachment_broker_mac_unittest.cc:50: LOG(FATAL) << "Couldn't get resident size."; On ...
5 years, 1 month ago (2015-11-20 00:37:59 UTC) #7
Tom Sepez
https://codereview.chromium.org/1465623002/diff/20001/ipc/attachment_broker_mac_unittest.cc File ipc/attachment_broker_mac_unittest.cc (right): https://codereview.chromium.org/1465623002/diff/20001/ipc/attachment_broker_mac_unittest.cc#newcode1223 ipc/attachment_broker_mac_unittest.cc:1223: volatile char c = '\0'; I suspect that an ...
5 years, 1 month ago (2015-11-20 17:23:03 UTC) #8
erikchen
https://codereview.chromium.org/1465623002/diff/20001/ipc/attachment_broker_mac_unittest.cc File ipc/attachment_broker_mac_unittest.cc (right): https://codereview.chromium.org/1465623002/diff/20001/ipc/attachment_broker_mac_unittest.cc#newcode1223 ipc/attachment_broker_mac_unittest.cc:1223: volatile char c = '\0'; On 2015/11/20 17:23:03, Tom ...
5 years, 1 month ago (2015-11-20 19:01:20 UTC) #9
Tom Sepez
lgtm
5 years, 1 month ago (2015-11-20 22:15:50 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1465623002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1465623002/60001
5 years, 1 month ago (2015-11-20 22:17:43 UTC) #13
commit-bot: I haz the power
Committed patchset #4 (id:60001)
5 years, 1 month ago (2015-11-20 22:47:58 UTC) #14
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/a519e56d03e1f6d69b7475bdd006f5e47b4f581e Cr-Commit-Position: refs/heads/master@{#360935}
5 years, 1 month ago (2015-11-20 23:03:45 UTC) #15
dcheng
A revert of this CL (patchset #4 id:60001) has been created in https://codereview.chromium.org/1466633003/ by dcheng@chromium.org. ...
5 years, 1 month ago (2015-11-21 02:45:36 UTC) #16
dcheng
5 years, 1 month ago (2015-11-21 02:46:06 UTC) #18
Message was sent while issue was closed.
https://build.chromium.org/p/chromium.memory/builders/Mac%20ASan%2064%20Tests...

Example test failure:
IPCAttachmentBrokerMacTest.MemoryUsageManyMessages (run #1):
[ RUN      ] IPCAttachmentBrokerMacTest.MemoryUsageManyMessages
[99259:3847:1120/182039:22097145484234:WARNING:test_suite.cc(197)] Test launcher
output path
/var/folders/65/nfq1c1v9661b310zc_n399tr0000gp/T/.org.chromium.Chromium.7kx3ef/test_results.xml
exists. Not adding test launcher result printer.
[99259:3847:1120/182039:22097145638327:INFO:attachment_broker_mac_unittest.cc(551)]
Privileged process start.
[99259:3847:1120/182039:22097146340818:INFO:attachment_broker_mac_unittest.cc(568)]
Privileged process spinning run loop.
[99259:3847:1120/182039:22097148139567:INFO:attachment_broker_mac_unittest.cc(576)]
Privileged process running callback.
[99259:3847:1120/182039:22097148480032:INFO:attachment_broker_mac_unittest.cc(1300)]
Disable privileged process message logging.
[99259:3847:1120/182039:22097963456543:INFO:attachment_broker_mac_unittest.cc(1307)]
Increase in memory usage in KB: 9464
../../ipc/attachment_broker_mac_unittest.cc:439: Failure
Value of: RESULT_SUCCESS
  Actual: 1
Expected: get_result_listener()->get_result()
Which is: 2
[99259:3847:1120/182039:22097964293731:INFO:attachment_broker_mac_unittest.cc(587)]
Privileged process end.
[  FAILED  ] IPCAttachmentBrokerMacTest.MemoryUsageManyMessages (1733 ms)

Powered by Google App Engine
This is Rietveld 408576698