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

Unified Diff: components/nacl/browser/nacl_process_host.cc

Issue 1612663002: Use a valid /prefetch argument when launching a process. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bit
Patch Set: rebase + prefetch argument for crashpad 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
Index: components/nacl/browser/nacl_process_host.cc
diff --git a/components/nacl/browser/nacl_process_host.cc b/components/nacl/browser/nacl_process_host.cc
index 01fed51c21a787607c46095964053e8df3fbad84..863c4b82d5adf016082c97e857d1e27ec7e9e659 100644
--- a/components/nacl/browser/nacl_process_host.cc
+++ b/components/nacl/browser/nacl_process_host.cc
@@ -77,6 +77,7 @@
#include "base/win/scoped_handle.h"
#include "components/nacl/browser/nacl_broker_service_win.h"
#include "components/nacl/common/nacl_debug_exception_handler_win.h"
+#include "components/startup_metric_utils/common/pre_read_field_trial_utils_win.h"
#include "content/public/common/sandbox_init.h"
#endif
@@ -643,7 +644,12 @@ bool NaClProcessHost::LaunchSelLdr() {
if (NaClBrowser::GetDelegate()->DialogsAreSuppressed())
cmd_line->AppendSwitch(switches::kNoErrorDialogs);
- // On Windows we might need to start the broker process to launch a new loader
+#if defined(OS_WIN)
+ if (startup_metric_utils::GetPreReadOptions().use_prefetch_argument)
+ cmd_line->AppendArg(switches::kPrefetchArgumentOther);
+#endif // defined(OS_WIN)
+
+// On Windows we might need to start the broker process to launch a new loader
#if defined(OS_WIN)
if (RunningOnWOW64()) {
if (!NaClBrokerService::GetInstance()->LaunchLoader(
« no previous file with comments | « components/nacl/browser/DEPS ('k') | components/startup_metric_utils/common/pre_read_field_trial_utils_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698