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

Side by Side Diff: src/startup-data-util.cc

Issue 2399323002: Reland of land "Turn libbase into a component" (Closed)
Patch Set: Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « src/icu_util.cc ('k') | src/v8.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/startup-data-util.h" 5 #include "src/startup-data-util.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include "src/base/file-utils.h" 10 #include "src/base/file-utils.h"
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 } 79 }
80 80
81 } // namespace 81 } // namespace
82 #endif // V8_USE_EXTERNAL_STARTUP_DATA 82 #endif // V8_USE_EXTERNAL_STARTUP_DATA
83 83
84 84
85 void InitializeExternalStartupData(const char* directory_path) { 85 void InitializeExternalStartupData(const char* directory_path) {
86 #ifdef V8_USE_EXTERNAL_STARTUP_DATA 86 #ifdef V8_USE_EXTERNAL_STARTUP_DATA
87 char* natives; 87 char* natives;
88 char* snapshot; 88 char* snapshot;
89 LoadFromFiles(RelativePath(&natives, directory_path, "natives_blob.bin"), 89 LoadFromFiles(
90 RelativePath(&snapshot, directory_path, "snapshot_blob.bin")); 90 base::RelativePath(&natives, directory_path, "natives_blob.bin"),
91 base::RelativePath(&snapshot, directory_path, "snapshot_blob.bin"));
91 free(natives); 92 free(natives);
92 free(snapshot); 93 free(snapshot);
93 #endif // V8_USE_EXTERNAL_STARTUP_DATA 94 #endif // V8_USE_EXTERNAL_STARTUP_DATA
94 } 95 }
95 96
96 97
97 void InitializeExternalStartupData(const char* natives_blob, 98 void InitializeExternalStartupData(const char* natives_blob,
98 const char* snapshot_blob) { 99 const char* snapshot_blob) {
99 #ifdef V8_USE_EXTERNAL_STARTUP_DATA 100 #ifdef V8_USE_EXTERNAL_STARTUP_DATA
100 LoadFromFiles(natives_blob, snapshot_blob); 101 LoadFromFiles(natives_blob, snapshot_blob);
101 #endif // V8_USE_EXTERNAL_STARTUP_DATA 102 #endif // V8_USE_EXTERNAL_STARTUP_DATA
102 } 103 }
103 104
104 } // namespace internal 105 } // namespace internal
105 } // namespace v8 106 } // namespace v8
OLDNEW
« no previous file with comments | « src/icu_util.cc ('k') | src/v8.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698