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

Side by Side Diff: src/bootstrapper.cc

Issue 1612323003: Introduce {FAST,SLOW}_STRING_WRAPPER_ELEMENTS (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: one more DCHECK fix Created 4 years, 10 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 | « no previous file | src/builtins.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/api-natives.h" 8 #include "src/api-natives.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/extensions/externalize-string-extension.h" 10 #include "src/extensions/externalize-string-extension.h"
(...skipping 1223 matching lines...) Expand 10 before | Expand all | Expand 10 after
1234 isolate->initial_object_prototype(), Builtins::kStringConstructor); 1234 isolate->initial_object_prototype(), Builtins::kStringConstructor);
1235 string_fun->shared()->set_construct_stub( 1235 string_fun->shared()->set_construct_stub(
1236 *isolate->builtins()->StringConstructor_ConstructStub()); 1236 *isolate->builtins()->StringConstructor_ConstructStub());
1237 string_fun->shared()->DontAdaptArguments(); 1237 string_fun->shared()->DontAdaptArguments();
1238 string_fun->shared()->set_length(1); 1238 string_fun->shared()->set_length(1);
1239 InstallWithIntrinsicDefaultProto(isolate, string_fun, 1239 InstallWithIntrinsicDefaultProto(isolate, string_fun,
1240 Context::STRING_FUNCTION_INDEX); 1240 Context::STRING_FUNCTION_INDEX);
1241 1241
1242 Handle<Map> string_map = 1242 Handle<Map> string_map =
1243 Handle<Map>(native_context()->string_function()->initial_map()); 1243 Handle<Map>(native_context()->string_function()->initial_map());
1244 string_map->set_elements_kind(FAST_STRING_WRAPPER_ELEMENTS);
1244 Map::EnsureDescriptorSlack(string_map, 1); 1245 Map::EnsureDescriptorSlack(string_map, 1);
1245 1246
1246 PropertyAttributes attribs = static_cast<PropertyAttributes>( 1247 PropertyAttributes attribs = static_cast<PropertyAttributes>(
1247 DONT_ENUM | DONT_DELETE | READ_ONLY); 1248 DONT_ENUM | DONT_DELETE | READ_ONLY);
1248 Handle<AccessorInfo> string_length( 1249 Handle<AccessorInfo> string_length(
1249 Accessors::StringLengthInfo(isolate, attribs)); 1250 Accessors::StringLengthInfo(isolate, attribs));
1250 1251
1251 { // Add length. 1252 { // Add length.
1252 AccessorConstantDescriptor d(factory->length_string(), string_length, 1253 AccessorConstantDescriptor d(factory->length_string(), string_length,
1253 attribs); 1254 attribs);
(...skipping 2376 matching lines...) Expand 10 before | Expand all | Expand 10 after
3630 } 3631 }
3631 3632
3632 3633
3633 // Called when the top-level V8 mutex is destroyed. 3634 // Called when the top-level V8 mutex is destroyed.
3634 void Bootstrapper::FreeThreadResources() { 3635 void Bootstrapper::FreeThreadResources() {
3635 DCHECK(!IsActive()); 3636 DCHECK(!IsActive());
3636 } 3637 }
3637 3638
3638 } // namespace internal 3639 } // namespace internal
3639 } // namespace v8 3640 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/builtins.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698