This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
thread apply all bt | |
Thread 6 (process 83744): | |
#0 0x00007fff88071a56 in semaphore_wait_trap () | |
#1 0x000000010034d2b7 in v8::internal::Semaphore::Wait (this=0x101014a48) at semaphore.h:69 | |
#2 0x00000001003c1b7b in v8::internal::Acquire_Load () at ../deps/v8/src/sweeper-thread.cc:64 | |
#3 v8::internal::Acquire_Load () at /Users/tjfontaine/Development/node/deps/v8/src/atomicops_internals_x86_macosx.h:288 | |
#4 0x00000001003c1b7b in v8::internal::SweeperThread::Run (this=0x101014a00) at ../deps/v8/src/sweeper-thread.cc:66 | |
#5 0x000000010045b20a in v8::internal::Thread::NotifyStartedAndRun () at /Users/tjfontaine/Development/node/deps/v8/src/platform.h:584 | |
#6 0x000000010045b20a in v8::internal::ThreadEntry (arg=0x101014a00) at platform.h:611 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// --max-old-space-size=4095 | |
var bigdata = [], | |
iterations = 0; | |
function addData() { | |
iterations++; | |
if (iterations % 10 == 0) | |
console.log(iterations, bigdata.length, process.memoryUsage()); | |
for (var i = 0; i < 1e5; i++) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 74a81f7588f86b66e277ea70724d17b583efc7d4 Mon Sep 17 00:00:00 2001 | |
From: Timothy J Fontaine <tjfontaine@gmail.com> | |
Date: Sun, 19 Jan 2014 11:41:25 -0800 | |
Subject: [PATCH] asyncListener: adapt to tracing interface | |
--- | |
lib/tracing.js | 174 +++++++++++++++++++++++++++++++++++++++++++++++ | |
src/async-wrap-inl.h | 92 +++++++++++++++++++++---- | |
src/async-wrap.h | 77 +++++++++++++++++++-- | |
src/cares_wrap.cc | 24 +++++-- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var restify = tracing.createProvider('restify'); // { namespace: 'anonymous', provider: 'restify', guid: stablehash } | |
var restify = tracing.createProvider({ | |
namespace: 'joyent', | |
provider: 'restify', | |
guid: '12345', | |
}); | |
restify.addProbe('foo', ['string', 'number', 'integer']); | |
restify.enable(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var util = require('util'); | |
var assert = require('assert'); | |
var net = require('net'); | |
var SIZE = 2E6; | |
var BUF = new Buffer(SIZE); | |
var ERRS = 0; | |
var PORT = 4000; | |
BUF.fill(0x62); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--harmony_typeof (enable harmony semantics for typeof) | |
--harmony_scoping (enable harmony block scoping) | |
--harmony_modules (enable harmony modules (implies block scoping)) | |
--harmony_symbols (enable harmony symbols (a.k.a. private names)) | |
--harmony_proxies (enable harmony proxies) | |
--harmony_collections (enable harmony collections (sets, maps, and weak maps)) | |
--harmony_observation (enable harmony object observation (implies harmony collections) | |
--harmony_generators (enable harmony generators) | |
--harmony_iteration (enable harmony iteration (for-of)) | |
--harmony_numeric_literals (enable harmony numeric literals (0o77, 0b11)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/node.h b/src/node.h | |
index 7a08dc9..5dbf28f 100644 | |
--- a/src/node.h | |
+++ b/src/node.h | |
@@ -122,6 +122,17 @@ NODE_EXTERN v8::Handle<v8::Value> MakeCallback( | |
# endif | |
#endif | |
+#ifdef _WIN32 | |
+// TODO(tjfontaine) consider changing the usage of ssize_t to ptrdiff_t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 8e3070ad5cc17116e47f71290d86b83aa06e98eb Mon Sep 17 00:00:00 2001 | |
From: Timothy J Fontaine <tj.fontaine@joyent.com> | |
Date: Tue, 12 Aug 2014 00:20:44 +0000 | |
Subject: [PATCH 2/2] descriptions are also 4 byte aligned | |
--- | |
usr/src/lib/libproc/common/Pcore.c | 22 +++++++++++++++++----- | |
1 file changed, 17 insertions(+), 5 deletions(-) | |
diff --git a/usr/src/lib/libproc/common/Pcore.c b/usr/src/lib/libproc/common/Pcore.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* thread #1: tid = 0x0000, 0x00007fff88075866 libsystem_kernel.dylib`__pthread_kill + 10, stop reason = signal SIGSTOP | |
frame #0: 0x00007fff88075866 libsystem_kernel.dylib`__pthread_kill + 10 | |
frame #1: 0x00007fff911f835c libsystem_pthread.dylib`pthread_kill + 92 | |
frame #2: 0x00007fff8f9debba libsystem_c.dylib`abort + 125 | |
frame #3: 0x00007fff8f9a8a5f libsystem_c.dylib`__assert_rtn + 321 | |
frame #4: 0x000000010013ddef node`uv__close(fd=<unavailable>) + 133 at core.c:422 | |
frame #5: 0x000000010014397b node`uv__stream_try_select(stream=0x00000001004b4c46, fd=0x00000001004b4cf3) + 165 at stream.c:318 | |
frame #6: 0x000000010014118b node`uv_pipe_open(handle=0x0000000101c00070, fd=2) + 21 at pipe.c:140 | |
frame #7: 0x0000000100024887 node`node::PipeWrap::Open(args=<unavailable>) + 91 at pipe_wrap.cc:259 | |
frame #8: 0x000000010016e160 node`v8::internal::FunctionCallbackArguments::Call(this=0x00007fff5fbfe8f0, f=0x000000010002482c)(v8::FunctionCallbackInfo<v8::Value> const&)) + 160 at arguments.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> import os,fcntl,struct | |
>>> fd = os.open('file', os.O_WRONLY|os.O_NOCTTY|os.O_CREAT, 0666) | |
>>> op = struct.pack('hhllhhl', fcntl.F_WRLCK, 0, 0, 0, 0, 0, 0) | |
>>> | |
>>> fcntl.fcntl(fd, fcntl.F_SETLK, op) |