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

Side by Side Diff: src/isolate.cc

Issue 2366283003: Remove runtime zone. (Closed)
Patch Set: Reaction to comments 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
OLDNEW
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/isolate.h" 5 #include "src/isolate.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 8
9 #include <fstream> // NOLINT(readability/streams) 9 #include <fstream> // NOLINT(readability/streams)
10 #include <sstream> 10 #include <sstream>
(...skipping 1957 matching lines...) Expand 10 before | Expand all | Expand 10 after
1968 stack_trace_for_uncaught_exceptions_frame_limit_(0), 1968 stack_trace_for_uncaught_exceptions_frame_limit_(0),
1969 stack_trace_for_uncaught_exceptions_options_(StackTrace::kOverview), 1969 stack_trace_for_uncaught_exceptions_options_(StackTrace::kOverview),
1970 keyed_lookup_cache_(NULL), 1970 keyed_lookup_cache_(NULL),
1971 context_slot_cache_(NULL), 1971 context_slot_cache_(NULL),
1972 descriptor_lookup_cache_(NULL), 1972 descriptor_lookup_cache_(NULL),
1973 handle_scope_implementer_(NULL), 1973 handle_scope_implementer_(NULL),
1974 unicode_cache_(NULL), 1974 unicode_cache_(NULL),
1975 allocator_(FLAG_trace_gc_object_stats 1975 allocator_(FLAG_trace_gc_object_stats
1976 ? new VerboseAccountingAllocator(&heap_, 256 * KB) 1976 ? new VerboseAccountingAllocator(&heap_, 256 * KB)
1977 : new AccountingAllocator()), 1977 : new AccountingAllocator()),
1978 runtime_zone_(new Zone(allocator_)),
1979 inner_pointer_to_code_cache_(NULL), 1978 inner_pointer_to_code_cache_(NULL),
1980 global_handles_(NULL), 1979 global_handles_(NULL),
1981 eternal_handles_(NULL), 1980 eternal_handles_(NULL),
1982 thread_manager_(NULL), 1981 thread_manager_(NULL),
1983 has_installed_extensions_(false), 1982 has_installed_extensions_(false),
1984 regexp_stack_(NULL), 1983 regexp_stack_(NULL),
1985 date_cache_(NULL), 1984 date_cache_(NULL),
1986 call_descriptor_data_(NULL), 1985 call_descriptor_data_(NULL),
1987 // TODO(bmeurer) Initialized lazily because it depends on flags; can 1986 // TODO(bmeurer) Initialized lazily because it depends on flags; can
1988 // be fixed once the default isolate cleanup is done. 1987 // be fixed once the default isolate cleanup is done.
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
2163 void Isolate::SetIsolateThreadLocals(Isolate* isolate, 2162 void Isolate::SetIsolateThreadLocals(Isolate* isolate,
2164 PerIsolateThreadData* data) { 2163 PerIsolateThreadData* data) {
2165 base::Thread::SetThreadLocal(isolate_key_, isolate); 2164 base::Thread::SetThreadLocal(isolate_key_, isolate);
2166 base::Thread::SetThreadLocal(per_isolate_thread_data_key_, data); 2165 base::Thread::SetThreadLocal(per_isolate_thread_data_key_, data);
2167 } 2166 }
2168 2167
2169 2168
2170 Isolate::~Isolate() { 2169 Isolate::~Isolate() {
2171 TRACE_ISOLATE(destructor); 2170 TRACE_ISOLATE(destructor);
2172 2171
2173 // Has to be called while counters_ are still alive
2174 runtime_zone_->DeleteKeptSegment();
2175
2176 // The entry stack must be empty when we get here. 2172 // The entry stack must be empty when we get here.
2177 DCHECK(entry_stack_ == NULL || entry_stack_->previous_item == NULL); 2173 DCHECK(entry_stack_ == NULL || entry_stack_->previous_item == NULL);
2178 2174
2179 delete entry_stack_; 2175 delete entry_stack_;
2180 entry_stack_ = NULL; 2176 entry_stack_ = NULL;
2181 2177
2182 delete unicode_cache_; 2178 delete unicode_cache_;
2183 unicode_cache_ = NULL; 2179 unicode_cache_ = NULL;
2184 2180
2185 delete date_cache_; 2181 delete date_cache_;
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
2242 2238
2243 delete random_number_generator_; 2239 delete random_number_generator_;
2244 random_number_generator_ = NULL; 2240 random_number_generator_ = NULL;
2245 2241
2246 delete debug_; 2242 delete debug_;
2247 debug_ = NULL; 2243 debug_ = NULL;
2248 2244
2249 delete cancelable_task_manager_; 2245 delete cancelable_task_manager_;
2250 cancelable_task_manager_ = nullptr; 2246 cancelable_task_manager_ = nullptr;
2251 2247
2252 delete runtime_zone_;
2253 runtime_zone_ = nullptr;
2254
2255 delete allocator_; 2248 delete allocator_;
2256 allocator_ = nullptr; 2249 allocator_ = nullptr;
2257 2250
2258 #if USE_SIMULATOR 2251 #if USE_SIMULATOR
2259 Simulator::TearDown(simulator_i_cache_, simulator_redirection_); 2252 Simulator::TearDown(simulator_i_cache_, simulator_redirection_);
2260 simulator_i_cache_ = nullptr; 2253 simulator_i_cache_ = nullptr;
2261 simulator_redirection_ = nullptr; 2254 simulator_redirection_ = nullptr;
2262 #endif 2255 #endif
2263 } 2256 }
2264 2257
(...skipping 1019 matching lines...) Expand 10 before | Expand all | Expand 10 after
3284 // Then check whether this scope intercepts. 3277 // Then check whether this scope intercepts.
3285 if ((flag & intercept_mask_)) { 3278 if ((flag & intercept_mask_)) {
3286 intercepted_flags_ |= flag; 3279 intercepted_flags_ |= flag;
3287 return true; 3280 return true;
3288 } 3281 }
3289 return false; 3282 return false;
3290 } 3283 }
3291 3284
3292 } // namespace internal 3285 } // namespace internal
3293 } // namespace v8 3286 } // namespace v8
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | src/list.h » ('j') | src/runtime/runtime-regexp.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698