joyent/node — pull request #8434 by cjihrig (2014-09-24 03:18:33+00:00)
Title: net: remove use of arguments object in Server constructor

The current implementation uses the `arguments` object in the `Server()` constructor. Since both arguments to `Server()` are optional, there was a high likelihood of accessing a non-existent element in `arguments`, which carries a performance overhead. This commit replaces the `arguments` object with named arguments.

In a simple test which calls `Server()` in a loop one million times, invoking with both arguments saw minimal improvements. However, invoking `Server()` with no arguments lead to approximately 12% increase in performance.