As configured in my dotfiles.
start new:
tmux
start new with session name:
As configured in my dotfiles.
start new:
tmux
start new with session name:
the goal: to do fast virtual host routing, e.g. to have a single process on a machine listening on port 80 and proxying data based on HTTP Host to other non-port-80 web processes on the same machine
many people use nginx for this because nginx is faster than node is currently for data-heavy applications (see below)
they use the JS proxies from https://github.com/substack/bouncy/tree/master/bench
The prep-script.sh
will setup the latest Node and install the latest perf version on your Linux box.
When you want to generate the flame graph, run the following (folder locations taken from install script):
sudo sysctl kernel.kptr_restrict=0
# May also have to do the following:
# (additional reading http://unix.stackexchange.com/questions/14227/do-i-need-root-admin-permissions-to-run-userspace-perf-tool-perf-events-ar )
sudo sysctl kernel.perf_event_paranoid=0
Notes:
On process.nextTick()
:
Embedders of V8 should generally use the head of the branch corresponding to the minor version of V8 that ships in Chrome.
To find out what version this is,
{ | |
'ecmaFeatures': { | |
'binaryLiterals': true, | |
'blockBindings': true, | |
'forOf': true, | |
'generators': true, | |
'octalLiterals': true, | |
'templateStrings': true, | |
}, | |
'env': { |
$ gdb --args ./iojs_g -pe 'process.hrtime([0,0])' | |
(gdb) source deps/v8/tools/gdbinit | |
(gdb) b node::Hrtime | |
Breakpoint 1 at 0x1282619: file ../src/node.cc, line 2028. | |
(gdb) r | |
Starting program: /usr/local/google/home/ofrobots/src/io.js/iojs_g -pe process.hrtime\(\[0,0\]\) | |
... | |
Breakpoint 1, node::Hrtime (args=...) at ../src/node.cc:2028 |
This is a short write-up that explains why test/addons/make-callback-recurse/test.js
in github.com/nodejs/node/pull/4507
fails with the following error message:
$ node test.js
d2 error
/Users/JulienGilli/dev/node/node/test/addons/make-callback-recurse/test.js:88
throw new Error('test d1');
export x = 42