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

Side by Side Diff: src/setup-isolate-full.cc

Issue 2840493002: [snapshot] full setup delegate should also be able to deserialize. (Closed)
Patch Set: fix comment 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 unified diff | Download patch
« no previous file with comments | « src/setup-isolate-deserialize.cc ('k') | src/snapshot/deserializer.cc » ('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 2017 the V8 project authors. All rights reserved. 1 // Copyright 2017 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/setup-isolate.h" 5 #include "src/setup-isolate.h"
6 6
7 #include "src/base/logging.h" 7 #include "src/base/logging.h"
8 #include "src/interpreter/interpreter.h"
8 #include "src/interpreter/setup-interpreter.h" 9 #include "src/interpreter/setup-interpreter.h"
9 #include "src/isolate.h" 10 #include "src/isolate.h"
10 11
11 namespace v8 { 12 namespace v8 {
12 namespace internal { 13 namespace internal {
13 14
14 void SetupIsolateDelegate::SetupBuiltins(Isolate* isolate, 15 void SetupIsolateDelegate::SetupBuiltins(Isolate* isolate,
15 bool create_heap_objects) { 16 bool create_heap_objects) {
16 #ifdef V8_GYP_BUILD
17 // Compatibility hack to keep the deprecated GYP build working.
18 if (create_heap_objects) { 17 if (create_heap_objects) {
19 SetupBuiltinsInternal(isolate); 18 SetupBuiltinsInternal(isolate);
20 } else { 19 } else {
21 isolate->builtins()->MarkInitialized(); 20 DCHECK(isolate->snapshot_available());
22 } 21 }
23 return;
24 #endif
25 DCHECK(create_heap_objects);
26 SetupBuiltinsInternal(isolate);
27 } 22 }
28 23
29 void SetupIsolateDelegate::SetupInterpreter( 24 void SetupIsolateDelegate::SetupInterpreter(
30 interpreter::Interpreter* interpreter, bool create_heap_objects) { 25 interpreter::Interpreter* interpreter, bool create_heap_objects) {
31 #ifdef V8_GYP_BUILD
32 // Compatibility hack to keep the deprecated GYP build working.
33 if (create_heap_objects) { 26 if (create_heap_objects) {
34 interpreter::SetupInterpreter::InstallBytecodeHandlers(interpreter); 27 interpreter::SetupInterpreter::InstallBytecodeHandlers(interpreter);
28 } else {
29 DCHECK(interpreter->IsDispatchTableInitialized());
35 } 30 }
36 return;
37 #endif
38 DCHECK(create_heap_objects);
39 interpreter::SetupInterpreter::InstallBytecodeHandlers(interpreter);
40 } 31 }
41 32
42 } // namespace internal 33 } // namespace internal
43 } // namespace v8 34 } // namespace v8
OLDNEW
« no previous file with comments | « src/setup-isolate-deserialize.cc ('k') | src/snapshot/deserializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698