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

Issue 305533006: Control process backgrounding from within the child process on Windows. (Closed)

Created:
6 years, 6 months ago by DaleCurtis
Modified:
6 years, 6 months ago
Reviewers:
jam, luken, nasko
CC:
chromium-reviews, darin-cc_chromium.org, nasko+codewatch_chromium.org, jam, creis+watch_chromium.org
Visibility:
Public.

Description

Control process backgrounding from within the child process on Windows. Windows has a fancy backgrounding mode which lowers IO priority. Sadly it can only be set from within the process to be backgrounded. So add a new ChildProcessMsg to tell child processes when they should enter and leave background mode. This reduces glitching during background tab load. This should only be landed along with https://codereview.chromium.org/298253004/ which removes backgrounding for active audio tabs. I expect this will reduce CPU and I/O load significantly for background processes which will lead to power savings. This is only done on Windows since ChromeOS / Linux require privileges only available to the browser process for setting background mode. BUG=362294 TEST=Play audio. Load background tabs. Observe less/no glitching. R=jam@chromium.org, luken@chromium.org, nasko@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=274071

Patch Set 1 : Fix other platforms. #

Total comments: 4

Patch Set 2 : Comments. #

Patch Set 3 : Rebase. Disable test. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -3 lines) Patch
M chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc View 1 2 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 2 chunks +9 lines, -2 lines 0 comments Download
M content/child/child_thread.h View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M content/child/child_thread.cc View 1 2 2 chunks +10 lines, -0 lines 0 comments Download
M content/common/child_process_messages.h View 1 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
DaleCurtis
luken: General review (per cpu@). jam: content/ approval. nasko: content/common/child_messages.h approval.
6 years, 6 months ago (2014-05-28 23:00:09 UTC) #1
nasko
LGTM with a nit. https://codereview.chromium.org/305533006/diff/30001/content/child/child_thread.cc File content/child/child_thread.cc (right): https://codereview.chromium.org/305533006/diff/30001/content/child/child_thread.cc#newcode557 content/child/child_thread.cc:557: base::Process::Current().SetProcessBackgrounded(background); Out of curiosity, does ...
6 years, 6 months ago (2014-05-28 23:08:37 UTC) #2
DaleCurtis
https://codereview.chromium.org/305533006/diff/30001/content/child/child_thread.cc File content/child/child_thread.cc (right): https://codereview.chromium.org/305533006/diff/30001/content/child/child_thread.cc#newcode557 content/child/child_thread.cc:557: base::Process::Current().SetProcessBackgrounded(background); On 2014/05/28 23:08:37, nasko wrote: > Out of ...
6 years, 6 months ago (2014-05-29 00:06:59 UTC) #3
jam
lgtm
6 years, 6 months ago (2014-05-29 17:28:58 UTC) #4
luken
lgtm
6 years, 6 months ago (2014-05-30 17:57:22 UTC) #5
DaleCurtis
The CQ bit was checked by dalecurtis@chromium.org
6 years, 6 months ago (2014-05-30 19:41:56 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dalecurtis@chromium.org/305533006/50001
6 years, 6 months ago (2014-05-30 19:43:08 UTC) #7
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: win_chromium_rel on tryserver.chromium ...
6 years, 6 months ago (2014-05-31 01:20:21 UTC) #8
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-05-31 03:38:16 UTC) #9
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/win_chromium_rel/builds/22003)
6 years, 6 months ago (2014-05-31 03:38:16 UTC) #10
DaleCurtis
I had to disable the ChromeRenderProcessHostTest.Backgrounding test since there doesn't appear to be a clean ...
6 years, 6 months ago (2014-05-31 04:05:26 UTC) #11
DaleCurtis
The CQ bit was checked by dalecurtis@chromium.org
6 years, 6 months ago (2014-05-31 04:06:09 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dalecurtis@chromium.org/305533006/70001
6 years, 6 months ago (2014-05-31 04:08:29 UTC) #13
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: win_chromium_rel on tryserver.chromium ...
6 years, 6 months ago (2014-05-31 07:40:12 UTC) #14
DaleCurtis
6 years, 6 months ago (2014-05-31 22:26:39 UTC) #15
Message was sent while issue was closed.
Committed patchset #3 manually as r274071 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698