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

Unified Diff: chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc

Issue 2922653003: TabManager: Kill background tabs before android (background) apps. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc
diff --git a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc
index 1fbefed6b3114f12f1de1f1c3d723b47353e3b5c..a91fcb401fb4ffe7f3ebac0da1ced52454251971 100644
--- a/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc
+++ b/chrome/browser/resource_coordinator/tab_manager_delegate_chromeos.cc
@@ -675,12 +675,11 @@ void TabManagerDelegate::AdjustOomPrioritiesImpl(
int range_middle =
(chrome::kLowestRendererOomScore + chrome::kHighestRendererOomScore) / 2;
- // Find some pivot point. For now processes with priority >= CHROME_INTERNAL
- // are prone to be affected by LRU change. Taking them as "high priority"
- // processes.
+ // Find some pivot point. For now (roughly) apps are in the first half and
+ // tabs are in the second half.
auto lower_priority_part = candidates.end();
for (auto it = candidates.begin(); it != candidates.end(); ++it) {
- if (it->process_type() >= ProcessType::BACKGROUND_APP) {
+ if (it->process_type() >= ProcessType::BACKGROUND_TAB) {
lower_priority_part = it;
break;
}

Powered by Google App Engine
This is Rietveld 408576698