OLD | NEW |
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 2393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2404 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) | 2404 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_property) |
2405 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_name) | 2405 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_name) |
2406 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) | 2406 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_function_sent) |
2407 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(promise_extra) | 2407 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(promise_extra) |
2408 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_explicit_tailcalls) | 2408 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_explicit_tailcalls) |
2409 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) | 2409 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_tailcalls) |
2410 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_instanceof) | 2410 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_instanceof) |
2411 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_restrictive_declarations) | 2411 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_restrictive_declarations) |
2412 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_exponentiation_operator) | 2412 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_exponentiation_operator) |
2413 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_string_padding) | 2413 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_string_padding) |
| 2414 EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_async_await) |
2414 | 2415 |
2415 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, | 2416 void InstallPublicSymbol(Factory* factory, Handle<Context> native_context, |
2416 const char* name, Handle<Symbol> value) { | 2417 const char* name, Handle<Symbol> value) { |
2417 Handle<JSGlobalObject> global( | 2418 Handle<JSGlobalObject> global( |
2418 JSGlobalObject::cast(native_context->global_object())); | 2419 JSGlobalObject::cast(native_context->global_object())); |
2419 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); | 2420 Handle<String> symbol_string = factory->InternalizeUtf8String("Symbol"); |
2420 Handle<JSObject> symbol = Handle<JSObject>::cast( | 2421 Handle<JSObject> symbol = Handle<JSObject>::cast( |
2421 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); | 2422 JSObject::GetProperty(global, symbol_string).ToHandleChecked()); |
2422 Handle<String> name_string = factory->InternalizeUtf8String(name); | 2423 Handle<String> name_string = factory->InternalizeUtf8String(name); |
2423 PropertyAttributes attributes = | 2424 PropertyAttributes attributes = |
(...skipping 547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2971 static const char* harmony_function_sent_natives[] = {nullptr}; | 2972 static const char* harmony_function_sent_natives[] = {nullptr}; |
2972 static const char* promise_extra_natives[] = {"native promise-extra.js", | 2973 static const char* promise_extra_natives[] = {"native promise-extra.js", |
2973 nullptr}; | 2974 nullptr}; |
2974 static const char* harmony_object_values_entries_natives[] = {nullptr}; | 2975 static const char* harmony_object_values_entries_natives[] = {nullptr}; |
2975 static const char* harmony_object_own_property_descriptors_natives[] = { | 2976 static const char* harmony_object_own_property_descriptors_natives[] = { |
2976 nullptr}; | 2977 nullptr}; |
2977 static const char* harmony_array_prototype_values_natives[] = {nullptr}; | 2978 static const char* harmony_array_prototype_values_natives[] = {nullptr}; |
2978 static const char* harmony_exponentiation_operator_natives[] = {nullptr}; | 2979 static const char* harmony_exponentiation_operator_natives[] = {nullptr}; |
2979 static const char* harmony_string_padding_natives[] = { | 2980 static const char* harmony_string_padding_natives[] = { |
2980 "native harmony-string-padding.js", nullptr}; | 2981 "native harmony-string-padding.js", nullptr}; |
| 2982 static const char* harmony_async_await_natives[] = {nullptr}; |
2981 | 2983 |
2982 for (int i = ExperimentalNatives::GetDebuggerCount(); | 2984 for (int i = ExperimentalNatives::GetDebuggerCount(); |
2983 i < ExperimentalNatives::GetBuiltinsCount(); i++) { | 2985 i < ExperimentalNatives::GetBuiltinsCount(); i++) { |
2984 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ | 2986 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ |
2985 if (FLAG_##id) { \ | 2987 if (FLAG_##id) { \ |
2986 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ | 2988 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ |
2987 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ | 2989 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ |
2988 if (strncmp(script_name.start(), id##_natives[j], \ | 2990 if (strncmp(script_name.start(), id##_natives[j], \ |
2989 script_name.length()) == 0) { \ | 2991 script_name.length()) == 0) { \ |
2990 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ | 2992 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ |
(...skipping 653 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3644 } | 3646 } |
3645 | 3647 |
3646 | 3648 |
3647 // Called when the top-level V8 mutex is destroyed. | 3649 // Called when the top-level V8 mutex is destroyed. |
3648 void Bootstrapper::FreeThreadResources() { | 3650 void Bootstrapper::FreeThreadResources() { |
3649 DCHECK(!IsActive()); | 3651 DCHECK(!IsActive()); |
3650 } | 3652 } |
3651 | 3653 |
3652 } // namespace internal | 3654 } // namespace internal |
3653 } // namespace v8 | 3655 } // namespace v8 |
OLD | NEW |