| 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 1560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1571 INSTALL_NATIVE(JSFunction, "ToUint32", to_uint32_fun); | 1571 INSTALL_NATIVE(JSFunction, "ToUint32", to_uint32_fun); |
| 1572 INSTALL_NATIVE(JSFunction, "ToInt32", to_int32_fun); | 1572 INSTALL_NATIVE(JSFunction, "ToInt32", to_int32_fun); |
| 1573 INSTALL_NATIVE(JSFunction, "GlobalEval", global_eval_fun); | 1573 INSTALL_NATIVE(JSFunction, "GlobalEval", global_eval_fun); |
| 1574 INSTALL_NATIVE(JSFunction, "Instantiate", instantiate_fun); | 1574 INSTALL_NATIVE(JSFunction, "Instantiate", instantiate_fun); |
| 1575 INSTALL_NATIVE(JSFunction, "ConfigureTemplateInstance", | 1575 INSTALL_NATIVE(JSFunction, "ConfigureTemplateInstance", |
| 1576 configure_instance_fun); | 1576 configure_instance_fun); |
| 1577 INSTALL_NATIVE(JSFunction, "GetStackTraceLine", get_stack_trace_line_fun); | 1577 INSTALL_NATIVE(JSFunction, "GetStackTraceLine", get_stack_trace_line_fun); |
| 1578 INSTALL_NATIVE(JSObject, "functionCache", function_cache); | 1578 INSTALL_NATIVE(JSObject, "functionCache", function_cache); |
| 1579 INSTALL_NATIVE(JSFunction, "ToCompletePropertyDescriptor", | 1579 INSTALL_NATIVE(JSFunction, "ToCompletePropertyDescriptor", |
| 1580 to_complete_property_descriptor); | 1580 to_complete_property_descriptor); |
| 1581 INSTALL_NATIVE(JSFunction, "NotifyChange", observers_notify_change); |
| 1582 INSTALL_NATIVE(JSFunction, "EnqueueSpliceRecord", observers_enqueue_splice); |
| 1583 INSTALL_NATIVE(JSFunction, "BeginPerformSplice", |
| 1584 observers_begin_perform_splice); |
| 1585 INSTALL_NATIVE(JSFunction, "EndPerformSplice", |
| 1586 observers_end_perform_splice); |
| 1581 } | 1587 } |
| 1582 | 1588 |
| 1583 | 1589 |
| 1584 void Genesis::InstallExperimentalNativeFunctions() { | 1590 void Genesis::InstallExperimentalNativeFunctions() { |
| 1585 INSTALL_NATIVE(JSFunction, "RunMicrotasks", run_microtasks); | 1591 INSTALL_NATIVE(JSFunction, "RunMicrotasks", run_microtasks); |
| 1586 INSTALL_NATIVE(JSFunction, "EnqueueExternalMicrotask", | 1592 INSTALL_NATIVE(JSFunction, "EnqueueExternalMicrotask", |
| 1587 enqueue_external_microtask); | 1593 enqueue_external_microtask); |
| 1588 | 1594 |
| 1589 if (FLAG_harmony_proxies) { | 1595 if (FLAG_harmony_proxies) { |
| 1590 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap); | 1596 INSTALL_NATIVE(JSFunction, "DerivedHasTrap", derived_has_trap); |
| 1591 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap); | 1597 INSTALL_NATIVE(JSFunction, "DerivedGetTrap", derived_get_trap); |
| 1592 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap); | 1598 INSTALL_NATIVE(JSFunction, "DerivedSetTrap", derived_set_trap); |
| 1593 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate); | 1599 INSTALL_NATIVE(JSFunction, "ProxyEnumerate", proxy_enumerate); |
| 1594 } | 1600 } |
| 1595 if (FLAG_harmony_observation) { | |
| 1596 INSTALL_NATIVE(JSFunction, "NotifyChange", observers_notify_change); | |
| 1597 INSTALL_NATIVE(JSFunction, "EnqueueSpliceRecord", observers_enqueue_splice); | |
| 1598 INSTALL_NATIVE(JSFunction, "BeginPerformSplice", | |
| 1599 observers_begin_perform_splice); | |
| 1600 INSTALL_NATIVE(JSFunction, "EndPerformSplice", | |
| 1601 observers_end_perform_splice); | |
| 1602 } | |
| 1603 } | 1601 } |
| 1604 | 1602 |
| 1605 #undef INSTALL_NATIVE | 1603 #undef INSTALL_NATIVE |
| 1606 | 1604 |
| 1607 | 1605 |
| 1608 Handle<JSFunction> Genesis::InstallInternalArray( | 1606 Handle<JSFunction> Genesis::InstallInternalArray( |
| 1609 Handle<JSBuiltinsObject> builtins, | 1607 Handle<JSBuiltinsObject> builtins, |
| 1610 const char* name, | 1608 const char* name, |
| 1611 ElementsKind elements_kind) { | 1609 ElementsKind elements_kind) { |
| 1612 // --- I n t e r n a l A r r a y --- | 1610 // --- I n t e r n a l A r r a y --- |
| (...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2044 } | 2042 } |
| 2045 | 2043 |
| 2046 | 2044 |
| 2047 bool Genesis::InstallExperimentalNatives() { | 2045 bool Genesis::InstallExperimentalNatives() { |
| 2048 for (int i = ExperimentalNatives::GetDebuggerCount(); | 2046 for (int i = ExperimentalNatives::GetDebuggerCount(); |
| 2049 i < ExperimentalNatives::GetBuiltinsCount(); | 2047 i < ExperimentalNatives::GetBuiltinsCount(); |
| 2050 i++) { | 2048 i++) { |
| 2051 INSTALL_EXPERIMENTAL_NATIVE(i, symbols, "symbol.js") | 2049 INSTALL_EXPERIMENTAL_NATIVE(i, symbols, "symbol.js") |
| 2052 INSTALL_EXPERIMENTAL_NATIVE(i, proxies, "proxy.js") | 2050 INSTALL_EXPERIMENTAL_NATIVE(i, proxies, "proxy.js") |
| 2053 INSTALL_EXPERIMENTAL_NATIVE(i, collections, "collection.js") | 2051 INSTALL_EXPERIMENTAL_NATIVE(i, collections, "collection.js") |
| 2054 INSTALL_EXPERIMENTAL_NATIVE(i, observation, "object-observe.js") | |
| 2055 INSTALL_EXPERIMENTAL_NATIVE(i, promises, "promise.js") | 2052 INSTALL_EXPERIMENTAL_NATIVE(i, promises, "promise.js") |
| 2056 INSTALL_EXPERIMENTAL_NATIVE(i, generators, "generator.js") | 2053 INSTALL_EXPERIMENTAL_NATIVE(i, generators, "generator.js") |
| 2057 INSTALL_EXPERIMENTAL_NATIVE(i, iteration, "array-iterator.js") | 2054 INSTALL_EXPERIMENTAL_NATIVE(i, iteration, "array-iterator.js") |
| 2058 INSTALL_EXPERIMENTAL_NATIVE(i, strings, "harmony-string.js") | 2055 INSTALL_EXPERIMENTAL_NATIVE(i, strings, "harmony-string.js") |
| 2059 INSTALL_EXPERIMENTAL_NATIVE(i, arrays, "harmony-array.js") | 2056 INSTALL_EXPERIMENTAL_NATIVE(i, arrays, "harmony-array.js") |
| 2060 INSTALL_EXPERIMENTAL_NATIVE(i, maths, "harmony-math.js") | 2057 INSTALL_EXPERIMENTAL_NATIVE(i, maths, "harmony-math.js") |
| 2061 } | 2058 } |
| 2062 | 2059 |
| 2063 InstallExperimentalNativeFunctions(); | 2060 InstallExperimentalNativeFunctions(); |
| 2064 InstallExperimentalBuiltinFunctionIds(); | 2061 InstallExperimentalBuiltinFunctionIds(); |
| (...skipping 681 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2746 return from + sizeof(NestingCounterType); | 2743 return from + sizeof(NestingCounterType); |
| 2747 } | 2744 } |
| 2748 | 2745 |
| 2749 | 2746 |
| 2750 // Called when the top-level V8 mutex is destroyed. | 2747 // Called when the top-level V8 mutex is destroyed. |
| 2751 void Bootstrapper::FreeThreadResources() { | 2748 void Bootstrapper::FreeThreadResources() { |
| 2752 ASSERT(!IsActive()); | 2749 ASSERT(!IsActive()); |
| 2753 } | 2750 } |
| 2754 | 2751 |
| 2755 } } // namespace v8::internal | 2752 } } // namespace v8::internal |
| OLD | NEW |