00:00:01  * ircretaryquit (Remote host closed the connection)
00:00:11  * ircretaryjoined
00:01:37  * loladiroquit (Quit: loladiro)
00:02:50  * paulfryzeljoined
00:03:30  <tjfontaine>mmalecki: https://gist.github.com/tjfontaine/9be3fec3e943452f89ad first one is node of course, second is python, looks like it's a different symbol?
00:05:51  <mmalecki>tjfontaine: oh the hell?
00:06:07  <trevnorris>tjfontaine: thanks. i'll save that for tomorrow.
00:07:04  <isaacs>trevnorris: interesting. lota arrays
00:07:07  * paulfryzelquit (Ping timeout: 246 seconds)
00:07:17  <tjfontaine>mmalecki: not really sure, I'm still trying to figure it out
00:07:25  <isaacs>trevnorris: what's 8ed0814d?
00:09:19  <isaacs>tjfontaine: trevnorris: where's the core file at?
00:09:48  <tjfontaine>isaacs: smartos.nodejs.org:/home/trevnorris/gh-*/core* I think is the wildcard I used to grab it
00:09:57  <isaacs>ok
00:10:06  <tjfontaine>isaacs: you'll also want to use the v8.so that's in his home dir
00:10:18  <isaacs>huh..
00:10:37  <tjfontaine>it gets stuck somewhere along the way without the newer v8.so
00:10:48  <isaacs>right
00:12:04  * paulfryzeljoined
00:14:41  <isaacs>trevnorris: so, there seem to be a lot of sockets that are readable:false,writable:false
00:15:14  <isaacs>oh, but those also aren't referred to by anything.
00:15:18  <isaacs>just garbage.
00:16:22  * dscape__joined
00:17:07  <tjfontaine>mmalecki: actually I forgot my node is 64, and my python 32, so the offset changes are just different libcs, though I am testing with proper arch for each preload
00:23:33  * loladirojoined
00:24:32  * AvianFluquit (Remote host closed the connection)
00:25:10  * c4milojoined
00:26:58  <isaacs>tjfontaine, trevnorris: ok, modified the test to run gc() repeatedly.
00:27:03  <isaacs>hammering it now
00:28:03  * bradleymeckjoined
00:28:07  <tjfontaine>k
00:28:11  <isaacs>trevnorris: how were you generating traffic? wrk or ab?
00:30:11  <tjfontaine>mmalecki: interestingly, the only time for the libuv test suite where the preloaded bind is triggered is when test-poll.c calls bind() itself
00:30:27  <tjfontaine>well more or less
00:32:54  <isaacs>gotta run
00:33:11  <tjfontaine>isaacs: mk
00:35:33  * defunctzombie_zzchanged nick to defunctzombie
00:39:45  * loladiroquit (Ping timeout: 264 seconds)
00:43:40  * loladirojoined
00:45:01  * defunctzombiechanged nick to defunctzombie_zz
00:55:29  * qardquit (Quit: Leaving.)
01:01:18  * kazuponjoined
01:02:34  * defunctzombie_zzchanged nick to defunctzombie
01:03:01  * kazuponquit (Remote host closed the connection)
01:03:13  * kazuponjoined
01:09:12  * mikealjoined
01:12:14  * defunctzombiechanged nick to defunctzombie_zz
01:17:27  * qardjoined
01:17:27  * qardquit (Client Quit)
01:22:09  * loladiroquit (Quit: loladiro)
01:22:49  * sblomquit (Ping timeout: 268 seconds)
01:23:32  * paulfryzelquit (Remote host closed the connection)
01:25:54  * kazuponquit (Remote host closed the connection)
01:29:14  * kazuponjoined
01:34:28  * loladirojoined
01:35:51  * abraxasjoined
01:37:42  * c4miloquit (Remote host closed the connection)
01:37:49  * ik_changed nick to ik
01:39:09  * loladiroquit (Ping timeout: 264 seconds)
01:44:25  * julianduquequit (Ping timeout: 246 seconds)
01:56:59  * TooTallNatequit (Quit: Computer has gone to sleep.)
02:04:47  * mikealquit (Quit: Leaving.)
02:17:33  * werlejoined
02:18:03  * werlequit (Client Quit)
02:22:09  * defunctzombie_zzchanged nick to defunctzombie
02:27:54  * M28_joined
02:28:04  * M28quit (Read error: Connection reset by peer)
02:31:39  * defunctzombiechanged nick to defunctzombie_zz
02:51:20  * jmar777joined
02:52:57  * pachet_quit (Ping timeout: 264 seconds)
03:07:38  * DrPizzaquit (Quit: alice.)
03:07:50  * DrPizzajoined
03:08:53  * jmar777quit (Remote host closed the connection)
03:09:27  * pachetjoined
03:09:54  * pachetquit (Client Quit)
03:23:23  * c4milojoined
03:23:37  * c4miloquit (Remote host closed the connection)
03:29:51  * loladirojoined
03:29:53  * defunctzombie_zzchanged nick to defunctzombie
03:31:20  * loladiroquit (Client Quit)
03:37:06  * kazuponquit (Remote host closed the connection)
03:42:41  * bradleymeckquit (Quit: bradleymeck)
04:04:24  * loladirojoined
04:07:23  * kazuponjoined
04:12:24  * kazuponquit (Ping timeout: 268 seconds)
04:20:24  * kazuponjoined
04:24:14  * qmxchanged nick to zombie222
04:24:25  * zombie222changed nick to qmx
05:44:49  * bajtosjoined
05:46:22  * paddybyersjoined
06:06:53  * stagasjoined
06:20:51  * rendarjoined
06:24:22  * hzquit (Disconnected by services)
06:24:27  * hzjoined
06:58:11  * defunctzombiechanged nick to defunctzombie_zz
07:04:57  * paddybyersquit (Ping timeout: 264 seconds)
07:13:17  * niska`joined
07:14:09  * niskaquit (*.net *.split)
07:39:14  * csaohjoined
07:40:24  * loladiroquit (Quit: loladiro)
07:41:51  * paddybyersjoined
08:14:16  * paddybyersquit (Ping timeout: 240 seconds)
08:29:57  * paddybyersjoined
08:31:52  * stagasquit (Read error: Connection reset by peer)
09:09:11  * abraxasquit (Remote host closed the connection)
09:18:46  * stagasjoined
09:26:47  * icarotjoined
09:47:01  * icarotquit (Remote host closed the connection)
09:47:46  * icarotjoined
09:54:25  * kazuponquit (Remote host closed the connection)
09:57:11  * icarotquit (Ping timeout: 264 seconds)
10:02:59  * icarotjoined
10:07:36  * icarotquit (Ping timeout: 268 seconds)
10:27:54  * csaohquit (Quit: csaoh)
10:32:34  * csaohjoined
10:42:33  * bajtosquit (Quit: bajtos)
10:44:54  * bajtosjoined
10:45:02  * bajtosquit (Client Quit)
10:48:18  * icarot2joined
10:55:01  * icarot2quit (Ping timeout: 256 seconds)
11:03:28  * icarotjoined
11:03:34  * bajtosjoined
11:05:32  * bajtosquit (Client Quit)
11:08:39  * icarotquit (Ping timeout: 268 seconds)
11:22:11  * icarotjoined
11:47:06  * AvianFlujoined
11:54:17  * icarotquit (Ping timeout: 268 seconds)
11:58:30  * felixgequit (Quit: IRCRelay - http://ircrelay.com)
11:59:07  * hzquit
12:14:04  * julianduquejoined
12:18:38  * jmar777joined
12:56:00  * wolfeidauquit (Remote host closed the connection)
12:56:26  * wolfeidaujoined
13:01:30  * wolfeidauquit (Ping timeout: 268 seconds)
13:01:51  * werlejoined
13:15:17  * werlequit (Quit: Leaving.)
13:22:47  * dapjoined
13:27:39  * icarotjoined
13:28:23  * c4milojoined
13:32:16  * icarotquit (Ping timeout: 240 seconds)
13:43:28  * icarotjoined
13:47:52  * icarotquit (Ping timeout: 246 seconds)
13:52:29  * kenperkinsjoined
13:58:39  * kenperkinsquit (Quit: Textual IRC Client: http://www.textualapp.com/)
14:04:53  * dapquit (Quit: Leaving.)
14:09:38  * bajtosjoined
14:15:47  * piscisaureus_joined
14:21:15  * werlejoined
14:21:57  * bajtosquit (Ping timeout: 248 seconds)
14:22:54  * icarotjoined
14:27:27  * icarotquit (Ping timeout: 257 seconds)
14:29:49  * julianduquequit (Quit: leaving)
14:30:00  * dapjoined
14:30:34  * hueniversequit (Quit: Leaving.)
14:31:17  * julianduquejoined
14:31:20  * julianduquequit (Changing host)
14:31:20  * julianduquejoined
14:38:05  * icarotjoined
14:42:28  * icarotquit (Ping timeout: 246 seconds)
14:44:47  * stagas_joined
14:46:39  * indexzerojoined
14:48:11  * stagasquit (Ping timeout: 264 seconds)
14:48:13  * stagas_changed nick to stagas
14:48:34  * icarotjoined
14:52:58  * icarotquit (Ping timeout: 246 seconds)
14:53:04  * piscisaureus_quit (Read error: Operation timed out)
14:53:33  * kenperkinsjoined
15:03:46  * icarotjoined
15:08:16  * icarotquit (Ping timeout: 240 seconds)
15:24:51  * kenperkinsquit (Ping timeout: 260 seconds)
15:25:19  * mcavagejoined
15:28:00  * werlequit (Quit: Leaving.)
15:28:28  * werlejoined
15:34:30  * defunctzombie_zzchanged nick to defunctzombie
15:43:02  * loladirojoined
15:49:29  * icarotjoined
15:49:57  * st_lukejoined
15:54:16  * icarotquit (Ping timeout: 276 seconds)
15:59:02  * pachetjoined
16:04:35  * icarotjoined
16:05:36  * werlequit (Quit: Leaving.)
16:06:58  * `3rdEdenchanged nick to `3E|COOKING
16:07:29  * dapquit (Quit: Leaving.)
16:09:31  * icarotquit (Ping timeout: 240 seconds)
16:10:35  <tjfontaine>good day folks
16:13:22  <trevnorris>morning
16:13:27  <trevnorris>isaacs: ping
16:14:18  <tjfontaine>how goes trevor?
16:17:38  * mikealjoined
16:21:06  <trevnorris>going well.
16:23:36  * icarotjoined
16:24:46  <mmalecki>tjfontaine: regarding that issue with LD_PRELOAD, only difference I found was that bind() in node happens in a thread, I *think*
16:25:08  <tjfontaine>erm that can't be right
16:26:16  * dapjoined
16:27:05  <tjfontaine>mmalecki: there's probably some LD_DEBUG flags to twiddle here to get better visibility
16:27:47  <mmalecki>tjfontaine: https://gist.github.com/mmalecki/14236fb1408107187648 - the /1 thing suprises me
16:28:05  * icarotquit (Ping timeout: 268 seconds)
16:29:08  <tjfontaine>well, there are probably no other threads in the python one, and it's prefixed with 1 because the fs threadpool has been activated?
16:29:55  <mmalecki>yeah, but I'm wondering if this affects anything
16:30:04  <mmalecki>need to write a test in C to figure this one out
16:30:08  * st_lukequit (Remote host closed the connection)
16:30:28  <tjfontaine>there's something else going on here, because I was getting the same with just libuv testsuite itself
16:30:31  * c4miloquit (Remote host closed the connection)
16:31:44  * st_lukejoined
16:32:23  <mmalecki>hmmm, I *think* I know what's up. bind doesn't seem to actually be the function it looks up.
16:32:40  <mmalecki>ld looks for _so_bind, but not bind
16:33:16  * mikealquit (Quit: Leaving.)
16:33:20  * icarotjoined
16:34:28  <tjfontaine>right
16:34:50  <tjfontaine>but I'm not sure what's different in tcp.c vs test/test-poll.c in taht regard
16:35:53  * werlejoined
16:35:54  * mikealjoined
16:37:10  * austojoined
16:38:28  * icarotquit (Ping timeout: 276 seconds)
16:41:52  <austo>Hi, I'm wondering about the best practice for using a semaphore inside of a uv_work_cb. If anyone has a link to an example I'd really appreciate it.
16:44:06  * dapquit (Quit: Leaving.)
16:44:37  * werlequit (Ping timeout: 246 seconds)
16:45:59  * c4milojoined
16:46:04  * hzjoined
16:47:33  * mikealquit (Quit: Leaving.)
16:48:53  * st_lukequit (Remote host closed the connection)
16:49:08  * loladiroquit (Quit: loladiro)
16:49:16  * werlejoined
16:49:17  * AndreasMadsenjoined
16:50:12  * csaohquit (Quit: csaoh)
16:50:35  * loladirojoined
16:51:09  <trevnorris>isaacs: ok. I have the server setup to reproduce the issue for you.
16:51:26  * loladiroquit (Client Quit)
16:53:09  * indexzeroquit (Quit: indexzero)
16:53:19  * AndreasMadsenquit (Remote host closed the connection)
16:53:37  * AndreasMadsenjoined
16:54:56  <trevnorris>tjfontaine: you around?
16:55:23  <tjfontaine>trevnorris: aye
16:55:39  * werlequit (Quit: Leaving.)
16:56:33  <trevnorris>tjfontaine: i want to try session sharing for tmux. that way you guys can see exactly what i'm doing. so can you login to smartos server and type: tmux -S /tmp/http-leak-session attach
16:57:24  <tjfontaine>k
16:57:31  * mikealjoined
16:59:20  * icarotjoined
16:59:56  <tjfontaine>trevnorris: doot doot
16:59:59  * rendarquit (Ping timeout: 245 seconds)
17:00:53  * rendarjoined
17:01:31  * dapjoined
17:01:33  <trevnorris>tjfontaine: nothing?
17:01:57  <tjfontaine>I'm on, are we not sharing it?
17:02:01  * mikealquit (Client Quit)
17:02:14  <trevnorris>tjfontaine: oh ok. so you can see the test running?
17:02:41  <tjfontaine>no, in the session I am just sitting at a shell
17:03:27  <trevnorris>tjfontaine: eh? that's strange
17:03:36  <tjfontaine>[trevnorris@828cbda3-e3d6-4744-86bf-8ad6733dcf15 /root]$ ready when you are^C
17:03:36  <tjfontaine>[trevnorris@828cbda3-e3d6-4744-86bf-8ad6733dcf15 /root]$ id
17:03:36  <tjfontaine>uid=24563(trevnorris) gid=1(other) groups=1(other)
17:03:41  <tjfontaine>is what I typed
17:04:44  <trevnorris>tjfontaine: that's really strange. I just logged in from another window and was able to share my session.
17:05:07  <trevnorris>ok. lemme test something
17:05:39  <trevnorris>tjfontaine: when I type w it doesn't show you logged in
17:06:09  <tjfontaine>I swear I'm there :)
17:06:17  <tjfontaine>you detached me
17:06:30  <trevnorris>ah, must be logged in as me I guess?
17:06:33  <trevnorris>that's really strange.
17:06:46  <tjfontaine> w
17:06:46  <tjfontaine> 5:06pm up 105 day(s), 9:56, 3 users, load average: 1.25, 1.15, 0.93
17:06:46  <tjfontaine>User tty login@ idle JCPU PCPU what
17:06:46  <tjfontaine>root pts/7 4:56pm w
17:06:46  <tjfontaine>root pts/8 5:05pm -bash
17:06:49  <tjfontaine>trevnorr pts/9 5:00pm 1 tmux -S /tmp/http-leak-session a
17:06:52  <tjfontaine>I'm root :)
17:06:52  * brsonjoined
17:06:57  <trevnorris>su - trevnorris
17:07:00  <trevnorris>then try to attach again
17:07:27  <tjfontaine>that a is important
17:07:36  <tjfontaine>ugh, are we in screen mode?
17:07:55  <trevnorris>how do you mean?
17:08:25  * icarotquit (Ping timeout: 252 seconds)
17:08:40  <tjfontaine>^Bn isn't doing what I expect :)
17:08:45  <trevnorris>heh, yeah
17:08:52  <tjfontaine>what's the bind key?
17:08:54  <trevnorris>swapped that for ctrl-a
17:09:03  <tjfontaine>ok, "screen mode"
17:09:20  <trevnorris>on sec
17:09:38  <trevnorris>there, just a few of the bindings.
17:09:42  <trevnorris>now all yours :)
17:09:44  <tjfontaine>I'm fine with it, I just wanted to know what world i was in :)
17:10:07  <tjfontaine>so you should gcore it now, and then later
17:10:33  <tjfontaine>looks pretty stable atm though
17:10:34  <trevnorris>tjfontaine: hm. i'm not seeing the same leak. one sec.
17:10:45  <tjfontaine>k
17:11:53  * mcavagequit (Remote host closed the connection)
17:12:17  <trevnorris>so it appears like the leak only manifests itself without keepalive
17:12:20  * mcavagejoined
17:12:57  <tjfontaine>I don't think it's that surprising, as you're cycling through more sockets
17:13:23  <tjfontaine>is there a flag for ab/wrk that says how many requests it should use for a socket?
17:14:14  <trevnorris>don't see one for ab, and wrk doesn't have one.
17:14:33  <trevnorris>it's just keepalive or don't
17:14:38  <tjfontaine>nod
17:15:26  <trevnorris>right now 99% of cycles are consumed by gc so mem growth is super slow
17:15:32  <trevnorris>but it's constant.
17:15:35  <tjfontaine>so, I would gcore it now, and then wait 30mins? and then gcore it again, and see what is held
17:16:51  * loladirojoined
17:16:51  * mcavagequit (Ping timeout: 260 seconds)
17:16:54  <trevnorris>whoa, why does gcore cause the rss to shoot up?
17:18:39  <tjfontaine>it may touch pages that previously weren't live
17:18:54  <tjfontaine>as it gathers information about the process
17:19:34  <trevnorris>ok
17:19:55  * TooTallNatejoined
17:21:33  * sblomjoined
17:22:08  * icarotjoined
17:22:38  * mjr__joined
17:22:59  <brson>do idle handles use an fd?
17:28:04  * icarotquit (Ping timeout: 260 seconds)
17:38:25  * icarotjoined
17:40:19  <tjfontaine>mmalecki: got it figured out
17:41:23  <tjfontaine>mmalecki: the symbol name isn't actually bind, it's __xnet_bind in this particualr case, which depends on what defines we've set
17:41:36  * stagas_joined
17:41:42  <tjfontaine>trevnorris: what have we learned?
17:41:58  <tjfontaine>lots of left over sockets
17:42:32  <trevnorris>tjfontaine: that i'm impatient. gc is preventing almost anything from happening since I set max_{old,new}_space_size=16, so need to let it run longer.
17:42:44  <tjfontaine>ok
17:42:46  <tjfontaine>:)
17:43:01  * icarotquit (Ping timeout: 248 seconds)
17:43:05  <trevnorris>started over. took a dump on startup, dump a few seconds after connections started coming in, and will take another in a while.
17:43:15  <tjfontaine>nod
17:43:23  <mmalecki>tjfontaine: I just got it to work with _so_bind too, just a few minutes ago
17:43:54  * stagasquit (Ping timeout: 240 seconds)
17:43:56  * stagas_changed nick to stagas
17:44:01  <tjfontaine>mmalecki: _so_bind seems slightly evil, but right, the symbol we're actually using for bind() gets all kinds of abuse done to it in the name of POSIX
17:45:02  <mmalecki>this is why we can't have nice things
17:45:27  <tjfontaine>no doubt
17:46:56  <mmalecki>tjfontaine: wanna see what I'm actually using that for :) ?
17:47:24  <tjfontaine>dunno, do I? :)
17:47:56  <mmalecki>it can hurt your eyes
17:48:26  <tjfontaine>what's the worst that could happen, hit me
17:49:01  <mmalecki>tjfontaine: I just added you on github :-)
17:49:06  <mmalecki>gotta go get dinner now
17:49:20  <mmalecki>hit me with any questions in PM tho
17:50:00  <tjfontaine>k, enjoy!
17:51:15  * icarotjoined
17:52:02  <isaacs>tjfontaine, bnoordhuis: 11.4 fails to build on Ubuntu Lucid: https://launchpadlibrarian.net/145153704/buildlog_ubuntu-lucid-amd64.nodejs_0.11.4-1chl1~lucid1_FAILEDTOBUILD.txt.gz
17:53:08  <isaacs>probably from the fact that it has gcc 4.4
17:53:10  <isaacs>not sure, though
17:54:43  <trevnorris>isaacs: Jun 18 13:16:54 <bnoordhuis> we don't really support gcc < 4.2
17:54:52  <trevnorris>so that hopefully wouldn't be the problem.
17:55:19  <isaacs>right
17:55:24  <isaacs>because we do support gcc 4.4
17:56:16  * icarotquit (Ping timeout: 268 seconds)
17:57:50  <trevnorris>isaacs: look at 2c470301
17:57:53  <trevnorris>same error
18:00:22  <tjfontaine>'gcc_version': 44, ya I kinda expected it to work
18:00:35  <isaacs>trevnorris: thanks!
18:00:39  <trevnorris>:)
18:00:40  <isaacs>yeah, that's the issue
18:00:46  <tjfontaine>ah right, ya
18:01:14  * stagasquit (Quit: Bye)
18:03:11  <trevnorris>it sorta irks me when people "correct" my memory leak tests. :P
18:08:57  <trevnorris>tjfontaine: so will that dump show me anything about external memory?
18:10:01  <tjfontaine>what do you want to know about external memory? it can tell you about allocated addresses
18:10:19  <trevnorris>not sure. just curious.
18:10:44  <trevnorris>so there does seem to be some retention. taking notes and i'll post back
18:11:43  <trevnorris>tjfontaine: i'm stepping away for a few. feel free to check things out in the terminal
18:11:54  <trevnorris>window on the left has the last core dump.
18:11:58  <trevnorris>window on the right has the previous
18:12:13  <tjfontaine>nod
18:16:30  * dapquit (Quit: Leaving.)
18:22:30  <trevnorris>well that was a lot quicker than I thought.
18:25:49  <trevnorris>tjfontaine: hm. there are two objects on screen that look very similar, but aren't.
18:25:57  <trevnorris>can't figure out where each is being created.
18:26:30  <tjfontaine>interesting
18:27:40  <trevnorris>ah, nm. one's readable, other's writable.
18:29:07  <trevnorris>tjfontaine: so if I resolve something back far enough and it says "not referred to by known object" does that mean it's dead?
18:30:32  <tjfontaine>that's what I how i would interpret it
18:30:48  <tjfontaine>at least, found in the heap, but not tracked by the gc
18:31:51  <trevnorris>what about some object passed to a callback function. not technically referred to directly by something else
18:32:00  <trevnorris>but still needs to be sticking around.
18:32:39  <tjfontaine>it should be like an "unknown object" I think
18:33:03  <trevnorris>ah, ok.
18:33:13  <trevnorris>i've seen lots of those before.
18:47:42  <trevnorris>tjfontaine: well, i'm not seeing a huge discrepancy between the two
18:49:59  * kenperkinsjoined
19:02:48  * wolfeidaujoined
19:12:36  * sblomquit (Ping timeout: 254 seconds)
19:13:26  <trevnorris>tjfontaine: well. so I can't reproduce the issue the same way on smartos like I can on my linux box.
19:15:37  * wolfeidauquit (Remote host closed the connection)
19:23:10  * brsonquit (Ping timeout: 246 seconds)
19:26:18  * brsonjoined
19:28:12  * `3E|COOKINGchanged nick to `3rdEden
19:39:48  <tjfontaine>trevnorris: well that's frustrating, and interesting
19:40:19  * piscisaureus_joined
19:40:25  <piscisaureus_>$ find . -iname package.json -exec node -pe "p=require(process.argv[1]); p.name + '@' + p.version" {} \;
19:40:25  * qmxquit (Read error: Operation timed out)
19:40:27  <trevnorris>tjfontaine: ugh! so I'm running gc() on every incoming request on my box. can't get the stupid thing to grow.
19:40:33  <piscisaureus_>suddenly node startup time matters ^
19:41:07  * brsonquit (Ping timeout: 276 seconds)
19:41:08  <trevnorris>tjfontaine: so i'm almost convinced it's a bug in v8's gc that was resolved in 3.20
19:41:18  <tjfontaine>trevnorris: seems reasonable
19:41:27  <trevnorris>i'm going to go look over v8 logs to see if there's mention of this.
19:41:42  * defunctzombiequit (Ping timeout: 246 seconds)
19:44:38  * kenperkinsquit (Ping timeout: 240 seconds)
19:46:41  * dapjoined
19:47:11  * defunctzombiejoined
19:47:13  * qmxjoined
19:48:45  * sblomjoined
19:49:39  * julianduquequit (Remote host closed the connection)
19:50:04  <trevnorris>damn you v8! get to use all that internal magic sauce for array buffers, ours could be so much faster.
19:52:47  * dapquit (Quit: Leaving.)
19:52:53  * sblomquit (Ping timeout: 240 seconds)
19:53:08  * dapjoined
19:55:09  * kenperkinsjoined
19:59:25  <trevnorris>tjfontaine: ha ha! ok. it memory is still growing despite constant gc, on my box. just at a freakishly slow rate.
19:59:33  <trevnorris>ok. so at least i'm not loosing my mind. completely.
20:00:15  <tjfontaine>heh
20:02:34  * sblomjoined
20:03:01  * julianduquejoined
20:03:23  <trevnorris>tjfontaine: well, have any ideas? memory on smartos might not be growing simply because it's only pulling 90 req/sec because gc is spinning so much.
20:03:43  <trevnorris>i dunno. getting tired of looking at this thing.
20:04:50  <tjfontaine>trevnorris: let it run for a few hours
20:05:06  <tjfontaine>pick something else up for a while :)
20:05:17  <tjfontaine>like evaluating again if ArrayBuffer can be the base type for Buffer :)
20:05:41  <trevnorris>ooh. now you're just trolling me. :P
20:06:04  <tjfontaine>no, I'm actually serious, after reading through the v8.h for 3.20 I was even more convinced it was possible :)
20:06:28  <trevnorris>yeah. I know you're serious, but it's still trolling. ;)
20:06:33  <tjfontaine>hehe
20:07:00  <tjfontaine>in gyp can I define a dependency that is a shared library but isn't actually included in linking?
20:07:17  <trevnorris>actually shouldn't* be too hard. smalloc guts are easy to replace.
20:07:23  <tjfontaine>right
20:07:48  <TooTallNate>tjfontaine: i think you can do that with "type": "none" instead of 'shared_library'
20:08:06  <tjfontaine>TooTallNate: that will make the dependency still build as the .so?
20:08:26  <TooTallNate>tjfontaine: hmm, well i'm not totally sure there... probably not though :p
20:08:31  <tjfontaine>right :)
20:09:06  <tjfontaine>worst worst worst case, I can turn it into a set of actions that buidls the .so, but I'd prefer it to be its normal thing, and then I just tell it not to link against it
20:09:51  <tjfontaine>maybe I can say !libraries
20:10:42  <tjfontaine>*libraries!
20:10:59  * mcavagejoined
20:14:37  * AvianFluquit (Remote host closed the connection)
20:17:22  <trevnorris>i swear, if using array buffers is faster i'm just going to resign as a maintainer. :P
20:17:33  * kenperkinsquit (Ping timeout: 264 seconds)
20:17:48  <isaacs>tjfontaine: demerit
20:18:08  <isaacs>we gotta get trent's bot converted to irc
20:18:14  <isaacs>i'd like to have a bnoogle.
20:19:28  * kenperkinsjoined
20:19:31  <tjfontaine>heh
20:20:06  * brsonjoined
20:21:14  <tjfontaine>TooTallNate: 'type': 'loadable_module'
20:21:19  * julianduquequit (Remote host closed the connection)
20:24:39  * julianduquejoined
20:25:49  * wolfeidaujoined
20:34:41  * ryahquit (Quit: leaving)
20:35:28  * ryahjoined
20:38:56  <trevnorris>wow. they've really gotten their calls to cc-land down. basic call with numeric return, under 10 ns.
20:38:58  <trevnorris>that's impressive.
20:39:18  <trevnorris>crossing into cc for simple stuff really shouldn't be a performance concern anymore.
20:39:20  <trevnorris>isaacs: ^
20:39:38  <tjfontaine>what's that? so long as we only speak in primitives? :)
20:39:52  <isaacs>trevnorris: intriguing
20:40:28  <trevnorris>tjfontaine: that's all i've tested, but it's looking good.
20:40:53  <tjfontaine>right, the best practices for addon modules, rule #1, only speak in primitives
20:41:57  * jmar777quit (Remote host closed the connection)
20:42:17  <trevnorris>tjfontaine: whoa, or returning any Persistent.
20:42:21  <trevnorris>that's under 25 ns
20:42:35  * jmar777joined
20:43:16  <trevnorris>tjfontaine: scratch that. it's under 10. the other 15 came from setting the HandleScope
20:43:27  <trevnorris>which you don't have to worry about in that specific case.
20:43:48  <isaacs>so... the downside of streams3 is that you're not allowed to impement your own 'read()' method now
20:43:58  <isaacs>or else you have a stream where pipe() doesn't work
20:44:20  <trevnorris>isaacs: as much as it pains me, i'm testing using ArrayBuffer class as a backer for Buffers. the smalloc re-work is making it a lot more simple to implement.
20:45:03  <trevnorris>isaacs: I haven't tried it but can you add a Transform to the middle of a pipe, so you can manipulate the data going through?
20:45:44  <isaacs>trevnorris: well, even the brokenStream.pipe(tx).pipe(dest) won't work
20:45:48  <isaacs>because brokenStream won't pipe() properly
20:46:46  * jmar777quit (Ping timeout: 240 seconds)
20:46:46  * brsonquit (Ping timeout: 240 seconds)
20:46:54  <trevnorris>hm.
20:47:44  * bnoordhuisjoined
20:48:24  * hzquit
20:48:44  <trevnorris>bnoordhuis: if node does implement multiple threads, would it be possible/safe to allow users to pass a callback that we call when switching?
20:49:37  <trevnorris>don't understand how it works completely, but was thinking something like they could reassign a global isolate when that happens. just so they don't have to call GetCurrent() constantly.
20:49:38  <tjfontaine>bnoordhuis: feeling better?
20:51:24  <trevnorris>tjfontaine: so. i'm going to test if it's possible to make Buffer a type of ArrayBufferView. then we get the Neuter functionality for free.
20:51:30  <trevnorris>that I have to admit would be awesome.
20:51:55  <tjfontaine>is that only on View? I thought it was on ArrayBuffer, but ya, it basically does everything you wanted :)
20:52:25  <trevnorris>it is on ArrayBuffer, but we'll have to use their inheritance method to take advantage of it.
20:52:46  <bnoordhuis>tjfontaine: marginally
20:52:50  <tjfontaine>trevnorris: mk
20:52:55  <trevnorris>or else we won't have the proper object properties that are necessary for Neuter to visit all of them.
20:52:58  <tjfontaine>bnoordhuis: as long as its not getting worse :)
20:55:21  <tjfontaine>trevnorris: "Test aborted after 10 failures"
20:55:39  <trevnorris>tjfontaine: yeah. that happens sometimes.
20:55:45  <tjfontaine>classy
20:56:03  <trevnorris>but I haven't been able to get it over 27 MB after running for a few hours.
20:56:13  <tjfontaine>nod
20:56:40  <trevnorris>ok. i'm going to remove the manual gc and see if that will allow memory to grow.
20:59:33  * wolfeidauquit (Remote host closed the connection)
20:59:56  <trevnorris>tjfontaine: ok, have a new plan. see if this one works out :P
21:01:52  <tjfontaine>:)
21:02:43  * sblomquit (Ping timeout: 251 seconds)
21:03:51  <trevnorris>isaacs: fyi, this might be some strange manifestation of a v8 gc bug. I was grep'ing the repo logs and there were mentions of gc issues, but haven't been able to identify anything yet.
21:04:06  <trevnorris>honestly if anything it might be how we're using Persistents
21:04:28  <trevnorris>oh, that reminds me, I can create a Persistent handle visitor and pump out information about everything that currently exists.
21:06:59  * wolfeidaujoined
21:09:17  <tjfontaine>isaacs: https://github.com/tjfontaine/node/compare/mdb this does the new world build v8.so into node binary, so that newer mdb's get the proper version always, that branch is against master but I don't see a particular problem making it work with v0.10 and potentially v0.8, the platform will still be shipping v8.so for a while but we'll be the canonical location for fixing the v8.so going forward
21:10:24  <tjfontaine>bnoordhuis: for your feedback as well ^^
21:10:42  <isaacs>trevnorris: that sounds promising
21:23:19  * wolfeidauquit (Remote host closed the connection)
21:28:52  * AndreasMadsenquit (Remote host closed the connection)
21:36:39  * AvianFlujoined
21:41:35  <austo>bnoordhius: is uv_sem_t appropriate inside a uv_work_cb?
21:41:36  * c4miloquit (Remote host closed the connection)
21:44:36  * defunctzombiechanged nick to defunctzombie_zz
21:52:13  <bnoordhuis>austo: what would you use it for?
21:52:57  <bnoordhuis>ircretary: tell brson idle handles are entries in a linked list, no fd involved
21:52:57  <ircretary>bnoordhuis: I'll be sure to tell brson
21:53:52  * loladiroquit (Quit: loladiro)
21:54:42  * brsonjoined
21:55:44  <austo>bnoordhius: I have a shared resource that gets created on the first applicable tcp connection. Initialization takes a little while, and I want to make sure that other applicable connections are not allowed to recreate the resource.
21:57:15  * mjr__quit (Quit: mjr__)
21:57:15  <trevnorris>bnoordhuis: in PersistentToLocal, why did you make it "const Persistent"?
21:57:57  * dominictarrjoined
21:58:07  <bnoordhuis>trevnorris: why not?
21:58:54  <bnoordhuis>austo: in that case a semaphore might be appropriate
21:59:35  <bnoordhuis>austo: if you're using uv_queue_work, it shouldn't be for jobs that never finish
21:59:57  <bnoordhuis>you'll tie up a thread indefinitely and the thread pool is only of limited size
22:00:01  <trevnorris>bnoordhuis: I dunno. thought there might be one of those compiler/usage/etc reasons that you're massive knowledge might now about. :)
22:00:34  <bnoordhuis>trevnorris: oh, like that. const > non-const, that's mainly why
22:00:49  <trevnorris>coolio. thanks :)
22:03:59  <austo>bnoordhuis: the job definitely finishes, but in cases where multiple connections happen and I need to initialize the resource only once, I'd like to block the other uv_work_cb's for +/- 100 ms.
22:04:02  <trevnorris>bnoordhuis: i'm testing out instantiation time with ArrayBuffer. bastards have made it really freaking fast.
22:14:46  * rendarquit
22:15:55  <isaacs>bnoordhuis: if you'd rather mmap stays dead, i'll go ahead and unpublish it
22:16:14  <isaacs>bnoordhuis: even though mmapping files is a bad idea, as it is, it's a module that is in the way
22:16:17  <isaacs>bnoordhuis: any objection?
22:18:36  * c4milojoined
22:20:22  * bnoordhuisquit (Ping timeout: 276 seconds)
22:23:37  * austo_joined
22:24:20  * austo_quit (Client Quit)
22:24:53  * austopart
22:25:37  * austo_joined
22:32:50  * austo_quit (Quit: Leaving)
22:34:36  * austojoined
22:36:26  * defunctzombie_zzchanged nick to defunctzombie
22:37:10  * defunctzombiequit (Changing host)
22:37:11  * defunctzombiejoined
22:39:32  <trevnorris>tjfontaine: sorry dude. not moving to ArrayBuffer any time soon :)
22:39:41  <tjfontaine>why is that
22:40:14  <trevnorris>when you pass in external memory it's not automatically free'd on gc, so you still have to make it persistent.
22:40:27  <trevnorris>and if you don't pass in external memory then it's memset 0
22:40:40  <tjfontaine>ya I wasn't expecting anything different there
22:41:28  <tjfontaine>as far as the latter, our implementation could just continue to do the same path and avoid letting v8 alloc that memory
22:42:18  <trevnorris>it's around 15% slower to use external memory
22:42:23  * loladirojoined
22:42:27  <trevnorris>depending on the size, etc.
22:42:44  <tjfontaine>what is slower?
22:42:57  * loladiroquit (Client Quit)
22:42:57  <trevnorris>creating an ArrayBuffer using pre-allocated memory
22:43:12  <tjfontaine>is 15% slower than creating a Buffer?
22:43:16  <trevnorris>yup
22:43:20  <tjfontaine>why?
22:43:55  <trevnorris>hm. i dunno. possibly because of the class instantiation.
22:44:07  <trevnorris>i know they set all properties to getters/setters, so that's not an issue anymore.
22:44:16  <trevnorris>but it does seem to be harder on total mem usage.
22:44:41  <trevnorris>when creating them in for loop, array buffers seem to consume about twice the amount.
22:45:19  * ik_joined
22:45:25  <tjfontaine>make sure you publish the branch for reference, it'd be interesting to profile it
22:45:35  <trevnorris>e.g. while (++i < 1e7) CreateArrayBuffer().
22:46:12  <trevnorris>just made a module since it'd be easier to figure out. i'll throw it into core and publish a branch.
22:46:26  <tjfontaine>which ever is easiest
22:46:33  <tjfontaine>publish it somewhere for comparison :)
22:46:39  <trevnorris>coolio
22:46:53  * defunctzombie_joined
22:47:32  * ikquit (Ping timeout: 240 seconds)
22:47:32  * defunctzombiequit (Ping timeout: 240 seconds)
22:52:16  * piscisaureus_quit (Ping timeout: 268 seconds)
22:55:17  <trevnorris>tjfontaine: https://github.com/trevnorris/node-use-array-buffer
22:55:29  <tjfontaine>trevnorris: excellent thanks!
22:55:41  <trevnorris>np. let me know if you find anything that can be improved.
22:55:48  <trevnorris>i'm interested to see if it can be.
22:59:13  <tjfontaine>heh, SET_RETURN, being JSAPI already :)
22:59:34  <trevnorris>hah, awesome.
22:59:53  <MI6>joyent/node: Shuan Wang v0.10 * 48a4600 : url: Fix edge-case when protocol is non-lowercase - http://git.io/eVWHTw
23:00:00  * defunctzombie_changed nick to defunctzombie_zz
23:00:19  <trevnorris>yeah. i'm creating a set of utils for module creation. maybe I should look at JSAPI for inspiration.
23:00:24  * julianduquequit (Quit: leaving)
23:00:44  * st_lukejoined
23:01:02  <tjfontaine>it sounds like you're basically wanting to help with the work I'm doing :)
23:01:54  <trevnorris>not so much to the point you're doing it. maybe basically a header file that you can drop in to make life easier.
23:02:09  <trevnorris>but not to the extent of what I understand you're undertaking :)
23:04:01  <tjfontaine>hmm this isn't compiling
23:06:30  <trevnorris>tjfontaine: what error you getting?
23:07:11  <tjfontaine>it's angry at functioncallbackinfo,
23:07:21  <tjfontaine>I've hacked it to evil to work here
23:07:25  <trevnorris>tjfontaine: oh, you compiling against latest master?
23:07:44  <tjfontaine>yes
23:07:45  * AvianFluquit (Remote host closed the connection)
23:07:48  * Denmadquit (Ping timeout: 256 seconds)
23:07:58  <trevnorris>hm.
23:08:07  * st_lukequit (Remote host closed the connection)
23:08:15  <tjfontaine>FATAL ERROR: basics::Run() Out of Memory
23:08:16  <tjfontaine>lul
23:08:34  <trevnorris>wtf? oh, I force pushed :P
23:08:35  * jez0990quit (Ping timeout: 264 seconds)
23:08:43  <trevnorris>thought I did it quickly enough. looks like I didn't
23:08:51  <tjfontaine>for what?
23:09:22  <tjfontaine>../basics.cc:10:11: error: 'FunctionCallbackInfo' is already declared in this scope
23:09:27  * AvianFlujoined
23:09:37  <trevnorris>eh? strange. one sec.
23:10:04  <trevnorris>damn you v8! 3.20.6 doesn't compile because they left the fail on warning flag on.
23:10:32  <tjfontaine>CFLAGS="-Wno-error"
23:10:43  <trevnorris>yeah yeah. I know. it's just annoying.
23:12:11  <MI6>nodejs-v0.10: #287 UNSTABLE osx-x64 (1/594) linux-ia32 (1/594) smartos-x64 (2/594) http://jenkins.nodejs.org/job/nodejs-v0.10/287/
23:12:41  <trevnorris>tjfontaine: oh, you using gcc?
23:12:45  <tjfontaine>yes
23:12:56  <trevnorris>ah, let me see if that fails on my box too
23:13:26  <trevnorris>ah, yup
23:13:28  <trevnorris>that's it.
23:14:41  * jez0990joined
23:15:01  * Denmadjoined
23:15:20  <trevnorris>tjfontaine: eh, know what's going on?
23:16:32  <tjfontaine>not particularly, I can tell you how I hacked it to work for me :)
23:16:42  <trevnorris>oh. have a fix. i'm pushing it now
23:16:53  <tjfontaine>I didn't look too much into it
23:18:25  <MI6>nodejs-v0.10-windows: #115 UNSTABLE windows-x64 (7/594) windows-ia32 (8/594) http://jenkins.nodejs.org/job/nodejs-v0.10-windows/115/
23:19:05  * piscisaureus_joined
23:22:54  * julianduquejoined
23:23:17  * paddybyersquit (Ping timeout: 248 seconds)
23:23:28  * pachetquit (Ping timeout: 252 seconds)
23:24:23  <trevnorris>tjfontaine: ok the fix is up. i wish gcc told me where else it was being declared.
23:24:54  <tjfontaine>heh
23:25:28  * sakkakujoined
23:25:55  * sakkakuquit (Remote host closed the connection)
23:27:24  <tjfontaine>your free cb is never firing
23:27:41  <tjfontaine>when I'm gc'ing
23:27:55  <trevnorris>how large a value are you passing in to create?
23:28:26  <tjfontaine>well, I'm seeing hte dispose, but free isn't happening
23:29:05  <tjfontaine>because length is -1
23:32:36  <tjfontaine>I'm getting about 44653 ns/op for native buffers, and 40k for array buffers
23:33:13  <trevnorris>mother effing.
23:33:39  <tjfontaine>there is a leak in there somewhere as well
23:34:17  <tjfontaine>about 10k per 1e3 allocations
23:35:04  <trevnorris>there, fixed.
23:35:31  <tjfontaine>hmm not too much different of an rss growth in that regard for native buffers
23:35:32  <trevnorris>please be more specific then, there's a leak in there.
23:36:34  <tjfontaine>well, rss growth, it's not scientific
23:36:37  <tjfontaine>DEBUG: -1
23:36:38  <tjfontaine>DEBUG: -1
23:36:38  <tjfontaine>DEBUG: -1
23:36:38  <LOUDBOT>NORTH KOREA PUT THOSE TORPEDOES DOWN THOSE ARE NOT FOR NOW
23:36:38  <LOUDBOT>OH MAN ITS THE COOLES SOFTWAREZ EVAR
23:36:38  <LOUDBOT>ACHIEVEMENT UNLOCKED: FALSE GIGGLES
23:36:38  <trevnorris>oh dam
23:36:40  <trevnorris>I know
23:36:41  <trevnorris>yeah
23:36:59  <trevnorris>i was treating it like an object, but have access it differently.
23:39:50  <trevnorris>tjfontaine: ok. fixed and pushed.
23:40:44  <trevnorris>tjfontaine: ok. how many ns/op does it take you to create length 1024?
23:41:18  <tjfontaine>with your default run.js I'm getting 49k to 58k atm
23:41:27  <trevnorris>and with new Buffer()?
23:41:47  <trevnorris>tjfontaine: wait. 49K?
23:42:03  <trevnorris>are you using a pentium 133?
23:42:23  <tjfontaine>sub 30k
23:42:42  <trevnorris>you're talking the first line that has: <NUMBER> ns/op
23:42:47  <tjfontaine>yes
23:42:52  <trevnorris>what machine you using?
23:42:58  <tjfontaine>the jenkins zone
23:42:59  <tjfontaine>zonememstat
23:42:59  <tjfontaine> ZONE RSS CAP NOVER POUT
23:43:00  <tjfontaine>fae04dee-95b3-414b-bb3f-179aa1a08f34 1512MB 8192MB 0 0MB
23:43:17  <trevnorris>i'm running sub 1000 ns/op
23:44:33  <tjfontaine>I could be seeing bursts right nwo
23:45:02  <trevnorris>you have a mac?
23:45:18  <tjfontaine>https://gist.github.com/tjfontaine/5195b4ecabf3ddaf4385
23:45:35  <tjfontaine>I do have a mac, but my intent is to profile with dtrace the allocs to see where time is being spent
23:46:09  <trevnorris>ah, i'll use --ll_prof to do the same on my end.
23:46:25  <tjfontaine>at 1024 I get 4k for arraybuffer and 2k for natives
23:47:24  <trevnorris>yeah. and you'll see worse for 1024 * 4 - 1
23:47:41  <tjfontaine>byte aligning, sure
23:47:47  <trevnorris>no, that's not it.
23:48:06  <trevnorris>that's the limit of allowing v8 to allocate memory, vs using external memory
23:48:32  <trevnorris>really small allocations are actually awesome, but as they get larger they start to suck because of memset.
23:48:38  <trevnorris>one sec, I'll show you.
23:48:46  * brson_joined
23:49:03  * brsonquit (Quit: leaving)
23:49:19  <tjfontaine>that seems fine here
23:49:47  <trevnorris>how do you mean?
23:50:17  <tjfontaine>it didnt' seem appreciably slower
23:50:24  <tjfontaine>at least on smartos
23:50:33  <trevnorris>hm. it's 3x's slower on my machine.
23:51:35  * c4miloquit (Remote host closed the connection)
23:53:25  * mikolalysenkojoined
23:56:08  * julianduquequit (Quit: leaving)
23:59:07  * wolfeidaujoined
23:59:42  * mcavagequit (Remote host closed the connection)