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

Unified Diff: chrome/common/prefetch_argument_win.h

Issue 1595633002: Use valid /prefetch arguments for process launches on Windows. - do not submit (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move
Patch Set: address simple comments from gab Created 4 years, 11 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
« no previous file with comments | « chrome/common/DEPS ('k') | chrome/common/prefetch_argument_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/prefetch_argument_win.h
diff --git a/chrome/common/prefetch_argument_win.h b/chrome/common/prefetch_argument_win.h
new file mode 100644
index 0000000000000000000000000000000000000000..1b3c32ca886401645ed208f632d019cf26646fb9
--- /dev/null
+++ b/chrome/common/prefetch_argument_win.h
@@ -0,0 +1,25 @@
+// Copyright (c) 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_COMMON_PREFETCH_ARGUMENT_WIN_H_
+#define CHROME_COMMON_PREFETCH_ARGUMENT_WIN_H_
+
+namespace base {
+class CommandLine;
+} // namespace base
+
+namespace chrome {
+// Adds a prefetch argument to |command_line|. The --type and
+// --no-startup-window switches must already have been added, if applicable, as
+// they determine which prefetch argument is added to |command_line|. It has
+// been observed that when file reads are consistent for 3 process launches with
+// the same prefetch argument, the prefetcher starts issuing the reads in batch
+// at process launch. This is more efficient than reading a few pages at a time
+// on-demand. The prefetcher isn't able to observe consistent file reads across
+// Chrome process launches when no prefetch argument is used, because the reads
+// depend on the process type.
+void AddWindowsPrefetchArgument(base::CommandLine* command_line);
+} // namespace chrome
+
+#endif // CHROME_COMMON_PREFETCH_ARGUMENT_WIN_H_
« no previous file with comments | « chrome/common/DEPS ('k') | chrome/common/prefetch_argument_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698