0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-30 15:30:56 +01:00
nodejs/test/message
Brian White b677b844fc events: optimize various functions
Cache events and listeners objects where possible and loop over
Object.keys() instead of using for..in. These changes alone give
~60-65% improvement in the ee-add-remove benchmark.

The changes to EventEmitter.listenerCount() gives ~14%
improvement and changes to emitter.listeners() gives
significant improvements for <50 listeners
(~195% improvement for 10 listeners).

The changes to emitter.emit() gives 3x speedup for the fast
cases with multiple handlers and a minor speedup for the slow
case with multiple handlers.

The swapping out of the util.is* type checking functions with inline
checks gives another ~5-10% improvement.

PR-URL: https://github.com/iojs/io.js/pull/601
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Evan Lucas <evanlucas@me.com>
2015-02-09 17:47:49 +01:00
..
2100bytes.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
2100bytes.out
error_exit.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
error_exit.out
eval_messages.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
eval_messages.out node: do not print SyntaxError hints to stderr 2014-02-06 13:26:57 +04:00
hello_world.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
hello_world.out
max_tick_depth.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
max_tick_depth.out process: remove maxTickDepth from _tickCallback 2013-05-30 09:30:19 -07:00
nexttick_throw.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
nexttick_throw.out
stack_overflow.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
stack_overflow.out
stdin_messages.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
stdin_messages.out events: optimize various functions 2015-02-09 17:47:49 +01:00
testcfg.py test: make test runner multi-arch/mode compatible 2014-10-16 22:39:34 +02:00
throw_custom_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
throw_custom_error.out test: fix message tests regression 2015-01-13 01:50:32 +01:00
throw_in_line_with_tabs.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
throw_in_line_with_tabs.out test: fix message tests regression 2015-01-13 01:50:32 +01:00
throw_non_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
throw_non_error.out test: fix message tests regression 2015-01-13 01:50:32 +01:00
throw_null.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
throw_null.out test: fix message tests regression 2015-01-13 01:50:32 +01:00
throw_undefined.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
throw_undefined.out test: fix message tests regression 2015-01-13 01:50:32 +01:00
timeout_throw.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
timeout_throw.out test: update tests after internal api change 2013-08-15 22:20:15 +02:00
undefined_reference_in_new_context.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
undefined_reference_in_new_context.out vm, core, module: re-do vm to fix known issues 2013-08-21 15:52:23 -07:00
vm_display_runtime_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
vm_display_runtime_error.out vm: update API to use options argument 2013-08-28 22:27:24 -07:00
vm_display_syntax_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
vm_display_syntax_error.out vm: update API to use options argument 2013-08-28 22:27:24 -07:00
vm_dont_display_runtime_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
vm_dont_display_runtime_error.out test: fix error messages after v8 upgrade 2014-10-12 02:05:02 +04:00
vm_dont_display_syntax_error.js Remove excessive copyright/license boilerplate 2015-01-12 15:30:28 -08:00
vm_dont_display_syntax_error.out test: fix error messages after v8 upgrade 2014-10-12 02:05:02 +04:00