| 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 2986 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2997 static const char* harmony_function_sent_natives[] = {nullptr}; | 2997 static const char* harmony_function_sent_natives[] = {nullptr}; |
| 2998 static const char* promise_extra_natives[] = {"native promise-extra.js", | 2998 static const char* promise_extra_natives[] = {"native promise-extra.js", |
| 2999 nullptr}; | 2999 nullptr}; |
| 3000 static const char* harmony_object_values_entries_natives[] = {nullptr}; | 3000 static const char* harmony_object_values_entries_natives[] = {nullptr}; |
| 3001 static const char* harmony_object_own_property_descriptors_natives[] = { | 3001 static const char* harmony_object_own_property_descriptors_natives[] = { |
| 3002 nullptr}; | 3002 nullptr}; |
| 3003 static const char* harmony_array_prototype_values_natives[] = {nullptr}; | 3003 static const char* harmony_array_prototype_values_natives[] = {nullptr}; |
| 3004 static const char* harmony_exponentiation_operator_natives[] = {nullptr}; | 3004 static const char* harmony_exponentiation_operator_natives[] = {nullptr}; |
| 3005 static const char* harmony_string_padding_natives[] = { | 3005 static const char* harmony_string_padding_natives[] = { |
| 3006 "native harmony-string-padding.js", nullptr}; | 3006 "native harmony-string-padding.js", nullptr}; |
| 3007 static const char* icu_case_mapping_natives[] = {"native icu-case-mapping.js", |
| 3008 nullptr}; |
| 3007 | 3009 |
| 3008 for (int i = ExperimentalNatives::GetDebuggerCount(); | 3010 for (int i = ExperimentalNatives::GetDebuggerCount(); |
| 3009 i < ExperimentalNatives::GetBuiltinsCount(); i++) { | 3011 i < ExperimentalNatives::GetBuiltinsCount(); i++) { |
| 3010 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ | 3012 #define INSTALL_EXPERIMENTAL_NATIVES(id, desc) \ |
| 3011 if (FLAG_##id) { \ | 3013 if (FLAG_##id) { \ |
| 3012 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ | 3014 for (size_t j = 0; id##_natives[j] != NULL; j++) { \ |
| 3013 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ | 3015 Vector<const char> script_name = ExperimentalNatives::GetScriptName(i); \ |
| 3014 if (strncmp(script_name.start(), id##_natives[j], \ | 3016 if (strncmp(script_name.start(), id##_natives[j], \ |
| 3015 script_name.length()) == 0) { \ | 3017 script_name.length()) == 0) { \ |
| 3016 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ | 3018 if (!Bootstrapper::CompileExperimentalBuiltin(isolate(), i)) { \ |
| 3017 return false; \ | 3019 return false; \ |
| 3018 } \ | 3020 } \ |
| 3019 } \ | 3021 } \ |
| 3020 } \ | 3022 } \ |
| 3021 } | 3023 } |
| 3022 HARMONY_INPROGRESS(INSTALL_EXPERIMENTAL_NATIVES); | 3024 HARMONY_INPROGRESS(INSTALL_EXPERIMENTAL_NATIVES); |
| 3023 HARMONY_STAGED(INSTALL_EXPERIMENTAL_NATIVES); | 3025 HARMONY_STAGED(INSTALL_EXPERIMENTAL_NATIVES); |
| 3024 HARMONY_SHIPPING(INSTALL_EXPERIMENTAL_NATIVES); | 3026 HARMONY_SHIPPING(INSTALL_EXPERIMENTAL_NATIVES); |
| 3025 INSTALL_EXPERIMENTAL_NATIVES(promise_extra, ""); | 3027 INSTALL_EXPERIMENTAL_NATIVES(promise_extra, ""); |
| 3028 INSTALL_EXPERIMENTAL_NATIVES(icu_case_mapping, ""); |
| 3026 #undef INSTALL_EXPERIMENTAL_NATIVES | 3029 #undef INSTALL_EXPERIMENTAL_NATIVES |
| 3027 } | 3030 } |
| 3028 | 3031 |
| 3029 if (!CallUtilsFunction(isolate(), "PostExperimentals")) return false; | 3032 if (!CallUtilsFunction(isolate(), "PostExperimentals")) return false; |
| 3030 | 3033 |
| 3031 InstallExperimentalBuiltinFunctionIds(); | 3034 InstallExperimentalBuiltinFunctionIds(); |
| 3032 return true; | 3035 return true; |
| 3033 } | 3036 } |
| 3034 | 3037 |
| 3035 | 3038 |
| (...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3673 } | 3676 } |
| 3674 | 3677 |
| 3675 | 3678 |
| 3676 // Called when the top-level V8 mutex is destroyed. | 3679 // Called when the top-level V8 mutex is destroyed. |
| 3677 void Bootstrapper::FreeThreadResources() { | 3680 void Bootstrapper::FreeThreadResources() { |
| 3678 DCHECK(!IsActive()); | 3681 DCHECK(!IsActive()); |
| 3679 } | 3682 } |
| 3680 | 3683 |
| 3681 } // namespace internal | 3684 } // namespace internal |
| 3682 } // namespace v8 | 3685 } // namespace v8 |
| OLD | NEW |