00:00:01  * ircretaryquit (Remote host closed the connection)
00:00:03  * shigekiquit (Ping timeout: 245 seconds)
00:00:08  * ircretaryjoined
00:00:45  * loladirojoined
00:02:32  <trevnorris>if you're not in a rush, give me tonight and i'll wrap up whatever i can get done.
00:03:35  * jmar777quit (Remote host closed the connection)
00:05:08  * paddybyersquit (Ping timeout: 248 seconds)
00:08:12  * jmar777joined
00:12:10  <MI6>joyent/node: Scott Blomquist master * 8164b2f : windows/msi: more installer enhancements Noteworthy installer improvemen (+1 more commits) - http://git.io/1-uCBA
00:12:45  <CoverSlide>what? bundles the Ask Toolbar?
00:15:45  * c4milojoined
00:18:40  <trevnorris>*rimshot
00:20:28  <isaacs>trevnorris: hahaa
00:20:32  <isaacs>trevnorris: that's Enterprise!
00:20:41  <isaacs>trevnorris: check out this script: https://gist.github.com/isaacs/4735492
00:20:55  <isaacs>oh, the comment at the top lies a little..
00:21:15  <isaacs>trevnorris: basically, if the args aren't specified, it runs it with a variety of settings.
00:21:40  * karupaneruraquit (Excess Flood)
00:21:48  <isaacs>trevnorris: here's what's fascinating... when i do this, the low-chunk-size runs have CRAZY low throughput.
00:22:15  <trevnorris>yeah. i have the same problem. =/
00:22:46  <isaacs>hm. ok
00:23:00  <isaacs>so, i guess, if you're writing small buffers, then node just sucks?
00:23:11  <trevnorris>heh, i guess.
00:23:13  <isaacs>$ ./node benchmark/tcp_raw_c2s.js 3 100
00:23:13  <isaacs>tcp_raw_c2s_dur_3_len_100: 0.060259
00:23:29  <isaacs>it's not new at least:
00:23:30  <isaacs>$ ../node-v0.8/node benchmark/tcp_raw_c2s.js 3 100
00:23:30  <isaacs>tcp_raw_c2s_dur_3_len_100: 0.062464
00:23:58  <isaacs>trevnorris: so, also, i'm beginning to see what i want from a shared benchmark util in core.
00:24:11  * karupanerurajoined
00:24:11  <trevnorris>that's good.
00:24:30  <isaacs>trevnorris: there's some repetition in this file, which is also repeated in that fs write benchmark thing i did for that other thing
00:24:47  <isaacs>especially, this "main" file...
00:25:39  <isaacs>what would be *awesome* would be something like: runBenchmark(myFunction, { dur: [1, 5], len: [100, 102400, ..] })
00:25:58  <isaacs>then the bench thingie would know if it's the "main" or a child
00:26:15  <isaacs>if the positional args are set, then interpret them
00:26:20  <isaacs>and call the function
00:26:35  <isaacs>in the function, youc an do benchThingie.start() and benchThingie.end(couht)
00:26:42  <isaacs>start does thte start = process.hrtime()
00:27:03  <isaacs>end(count) does the elapsed, and prints out filename_dur_$dir_len_$len: value
00:27:03  <trevnorris>isaacs: ok. go ahead and gist a benchmark how you'd like to write one.
00:27:26  <isaacs>i *think* this can all be done with a pretty small number of features.
00:27:38  <isaacs>and not a large surface area to have to grok in order to write a good benchmark
00:27:49  * jmar777quit (Remote host closed the connection)
00:27:57  <trevnorris>already have code for start and end()
00:28:16  <trevnorris>and, just in case, theres an onend(fn) where you can pass a template for a custom output message if you want.
00:29:28  <trevnorris>i do like the runBenchmark idea. would make it super simple to create a node script that launched other benchs
00:30:02  <bnoordhu1s>so how are we re: performance?
00:30:29  <trevnorris>getting there.
00:30:42  <CoverSlide>getting where?
00:30:51  <trevnorris>to the same as v0.8
00:30:56  <CoverSlide>on par or acceptable slowdown
00:31:00  <trevnorris>least as far as my tcp_net benchs go
00:31:02  <CoverSlide>ok cool
00:31:57  <trevnorris>CoverSlide: there's no such thing as acceptably slow, there's just ludicrous speed!
00:33:03  <isaacs>trevnorris: https://gist.github.com/isaacs/4735553
00:33:09  <isaacs>trevnorris: we should not have any bonus features.
00:33:22  <isaacs>CoverSlide: slowdowns are not acceptable.
00:33:32  <CoverSlide>alright
00:33:43  <CoverSlide>so is this the 0.10.0 blocker?
00:33:47  <isaacs>CoverSlide: yep
00:33:51  <CoverSlide>sweet
00:33:55  <isaacs>other than that, things are pretty much golden
00:34:04  <isaacs>CoverSlide: but i think some things might change a bit to get us fast again
00:34:14  <isaacs>CoverSlide: stream.Writable is kind of klunky
00:34:19  <isaacs>does a lot of array juggling bs
00:34:51  <trevnorris>isaacs: like the idea, re: no bonus features. don't think cli customization is a bonus.
00:34:52  <trevnorris>think it's necessary. if it doesn't exist then no way to run valgrind et all against them.
00:34:53  <MI6>joyent/node: Ben Noordhuis v0.8 * c4f418d : test: disable simple/test-dgram-send-error It's not a good citizen, it s - http://git.io/SOaXng
00:35:03  <isaacs>trevnorris: in this case, yeah, i think you're probably right.
00:35:13  <isaacs>trevnorris: but it should be the simplest cli parser ever.
00:35:26  <isaacs>trevnorris: --KEY=value
00:35:35  <isaacs>no positional args, none of the other fancy stuff, no shorthands or anything else.
00:35:47  <trevnorris>isaacs: ok. what I have pretty much just takes any key with -- and turn the thing into an object.
00:35:48  <isaacs>and in fact, most of the time, people writing a benchmark script should not know that it's even doing anything
00:36:19  <isaacs>ie, i should just specify my parameters to run the benchmark function, and get the output printed for all the combinations
00:36:42  <trevnorris>isaacs: here's the example: https://github.com/trevnorris/bench-timer/wiki/Docs#wiki-timerparse-argv-
00:37:00  <trevnorris>and it'd be easy to specify a "global" default that all tests use w/o the user knowing about it.
00:37:15  <isaacs>trevnorris: so... if you feel the need to doucment it, don't.
00:37:18  <isaacs>instead, make it simpler :)
00:37:42  <trevnorris>...
00:38:11  * c4milo_joined
00:38:59  <trevnorris>sorry, don't get it. defaults exist so no user needs to use them. but there'll need to be some docs to tell "advanced" users how to use them.
00:39:30  <trevnorris>at least --param0 does this, and --param1 does that.
00:39:38  <trevnorris>right? or am i missing something.
00:40:52  * c4miloquit (Ping timeout: 248 seconds)
00:40:54  <isaacs>the only params should be the ones that you specify in your benchmark(fn, opts) function
00:41:10  <isaacs>ie, if you specify --dur=1 --len=1024 then it'll use that only
00:41:17  <isaacs>because it'll just think it's being run by itself
00:41:30  <isaacs>but if you don't, then it'll run the combinations you specify
00:42:05  <trevnorris>two questions. would you allow `--dur 1 10 20`, and have it run combinations of the three?
00:42:44  <isaacs>no
00:43:03  <isaacs>here, let's have a race to write this thing as fast as we can in as few lines as we can :)
00:43:07  <isaacs>;P
00:50:23  * garbagecollectioquit (Quit: garbagecollectio)
00:54:50  <trevnorris>isaacs: here a quick thing: https://gist.github.com/trevnorris/4735675
00:54:55  <trevnorris>most the code for that is done.
01:00:12  * indexzerojoined
01:04:48  <trevnorris>also you'll notice that there's no .end(), because the the counter is kept internally then terminates the test when complete.
01:07:54  * abraxasjoined
01:19:34  <trevnorris>isaacs: also there are still caveats running functions out of scope. https://gist.github.com/trevnorris/4735793
01:21:53  * trevnorrisquit (Quit: Leaving)
01:31:01  * hzjoined
01:42:15  * lohkeypart
01:44:25  * pooyajoined
01:49:15  * piscisaureus_quit (Quit: ~ Trillian Astra - www.trillian.im ~)
01:56:14  * dapquit (Quit: Leaving.)
02:04:49  * jmar777joined
02:05:36  * bradleymeckjoined
02:30:19  * bradleymeck_joined
02:31:43  * bradleymeckquit (Ping timeout: 244 seconds)
02:31:43  * bradleymeck_changed nick to bradleymeck
02:31:49  * sblomquit (Ping timeout: 246 seconds)
02:36:24  * dsantiagoquit (Quit: Computer has gone to sleep.)
02:36:30  * trevnorrisjoined
02:37:33  * bnoordhu1squit (Ping timeout: 256 seconds)
02:45:54  * bradleymeckquit (Quit: bradleymeck)
02:49:39  * stagas_joined
02:50:19  * pooyaquit (Quit: pooya)
02:50:57  * hzquit
02:51:48  * stagasquit (Ping timeout: 264 seconds)
02:51:49  * stagas_changed nick to stagas
02:52:54  * bnoordhuisquit (Ping timeout: 244 seconds)
02:53:46  * stagas_joined
02:56:20  * stagasquit (Ping timeout: 248 seconds)
02:56:26  * stagas_changed nick to stagas
02:57:58  * loladiroquit (Quit: loladiro)
03:01:11  * TooTallNatequit (Quit: ["Textual IRC Client: www.textualapp.com"])
03:13:02  * stagasquit (*.net *.split)
03:13:02  * trevnorrisquit (*.net *.split)
03:13:02  * cjdquit (*.net *.split)
03:13:02  * CoverSlidequit (*.net *.split)
03:13:02  * Benviequit (*.net *.split)
03:13:03  * indexzeroquit (*.net *.split)
03:13:03  * txdvquit (*.net *.split)
03:13:03  * benoitcquit (*.net *.split)
03:13:03  * creationixquit (*.net *.split)
03:13:03  * mralephquit (*.net *.split)
03:13:03  * hij1nxquit (*.net *.split)
03:13:03  * philips_quit (*.net *.split)
03:13:03  * AvianFluquit (*.net *.split)
03:13:05  * kuplatupsuquit (*.net *.split)
03:13:05  * tellnesquit (*.net *.split)
03:13:05  * chobiequit (*.net *.split)
03:13:05  * pfox__quit (*.net *.split)
03:13:05  * pquernaquit (*.net *.split)
03:13:05  * wolfeidauquit (*.net *.split)
03:13:05  * MI6quit (*.net *.split)
03:13:05  * indutnyquit (*.net *.split)
03:13:05  * joshthecoder_quit (*.net *.split)
03:13:05  * rphillipsquit (*.net *.split)
03:13:05  * Chip_Zeroquit (*.net *.split)
03:13:05  * CAPSLOCKBOTquit (*.net *.split)
03:13:05  * saghulquit (*.net *.split)
03:13:05  * rvaggquit (*.net *.split)
03:13:05  * abraxasquit (*.net *.split)
03:13:05  * ircretaryquit (*.net *.split)
03:13:05  * brsonquit (*.net *.split)
03:13:07  * mmaleckiquit (*.net *.split)
03:13:07  * qmx|awayquit (*.net *.split)
03:13:07  * tjfontainequit (*.net *.split)
03:13:07  * Raynosquit (*.net *.split)
03:13:07  * Gottoxquit (*.net *.split)
03:13:07  * roxluquit (*.net *.split)
03:13:07  * toothrotquit (*.net *.split)
03:13:07  * othiym23quit (*.net *.split)
03:13:07  * davispquit (*.net *.split)
03:13:07  * joclekquit (*.net *.split)
03:13:07  * russell_hquit (*.net *.split)
03:13:07  * chrisdickinsonquit (*.net *.split)
03:13:07  * karupaneruraquit (*.net *.split)
03:13:07  * mikealquit (*.net *.split)
03:13:07  * jmar777quit (*.net *.split)
03:13:07  * c4milo_quit (*.net *.split)
03:13:07  * skebcio_quit (*.net *.split)
03:13:07  * ryahquit (*.net *.split)
03:13:07  * trepan_quit (*.net *.split)
03:13:07  * KiNgMaRquit (*.net *.split)
03:13:07  * niskaquit (*.net *.split)
03:13:07  * stephankquit (*.net *.split)
03:13:07  * DrPizzaquit (*.net *.split)
03:13:07  * brucemquit (*.net *.split)
03:13:07  * rje`macquit (*.net *.split)
03:13:07  * LOUDBOTquit (*.net *.split)
03:13:07  * wavded_quit (*.net *.split)
03:13:07  * dscapequit (*.net *.split)
03:13:07  * papertigersquit (*.net *.split)
04:25:47  * papertigersjoined
04:25:54  * wavded_joined
04:25:54  * dscapejoined
04:25:57  * AvianFlujoined
04:25:57  * abraxasjoined
04:25:57  * karupanerurajoined
04:25:57  * ircretaryjoined
04:25:57  * chrisdickinsonjoined
04:25:57  * wolfeidaujoined
04:25:57  * roxlujoined
04:25:57  * mikealjoined
04:25:57  * toothrotjoined
04:25:57  * qmx|awayjoined
04:25:57  * othiym23joined
04:25:57  * Chip_Zerojoined
04:25:57  * joshthecoder_joined
04:25:57  * MI6joined
04:25:57  * saghuljoined
04:25:57  * CAPSLOCKBOTjoined
04:25:57  * rvaggjoined
04:25:57  * indutnyjoined
04:25:57  * rphillipsjoined
04:25:57  * tjfontainejoined
04:25:57  * Raynosjoined
04:25:57  * davispjoined
04:25:57  * joclekjoined
04:25:57  * mmaleckijoined
04:25:57  * Gottoxjoined
04:25:57  * russell_hjoined
04:26:04  * CoverSlidejoined
04:26:04  * Benviejoined
04:26:09  * niskajoined
04:26:09  * mralephjoined
04:26:14  * cjdjoined
04:26:22  * hij1nxjoined
04:26:35  * philips_joined
04:26:35  * kuplatupsujoined
04:26:50  * tellnesjoined
04:26:50  * pfox__joined
04:26:50  * chobiejoined
04:26:50  * pquernajoined
04:26:59  * skebcio_joined
04:26:59  * ryahjoined
04:26:59  * trepan_joined
04:27:04  * stephankjoined
04:27:04  * DrPizzajoined
04:27:04  * rje`macjoined
04:27:04  * LOUDBOTjoined
04:27:09  * KiNgMaRjoined
04:27:15  * indexzerojoined
04:27:15  * txdvjoined
04:27:15  * benoitcjoined
04:27:15  * creationixjoined
04:27:27  * brucemjoined
04:37:07  * pooyajoined
04:45:25  * qmx|awaychanged nick to qmx
04:55:10  * qmxchanged nick to qmx|away
05:44:56  * loladirojoined
06:05:33  * TheJHjoined
06:16:09  * wolfeidauquit (Remote host closed the connection)
06:17:30  * TheJHquit (Ping timeout: 244 seconds)
06:23:10  * Benviequit (Ping timeout: 256 seconds)
06:23:30  * Benviejoined
06:33:14  * mikealquit (Quit: Leaving.)
06:34:17  * mikealjoined
06:35:24  * bradleymeckjoined
06:48:37  * paddybyersjoined
06:49:34  * wolfeidaujoined
06:52:27  * mikealquit (Quit: Leaving.)
06:53:22  * mikealjoined
06:53:26  * mikealquit (Client Quit)
07:00:27  * dsantiagojoined
07:02:18  * mikealjoined
07:14:47  * paddybyersquit (Ping timeout: 252 seconds)
07:14:48  * pooyaquit (Quit: pooya)
07:31:17  * rendarjoined
07:44:18  * `3rdEdenjoined
08:29:41  * paddybyersjoined
08:34:05  <indutny>morning
09:09:01  * loladiroquit (Read error: Connection reset by peer)
09:09:20  * loladirojoined
09:14:36  * hzjoined
09:20:34  * stagasjoined
09:25:01  * loladiroquit (Quit: loladiro)
09:36:08  * loladirojoined
09:45:20  * hzquit
10:06:39  * shigekijoined
10:10:30  * abraxasquit (Remote host closed the connection)
10:10:39  <shigeki>ircretary: tell piscisaureus_ Thanks. I will re-work this in this weekend. But could you please teach me the reason why "return a->timeout < b->timeout ? -1: 1;" is wrong? Probably I missed something about it.
10:10:39  <ircretary>shigeki: I'll be sure to tell piscisaureus_
10:11:03  * abraxasjoined
10:11:09  * shigekipart
10:15:23  * abraxasquit (Ping timeout: 255 seconds)
10:16:36  * stagasquit (Ping timeout: 276 seconds)
10:20:22  * piscisaureus_joined
10:29:56  * stagasjoined
10:44:12  * saghulquit (Quit: Bye!)
10:46:16  * saghuljoined
10:46:37  <indutny>piscisaureus_: morning
10:48:45  * loladiroquit (Quit: loladiro)
10:51:21  <piscisaureus_>indutny: morning!
11:07:41  * hzjoined
11:14:13  * indexzeroquit (Quit: indexzero)
11:43:36  * c4milojoined
11:52:11  <rendar>piscisaureus_: hi
11:56:52  <txdv>saghul: yo bro
11:57:01  * piscisaureus_quit (Ping timeout: 256 seconds)
11:57:04  <saghul>txdv hey
12:16:28  * c4miloquit (Remote host closed the connection)
12:17:00  * piscisaureus_joined
12:46:14  * c4milojoined
13:07:57  * sgallaghjoined
13:23:15  <indutny>piscisaureus_: where is ben? :)
13:23:17  <indutny>in gouda?
13:23:47  <piscisaureus_>indutny: making babies
13:23:59  <indutny>piscisaureus_: oh, I shall not bother him then
13:24:12  <piscisaureus_>indutny: ... I don't know actually. he was kind of sick yesterday.
13:24:17  <indutny>oh
13:24:24  <piscisaureus_>So I think he may be still sleeping
13:24:43  <piscisaureus_>There's a small flu epidemic in the netherlands atm
13:25:23  <indutny>its everywhere
13:43:58  * qmx|awaychanged nick to qmx
13:57:00  * AvianFluquit (Remote host closed the connection)
14:02:59  * jmar777joined
14:07:47  * sgallaghchanged nick to sgallagh_mtg
14:46:16  * jmar777quit (Ping timeout: 245 seconds)
14:47:58  * paddybyersquit (Read error: No route to host)
14:49:31  * jmar777joined
14:54:01  * bradleymeckquit (Quit: bradleymeck)
14:55:42  * qmxchanged nick to qmx|away
14:56:06  * `3rdEdenchanged nick to `3E|BRB
15:01:34  * qmx|awaychanged nick to qmx
15:09:00  * mmaleckichanged nick to mmalecki[out]
15:13:12  * cjdquit (Quit: Lost terminal)
15:31:03  * sgallagh_mtgchanged nick to sgallagh
15:38:37  * bradleymeckjoined
15:43:39  * felixgejoined
15:43:39  * felixgequit (Changing host)
15:43:39  * felixgejoined
15:44:18  * TheJHjoined
15:46:57  <isaacs>indutny: piscisaureus_: What do you think of this? https://gist.github.com/isaacs/4739818
15:47:37  * `3E|BRBchanged nick to `3rdEden
15:48:32  <isaacs>if you read that http_simple.js file, how easy is it to grok the output?
15:50:09  <isaacs>or net-pipe.js
15:59:40  * bnoordhuisjoined
16:02:07  * Raltjoined
16:09:34  <indutny>isaacs: hoya
16:09:36  <indutny>what's that?
16:10:21  * mikealquit (Quit: Leaving.)
16:12:54  <isaacs>indutny: that's running a bunch of benchmarks with one command.
16:12:59  <isaacs>indutny: with consistent output
16:13:21  <isaacs>i'm writing a little script now to compare the output from multiple different nodes and find the winner
16:15:49  <isaacs>indutny: hopefully, it's also a little bit closer to "adding a benchmark is like adding a test"
16:16:00  <isaacs>and "we don't ignore benchmark regressions for months at a time"
16:17:04  * AvianFlujoined
16:25:25  * mralephquit (Ping timeout: 240 seconds)
16:27:59  * mikealjoined
16:28:13  * paddybyersjoined
16:35:25  * `3rdEdenquit (Quit: zomg, pewpew!)
16:36:18  <indutny>ok
16:39:19  <bnoordhuis>indutny: that kqueue PR is amusing, i was thinking of doing something similar yesterday
16:39:23  <bnoordhuis>great minds and all that
16:39:28  <indutny>haha
16:39:30  <indutny>yep,
16:39:31  <indutny>but
16:39:36  <indutny>multi accept benchmark doesn't work for me
16:39:39  <indutny>neither on osx
16:39:42  <indutny>nor on freebsd
16:39:47  <indutny>I always get ETIMEDOUT
16:39:52  <indutny>from clients
16:41:30  * pooyajoined
16:43:54  * dapjoined
16:44:48  <indutny>bnoordhuis: ^
16:47:48  * mikealquit (Quit: Leaving.)
16:47:59  * trevnorrisjoined
16:49:47  <bnoordhuis>indutny: noted
16:49:52  <indutny>yep
16:49:58  <indutny>btw, what do you think about pull request?
16:50:43  <indutny>may be we can have some sort of HAVE_KQUEUE define?
16:50:51  <indutny>this will reduce amount of code significantly
16:53:15  * piscisaureus_quit (Quit: ~ Trillian Astra - www.trillian.im ~)
16:56:00  <bnoordhuis>indutny: yes, i was going to suggest that
17:00:41  <indutny>bnoordhuis: HAVE_KQUEUE/
17:00:43  <indutny>?
17:00:46  <bnoordhuis>yes
17:00:58  <indutny>ok, I'll do it
17:01:29  * jmar777quit (Remote host closed the connection)
17:07:07  <MI6>joyent/libuv: indutny created branch feature-use-kevent-data - http://git.io/YCXisw
17:07:51  <MI6>joyent/libuv: Fedor Indutny feature-use-kevent-data * f9b9f0f : stream: use kevent() information before accept() Limit number of syscall - http://git.io/0ZMYRg
17:08:00  <indutny>ooops
17:08:07  <indutny>not exactly what I wanted to do
17:08:26  <indutny>removed branch
17:09:02  * bradleymeckquit (Quit: bradleymeck)
17:09:06  <indutny>bnoordhuis: updated PR
17:09:23  <bnoordhuis>okay, i'll look at it in a bit
17:09:53  * qmxchanged nick to qmx|away
17:18:27  * mikealjoined
17:27:21  * mikealquit (Ping timeout: 252 seconds)
17:31:01  * paddybyers_joined
17:33:00  * piscisaureus_joined
17:34:12  * paddybyersquit (Ping timeout: 248 seconds)
17:34:12  * paddybyers_changed nick to paddybyers
17:37:05  * loladirojoined
17:45:26  * piscisaureus_quit (Ping timeout: 245 seconds)
17:49:39  * pooyaquit (Quit: pooya)
17:51:55  <isaacs>bnoordhuis, piscisaureus_: What do you think about making fd's more easily accessible from handle objects in unix?
17:52:30  <bnoordhuis>isaacs: why? also, handles aren't necessarily backed by just one fd
17:52:35  <isaacs>the lack of this is causing heaps of pain for joyent and their customers. it's an unnecessary road bump between debugging from the system and from the js.
17:53:02  <isaacs>having the fd easily accessible makes it a lot simpler to use dtrace to figure out what's actually going on in the system.
17:53:09  <isaacs>and then connect it back with a js object
17:54:31  <isaacs>also, if we had the fd, we could more easily track server latency, and client latency tracking is just busted atm
17:54:43  * mikealjoined
17:54:51  <bnoordhuis>sorry, isaac. biab
17:54:55  <isaacs>put another way: aside from teh lack of portability to windows, what are the reasons to NOT expose it.
17:55:01  <isaacs>k, see ya later :)
17:55:42  * felixgequit (Quit: felixge)
17:59:27  * mikealquit (Ping timeout: 260 seconds)
17:59:55  * EhevuTovjoined
18:00:38  * EhevuTovquit (Remote host closed the connection)
18:05:33  * pooyajoined
18:12:51  * bnoordhu1sjoined
18:13:33  <bnoordhu1s>i was going to say 'back' but i have to go again :/
18:13:58  <trevnorris>isaacs: is there a reason the try catch wraps around more than just the function call in MakeCallback?
18:15:40  * sgallaghquit (Remote host closed the connection)
18:15:44  * piscisaureus_joined
18:15:49  <isaacs>bnoordhu1s: hey, there... i know a fake when i see one
18:15:56  <isaacs>1 !== i
18:16:13  <isaacs>trevnorris: um.. cuz other things might fail? i dunno.
18:16:26  <isaacs>the domain.enter/exit stuff, for instance
18:16:30  <isaacs>procss.tickCallback might fail
18:16:42  <isaacs>if you dont' try_catch around it, then throws are just silently ignored.
18:16:47  <isaacs>every call into JS should always have that
18:17:48  <trevnorris>wait. you can use a single TryCatch then do HasCaught multiple times?
18:17:55  <isaacs>hm... not sure if that works.
18:17:58  <isaacs>maybe?
18:18:10  <isaacs>sounds like it should
18:18:29  <trevnorris>well, that's what's in there. so must.
18:19:12  * bnoordhu1squit (Ping timeout: 276 seconds)
18:23:19  <trevnorris>i understand the code difference, but what is the check difference between IsEmpty and IsUndefined?
18:23:44  <trevnorris>nm, just found the comment.
18:25:29  * mikealjoined
18:28:29  * `3rdEdenjoined
18:29:57  <trevnorris>anyone know if GetHiddenValue is faster than Get?
18:30:04  <isaacs>trevnorris: ISEmpty means that it hasnt' been set to anythign
18:30:12  * mikealquit (Ping timeout: 264 seconds)
18:32:19  * mikealjoined
18:32:47  * mikealquit (Client Quit)
18:33:02  * TooTallNatejoined
18:35:33  <trevnorris>isaacs: mind a quick explanation of "MakeCallback may only be made directly off the event loop"?
18:35:42  <trevnorris>don't know what you mean by "js stack"
18:37:46  * mikealjoined
18:37:56  * piscisaureus_quit (Ping timeout: 245 seconds)
18:39:17  <creationix>Want to know something interesting? My pure JS implementation of MD5 is faster than node's native openssl binding. Why are C bindings so slow?
18:40:40  <isaacs>creationix: careful how you measure those.
18:40:51  <isaacs>creationix: it could be that V8 is inlining the asm code.
18:40:56  <isaacs>creationix: but would not do that normally, for reasons.
18:41:06  <isaacs>creationix: the openssl code, called from js, requires a context switch
18:41:33  <isaacs>creationix: but it's probably actually faster, once that's accounted for.
18:41:34  <creationix>true, I got the greatest speed increase by returning a value directly instead of setting it to a variable and then returning the variable
18:41:42  <creationix>I'm guessing it triggered some inlining threshold
18:41:46  <isaacs>creationix: ie, calling it 1000x from C is probably faster tahn calling your JS fn 1000x
18:41:50  <trevnorris>creationix: post the code?
18:41:53  * Ralt_joined
18:42:18  <isaacs>trevnorris: "MakeCallback may only be made directly off the event loop" is ryah's comment. but iirc, it means, you should not call a js function that triggers a makecallback directly.
18:42:33  <isaacs>it should only be called once we've done some stuff.
18:42:46  <isaacs>in practice? i don't know how big a deal that would be anyway, or if there are any exceptions.
18:42:49  <creationix>https://github.com/openpeer/cifre/blob/master/bench/bench-md5.js
18:42:54  <isaacs>we pretty much just call it any time we want to call into JS from C++
18:42:56  <trevnorris>isaacs: how'd that even be possible? it's not exposed to js land.
18:43:09  <isaacs>trevnorris: well, let's say you have some sync thing that doesn't hit the event loop
18:43:14  <creationix>now it's not quite identical and I'm using typed arrays which are fairly slow in node
18:43:20  <creationix>I think using node Buffers would be even faster
18:43:25  <isaacs>so now you have jsSyncFunction() -> someC++ code -> MakeCallback
18:43:44  <trevnorris>aahhh. ok.
18:43:45  <isaacs>but i think that comment was made back when the idea was that it'd be used for long stack traces.
18:43:52  <isaacs>and we've pretty much forgotten about those.
18:44:16  <isaacs>but we do use it for domains, which means it must be called for *every* call into JS, sync or not.
18:44:22  <isaacs>so... i think the comment is probably actually a lie at this point.
18:44:26  <creationix>isaacs, no doubt the openssl code is faster called from C, but in node js code has to context switch to access C apis
18:44:36  <isaacs>creationix: right.
18:44:49  <isaacs>boy, if v8 could make context switches faster... man.
18:44:52  <isaacs>that'd be *awesome*
18:44:55  <creationix>no kidding
18:45:00  <creationix>they are cheap in lua, it's great
18:45:03  <isaacs>trevnorris: so, also, there was some talk of upgrading v8 to 3.16 pre-v0.10
18:45:06  <creationix>(and writing C bindings is easier too)
18:45:28  <creationix>but v8 is what is it is
18:45:29  <isaacs>trevnorris: that might actually make a lot of these microbenches less relevant (or more relevant, who knows!?)
18:45:46  <creationix>it was designed for the web after all, not a lot of custom C extensions there, just the built-in dom stuff
18:45:54  <trevnorris>isaacs: that's a good idea imho. and we can only know after we try. :)
18:46:06  * bnoordhu1sjoined
18:46:23  <trevnorris>isaacs: before i burn cycles making the change. wanted to use ->Has(domain_symbol) then return from a function that doesn't have all the extra domain checks.
18:46:26  <trevnorris>sound good?
18:47:11  <isaacs>trevnorris: um... not sure what you mean
18:47:22  <isaacs>trevnorris: you mean we call a different _tickCallback from MakeCallback if there's no domain?
18:47:32  <isaacs>(if so, kinda brilliant...)
18:47:51  <isaacs>or something?
18:48:08  <trevnorris>yeah. that and there's a lot of domain stuff checking in the same MakeCallback. so also return from a much simpler MakeCallbackNoDomain()
18:48:31  <trevnorris>and Has() is a lot faster than trying to get the object then checking if it was sset
18:49:02  <isaacs>so, MakeCallback(..){... if (!has(domain)) return MCNoDomain(...); startDomainStuff(); ret = mcNoDomain(); endDomainStuff(); return ret }
18:49:05  <isaacs>kinda like that?
18:49:12  <trevnorris>yeah.
18:49:18  <isaacs>yeah, that's a good idea.
18:49:25  <trevnorris>cool. i'll make the changes.
18:49:33  <isaacs>i'll be surprised if it doesn't yield a modest perf boost.
18:51:20  * mralephjoined
18:51:33  <isaacs>that's a lotta red: http://cl.ly/image/0P1I3x0C3k0X
18:51:55  <isaacs>and i've just started.
18:52:07  <isaacs>luckily the Buffer stuff will be pretty green, and a few other things.
18:52:19  <trevnorris>you mean from v8?
18:52:25  <isaacs>trevnorris: and this MC/TC stuff hopefully will make a difference.
18:52:33  <isaacs>trevnorris: that's my benchmark/compare.js script output
18:52:43  <trevnorris>cool. like the color
18:52:43  <isaacs>you give you two node binaries, and it prints out colored %age diffs
18:53:07  <isaacs>green = first one is faster, red = second is faster.
18:53:17  <isaacs>./node benchmark/compare.js ./node ../node-v0.8/node
18:53:59  <isaacs>the tcp-raw stuff is WAY faster with ascii than v0.8
18:54:15  <isaacs>net/tcp-raw-pipe.js len=16777216 type=asc dur=3: ./node: 3.7436 ../node-v0.8/node: 2.8052 28.66%
18:54:22  <isaacs>net/tcp-raw-pipe.js len=102400 type=asc dur=3: ./node: 4.659 ../node-v0.8/node: 3.0617 41.38%
18:54:41  <isaacs>so is net-pipe
18:55:43  <isaacs>also fascinating: our net-pipe diffs are actually *smaller* than our tcp-raw diffs.
18:55:57  <trevnorris>hm? that's strange.
18:55:58  <isaacs>ie, we're slower, but less slower than we are with tcp-raw
18:56:03  <trevnorris>what's the system?
18:56:04  <isaacs>well, not really. if v8 is just faster.
18:56:08  <isaacs>and streams2 isn't SO bad.
18:56:18  <trevnorris>lol ok.
18:56:30  <isaacs>rather, if streams2 isn't as much worse as v8 is better :)
18:56:36  <trevnorris>heh
18:56:38  <isaacs>just means that more of the problem lies in src/node.js
18:56:46  <isaacs>(ie, what you're working on right now)
18:57:37  <isaacs>actually, i should just comment out the ascii tests for now. we're so much more fast than v0.8 there, ti's not even worth tracking.
18:57:55  <isaacs>boosts self-esteem, but not really helpful for debugging :)
18:58:06  <isaacs>maybe the compare.js script could have a mode to only show red lines or only show green lines.
18:58:10  <isaacs>that'd be useful
18:58:46  <isaacs>mostly, this is what people care about:
18:58:47  <isaacs>http/cluster.js type=buffer length=4 c=150: ./node: 17493 ../node-v0.8/node: 19372 -10.19%
18:59:06  <isaacs>and i have a feeling that that's going to be some nitty gritty work in lib/http.js, which is pretty /o\
19:05:51  * qmx|awaychanged nick to qmx
19:06:06  <trevnorris>isaacs: input on other name for no domain _makeCallback?
19:06:16  <trevnorris>and have fun in http.js. ;-)
19:07:00  <isaacs>so you're leaving it in JS? or domainless node::MakeCallback()?
19:07:22  <isaacs>(no opinions either way, just curious)
19:07:32  <isaacs>you can name it whatever seems like it makes sense to you, and we'll bikeshed in the PR.
19:07:37  <trevnorris>oops. meant another name for _tickCallback
19:07:45  <trevnorris>that has all the domain stuff removed.
19:07:45  <isaacs>i don't care much, as long as it's not badly misleading
19:07:47  <isaacs>right
19:07:58  <trevnorris>ok, will do
19:08:06  <isaacs>roll some dice if you need help :)
19:08:12  <isaacs> makeTickCallback
19:08:24  <isaacs>as long as it starts with a _, or is private in the node.js file
19:08:44  <trevnorris>_makeWeDontNeedNoStinkingDomainCallback?
19:08:44  <isaacs>heading out for a bit. back in a few hours.
19:09:02  <isaacs>_domainsAreForLosersWhoWriteErrorsInTheirCode()
19:09:07  <trevnorris>lol
19:09:22  <isaacs>real hard core programmers a) don't make mistakes, b) deserve to be punished when they do.
19:09:27  <isaacs>domains are for sissies
19:09:38  <isaacs>ok, i'm out for a bit.
19:09:45  <isaacs>will be back in a few hours.
19:10:00  <trevnorris>cool
19:11:13  <trevnorris>whoa whoa, wait. domains exist to help devs who need help w/ their errors? that's all sorts of messed up.
19:15:05  <isaacs>yeah, it's totally enabling
19:15:12  * isaacs&
19:15:12  <LOUDBOT>DOUCHEBAG GIRLFRIEND GETS HOME EARLY FROM WORK, COMPLAINS.
19:31:17  * paddybyersquit (Read error: Connection reset by peer)
19:31:36  * paddybyersjoined
19:33:46  * Ralt_quit (Remote host closed the connection)
19:36:07  <trevnorris>isaacs: why you use fprintf and not ThrowException, ThrowError, etc?
19:43:18  <bnoordhu1s>trevnorris: because it's a fatal error
19:43:31  <trevnorris>ah, thanks.
19:43:34  * lohkeyjoined
19:44:24  <trevnorris>bnoordhu1s: i noticed that in isaacs changes he always runs process_tickCallback->Call(process, NULL, 0);
19:44:40  <trevnorris>wait. duh. nm.
19:46:56  <trevnorris>bnoordhu1s: just to check. a TryCatch can catch multiple times?
19:49:14  <indutny>bnoordhu1s: ping :)
19:49:25  <indutny>trevnorris: I think better not try it :)
19:49:52  <trevnorris>indutny: ok, so declare a new TryCatch before every call to js?
19:50:43  <bnoordhu1s>indutny: #703 conceptually lgtm but i would suggest to wrap the w->rcount-- bits in a macro so you don't have #ifdef statements all over the place
19:51:15  <bnoordhu1s>i.e. a macro that evaluates to nothing on non-kqueue platforms
19:51:31  <indutny>bnoordhu1s: yep
19:51:33  <indutny>bnoordhu1s: sure
19:59:58  * indexzerojoined
20:14:29  * stagas_joined
20:16:45  * stagasquit (Ping timeout: 252 seconds)
20:16:54  * stagas_changed nick to stagas
20:26:52  * jmar777joined
20:27:32  * qmxchanged nick to qmx|away
20:29:04  <trevnorris>whoot! domains can go suck a duck.
20:29:54  * qmx|awaychanged nick to qmx
20:32:03  <trevnorris>indutny: you know of any gc changes between 3.15 and 3.16?
20:33:13  * Ralt_joined
20:33:22  * Ralt_quit (Remote host closed the connection)
20:36:31  * stagas_joined
20:37:40  * stagasquit (Ping timeout: 248 seconds)
20:37:42  * stagas_changed nick to stagas
20:38:10  <indutny>trevnorris: no, not really
20:38:14  <indutny>I'm not developing it, honestly
20:38:21  <trevnorris>heh, ok.
20:38:33  <trevnorris>i'm just trying to figure out why master is using twice as much ram as v0.8
20:39:03  <indutny>could be GC
20:39:51  <trevnorris>that's what's been suggested. think bnoordhu1s said something to that effect.
20:40:08  <trevnorris>traced gc's and v0.8 is cleaning up twice as often.
20:41:39  * bnoordhu1squit (Ping timeout: 256 seconds)
20:41:57  * sblomjoined
20:49:05  * bnoordhuisquit (Ping timeout: 255 seconds)
20:51:25  <trevnorris>isaacs: so the changes don't do much for tcp_net2, but it does a lot more for tcp_net_
20:53:17  <MI6>joyent/libuv: Fedor Indutny master * 4deb3bf : stream: use kevent() information before accept() Limit number of syscall - http://git.io/oFqNcA
20:55:12  <MI6>joyent/libuv: Fedor Indutny master * c15d4a7 : stream: use kevent() information before accept() Limit number of syscall - http://git.io/i6idbg
20:55:20  <indutny>oops
20:55:21  <indutny>force push
20:55:24  <indutny>please forgive me ben
21:19:24  * TheJHquit (Read error: Operation timed out)
21:32:06  * stagas_joined
21:34:07  * stagasquit (Ping timeout: 260 seconds)
21:34:22  * stagasjoined
21:34:34  * Sh4rKjoined
21:34:43  <Sh4rK>hi!
21:35:07  <Sh4rK>what is the correct way to get a file size from an uv_fs_fstat callback?
21:35:23  * jmar777quit (Remote host closed the connection)
21:36:15  <Sh4rK>It seems like on OS X the name of the stat struct is statbuf, while on windows and linux it's just stat
21:36:27  <Sh4rK>is there a platform independent way to access it?
21:36:54  * stagas_quit (Ping timeout: 256 seconds)
21:37:50  * Ralt_joined
21:40:52  * wolfeidauquit (Remote host closed the connection)
21:41:27  * qmxchanged nick to qmx|away
21:43:05  * trevnorris&
21:43:05  <LOUDBOT>OK YOU ARE A GENERAL AGAIN SIR
21:48:04  * bnoordhuisjoined
21:50:27  <indutny>Sh4rK: it's not really documented
21:50:45  <indutny>but
21:50:51  <indutny>after uv_fs_stat has called callback
21:50:53  * `3rdEdenquit (Remote host closed the connection)
21:50:55  <indutny>req->ptr
21:51:07  <indutny>is basically uv_statbuf_t*
21:51:20  <indutny>Sh4rK: if you've some time please open issue on https://github.com/joyent/libuv
21:51:39  <Sh4rK>what should be the issue?
21:51:44  <Sh4rK>missing documentation?
21:52:31  * bnoordhuisquit (Ping timeout: 245 seconds)
21:53:29  <indutny>yes
21:56:35  <Sh4rK>ok, I will
22:00:34  * qmx|awaychanged nick to qmx
22:00:43  <CoverSlide>libuv has documentation now?
22:02:40  * trevnorrisfg
22:04:19  <indutny>CoverSlide: include/uv.h
22:04:20  <indutny>as usual
22:04:24  <CoverSlide>haha
22:04:30  * jmar777joined
22:04:48  <trevnorris>are domains a feature isaacs added?
22:05:16  <CoverSlide>I think domains were ry's baby
22:05:46  <trevnorris>well they're making my life hell right now...
22:07:33  <trevnorris>just in the fact that some code logic changes that shouldn't make sense, work.
22:07:41  <trevnorris>it hurts my small brain
22:15:33  <roxlu>what libs do I need to link with on windows ? (ws2_32.lib + ?? )
22:17:29  <roxlu>I'm getting a unresolved for "GetProcessMemoryInfo" (which seems to be part of the kernel dll)
22:19:41  <roxlu>so it seems one must link with: ws2_32.lib, Iphlpapi.lib and psapi.lib on windows (7)
22:19:54  <roxlu>would be cool if this could be added to the git readme
22:20:24  * rendarquit
22:21:23  * `3rdEdenjoined
22:21:23  * c4miloquit (Remote host closed the connection)
22:27:15  <roxlu>hey, I was using the tty feature but it's not working on windows :(
22:27:42  <roxlu>I only get "question mark" charachters (or those unicode thingies)
22:29:25  * `3rdEdenquit (Ping timeout: 240 seconds)
22:34:47  * brsonjoined
22:43:20  <roxlu>hmm intresting .. it seems to be a problem with std::stringstream on windwos
22:47:00  * qmxchanged nick to qmx|away
22:51:34  * sblomquit (Ping timeout: 244 seconds)
23:01:00  * indexzeroquit (Quit: indexzero)
23:06:25  * Ralt_quit (Remote host closed the connection)
23:14:24  * qmx|awaychanged nick to qmx
23:16:05  * wolfeidaujoined
23:24:50  * c4milojoined
23:37:01  * mmalecki[out]changed nick to mmalecki
23:41:46  * c4miloquit (Remote host closed the connection)
23:42:38  * c4milojoined
23:49:47  * paddybyersquit (Ping timeout: 256 seconds)
23:55:37  * piscisaureus_joined
23:56:54  * jmar777quit (Remote host closed the connection)
23:58:02  * isaacsfg
23:59:56  * jmar777joined