summaryrefslogtreecommitdiff
path: root/test/message
diff options
context:
space:
mode:
authorBrian White <mscdex@mscdex.net>2015-05-01 14:08:02 -0400
committerBrian White <mscdex@mscdex.net>2015-05-01 21:27:34 -0400
commitc7782c0af8a4e4ee26da6e44e07c3987d9d3ddb6 (patch)
treec34ab5332254a02afdfa73476c5ce742da981dca /test/message
parentea5195ccaf6d51262c9089c2ec5c6f5634bc12b5 (diff)
downloadnode-new-c7782c0af8a4e4ee26da6e44e07c3987d9d3ddb6.tar.gz
node: improve nextTick performance
This commit uses separate functions to isolate deopts caused by try-catches and avoids fn.apply() for callbacks with small numbers of arguments. These changes improve performance by ~1-40% in the various nextTick benchmarks. PR-URL: https://github.com/iojs/io.js/pull/1571 Reviewed-By: Trevor Norris <trev.norris@gmail.com> Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
Diffstat (limited to 'test/message')
-rw-r--r--test/message/nexttick_throw.out1
-rw-r--r--test/message/stdin_messages.out7
2 files changed, 5 insertions, 3 deletions
diff --git a/test/message/nexttick_throw.out b/test/message/nexttick_throw.out
index baced2ce87..1dd60694a8 100644
--- a/test/message/nexttick_throw.out
+++ b/test/message/nexttick_throw.out
@@ -4,6 +4,7 @@
^
ReferenceError: undefined_reference_error_maker is not defined
at *test*message*nexttick_throw.js:*:*
+ at doNTCallback0 (node.js:*:*)
at process._tickCallback (node.js:*:*)
at Function.Module.runMain (module.js:*:*)
at startup (node.js:*:*)
diff --git a/test/message/stdin_messages.out b/test/message/stdin_messages.out
index cbdc1fdb12..92d09a0a14 100644
--- a/test/message/stdin_messages.out
+++ b/test/message/stdin_messages.out
@@ -12,6 +12,7 @@ SyntaxError: Strict mode code may not include a with statement
at emitNone (events.js:*:*)
at Socket.emit (events.js:*:*)
at endReadableNT (_stream_readable.js:*:*)
+ at doNTCallback2 (node.js:*:*)
at process._tickCallback (node.js:*:*)
42
42
@@ -29,7 +30,7 @@ Error: hello
at emitNone (events.js:*:*)
at Socket.emit (events.js:*:*)
at endReadableNT (_stream_readable.js:*:*)
- at process._tickCallback (node.js:*:*)
+ at doNTCallback2 (node.js:*:*)
[stdin]:1
throw new Error("hello")
@@ -44,7 +45,7 @@ Error: hello
at emitNone (events.js:*:*)
at Socket.emit (events.js:*:*)
at endReadableNT (_stream_readable.js:*:*)
- at process._tickCallback (node.js:*:*)
+ at doNTCallback2 (node.js:*:*)
100
[stdin]:1
@@ -60,7 +61,7 @@ ReferenceError: y is not defined
at emitNone (events.js:*:*)
at Socket.emit (events.js:*:*)
at endReadableNT (_stream_readable.js:*:*)
- at process._tickCallback (node.js:*:*)
+ at doNTCallback2 (node.js:*:*)
[stdin]:1
var ______________________________________________; throw 10