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

Side by Side Diff: src/isolate.cc

Issue 2469002: - Add a pointer to Bootstrapper from Isolate.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/isolates/
Patch Set: '' Created 10 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « src/isolate.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2010 the V8 project authors. All rights reserved. 1 // Copyright 2006-2010 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 return global_isolate; 58 return global_isolate;
59 } else { 59 } else {
60 delete global_isolate; 60 delete global_isolate;
61 global_isolate = NULL; 61 global_isolate = NULL;
62 return NULL; 62 return NULL;
63 } 63 }
64 } 64 }
65 65
66 66
67 Isolate::Isolate() 67 Isolate::Isolate()
68 : stub_cache_(NULL) { 68 : bootstrapper_(NULL),
69 stub_cache_(NULL) {
69 } 70 }
70 71
71 72
72 Isolate::~Isolate() { 73 Isolate::~Isolate() {
73 delete stub_cache_; 74 delete stub_cache_;
74 stub_cache_ = NULL; 75 stub_cache_ = NULL;
76 delete bootstrapper_;
77 bootstrapper_ = NULL;
75 } 78 }
76 79
77 80
78 bool Isolate::Init(Deserializer* des) { 81 bool Isolate::Init(Deserializer* des) {
79 ASSERT(global_isolate == this); 82 ASSERT(global_isolate == this);
80 83
81 bool create_heap_objects = des == NULL; 84 bool create_heap_objects = des == NULL;
82 85
83 #ifdef DEBUG 86 #ifdef DEBUG
84 // The initialization process does not handle memory exhaustion. 87 // The initialization process does not handle memory exhaustion.
85 DisallowAllocationFailure disallow_allocation_failure; 88 DisallowAllocationFailure disallow_allocation_failure;
86 #endif 89 #endif
87 90
91 // Allocate per-isolate globals early.
92 bootstrapper_ = new Bootstrapper();
93
88 // Enable logging before setting up the heap 94 // Enable logging before setting up the heap
89 Logger::Setup(); 95 Logger::Setup();
90 96
91 CpuProfiler::Setup(); 97 CpuProfiler::Setup();
92 98
93 // Setup the platform OS support. 99 // Setup the platform OS support.
94 OS::Setup(); 100 OS::Setup();
95 101
96 // Initialize other runtime facilities 102 // Initialize other runtime facilities
97 #if !V8_HOST_ARCH_ARM && V8_TARGET_ARCH_ARM 103 #if !V8_HOST_ARCH_ARM && V8_TARGET_ARCH_ARM
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 HandleScope scope; 157 HandleScope scope;
152 LOG(LogCodeObjects()); 158 LOG(LogCodeObjects());
153 LOG(LogCompiledFunctions()); 159 LOG(LogCompiledFunctions());
154 } 160 }
155 161
156 return true; 162 return true;
157 } 163 }
158 164
159 165
160 } } // namespace v8::internal 166 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698