00:03:02  * pastjeanjoined
00:05:15  <tjfontaine>I wonder what's worse, crossing the c++ layer or the regex https://github.com/joyent/node/pull/4102
00:05:53  <tjfontaine>I would imagine the jit handles the regex well
00:06:36  <txdv>libuv does use io completion ports on windows for the fs_*?
00:07:25  * pastjeanquit (Ping timeout: 260 seconds)
00:08:28  <txdv>tjfontaine: why did he merge the other branches into this pl?
00:08:33  <txdv>pr?
00:09:00  <CoverSlide>maybe he snuck a virus in
00:09:20  <txdv>that iws like the most stupid thing you can do
00:09:56  <tjfontaine>txdv: user doesn't understand git mostly
00:12:55  <txdv>someone has to work through all the pull requests
00:13:04  <txdv>100 at libuv, 500 at node
00:14:10  * kazuponjoined
00:16:25  <TooTallNate>txdv: are you volunteering? :p
00:16:38  <tjfontaine>that's what it sounds like to me
00:17:33  <txdv>TooTallNate: yeah
00:17:55  <TooTallNate>why the hell is `util._extend()` prefixed? I wanted to use it...
00:20:28  <txdv>TooTallNate: what now?
00:33:07  <mmalecki>TooTallNate: ryah/Ben wanted it prefixed
00:33:14  <mmalecki>TooTallNate: since that doesn't cover all the cases
00:33:20  <mmalecki>like getters and such
00:40:52  <txdv>and ryah wants ryah gets
00:42:14  <txdv>and what*
00:46:13  <TooTallNate>txdv: well he's actually had a few pull requests turned down but who's counting :p
00:46:23  <TooTallNate>err, not pull requests but feature requests
00:47:43  * lohkeyjoined
00:47:57  * Ariaquit (Remote host closed the connection)
00:48:25  * Ariajoined
00:49:55  * Ariaquit (Read error: Operation timed out)
00:55:01  * DrPizzaquit (Remote host closed the connection)
00:57:03  * DrPizzajoined
01:03:32  * pastjeanjoined
01:03:43  * EhevuTovquit (Quit: This computer has gone to sleep)
01:04:08  * TooTallNatequit (Quit: Computer has gone to sleep.)
01:07:53  * pastjeanquit (Ping timeout: 246 seconds)
01:10:18  * kazuponquit (Remote host closed the connection)
01:18:35  * pastjeanjoined
01:19:57  * kazuponjoined
01:30:33  * kazuponquit (Remote host closed the connection)
01:36:54  * abraxasjoined
01:44:44  <tjfontaine>bnoordhuis: just because you don't see it on profiles now doesn't mean the change should make it :P
01:45:56  <bnoordhuis>tjfontaine: :) the thing is, the current ipv6 address parser is pretty bad
01:46:10  <bnoordhuis>i'm hoping i can nudge him to redo it in pure js so i don't have to
01:46:13  * pastjeanquit (Remote host closed the connection)
01:46:17  <tjfontaine>I don't disagree, I think the whole net.ip thing needs revamping
01:46:28  <tjfontaine>the jit would do a much better job with it in pure js imo
01:46:50  <tjfontaine>there are other places it would be nice to move an ip to/from a buffer as well :)
01:47:02  <tjfontaine>like say a dns implementation
01:51:28  * pastjeanjoined
01:54:24  * c4miloquit (Remote host closed the connection)
01:54:48  * avalanche123|hjoined
01:56:44  * joeandaverdequit (Ping timeout: 246 seconds)
01:56:45  * pastjeanquit (Remote host closed the connection)
01:56:53  * joeandaverdejoined
01:59:21  <bnoordhuis>fedor's tls slab allocator patch at least reduces memory usage somewhat
01:59:45  <bnoordhuis>from a whopping 8.4 GB to 5.7 GB on average
02:00:09  <tjfontaine>those gigs they add up
02:00:28  <bnoordhuis>yeah
02:00:39  <bnoordhuis>i wouldn't have been able to run it to completion on my old pc
02:00:59  <bnoordhuis>okay, i'm off - sleep tight everyone
02:01:54  * ericktjoined
02:03:00  * bnoordhuisquit (Read error: Operation timed out)
02:07:03  * joeandaverdequit (Ping timeout: 252 seconds)
02:08:00  * joeandaverdejoined
02:09:01  * stephankquit (Ping timeout: 256 seconds)
02:14:17  * brsonquit (Quit: leaving)
02:19:36  * avalanche123|hquit (Quit: Computer has gone to sleep.)
02:24:29  * stephankjoined
02:33:07  * stephankquit (Quit: *Poof!*)
02:39:21  * joshthecoderquit (Quit: Leaving...)
02:50:32  * hzquit
02:54:23  * TooTallNatejoined
02:58:41  * TooTallNatequit (Ping timeout: 246 seconds)
03:13:28  * joshthecoderjoined
03:15:45  * indexzeroquit (Quit: indexzero)
03:31:46  * kazuponjoined
03:51:19  * joshthecoderquit (Read error: Connection reset by peer)
03:51:31  * joshthecoderjoined
05:43:54  * paddybyersjoined
06:01:45  * lohkeyquit (Quit: lohkey)
06:05:14  * stagasjoined
06:11:54  * kristatejoined
06:18:56  * loladirojoined
06:33:41  * V1joined
06:34:02  * V1changed nick to `3rdEden
06:34:10  * paddybyersquit (Ping timeout: 260 seconds)
06:42:09  * ericktquit (Quit: erickt)
06:45:57  * paddybyersjoined
07:11:04  * Raltjoined
07:11:46  * stagasquit (Quit: ChatZilla 0.9.89-rdmsoft [XULRunner 1.9.0.17/2009122204])
07:19:00  * stephankjoined
08:03:46  * rendarjoined
09:00:37  * hzjoined
09:43:00  * mmaleckiquit (Ping timeout: 260 seconds)
09:44:03  * joshthecoderquit (Quit: Leaving...)
09:55:27  * loladiroquit (Quit: loladiro)
09:57:10  <indutny>hoya
10:16:28  <txdv>is there no getuid for windows?
10:17:25  * kazuponquit (Remote host closed the connection)
10:26:06  <indutny>where is bert or ben?
10:27:20  <indutny>ircretary: tell bnoorhuis that I've figured out balancing problems. It was due to locking inside openssl
10:27:21  <ircretary>indutny: I'll be sure to tell bnoorhuis
10:27:27  <indutny>arrgh
10:27:34  <indutny>ircretary: tell bnoordhuis that I've figured out balancing problems. It was due to locking inside openssl
10:27:35  <ircretary>indutny: I'll be sure to tell bnoordhuis
10:28:06  <indutny>ircretary: tell bnoordhuis openssl is fucked, it's general locks instead of fine-grained locking (i.e. per structure)
10:28:06  <ircretary>indutny: I'll be sure to tell bnoordhuis
10:28:18  <indutny>ircretary: tell bnoorhuis that I'm going to bundle openssl with tlsnappy
10:28:18  <ircretary>indutny: I'll be sure to tell bnoorhuis
10:28:30  <indutny>ircretary: tell bnoordhuis that I'm going to bundle openssl with tlsnappy
10:28:30  <ircretary>indutny: I'll be sure to tell bnoordhuis
10:39:53  * kazuponjoined
11:37:55  * piscisaureus_joined
11:43:48  <indutny>piscisaureus_: hoya
11:44:02  <indutny>piscisaureus_: how are you doing?
11:48:43  <indutny>ok
11:48:48  <indutny>I'm going to be offline for one more day
11:48:53  <indutny>:D
11:49:28  <piscisaureus_>indutny: ok :-)
11:49:39  <indutny>btw
11:49:46  <indutny>I've found cause of slowness in tlsnappy
11:49:49  <indutny>it was openssl
11:49:54  <piscisaureus_>like, "the" cause?
11:50:02  <indutny>https://github.com/indutny/node/commit/b2bc37740b04ad852bf7e56174a1d65caa14ac96.patch
11:50:02  <piscisaureus_>there was a single cause?
11:50:07  <indutny>nope
11:50:43  <indutny>but it's mostly it
11:50:58  <indutny>the thing is that openssl is using global locks
11:51:08  <indutny>https://github.com/indutny/tlsnappy/commit/ecae86a65134c8ecb51453e79746a7f455c9d741
11:51:16  <piscisaureus_>did it become faster when you changed that?
11:51:24  * `3rdEdenquit
11:51:28  <indutny>I'm running benchmarks
11:51:29  <piscisaureus_>many software use global locks but it often doesn't really matter
11:51:29  <indutny>but yes
11:51:37  <indutny>default mode runs in 2000 req/sec
11:51:50  <indutny>it was doing 1800 req/sec
11:52:01  <piscisaureus_>ok
11:52:07  <piscisaureus_>so significant enough :-)
11:52:11  <indutny>indeed it is
11:53:41  <indutny>going to write blog post describing it
11:53:47  <indutny>and also describing ring buffer that I've created
11:53:53  <indutny>it's really fascinating that it works
11:53:54  <indutny>;D
11:54:09  * kristatequit (Ping timeout: 255 seconds)
11:54:18  <piscisaureus_>indutny: kewl
11:54:31  <indutny>have you seen it?
11:54:35  <piscisaureus_>indutny: i fancy the ring buffer. The BIO_s_mem is too slow
11:54:43  <indutny>indeed
11:54:46  <indutny>you can use mine
11:54:53  <indutny>at least
11:54:55  <indutny>you can try it
11:54:59  <piscisaureus_>yeah
11:55:02  <piscisaureus_>sounds like a plan
11:55:37  * abraxasquit (Remote host closed the connection)
11:55:56  <indutny>just pull bio.c bio.h atomic.h ring.h ring.cc out of tlsnappy
11:55:57  <indutny>and use it
11:57:05  <indutny>piscisaureus_: also
11:57:20  <indutny>piscisaureus_: can you please contribute MSVC stuff for atomic.h? https://github.com/indutny/tlsnappy/blob/master/src/atomic.h
11:58:22  * kristatejoined
11:58:28  <piscisaureus_>ah sure
11:58:30  <piscisaureus_>easy
11:58:32  <piscisaureus_>although
11:58:50  <piscisaureus_>it needs some hacks because of a bug in the SDK that disables intrinsics on x86
11:59:00  <indutny>heh
11:59:00  <piscisaureus_>actually
11:59:35  <piscisaureus_>indutny: http://msdn.microsoft.com/en-us/library/windows/desktop/ms683614%28v=vs.85%29.aspx
11:59:52  <piscisaureus_>indutny: Its so easy that you can probably do it yourself. Don't bother about the hacks yet.
12:02:16  <piscisaureus_>indutny: oh wait do you ever add something more than 1 ?
12:03:20  <indutny>yes
12:03:23  <indutny>I want more than one
12:03:44  <piscisaureus_>indutny: this probably does it: http://msdn.microsoft.com/en-us/library/windows/desktop/ms683597%28v=vs.85%29.aspx
12:03:53  <indutny>man, I'm without internet
12:03:57  <indutny>and windows machine to test it
12:03:59  <indutny>so
12:04:03  <indutny>if you have a minute :)
12:04:08  <indutny>I would be really glad
12:04:08  <piscisaureus_>ah ya
12:04:19  <piscisaureus_>indutny: ok, when i be at the office
12:04:21  <piscisaureus_>indutny: no internet?
12:04:29  <indutny>piscisaureus_: yep
12:04:31  <piscisaureus_>indutny: somehow /me does not believe that ;-)
12:04:34  <indutny>haha
12:04:39  <indutny>well, I'm not at home
12:04:53  <indutny>but i'm going to move to it soon
12:05:04  <indutny>4200req/sec on hybrid
12:05:05  <indutny>yay
12:05:26  <indutny>it was around 3800req/sec
12:16:26  * kristatequit (Remote host closed the connection)
12:17:00  <indutny>piscisaureus_: updated https://github.com/indutny/tlsnappy/blob/master/src/atomic.h
12:20:28  <piscisaureus_>ik
12:20:33  <piscisaureus_>will do it when i get to the office
12:21:10  <indutny>kewl
12:21:11  <indutny>thanks
12:27:17  <indutny>piscisaureus_: btw, added new sheet here
12:27:18  * bnoordhuisjoined
12:27:18  <indutny>https://docs.google.com/spreadsheet/ccc?key=0AhEDnA4M4EKGdDIwb3VYZTd1alA5T1pTVnlQWl9wanc#gid=6
12:27:22  <indutny>patched openssl
12:27:25  <indutny>bnoordhuis: ohai!
12:27:27  <indutny>bnoordhuis: https://docs.google.com/spreadsheet/ccc?key=0AhEDnA4M4EKGdDIwb3VYZTd1alA5T1pTVnlQWl9wanc#gid=6
12:27:33  <indutny>bnoordhuis: patched openssl sheet
12:27:33  <bnoordhuis>indutny: sup
12:27:36  * piscisaureus_quit (Quit: ~ Trillian Astra - www.trillian.im ~)
12:31:43  <indutny>gtg
12:32:30  <bnoordhuis>so nginx is still winning out? :)
12:33:10  <indutny>haha
12:33:10  <indutny>yes
12:33:17  <indutny>openssl is really bad at multithreading
12:33:43  * pastjeanjoined
12:33:52  <indutny>bnoordhuis: have you seen my pull request?
12:33:59  <bnoordhuis>indutny: yes
12:34:26  <indutny>ok
12:34:27  <indutny>kewl
12:35:37  <bnoordhuis>the ex data thing looks okay to me. i've never seen lots of lock contention in openssl though
12:35:58  <indutny>haha
12:36:02  <indutny>you did a lot of multithreaded openssl?
12:36:08  <bnoordhuis>yes
12:36:11  <bnoordhuis>if you have some numbers or profile data, please post them
12:36:12  <indutny>oh
12:36:16  <indutny>yeah, will do
12:36:20  <indutny>once I'll be online again
12:36:21  <indutny>:)
12:36:23  <indutny>ttyl
12:36:27  <bnoordhuis>have fun :)
13:06:19  * kazuponquit (Ping timeout: 252 seconds)
13:24:59  * hnakamurjoined
13:33:33  <txdv>where is pisci
13:38:39  <txdv>bnoordhuis: hey
13:39:18  * mmaleckijoined
13:44:33  * c4milojoined
13:53:13  <bnoordhuis>txdv: ho
13:57:17  <txdv>how is it going? ;>
13:57:36  * loladirojoined
13:59:49  <txdv>bnoordhuis: you work with pisci in the same company, right?
14:00:09  <bnoordhuis>txdv: yes, cloud9
14:03:30  <txdv>he does all the windows stuff on libuv?
14:05:31  <bnoordhuis>and makes coffee
14:05:43  <bnoordhuis>not great coffee, mind you
14:07:13  <txdv>only unix guys know how to make great coffee
14:09:11  <txdv>so he is like the windows counterpart of you, because you always work on libuv unix related stuff
14:09:54  <bnoordhuis>txdv: yes
14:10:20  <bnoordhuis>i sometimes fix windows bugs and he sometimes fixes unix bugs (rare they may be) but i'm mostly the unix guy and he's mostly the windows guy
14:10:51  <bnoordhuis>it's funny, i was initially hired by microsoft to do the windows port of node
14:11:04  <bnoordhuis>but in the end bert and igor did nearly all the windows work
14:11:09  <bnoordhuis>i still got payed though :)
14:11:16  <tjfontaine>that's all that matters
14:11:26  <mmalecki>pisci is bnoordhuis's evil counterpart
14:11:56  * ericktjoined
14:12:13  <mmalecki>bnoordhuis: http://panji.web.id/wp-content/uploads/2011/03/I_did_nothing_today____by_MarioReiv.png eh :) ?
14:12:27  <bnoordhuis>mmalecki: exactly :)
14:15:22  <bnoordhuis>hmm, did i actually write 'payed'?
14:15:25  <txdv>mmalecki: lol
14:15:41  <bnoordhuis>indutny: ping
14:15:44  <mmalecki>bnoordhuis: yes, you did
14:16:38  <mmalecki>gotta pick up my phone from the repair shop, I drunkenly thrown it into a bathtub :/
14:16:46  <tjfontaine>...
14:17:27  <txdv>mmalecki: I am coding a c# wrapper for libuv, mostly on linux/mono, but I check if the code works on windows occasionally, am I good or am I evil?
14:18:05  <mmalecki>txdv: acceptable evil, looking at how popular c# is in Windows community
14:18:44  <txdv>chaotic evil as the rpg guys would call it
14:19:11  <tjfontaine>c# is my favorite strongly typed language
14:19:16  * ericktquit (Quit: erickt)
14:20:36  <txdv>strong typed
14:21:38  <txdv>but you have no csharp repos
14:21:47  <tjfontaine>not on github no
14:22:14  <rendar>txdv: why in c# ?
14:22:35  <txdv>why am I doing a wrapper in C#?
14:22:48  <rendar>yeah
14:23:51  <txdv>why not
14:24:27  <txdv>i have a project where threaded blocking operations are just not an option
14:24:35  <txdv>and I love types
14:24:35  * mmaleckiquit (Ping timeout: 244 seconds)
14:24:43  <rendar>i see
14:24:44  <rendar>:)
14:24:57  <txdv>and I have a embedded c# in a gaming engine for server side scripting, again, blocking is not an option there
14:26:03  <rendar>what game engine is that? your own?
14:26:10  <txdv>no
14:26:20  <txdv>valves goldsrc/source
14:26:38  <rendar>i see
14:29:42  <txdv>and c# has await/async and you can use that to make your asynchronous code (code with callbacks for example) make look like synchronous code
14:29:51  <txdv>it just rewrites everythign into promises
14:29:55  <txdv>and does the execption handling
14:30:44  <txdv>rendar: what programming language background do you have?
14:33:13  * sgallaghjoined
14:34:21  <sgallagh>bnoordhuis: Hey, just wanted to let you know that I ended up swamped this weekend and didn't have any time to work on the bundling separation. At this point I probably won't have time in the next week and a half. I didn't want you to think I'd vanished, though.
14:34:46  <bnoordhuis>sgallagh: oh, no worries. no rush either
14:38:11  <sgallagh>bnoordhuis: Sure, but I've been in open-source long enough that I wouldn't trust me not to be a "Here one day, gone the next" contributor if I didn't pop in occasionally :)
14:38:36  <bnoordhuis>sgallagh: true enough, we get those a lot :)
14:39:40  * piscisaureus_joined
14:40:37  <saghul>hey bnoordhuis how is rm_ev going? should I rebase that uv_run2 thing and add uv_break against your branch or better wait?
14:40:57  <bnoordhuis>saghul: i need to clean up my branch so it's probably best to wait
14:41:06  <bnoordhuis>i want to finish it sometime this week
14:41:18  <saghul>great, thanks! :-)
14:42:06  <rendar>txdv: C/C++
14:43:19  <bnoordhuis>it would be very nice if `make test` could run tests in parallel...
14:44:48  <MI6>joyent/node: Ben Noordhuis master * 0ad0058 : https: fix renegotation attack protection Listen for the 'clientError' e (+3 more commits) - http://git.io/HuU6Dg
14:45:35  <txdv>rendar: why don't you code on node.native?
14:46:50  <rendar>txdv: too much busy, but i'd like maybe in the future :)
14:47:17  <piscisaureus_>indutny: hey
14:48:14  <txdv>piscisaureus_: struct layoyt
14:48:16  <txdv>https://github.com/joyent/libuv/pull/578
14:53:40  <piscisaureus_>indutny: how can I implement these atomic macros on windows if you are so sloppy with data types? :-(
14:54:25  <piscisaureus_>txdv: the patches look good to me
14:54:38  <piscisaureus_>txdv: it scares me somewhat that you come to rely on this so heavily tho...
14:56:16  <bnoordhuis>piscisaureus_: barriers, aye or nay?
14:56:30  <piscisaureus_>bnoordhuis: shrug. I don't care about them so much.
14:56:30  <txdv>piscisaureus_: em, i do not rely on it, i just make it convenient to be used from ffi
14:56:35  <tjfontaine>I think we've discussed this before, but I suppose you don't want to clutter uv with struct accessor methods?
14:56:38  <bnoordhuis>piscisaureus_: i'll take that as an aye
14:57:02  <piscisaureus_>bnoordhuis: do I need to review it?
14:57:17  <bnoordhuis>piscisaureus_: if you care about uv-win compiling
14:57:25  <piscisaureus_>oh, who cares about that :-p
14:57:47  <txdv>in a perfect world libuv would expose only structs which have no size differences between platforms except for 32/64 pointer sizes
14:58:16  <piscisaureus_>txdv: haha. not going to happen
15:00:06  <txdv>yeah, so I am trying to minimize the damage, making it easier for me to access the structs
15:00:44  * pastjeanquit (Remote host closed the connection)
15:00:49  <txdv>or anyonse else who will use ffi to create bindings for libuv
15:01:47  <txdv>i don't understand you perceive as scary, can you elaborate on that?
15:02:01  <MI6>joyent/libuv: Hiroaki Nakamura master * 2684f87 : windows: don't set CRT debug mode on MinGW (+2 more commits) - http://git.io/NHM8FA
15:02:24  <piscisaureus_>bnoordhuis: I don't see the point in adding the entire pthread library to libuv
15:03:46  * travis-cijoined
15:03:46  <travis-ci>[travis-ci] joyent/libuv#786 (master - 2684f87 : Hiroaki Nakamura): The build passed.
15:03:46  <travis-ci>[travis-ci] Change view : https://github.com/joyent/libuv/compare/40134c35377c...2684f876a999
15:03:46  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/libuv/builds/2721521
15:03:46  * travis-cipart
15:05:30  <bnoordhuis>piscisaureus_: i don't disagree. also, i like double negatives
15:06:09  * mraleph1joined
15:06:20  * pastjeanjoined
15:06:24  * mralephquit (Read error: Connection reset by peer)
15:09:40  * kazuponjoined
15:15:36  <piscisaureus_>bnoordhuis: I don't know much about the implementation of barriers but it seems to werk
15:15:38  <piscisaureus_>*work
15:15:42  <piscisaureus_>the tests pass at least
15:16:18  <bnoordhuis>piscisaureus_: barriers are synchronization points, i.e. all line up here before we continue
15:16:38  <bnoordhuis>you can emulate them with semaphores or condition variables
15:16:49  <bnoordhuis>but this is easier of course
15:17:39  <piscisaureus_>ya
15:17:53  <piscisaureus_>I could actually use it for a test im writing
15:19:00  * pastjeanquit (Remote host closed the connection)
15:19:22  <bnoordhuis>piscisaureus_: yeah. i could've used them as well :)
15:19:40  <bnoordhuis>so a belated +1 from me
15:20:01  * c4miloquit (Remote host closed the connection)
15:20:09  * dapjoined
15:21:50  <piscisaureus_>the windows implementation doesn't look too efficient
15:21:53  <piscisaureus_>but shrug
15:22:27  <bnoordhuis>piscisaureus_: i'll let you have the final say in it
15:22:33  <bnoordhuis>must feel nice for a change, right?
15:22:46  <piscisaureus_>haha
15:22:48  <piscisaureus_>no
15:22:53  <piscisaureus_>yeah, land it
15:22:56  <bnoordhuis>okay
15:23:02  <piscisaureus_>I though you were going to fix it up and stuff?
15:23:08  <piscisaureus_>bnoordhuis: you know what would be nice
15:23:15  <bnoordhuis>yes, but that's adding a couple of newlines
15:23:16  <piscisaureus_>bnoordhuis: cross-platform atomic intrinsics
15:23:19  <bnoordhuis>yes
15:23:28  <bnoordhuis>i've been thinking about that for a while now
15:24:02  <bnoordhuis>they'd have to be inline header definitions though, you don't want the overhead of a function call for your atomic swap
15:24:02  <piscisaureus_>bnoordhuis: we could always write a fallback that uses a global lock for really-shitty compilers
15:24:20  <piscisaureus_>bnoordhuis: but gcc and msvc do this stuff just fine
15:24:26  <piscisaureus_>and icc too iirc
15:24:30  <bnoordhuis>and clang
15:25:10  <bnoordhuis>supporting arm and mips would be something of a hassle, but not terribly so
15:25:18  <piscisaureus_>bnoordhuis: maybe we can have uv-atomics.h ?
15:25:29  * loladiroquit (Quit: loladiro)
15:25:36  <bnoordhuis>uv-atomic-ops.h
15:25:42  <bnoordhuis>just because i like being contrarian
15:29:20  * tommybergeronjoined
15:30:32  * c4milojoined
15:31:18  * felixgejoined
15:32:25  <MI6>joyent/libuv: Hiroaki Nakamura master * acea302 : unix, windows: add thread barrier support - http://git.io/OSGvww
15:32:58  * tomshredsquit (Ping timeout: 245 seconds)
15:34:18  * travis-cijoined
15:34:18  <travis-ci>[travis-ci] joyent/libuv#787 (master - acea302 : Hiroaki Nakamura): The build passed.
15:34:18  <travis-ci>[travis-ci] Change view : https://github.com/joyent/libuv/compare/2684f876a999...acea3028c53c
15:34:18  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/libuv/builds/2721934
15:34:18  * travis-cipart
15:34:37  <bnoordhuis>i like how chromium's task manager window has a 'stats for nerds' link
15:35:47  * piscisaureusjoined
15:37:01  * loladirojoined
15:39:03  * loladiroquit (Client Quit)
15:44:47  <felixge>ircretary: seen TooTallNate
15:44:47  <ircretary>felixge: I'm not sure what to do with that command. Ask for help in PM.
15:45:24  <tjfontaine>little more than 12 hours ago in here
15:45:28  <piscisaureus_>ircretary: when TooTallNate
15:45:28  <ircretary>piscisaureus_: tootallnate was last seen at 2012-10-09T02:53:23.160Z, joining #nodejitsu
15:45:33  <piscisaureus_>^-- felixge
15:47:12  * kazuponquit (Remote host closed the connection)
15:47:57  * mmaleckijoined
15:48:10  <mmalecki>so I need a new phone...
15:50:03  * pastjeanjoined
15:51:51  * tommybergeronquit (Quit: Linkinus - http://linkinus.com)
15:54:39  * pastjeanquit (Ping timeout: 256 seconds)
15:54:57  * TooTallNatejoined
15:55:12  <TooTallNate>felixge: can't reply cause you don't follow back :p
15:55:38  <felixge>TooTallNate: dafuq!? I swear this is the second time I'm re-following you
15:55:47  <felixge>twitter does not like our connection
15:55:49  <felixge>anyway
15:55:53  <felixge>fixed
15:55:54  <TooTallNate>hahah, ya weird, damn twitter
15:56:19  <felixge>TooTallNate: so I'm trying to get node to run on the AR Drone
15:56:24  <felixge>following your tutorial
15:56:29  <TooTallNate>felixge: nice :)
15:56:32  <felixge>I was able to get v8 running with another tutorial when building under linux
15:56:47  <felixge>but it seems like your approach will work from OSX as well if i have the toolchain setup?
15:56:52  <TooTallNate>felixge: i was gonna write a blog post about getting a toolchain setup on OSX
15:56:56  <TooTallNate>i did end up figuring it out
15:56:57  <TooTallNate>somehow
15:56:59  <TooTallNate>haha
15:57:13  <felixge>TooTallNate: I see, but it's not easy?
15:57:29  <TooTallNate>felixge: there's just some quirks along the way I guess… in a nutshell, crosstool-ng is your friend
15:57:47  <TooTallNate>felixge: there's a file in the crosstool-ng repo about using it on OSX, that was helpful
15:57:56  <TooTallNate>felixge: and after that I mostly followed http://www.bootc.net/archives/2012/05/26/how-to-build-a-cross-compiler-for-your-raspberry-pi/
15:58:24  * tomshredsjoined
15:58:26  <felixge>TooTallNate: ok, I already have a toolchain working in a Linux VM, your approach should work for this as well right?
15:58:33  <felixge>(will try the osx thing later, seems like more work : )
15:58:44  <tjfontaine>one day this wont' be such a hassle http://clang.llvm.org/UniversalDriver.html
15:58:48  <TooTallNate>felixge: yes, should work just the same
15:58:50  * pastjeanjoined
15:59:45  <felixge>ok
16:00:00  * kazuponjoined
16:00:25  <TooTallNate>felixge: I have v0.8.9 precompiled here if you wanna try that too https://github.com/TooTallNate/node/downloads
16:00:35  <TooTallNate>it's for armv6 vfp2 though
16:00:46  <TooTallNate>what's the AR Drone running?
16:01:02  <TooTallNate>tjfontaine: that's pretty sweet
16:05:37  <txdv>piscisaureus_: are you going to merge it?
16:08:37  <piscisaureus_>txdv: it was a;ready
16:09:14  <isaacs>wow, people really want crypto to use buffers instead of binary strings.
16:09:23  <piscisaureus_>yay
16:09:24  <isaacs>i'm going to go for it.
16:09:29  * felixgequit (Remote host closed the connection)
16:09:36  <isaacs>with the stream interface changes there.
16:09:42  * felixgejoined
16:10:58  <txdv>a ok
16:11:00  * TheJHjoined
16:13:23  <isaacs>that also makes the crypto stream changes a lot easier, because i ddon't have to special-case a bunch of stuff.
16:13:30  <felixge>TooTallNate: I think it's a ARM Cortex A8
16:13:40  <felixge>TooTallNate: yeah, seems like your binary doesn't work
16:14:02  <TooTallNate>felixge: ok
16:14:11  <tjfontaine>TooTallNate: ya that's in lieu of what you have to do now `clang++ -ccc-gcc-name arm-none-linux-gnueabi-g++ -ccc-host-triple
16:14:14  <tjfontaine>thumbv7m-none-gnueabi sourceCode.cpp -c -mcpu=cortex-m3 -mthumb`
16:15:01  <TooTallNate>woah
16:15:05  <tjfontaine>but with llvm/clang working on their own assemblers and linkers there's little need to worry about full chains
16:15:49  <felixge>running into stupid build errors
16:15:50  <felixge>https://gist.github.com/3859807
16:15:52  <felixge>^--- any ideas?
16:16:11  <felixge>seems like http parser does not use the CPPFLAGS I'm setting?
16:17:44  * TheJHquit (Ping timeout: 244 seconds)
16:19:05  <TooTallNate>felixge: might be a gyp bug; use CFLAGS and CXXFLAGS instead
16:20:24  <felixge>that does give me a new error :)
16:20:25  <felixge>https://gist.github.com/3859807
16:22:10  <TooTallNate>felixge: what is USR_DIR?
16:22:19  <TooTallNate>felixge: your cross-compiler is just "g++"?
16:22:36  <tjfontaine>TooTallNate: he mucks with path though
16:22:42  * mmaleckiquit (Ping timeout: 264 seconds)
16:22:53  <felixge>USR_DIR is just a path I found with the include / lib files in my toolchain install
16:23:02  <felixge>I include my toolchain bin folder in my $PATH
16:23:02  <TooTallNate>oh i see
16:23:11  <felixge>so g++ is found in there
16:23:35  <tjfontaine>it does feel like the compiler should be able to find stddef.h without providing a hint to it though
16:24:40  <TooTallNate>bnoordhuis: ^ you make anything of those build errors?
16:25:23  <felixge>(if I get this to work, I'll make a vagrant script and put it on github)
16:26:52  * mikealjoined
16:27:01  <TooTallNate>felixge: i mean i guess i'm skeptical about which "gcc" is being used
16:27:29  <felixge>when I run `which gcc` I get: /vagrant/deps/sourcery/arm-2009q1/arm-none-linux-gnueabi/bin/gcc
16:27:30  * brsonjoined
16:27:39  <felixge>(that is when I put it after the exports inside my script)
16:28:15  <tjfontaine>always possible that gyp is trying to be smarter than you
16:29:01  <txdv>can someone write that
16:29:05  <txdv>can someone write "that"
16:29:37  <tjfontaine>"that" or that? and what?
16:31:17  * Raltquit (Ping timeout: 245 seconds)
16:31:30  <felixge>ok, will give it up for today
16:31:35  <felixge>but will continue tomorrow
16:31:44  <felixge>once we have node on these drones we can build a node.js firmware
16:31:45  <felixge>muhahah
16:32:13  <TooTallNate>felixge: are you able to compile simple programs? it says it can't find stddef.h
16:32:18  <TooTallNate> /vagrant/deps/sourcery/arm-2009q1/arm-none-linux-gnueabi/libc/usr/include/sys/types.h:147:20: warning: stddef.h: No such file or directory
16:32:27  <txdv>tjfontaine: thanks
16:32:35  <felixge>Side benefit: We'll automatically have a drone visualizing v8 garbage collection *g*
16:32:53  <felixge>TooTallNate: have not tried
16:32:54  <felixge>let me try
16:34:39  * mikealquit (Quit: Leaving.)
16:35:01  * mikealjoined
16:35:11  <felixge>ohhh maybe I just did sth stupid
16:35:16  <felixge>I think I got it compiling now
16:35:31  <felixge>TooTallNate: thx - I think I was pointing my stuff to the wrong dir
16:35:39  <tjfontaine>that'd do it
16:35:43  <felixge>compiling now
16:35:51  <TooTallNate>:)
16:36:03  <felixge>(I mean that dir had toolchain binaries, but I guess they have multiple copies in there to confuse noobs like me)
16:36:46  <felixge>anyway, if GC will become an issue for the nodecopter-firmware, I think I'll try low level js
16:37:21  <tjfontaine>I thought for a moment I thought you meant your drone would hover if gc were running in some other app
16:37:57  <TooTallNate>felixge: ya the memory would be the only thing I'd worry about, only like 20mb right?
16:38:04  <felixge>TooTallNate: 125 MB
16:38:07  <felixge>1 Ghz
16:38:11  <TooTallNate>oh wow
16:38:11  <felixge>this thing is a beast
16:38:13  <felixge>:)
16:38:22  <felixge>so I think writing a node.js firmware is kinda doable
16:38:27  <TooTallNate>well my pi has 200mb and i haven't run into any problems, so it should be good :)
16:39:29  <TooTallNate>felixge: btw, have you figured out a good way to telnet into the drone over usb?
16:39:40  <TooTallNate>or how do you do it?
16:39:44  <felixge>TooTallNate: nope, but haven't tried it yet
16:39:49  <felixge>I generally connect to the drone via wifi
16:39:55  <felixge>and use my iPhone tethering for internet meanwhile
16:40:02  <felixge>so I can be online while connected to a drone
16:40:10  <TooTallNate>nice
16:40:16  <felixge> /vagrant/deps/sourcery/arm-2009q1/bin/arm-none-linux-gnueabi-ld: bad -rpath option
16:40:18  <felixge>nooo :(
16:40:21  <felixge>wtf is that : )
16:40:34  <TooTallNate>we can probably remove that
16:40:38  <TooTallNate>one sec
16:40:42  <tjfontaine>heh rpath is a way of specifying where a library should be located, iirc
16:41:08  <felixge>https://gist.github.com/3859807
16:41:09  <felixge>^---
16:42:30  * pastjeanquit (Remote host closed the connection)
16:42:44  <felixge>found this in the irc logs: 11:28 < erwin_> May I have some advice on the following issue? I have tried building node v0.8.9 on openembedded for the Beaglebone target (ARM cortex A8 proc), and it failed at the compile phase (arm-angstrom-linux-gnueabi-ld: bad -rpath option). However, I could correctly build node v0.8.8.
16:43:03  * pastjeanjoined
16:43:05  <felixge>http://piscisaureus.no.de/node.js/2012-09-13#11:28:33.729
16:43:50  <TooTallNate>haha, nice
16:43:53  <tjfontaine>I think gyp upgraded in that rev
16:44:39  <TooTallNate>felixge: i don't even see -rpath in the ld command
16:44:47  <TooTallNate>felixge: what's the verbose output? make V=1
16:44:57  <felixge>me neither
16:45:02  <felixge>coming right up
16:45:11  <TooTallNate>felixge: oh no nvm, that is verbose
16:45:16  <TooTallNate>it's default now
16:45:19  <TooTallNate>weird though
16:45:46  <felixge>TooTallNate: https://gist.github.com/3859807
16:45:50  <felixge>k
16:47:50  * pastjeanquit (Ping timeout: 260 seconds)
16:48:03  <tjfontaine>I bet it's related to rdynamic
16:48:33  <felixge>I can try an older node version
16:48:47  <TooTallNate>tjfontaine: ya me too
16:49:04  <felixge>trying 0.8.8 now
16:49:17  <tjfontaine>https://github.com/joyent/node/commit/5a5e128165e85e15843f21d4ca01c8765323b030
16:49:20  <felixge>tjfontaine / TooTallNate : so how does one fix that?
16:49:41  <felixge>ah ok, so reverting this may be needed?
16:50:00  <tjfontaine>well you can try just removing rdynamic from common.gypi
16:50:07  <TooTallNate>felixge: try applying https://gist.github.com/88ad7dcd21e3750f12fb
16:50:17  <TooTallNate>basically what tjfontaine said :p
16:50:38  * mikealquit (Quit: Leaving.)
16:51:31  * mikealjoined
16:51:43  <felixge>ok … rebuilding!
16:51:57  <TooTallNate>felixge: ya, you'll have to run ./configure agaon
16:51:58  <felixge>with these things … I generally have to make clean/distclean, right?
16:52:04  <felixge>yeah, doing that
16:52:07  <tjfontaine>clean should suffice
16:52:12  <TooTallNate>felixge: clean/distclean might be overkill
16:52:20  <TooTallNate>but definitely safe
16:52:22  <felixge>*g*
16:52:26  <tjfontaine>but gyp should do the right thing when it sees the flag change
16:52:32  <felixge>build systems are black magic
16:52:33  <tjfontaine>gyp/make
16:52:34  <felixge>:)
16:52:39  <felixge>to me at least
16:52:45  <felixge>anyway, did a clean/distclean/configure
16:52:46  <felixge>so lets see
16:52:58  <tjfontaine>dear dtrace/jstack why have you stopped giving me symbols
16:54:35  <tjfontaine>oh
16:56:11  * mjr_joined
16:57:12  <felixge>yeah
16:57:13  <felixge>new error
16:57:14  <felixge>https://gist.github.com/3859807
16:57:19  <felixge>TooTallNate / tjfontaine : Any ideas?
16:57:54  <TooTallNate>felixge: OH OH OH
16:57:59  * loladirojoined
16:58:08  <TooTallNate>felixge: why is it running ld? that should be g++
16:58:17  * loladiroquit (Client Quit)
16:58:18  <TooTallNate>these are flags that only g++ understands
16:58:29  <TooTallNate>felixge: i think remove your LD export
16:58:33  <tjfontaine>yes in that case, maybe because LD...
16:58:40  <tjfontaine>TooTallNate too quick this time :)
16:59:05  <felixge>ok
16:59:06  <felixge>re-configure?
16:59:10  <TooTallNate>felixge: no
17:00:22  <felixge>seems like it still uses arm-none-linux-gnueabi-ld even when removing the LD export
17:00:25  <felixge>same error
17:00:49  * xaqjoined
17:00:57  <felixge>oh
17:00:58  <felixge>my LINK
17:01:11  <felixge>nvm
17:01:13  <felixge>that seems correct
17:02:27  <felixge>had to run configure again
17:02:29  <tjfontaine>did you do the reconfigure? I would have expected gyp to pick that up and enforce it
17:02:39  <TooTallNate>felixge: ok
17:02:43  <TooTallNate>my bad :p
17:04:07  <felixge>FUCK YEAH
17:04:10  <felixge>GOT NODE RUNNING
17:04:12  <felixge>ON MY DRONE
17:04:14  <tjfontaine>heh
17:04:15  * xaq_joined
17:04:18  * xaqquit (Read error: Connection reset by peer)
17:04:27  <felixge>TooTallNate / tjfontaine : Thank you so much!
17:04:38  <TooTallNate>felixge: YAAYYY!!!
17:04:43  <felixge>I'll make this an automated process and put it on github as a vagrant thingie
17:04:48  <felixge>so people can build node for their drones
17:04:49  <TooTallNate>felixge: I expect some sweetness coming from that!
17:05:05  <tjfontaine>felixge: can you retry with rdynamic added but no ld set?
17:05:10  <TooTallNate>felixge: binaries work well for a targeted platform like that too :p
17:05:26  <TooTallNate>felixge: ya, you want -rdynamic otherwise native addons won't work
17:06:47  <felixge>my drone is running a webserver!
17:06:48  <felixge>whooout
17:07:10  <felixge>TooTallNate: I'll retry when I automate this tomorrow
17:07:13  <felixge>will let you know
17:07:16  <felixge>and do a writeup
17:07:35  <TooTallNate>felixge: cool, and you should be able to add ssl support, was there an error?
17:07:45  <TooTallNate>felixge: otherwise npm doesn't work i think
17:08:17  <felixge>tjfontaine: what's your twitter?
17:08:33  * brsonquit (Ping timeout: 248 seconds)
17:08:46  <felixge>TooTallNate: just disabled it to mimize chances of problems due to that
17:08:50  <felixge>let me rebuild with ssl
17:09:35  * loladirojoined
17:09:42  <ryah>i am happy with this "libuv" library you people have made.
17:09:57  <ryah>very useful
17:10:37  * brsonjoined
17:13:08  * mmaleckijoined
17:13:13  * mikealquit (Quit: Leaving.)
17:15:14  <felixge>ok, now I deserve food. going out to buy some …
17:15:28  <felixge>TooTallNate: I guess I'll just try this other stuff right now and put it all on github
17:15:46  <felixge>procrastinating a little longer on actual work sounds more fun
17:15:49  <felixge>will do so when back
17:15:51  * mikealjoined
17:16:48  * mikealquit (Client Quit)
17:17:04  * felixgequit (Read error: Connection reset by peer)
17:17:38  * felixgejoined
17:17:38  * felixgequit (Changing host)
17:17:38  * felixgejoined
17:25:03  * jmar777joined
17:27:29  * othiym23joined
17:28:09  <isaacs>ryah: thanks, that's nice to hear :)
17:28:37  <isaacs>ryah: you write a go binding yet?
17:28:40  <isaacs>;P
17:30:17  <piscisaureus_>bbl
17:30:57  * piscisaureusquit (Quit: Lost terminal)
17:31:38  * joshthecoderjoined
17:34:06  <ryah>?
17:34:16  <ryah>go binding.. psh
17:34:22  <ryah>go has this all figured out already
17:34:39  * Raltjoined
17:35:26  * piscisaureus_quit (Ping timeout: 246 seconds)
17:36:27  <isaacs>haha, i know, i'm just joking.
17:37:16  <isaacs>ryah: any programming language created after 2000 is a hippie language.
17:37:22  <isaacs>aka "new fangled"
17:37:30  * isaacswaves cane at go, coffee-script, and dart
17:38:43  * txdvquit (Quit: leaving)
17:38:59  * txdvjoined
17:43:12  * loladiroquit (Quit: loladiro)
17:43:52  <tjfontaine>felixge: tjfontaine
17:44:14  * felixgequit (Read error: Connection reset by peer)
17:44:35  * felixgejoined
17:44:36  * felixgequit (Changing host)
17:44:36  * felixgejoined
17:45:31  * Raltquit (Remote host closed the connection)
17:47:39  * perezdjoined
17:49:35  * tomshredsquit (Quit: Linkinus - http://linkinus.com)
17:49:41  * Raltjoined
17:55:29  * kazuponquit (Remote host closed the connection)
17:55:48  * perezdquit (Read error: Connection reset by peer)
17:55:54  * loladirojoined
17:56:24  * perezdjoined
18:02:36  * Raltquit (Remote host closed the connection)
18:02:54  * perezdquit (Ping timeout: 264 seconds)
18:06:40  * Raltjoined
18:08:06  * lohkeyjoined
18:11:48  * TooTallNatequit (Quit: ["Textual IRC Client: www.textualapp.com"])
18:12:46  * EhevuTovjoined
18:12:58  * Raltquit (Remote host closed the connection)
18:15:04  * perezdjoined
18:15:24  * V1joined
18:15:48  * V1changed nick to `3rdEden
18:19:59  * xaq_quit (Remote host closed the connection)
18:20:05  * txdvquit (Quit: leaving)
18:20:59  * txdvjoined
18:21:14  * perezdquit (Read error: Connection reset by peer)
18:22:08  * perezdjoined
18:31:29  * `3rdEdenquit (Remote host closed the connection)
18:33:27  * loladiroquit (Quit: loladiro)
18:44:27  * felixgequit (Read error: Connection reset by peer)
18:45:57  * V1joined
18:46:26  * V1changed nick to `3rdEden
18:49:56  * felixgejoined
18:49:56  * felixgequit (Changing host)
18:49:57  * felixgejoined
18:55:48  * Raltjoined
18:59:40  * Raltquit (Remote host closed the connection)
18:59:56  * TooTallNatejoined
19:05:52  * kazuponjoined
19:10:25  * kazuponquit (Ping timeout: 252 seconds)
19:19:00  * c4miloquit (Remote host closed the connection)
19:25:52  * TheJHjoined
19:40:31  * `3rdEdenquit (Remote host closed the connection)
19:43:34  * c4milojoined
19:49:40  * piscisaureus_joined
19:52:30  * lohkeyquit (Quit: lohkey)
19:55:10  <piscisaureus_>txdv: although I have nothing agains uv_listen_stop, you don't really need it either.
19:55:33  <piscisaureus_>txdv: you can just not call uv_accept and call it some time later, when it suits you
19:56:15  * EhevuTov_joined
19:59:13  * EhevuTovquit (Ping timeout: 246 seconds)
20:03:36  <txdv>bnoordhuis: said that if you don't call it in the callback, it dfoesnt work anymore
20:03:42  <txdv>but ill try that
20:03:47  <txdv>to check
20:04:24  <txdv>piscisaureus_: you are the windows guy on cloud9, do you code or have you coded with c#?
20:05:07  <piscisaureus_>txdv: bnoordhuis is right or wrong, dependent on what he means
20:05:24  <piscisaureus_>txdv: if you don't uv_accept you won't get another connection callback until you do
20:05:51  <txdv>hm sounds good to me
20:06:34  * loladirojoined
20:09:47  * piscisaureus_quit (Ping timeout: 246 seconds)
20:09:48  * EhevuTov_quit (Quit: Leaving)
20:10:17  * piscisaureus_joined
20:10:49  <piscisaureus_>wtf was aapl thinking when they decided to put the power button just above the delete button :-(
20:10:50  <piscisaureus_>anyway
20:11:06  <piscisaureus_>txdv: my only c# experience was XNA a couple of years ago.
20:14:53  * `3rdEdenjoined
20:17:35  <isaacs>you guys want a 0.8.12 release this week?
20:17:46  <isaacs>bnoordhuis, piscisaureus_, TooTallNate, ryah?
20:18:01  <isaacs>there's not much to it.
20:18:12  <txdv>we want features
20:18:13  <txdv>not numbers
20:18:51  <TooTallNate>isaacs: i'm not anxious for any new fixes to be released personally
20:18:56  * loladiroquit (Quit: loladiro)
20:19:11  <TooTallNate>txdv: features come in unstable releases, v0.8.x is bug fixes
20:19:27  <piscisaureus_>isaacs: it's mostly doc fixes I think
20:19:41  <piscisaureus_>isaacs: maybe some repl stuff by TooTallNate
20:19:47  <txdv>SyncAsync
20:19:50  <txdv>Great.
20:23:01  * pastjeanjoined
20:24:12  * paddybyersquit (Ping timeout: 260 seconds)
20:26:17  * loladirojoined
20:35:54  * stagasjoined
20:37:46  <TooTallNate>isaacs: there's no write() callback anymore with the new streams?
20:39:11  * jmar777quit (Remote host closed the connection)
20:49:02  <piscisaureus_>there should be
20:49:04  <piscisaureus_>isaacs: ^
20:55:51  * `3rdEdenquit (Remote host closed the connection)
20:57:56  * sgallagh1joined
20:58:05  * sgallaghquit (Remote host closed the connection)
21:01:07  <isaacs>there is on _write()
21:01:08  * sgallagh1quit (Remote host closed the connection)
21:01:19  <isaacs>we could make the cb optional on write() as well
21:01:38  <isaacs>it's a bit more of a pita, though
21:02:02  <isaacs>but doable.
21:02:22  <isaacs>i guess it's useful.
21:05:12  <isaacs>piscisaureus_, TooTallNate: so, it's write(chunk,[encoding],callback)
21:05:34  <isaacs>piscisaureus_, TooTallNate: if there's an error, should the callback be called with the error? or just emit?
21:05:58  * lohkeyjoined
21:05:59  <piscisaureus_>isaacs: well, ehm, we have to retain compatibility
21:06:28  <piscisaureus_>isaacs: if I were to do it all over, I'd say definitely
21:06:35  <TooTallNate>isaacs: ya i've never used it personally, but i feel like people fought pretty hard a while back for write() callbacks
21:06:51  <TooTallNate>isaacs: if there's no callback then emit "error"
21:07:20  <TooTallNate>isaacs: and if it's part of the base class and consistent for all write streams then that would be really nice
21:08:03  <isaacs>yeah, whatever we do will definitely be 100% consistent here.
21:08:12  <isaacs>it's actually easier at this point to make it consistent than not.
21:08:36  <isaacs>here's the problem with a write() callback:
21:08:45  <isaacs>either it returns true, in which case, the cb should fire *right now*
21:08:55  <isaacs>or it returns false, and the cb fires on drain
21:09:13  <isaacs>and we have a situation where a callback-taking function can call the callback either immediately or not-immediately.
21:09:19  <isaacs>that ambiguity is very dangerous.
21:09:38  <isaacs>for internal functions, it's merely annoying.
21:09:48  <isaacs>but for exposed api functions, it's actively harmful and dangerous.
21:10:28  <isaacs>so, the write buffer has to stash the callback with the chunk in an array, and when the chunk is finished, check to see if it's still the same tick, and if it is, then call the callback on the next tick
21:11:39  <TooTallNate>isaacs: do zlib streams ever return true on write?
21:11:59  <TooTallNate>i mean, they always need to go to the backend layer right, and that happens on the thread pool?
21:12:18  <TooTallNate>so unless i'm missing something those are always async
21:13:02  * `3rdEdenjoined
21:13:37  <isaacs>TooTallNate: oh, well, there's also this high/low water mark concept
21:13:45  <isaacs>so streams return true even when they haven't actually flushed the bits.
21:14:14  <TooTallNate>right, right
21:14:20  <isaacs>but crypto streams don't actually do their work in the thread pool (which is a bit wrong, since crypto is so much more expensive than compression)
21:14:56  <piscisaureus_>isaacs: no
21:15:09  <piscisaureus_>isaacs: just make the write callback when libuv does it
21:15:14  * V1joined
21:15:34  <isaacs>piscisaureus_: but some streams don't go to libuv
21:15:42  <isaacs>and the Writable class has to be generic.
21:16:01  <piscisaureus_>well...
21:16:14  <isaacs>ie, even if _write=function(c,cb) { buffer.push(c); cb() }
21:16:15  <piscisaureus_>it's the wrong abstraction then, I'm afrwaid
21:16:17  <isaacs>it still has to not break.
21:16:38  * V1changed nick to `3rdEden_
21:16:38  <piscisaureus_>isaacs: process.nextTick(cb) ?
21:16:42  <isaacs>yeah
21:16:47  <piscisaureus_>isaacs: the cb can never be on the same tich
21:16:49  <piscisaureus_>*tick
21:16:49  <isaacs>ok, so, i can make this work.
21:16:50  <TooTallNate>isaacs: i would think the callback should be called when _write()'s cb() is called with the given chunk
21:17:02  <isaacs>TooTallNate: or on nextTick, whichever is sooner.
21:17:05  <isaacs>that's easy to do.
21:17:37  <isaacs>var sync = true; this._write(chunk, writeCb); sync = false; function writeCb() { if (sync) process.nextTick(cb); else cb();
21:17:40  <isaacs>something like that
21:17:49  <TooTallNate>yup
21:17:53  <piscisaureus_>isaacs: nah, I don't like that for libuv streams
21:17:55  * `3rdEdenquit (Ping timeout: 260 seconds)
21:17:56  <isaacs>i have to do that in the Readable _read function anyway
21:18:18  <piscisaureus_>isaacs: you end up making the write callback before you can even tell whether it worked or not
21:18:34  <isaacs>piscisaureus_: nu uh
21:18:40  <isaacs>piscisaureus_: the callback is called in the writeCb function
21:18:46  <isaacs>piscisaureus_: which is the actual callback passed to libuv
21:18:50  <piscisaureus_>aha i see
21:18:58  <piscisaureus_>oh wait the sync trick is to defer to the next tick
21:19:02  <isaacs>but we set a sync flag while calling, so we can tell in writecb if we're in teh same tick
21:19:09  <isaacs>right
21:19:16  <piscisaureus_>isaacs: well, libuv will never make a callback like that
21:19:18  <isaacs>s/sync/sameTick/
21:19:25  <isaacs>piscisaureus_: right, but synthetic streams do all the time.
21:19:34  <isaacs>and crypto streams HAVE to in order to keep backwareds compability
21:19:39  <isaacs>compatibility
21:19:47  <piscisaureus_>ah
21:19:55  <piscisaureus_>I consider this a bug btw :-)
21:19:57  <isaacs>ok
21:20:01  <piscisaureus_>callbacks can never be sync
21:20:33  <piscisaureus_>isaacs: but maybe it's good to plaster over third-party synthetic streams that do it
21:20:38  <isaacs>well, we're using the Stream interface classes to make callbacks universally not-sync in the exposed api
21:20:40  * TheJHquit (Ping timeout: 260 seconds)
21:20:45  <piscisaureus_>ya
21:20:53  <isaacs>piscisaureus_: .pipe(), .read(), .write() etc are all consistent.
21:21:03  <isaacs>even if your synthetic stream does synchronous stuff.
21:21:30  <isaacs>but it means you can get hashes like: hash.write('foo'); hash.end(); sha = hash.read()
21:21:37  <isaacs>all in teh same tick
21:22:00  <piscisaureus_>yeah
21:22:22  <isaacs>which is actually kind of nice.
21:22:24  <piscisaureus_>I don't see any callbacks happening in that snippet btw ;-)
21:22:28  <piscisaureus_>btw
21:22:32  <piscisaureus_>FINALLY
21:22:36  <isaacs>well, no, the callbacks are all internal there :)
21:22:55  <isaacs>the Transform class is the liberal utopian in this equation.
21:23:29  <isaacs>and Readable allows _read(n,cb) to call immediately/synchronously. i guess it makes sensse for _write(chunk,cb) to do the same.
21:23:31  <piscisaureus_>isaacs: btw - that won't work for zlib btw
21:23:37  <isaacs>piscisaureus_: it does work for zlib.
21:23:42  <piscisaureus_>isaacs: zlib is off-thread I thought?
21:23:43  <isaacs>oh, the immediate read.
21:23:44  <isaacs>no, it won't
21:23:45  <piscisaureus_>ya
21:23:49  <isaacs>you have to actually wati.
21:23:59  <isaacs>that first read() will return null, then you wait for a 'readable' event, etc.
21:24:06  <piscisaureus_>y
21:24:10  <isaacs>but zlib is also a bit more weird.
21:24:17  <isaacs>since the writes and reads are assymmetric
21:24:26  <piscisaureus_>yes
21:24:30  <isaacs>one write might lead to many chunks coming out, or vice versa.
21:24:55  <isaacs>Cipher streams are relatively symmetric, and hash streams are so assymetric that they sort of don't even matter.
21:24:58  <piscisaureus_>zlib being threaded is rather questionable :-)
21:25:25  <isaacs>we can talk about it post-0.10
21:25:31  <piscisaureus_>agreed
21:26:03  <isaacs>with the new stream api, even if we make zlib sync, it'll still never actually trigger a zlib call until you read() from it.
21:26:09  <isaacs>well, the first one will go
21:26:25  <isaacs>but it won't keep a very big read buffer.
21:26:26  * rendarquit
21:26:35  <isaacs>so you dont' have to worry about it blowing up
21:26:46  * hzquit
21:27:35  <piscisaureus_>umm, right, I haven't looked at the zlib bindings close enough to have something meaningful to say about that
21:27:49  <isaacs>piscisaureus_: so, for streams where we *don't* want to pre-buffer-ize the chunks
21:28:01  <isaacs>piscisaureus_: ie, tcp, and i guess soon tls
21:28:18  <piscisaureus_>yes?
21:28:33  <isaacs>piscisaureus_: i'm thinking of having an option to say decodeStrings=false, and then _write(chunk,cb) gets chunk=['foo', 'utf8'] or something
21:29:03  <isaacs>piscisaureus_: and if you opt into that option, then your _write function needs to expect a [string,encoding] as the first arg
21:29:04  <piscisaureus_>isaacs: _writeString
21:29:05  <piscisaureus_>?
21:29:11  <isaacs>piscisaureus_: hmm...
21:29:37  <piscisaureus_>isaacs: you should be aware that tcp only supports utf8/ascii/ucs2 natively
21:29:51  <piscisaureus_>isaacs: e.g. base64 still needs pre-bufferization
21:29:55  <isaacs>so, if the flag is set, and it's a string, i call _writeString(string,encoding,cb)?
21:30:00  <piscisaureus_>ya
21:30:05  <isaacs>piscisaureus_: sure, but you can do that in the implementation function.
21:30:15  <piscisaureus_>yeah, but it's ugly :-)
21:30:26  <isaacs>piscisaureus_: basically, it's just a way to say, "Please do not turn strings into buffers ahead of time. I got that."
21:30:27  <piscisaureus_>whatever
21:31:07  <piscisaureus_>isaacs: I mean, providing either a buffer or an array for `chunk` is ugly
21:31:09  <piscisaureus_>isaacs: but sure
21:31:14  <isaacs>i mean, i think it's basically only internal node-core streams where that matters.
21:31:15  <piscisaureus_>isaacs: paint your own bikeshed :-)
21:31:20  <isaacs>and it's not something that a user's gonna change.
21:31:20  <piscisaureus_>yeah
21:31:29  <isaacs>like, net.Socket streams will just force that flag to be set.
21:31:53  <piscisaureus_>isaacs: can't we do it the other way round?
21:32:07  <piscisaureus_>isaacs: just never bufferize and make the implementators responsible for it?
21:32:20  <piscisaureus_>*implementations
21:32:23  <isaacs>no, that sucks.
21:32:39  <isaacs>most userland streams (which aren't taking weirdo objects) assume that they'll always get buffers.
21:32:43  <piscisaureus_>isaacs: but this sucks as well if you e.g. write a string-filtering transform
21:32:54  <isaacs>and treat all strings as utf8
21:33:01  * stagasquit (Ping timeout: 246 seconds)
21:33:24  <isaacs>string-filtering transform?
21:33:33  <isaacs>oic, like output(chunk.toUpperCase())
21:33:34  <isaacs>or something
21:33:41  <piscisaureus_>yeah, for example
21:33:51  <piscisaureus_>or replace \r\n by \n :-)
21:33:58  <piscisaureus_>or parse and remove http headers
21:34:12  <isaacs>and people can't just slice buffers?
21:34:15  <isaacs>pshaw!
21:34:20  <isaacs>lazy coders!
21:34:22  <isaacs>;)
21:34:49  <isaacs>piscisaureus_: well, in those cases, you can set that same flag, and do it yourself, right?
21:35:33  <isaacs>this._writableState.decodeStrings=false;
21:35:49  <isaacs>throw that in your ctor, and nothing will be bufferized for you.
21:36:00  <isaacs>of course, the user can still stream.write(new Buffer('yabba dabba doo')) or something
21:36:11  <isaacs>so you *always* have to be prepared to receive buffers.
21:41:51  <piscisaureus_>isaacs: yes, so it should be a public api
21:47:30  * `3rdEden_quit (Remote host closed the connection)
21:48:00  * `3rdEdenjoined
21:52:37  * joshthecoderquit (Quit: Leaving...)
21:56:55  * loladiroquit (Quit: loladiro)
22:02:45  * piscisaureus_quit (Ping timeout: 252 seconds)
22:03:25  * `3rdEdenquit (Ping timeout: 260 seconds)
22:04:14  <txdv>stat is the most disgusting stgruct of the m all
22:11:40  * piscisaureus_joined
22:18:10  * joshthecoderjoined
22:22:01  * loladirojoined
22:24:10  * lohkeyquit (Read error: Connection reset by peer)
22:30:48  * lohkeyjoined
22:33:02  * felixge_joined
22:33:02  * felixge_quit (Changing host)
22:33:03  * felixge_joined
22:35:09  * loladiroquit (Quit: loladiro)
22:36:32  * c4miloquit (Remote host closed the connection)
22:36:40  * felixgequit (Ping timeout: 260 seconds)
22:36:40  * felixge_changed nick to felixge
22:38:41  * EhevuTovjoined
22:44:35  * loladirojoined
22:47:20  * felixgequit (Quit: felixge)
22:47:31  * mikealjoined
23:01:40  * felixgejoined
23:01:40  * felixgequit (Changing host)
23:01:41  * felixgejoined
23:11:04  * lohkeyquit (Ping timeout: 244 seconds)
23:12:57  <MI6>joyent/libuv: Ben Noordhuis master * 4affbe7 : unix: remove unnecessary pthread_join ESRCH check ESRCH means the thread - http://git.io/fhyoiA
23:13:43  * mraleph1quit (Quit: Leaving.)
23:14:46  * travis-cijoined
23:14:47  <travis-ci>[travis-ci] joyent/libuv#788 (master - 4affbe7 : Ben Noordhuis): The build passed.
23:14:47  <travis-ci>[travis-ci] Change view : https://github.com/joyent/libuv/compare/acea3028c53c...4affbe70b6f2
23:14:47  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/libuv/builds/2727701
23:14:47  * travis-cipart
23:28:26  * Ariajoined
23:30:29  * tomshredsjoined
23:36:30  <isaacs>bnoordhuis: any idea what the root cause is on sir-writes-alot?
23:36:55  <isaacs>bnoordhuis: i tried bisecting it, but it's tricky since there's a bunch of libuv commits around that area where node doesn't compile.
23:39:18  <bnoordhuis>isaacs: what's the deal with that test?
23:39:48  <bnoordhuis>isaacs: test/simple/test-fs-sir-writes-alot.js?
23:40:33  <bnoordhuis>consistently passes for me
23:42:24  * xaqjoined
23:44:34  <isaacs>bnoordhuis: i get nulls in the file.
23:44:55  <isaacs>bnoordhuis: at random places.
23:45:05  <bnoordhuis>isaacs: does that make the test fail for you?
23:45:05  <isaacs>bnoordhuis: it's as if the buffer is getting GC'd or something.
23:45:08  <isaacs>yes.
23:45:13  <isaacs>the file should be nothing but 'x' and '\n' chars.
23:45:17  <bnoordhuis>right
23:45:22  <bnoordhuis>that seems to be what's happening here
23:45:33  <bnoordhuis>you're on cupertino os, i assume?
23:45:49  <isaacs>yes, fruitycat
23:46:10  <isaacs>Big African Savannah version.
23:46:35  <bnoordhuis>isaac, can you open deps/uv/src/unix/threadpool.c and set the number of threads from 4 to 1 and recompile
23:47:09  <bnoordhuis>that's the line that says static pthread_t threads[4];
23:47:54  <isaacs>yep
23:47:56  <isaacs>compiling
23:49:42  <txdv>only 4 threads?
23:49:46  <bnoordhuis>txdv: for now
23:50:00  <bnoordhuis>i'll land some auto-tune patches later this month
23:50:28  <isaacs>bnoordhuis: works.
23:50:35  <bnoordhuis>test stops failing?
23:50:37  <isaacs>yessir.
23:50:57  <bnoordhuis>it's probably the return of the os x pwrite bug
23:51:09  <bnoordhuis>i think i put a mutex in place but apparently it's not working
23:51:36  <txdv>libuv: the return of the os x pwrite bug
23:52:25  <bnoordhuis>isaacs: can you `gdb out/Release/node` and `list uv__fs_pwrite`?
23:53:07  <isaacs>(gdb) list uv__fs_pwrite
23:53:07  <isaacs>Function "uv__fs_pwrite" not defined.
23:53:21  <bnoordhuis>oh, it's probably inlined
23:53:34  <bnoordhuis>isaacs: list uv__fs_write?
23:53:54  <isaacs>(gdb) list uv__fs_write
23:53:54  <isaacs>Function "uv__fs_write" not defined.
23:54:13  <isaacs>(gdb) list uv__f
23:54:13  <isaacs>uv__fs_done uv__fs_readdir_filter uv__fsevents_event_cb
23:54:13  <isaacs>uv__fs_event uv__fs_work uv__fsevents_init
23:54:13  <isaacs>uv__fs_event_close uv__fsevents_cb uv__fsevents_schedule
23:54:13  <isaacs>uv__fs_poll_close uv__fsevents_close
23:54:15  <isaacs>(gdb) list uv__fs
23:54:26  <bnoordhuis>ah, it inlined everything into uv__fs_work
23:54:42  <isaacs>(gdb) list uv__fs_work
23:54:42  <isaacs>452 else
23:54:42  <isaacs>453 return uv__fs_pwrite(req);
23:54:42  <isaacs>454 }
23:54:42  <isaacs>455
23:54:44  <isaacs>456
23:54:47  <isaacs>457 static void uv__fs_work(struct uv__work* w) {
23:54:49  <isaacs>458 int retry_on_eintr;
23:54:52  <isaacs>459 uv_fs_t* req;
23:54:54  <isaacs>460 ssize_t r;
23:54:57  <isaacs>461
23:54:59  <isaacs>(gdb)
23:55:37  <bnoordhuis>isaacs: can you add a __attribute__((noinline)) just before uv__fs_pwrite and recompile?
23:55:55  <bnoordhuis>oh, and undo the changes to threadpool.c please :)
23:56:49  <txdv>how big will you make it?
23:56:57  <txdv>maybe dynamic size?
23:56:59  * TooTallNatequit (Quit: Computer has gone to sleep.)
23:57:06  <isaacs>(gdb) list uv__fs_pwrite
23:57:06  <isaacs>132 #endif
23:57:06  <isaacs>133 }
23:57:06  <isaacs>134
23:57:06  <isaacs>135
23:57:08  <isaacs>136 __attribute__((noinline))
23:57:11  <isaacs>137 static ssize_t uv__fs_pwrite(uv_fs_t* req) {
23:57:14  <isaacs>138 #if defined(__APPLE__)
23:57:16  <isaacs>139 /* Serialize writes on OS X, concurrent pwrite() calls result in data loss.
23:57:19  <isaacs>140 * We can't use a per-file descriptor lock, the descriptor may be a dup().
23:57:21  <isaacs>141 */
23:57:27  <isaacs>and test fails again, of course.
23:58:34  <isaacs>there's clearly a pthread_mutex around it
23:58:53  <bnoordhuis>interesting
23:59:30  <bnoordhuis>can you try this: gdb --args out/Release/node test/simple/test-fs-sir-writes-alot.js
23:59:57  <bnoordhuis>then: bt uv__fs_pwrite; commands; silent; bt 1; c; end; r (replace ; with newline)