OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1570 INSTALL_NATIVE(JSFunction, "ToUint32", to_uint32_fun); | 1570 INSTALL_NATIVE(JSFunction, "ToUint32", to_uint32_fun); |
1571 INSTALL_NATIVE(JSFunction, "ToInt32", to_int32_fun); | 1571 INSTALL_NATIVE(JSFunction, "ToInt32", to_int32_fun); |
1572 INSTALL_NATIVE(JSFunction, "GlobalEval", global_eval_fun); | 1572 INSTALL_NATIVE(JSFunction, "GlobalEval", global_eval_fun); |
1573 INSTALL_NATIVE(JSFunction, "Instantiate", instantiate_fun); | 1573 INSTALL_NATIVE(JSFunction, "Instantiate", instantiate_fun); |
1574 INSTALL_NATIVE(JSFunction, "ConfigureTemplateInstance", | 1574 INSTALL_NATIVE(JSFunction, "ConfigureTemplateInstance", |
1575 configure_instance_fun); | 1575 configure_instance_fun); |
1576 INSTALL_NATIVE(JSFunction, "GetStackTraceLine", get_stack_trace_line_fun); | 1576 INSTALL_NATIVE(JSFunction, "GetStackTraceLine", get_stack_trace_line_fun); |
1577 INSTALL_NATIVE(JSObject, "functionCache", function_cache); | 1577 INSTALL_NATIVE(JSObject, "functionCache", function_cache); |
1578 INSTALL_NATIVE(JSFunction, "ToCompletePropertyDescriptor", | 1578 INSTALL_NATIVE(JSFunction, "ToCompletePropertyDescriptor", |
1579 to_complete_property_descriptor); | 1579 to_complete_property_descriptor); |
| 1580 INSTALL_NATIVE(JSFunction, "NotifyChange", observers_notify_change); |
| 1581 INSTALL_NATIVE(JSFunction, "EnqueueSpliceRecord", observers_enqueue_splice); |
| 1582 INSTALL_NATIVE(JSFunction, "BeginPerformSplice", |
| 1583 observers_begin_perform_splice); |
| 1584 INSTALL_NATIVE(JSFunction, "EndPerformSplice", |
| 1585 observers_end_perform_splice); |
1580 } | 1586 } |
1581 | 1587 |
1582 | 1588 |
1583 void Genesis::InstallExperimentalNativeFunctions() { | 1589 void Genesis::InstallExperimentalNativeFunctions() { |
1584 INSTALL_NATIVE(JSFunction, "RunMicrotasks", run_microtasks); | 1590 INSTALL_NATIVE(JSFunction, "RunMicrotasks", run_microtasks); |
1585 INSTALL_NATIVE(JSFunction, "EnqueueExternalMicrotask", | 1591 INSTALL_NATIVE(JSFunction, "EnqueueExternalMicrotask", |
1586 enqueue_external_microtask); | 1592 enqueue_external_microtask); |
1587 | 1593 |
1588 if (FLAG_harmony_proxies) { | 1594 if (FLAG_harmony_proxies) { |
1589 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap); | 1595 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap); |
1590 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap); | 1596 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap); |
1591 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap); | 1597 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap); |
1592 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate); | 1598 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate); |
1593 } | 1599 } |
1594 if (FLAG_harmony_observation) { | |
1595 INSTALL_NATIVE(JSFunction, "NotifyChange", observers_notify_change); | |
1596 INSTALL_NATIVE(JSFunction, "EnqueueSpliceRecord", observers_enqueue_splice); | |
1597 INSTALL_NATIVE(JSFunction, "BeginPerformSplice", | |
1598 observers_begin_perform_splice); | |
1599 INSTALL_NATIVE(JSFunction, "EndPerformSplice", | |
1600 observers_end_perform_splice); | |
1601 } | |
1602 } | 1600 } |
1603 | 1601 |
1604 #undef INSTALL_NATIVE | 1602 #undef INSTALL_NATIVE |
1605 | 1603 |
1606 | 1604 |
1607 Handle<JSFunction> Genesis::InstallInternalArray( | 1605 Handle<JSFunction> Genesis::InstallInternalArray( |
1608 Handle<JSBuiltinsObject> builtins, | 1606 Handle<JSBuiltinsObject> builtins, |
1609 const char* name, | 1607 const char* name, |
1610 ElementsKind elements_kind) { | 1608 ElementsKind elements_kind) { |
1611 // --- I n t e r n a l A r r a y --- | 1609 // --- I n t e r n a l A r r a y --- |
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2035 } | 2033 } |
2036 | 2034 |
2037 | 2035 |
2038 bool Genesis::InstallExperimentalNatives() { | 2036 bool Genesis::InstallExperimentalNatives() { |
2039 for (int i = ExperimentalNatives::GetDebuggerCount(); | 2037 for (int i = ExperimentalNatives::GetDebuggerCount(); |
2040 i < ExperimentalNatives::GetBuiltinsCount(); | 2038 i < ExperimentalNatives::GetBuiltinsCount(); |
2041 i++) { | 2039 i++) { |
2042 INSTALL_EXPERIMENTAL_NATIVE(i, symbols, "symbol.js") | 2040 INSTALL_EXPERIMENTAL_NATIVE(i, symbols, "symbol.js") |
2043 INSTALL_EXPERIMENTAL_NATIVE(i, proxies, "proxy.js") | 2041 INSTALL_EXPERIMENTAL_NATIVE(i, proxies, "proxy.js") |
2044 INSTALL_EXPERIMENTAL_NATIVE(i, collections, "collection.js") | 2042 INSTALL_EXPERIMENTAL_NATIVE(i, collections, "collection.js") |
2045 INSTALL_EXPERIMENTAL_NATIVE(i, observation, "object-observe.js") | |
2046 INSTALL_EXPERIMENTAL_NATIVE(i, promises, "promise.js") | 2043 INSTALL_EXPERIMENTAL_NATIVE(i, promises, "promise.js") |
2047 INSTALL_EXPERIMENTAL_NATIVE(i, generators, "generator.js") | 2044 INSTALL_EXPERIMENTAL_NATIVE(i, generators, "generator.js") |
2048 INSTALL_EXPERIMENTAL_NATIVE(i, iteration, "array-iterator.js") | 2045 INSTALL_EXPERIMENTAL_NATIVE(i, iteration, "array-iterator.js") |
2049 INSTALL_EXPERIMENTAL_NATIVE(i, strings, "harmony-string.js") | 2046 INSTALL_EXPERIMENTAL_NATIVE(i, strings, "harmony-string.js") |
2050 INSTALL_EXPERIMENTAL_NATIVE(i, arrays, "harmony-array.js") | 2047 INSTALL_EXPERIMENTAL_NATIVE(i, arrays, "harmony-array.js") |
2051 INSTALL_EXPERIMENTAL_NATIVE(i, maths, "harmony-math.js") | 2048 INSTALL_EXPERIMENTAL_NATIVE(i, maths, "harmony-math.js") |
2052 } | 2049 } |
2053 | 2050 |
2054 InstallExperimentalNativeFunctions(); | 2051 InstallExperimentalNativeFunctions(); |
2055 InstallExperimentalBuiltinFunctionIds(); | 2052 InstallExperimentalBuiltinFunctionIds(); |
(...skipping 681 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2737 return from + sizeof(NestingCounterType); | 2734 return from + sizeof(NestingCounterType); |
2738 } | 2735 } |
2739 | 2736 |
2740 | 2737 |
2741 // Called when the top-level V8 mutex is destroyed. | 2738 // Called when the top-level V8 mutex is destroyed. |
2742 void Bootstrapper::FreeThreadResources() { | 2739 void Bootstrapper::FreeThreadResources() { |
2743 ASSERT(!IsActive()); | 2740 ASSERT(!IsActive()); |
2744 } | 2741 } |
2745 | 2742 |
2746 } } // namespace v8::internal | 2743 } } // namespace v8::internal |
OLD | NEW |