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

Side by Side Diff: src/bootstrapper.cc

Issue 504093002: Fix and re-enable test-api/InitializeAndDispose. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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/assembler.cc ('k') | src/compiler/instruction.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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/bootstrapper.h" 5 #include "src/bootstrapper.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/extensions/externalize-string-extension.h" 9 #include "src/extensions/externalize-string-extension.h"
10 #include "src/extensions/free-buffer-extension.h" 10 #include "src/extensions/free-buffer-extension.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 v8::RegisterExtension(externalize_string_extension_); 92 v8::RegisterExtension(externalize_string_extension_);
93 statistics_extension_ = new StatisticsExtension; 93 statistics_extension_ = new StatisticsExtension;
94 v8::RegisterExtension(statistics_extension_); 94 v8::RegisterExtension(statistics_extension_);
95 trigger_failure_extension_ = new TriggerFailureExtension; 95 trigger_failure_extension_ = new TriggerFailureExtension;
96 v8::RegisterExtension(trigger_failure_extension_); 96 v8::RegisterExtension(trigger_failure_extension_);
97 } 97 }
98 98
99 99
100 void Bootstrapper::TearDownExtensions() { 100 void Bootstrapper::TearDownExtensions() {
101 delete free_buffer_extension_; 101 delete free_buffer_extension_;
102 free_buffer_extension_ = NULL;
102 delete gc_extension_; 103 delete gc_extension_;
104 gc_extension_ = NULL;
103 delete externalize_string_extension_; 105 delete externalize_string_extension_;
106 externalize_string_extension_ = NULL;
104 delete statistics_extension_; 107 delete statistics_extension_;
108 statistics_extension_ = NULL;
105 delete trigger_failure_extension_; 109 delete trigger_failure_extension_;
110 trigger_failure_extension_ = NULL;
106 } 111 }
107 112
108 113
109 char* Bootstrapper::AllocateAutoDeletedArray(int bytes) { 114 char* Bootstrapper::AllocateAutoDeletedArray(int bytes) {
110 char* memory = new char[bytes]; 115 char* memory = new char[bytes];
111 if (memory != NULL) { 116 if (memory != NULL) {
112 if (delete_these_arrays_on_tear_down_ == NULL) { 117 if (delete_these_arrays_on_tear_down_ == NULL) {
113 delete_these_arrays_on_tear_down_ = new List<char*>(2); 118 delete_these_arrays_on_tear_down_ = new List<char*>(2);
114 } 119 }
115 delete_these_arrays_on_tear_down_->Add(memory); 120 delete_these_arrays_on_tear_down_->Add(memory);
(...skipping 2606 matching lines...) Expand 10 before | Expand all | Expand 10 after
2722 return from + sizeof(NestingCounterType); 2727 return from + sizeof(NestingCounterType);
2723 } 2728 }
2724 2729
2725 2730
2726 // Called when the top-level V8 mutex is destroyed. 2731 // Called when the top-level V8 mutex is destroyed.
2727 void Bootstrapper::FreeThreadResources() { 2732 void Bootstrapper::FreeThreadResources() {
2728 DCHECK(!IsActive()); 2733 DCHECK(!IsActive());
2729 } 2734 }
2730 2735
2731 } } // namespace v8::internal 2736 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/assembler.cc ('k') | src/compiler/instruction.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698