OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/assembler.h" | 7 #include "src/assembler.h" |
8 #include "src/base/once.h" | 8 #include "src/base/once.h" |
9 #include "src/base/platform/platform.h" | 9 #include "src/base/platform/platform.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 FlagList::SetFlagsFromString(filter_flag, StrLength(filter_flag)); | 73 FlagList::SetFlagsFromString(filter_flag, StrLength(filter_flag)); |
74 } | 74 } |
75 | 75 |
76 base::OS::Initialize(FLAG_random_seed, FLAG_hard_abort, FLAG_gc_fake_mmap); | 76 base::OS::Initialize(FLAG_random_seed, FLAG_hard_abort, FLAG_gc_fake_mmap); |
77 | 77 |
78 Isolate::InitializeOncePerProcess(); | 78 Isolate::InitializeOncePerProcess(); |
79 | 79 |
80 Sampler::SetUp(); | 80 Sampler::SetUp(); |
81 CpuFeatures::Probe(false); | 81 CpuFeatures::Probe(false); |
82 init_memcopy_functions(); | 82 init_memcopy_functions(); |
83 #ifdef _WIN64 | |
84 init_modulo_function(); | |
85 #endif | |
86 ElementsAccessor::InitializeOncePerProcess(); | 83 ElementsAccessor::InitializeOncePerProcess(); |
87 LOperand::SetUpCaches(); | 84 LOperand::SetUpCaches(); |
88 SetUpJSCallerSavedCodeData(); | 85 SetUpJSCallerSavedCodeData(); |
89 ExternalReference::SetUp(); | 86 ExternalReference::SetUp(); |
90 Bootstrapper::InitializeOncePerProcess(); | 87 Bootstrapper::InitializeOncePerProcess(); |
91 } | 88 } |
92 | 89 |
93 | 90 |
94 void V8::InitializeOncePerProcess() { | 91 void V8::InitializeOncePerProcess() { |
95 base::CallOnce(&init_once, &InitializeOncePerProcessImpl); | 92 base::CallOnce(&init_once, &InitializeOncePerProcessImpl); |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 | 126 |
130 void V8::SetSnapshotBlob(StartupData* snapshot_blob) { | 127 void V8::SetSnapshotBlob(StartupData* snapshot_blob) { |
131 #ifdef V8_USE_EXTERNAL_STARTUP_DATA | 128 #ifdef V8_USE_EXTERNAL_STARTUP_DATA |
132 base::CallOnce(&init_snapshot_once, &SetSnapshotFromFile, snapshot_blob); | 129 base::CallOnce(&init_snapshot_once, &SetSnapshotFromFile, snapshot_blob); |
133 #else | 130 #else |
134 CHECK(false); | 131 CHECK(false); |
135 #endif | 132 #endif |
136 } | 133 } |
137 } // namespace internal | 134 } // namespace internal |
138 } // namespace v8 | 135 } // namespace v8 |
OLD | NEW |