00:00:00  * ircretaryquit (Remote host closed the connection)
00:00:08  * ircretaryjoined
00:02:37  * WalrusPonyjoined
00:03:41  * rmgquit (Remote host closed the connection)
00:05:17  * thlorenzjoined
00:06:46  <trevnorris>oy, maybe i'll get this. now i'm getting: FATAL: ThreadSanitizer: failed to intercept pthread_mutex_lock
00:06:52  * brunklejoined
00:07:10  <mmalecki>trevnorris: this is an LD_PRELOAD thingy, I assume?
00:07:34  * thlorenzquit (Remote host closed the connection)
00:07:40  <trevnorris>don't think so. already had to take care of that just to load libuv
00:08:02  <trevnorris>here's the actual error:
00:08:02  <trevnorris>FATAL: ThreadSanitizer CHECK failed: /build/buildd/llvm-toolchain-3.4-3.4/projects/compiler-rt/lib/sanitizer_common/sanitizer_allocator.h:316 "((kSpaceBeg)) == (( reinterpret_cast<uptr>(Mprotect(kSpaceBeg, kSpaceSize))))" (0x7d0000000000, 0xfffffffffffffff4)
00:08:34  <mmalecki>trevnorris: this is why I drink
00:08:39  <trevnorris>hehe
00:08:40  <mmalecki>trevnorris: is there anything more?
00:08:51  <trevnorris>nope. just those two lines.
00:08:57  <mmalecki>let me actually pull this thing and see if I can reproduce
00:10:05  * brsonquit (Ping timeout: 258 seconds)
00:10:48  <mmalecki>trevnorris: you built it from source or got binaries?
00:11:04  <trevnorris>everything's from source
00:11:43  * brsonjoined
00:11:59  <trevnorris>well. not llvm
00:12:06  <mmalecki>all right, running their script thingy. seems fairly terrible.
00:12:23  * brsonquit (Client Quit)
00:12:30  <mmalecki>ah, SVN.
00:14:48  <mmalecki>hmmm, okay, that failed for me: https://gist.github.com/mmalecki/9a92e8e1d15cf92546fb
00:15:20  <trevnorris>hm. ok
00:15:44  <trevnorris>i just ran their most basic test case on the faq page and that failed w/ the same message
00:16:07  <trevnorris>well... bummer
00:16:10  <mmalecki>with the check message?
00:16:42  <mmalecki>I'm afraid debugging LLVM code might be a little bit over my pay grade
00:16:50  <trevnorris>haha, ditto
00:16:51  * sh1mmerquit (Quit: sh1mmer)
00:16:57  <trevnorris>yeah, with the check message
00:18:40  <mmalecki>although, https://github.com/llvm-mirror/compiler-rt/blob/master/lib/sanitizer_common/sanitizer_allocator.h#L288-L303
00:18:58  <mmalecki>and https://github.com/llvm-mirror/compiler-rt/blob/master/lib/sanitizer_common/sanitizer_allocator.h#L315-L316
00:19:47  <mmalecki>hmm, my best guess would be that it's failing to mprotect?
00:19:58  <trevnorris>sounds probable.
00:20:16  <mmalecki>trevnorris: could you possibly strace it and see if calls mprotect at all?
00:20:33  <trevnorris>i'll try it out. need to head in a sec.
00:20:58  <mmalecki>I have no clue where their Mprotect comes from tho, because yay C++
00:22:00  <trevnorris>the reason for this is i'm trying to create a lock-less queue for SPSC: https://gist.github.com/trevnorris/1b17e2d4f567e754e728
00:22:31  <mmalecki>haha, love the name
00:23:26  <mmalecki>what are your requirements?
00:24:15  * AlexisMochajoined
00:25:04  * daviddiasjoined
00:25:11  <trevnorris>heh, yeah. name was actually an accident, but decided to go with it. :)
00:25:11  <trevnorris>one thread pushes data in, one thread shifts data off.
00:25:17  * brsonjoined
00:25:23  * AlexisMocha_quit (Ping timeout: 245 seconds)
00:25:57  <trevnorris>so far I haven't been able to make it fail in any way, which for some reason worries me.
00:26:51  <mmalecki>right. so iirc binding process to a core can be achieved fairly easily
00:27:15  <mmalecki>your other options include clever fusing of pthread through LD_PRELOAD
00:27:18  <mmalecki>*fuzzing
00:27:25  <mmalecki>s/process/thread/
00:29:03  <trevnorris>ok cool
00:29:23  * TooTallNatequit (Quit: Computer has gone to sleep.)
00:29:33  * daviddiasquit (Ping timeout: 245 seconds)
00:30:47  * AlexisMocha_joined
00:31:25  <mmalecki>trevnorris: let me know if you need anything, this is something I'd love to help with. can't really contribute code at this point due to amount of things tho
00:31:47  <trevnorris>no worries. thanks for the help so far.
00:32:01  * zz_karupachanged nick to karupa
00:32:29  * AlexisMochaquit (Ping timeout: 255 seconds)
00:32:53  <mordy_>curious, in which cases does a read callback receive a 0 for nread?
00:33:09  <mordy_>too lazy to dive into the source code, but the "UV is done reading for now" description is rather vague
00:33:23  <mmalecki>trevnorris: pleasure :)
00:33:39  <mmalecki>mordy_: I think it's EOF
00:34:20  <mmalecki>oh wait, I'm wrong there
00:34:23  <mmalecki>uvbook disagrees
00:34:50  <mordy_>yeah
00:35:04  <mordy_>i was expecting it to be EOF, but the header says EOF will contain UV_EOF
00:35:44  <mmalecki>hmm. 0 is confusing then. did you ever see this happen?
00:36:07  <mordy_>no; i'm getting -1 on a socket close it seems like
00:36:12  <mordy_>let me abort/debug this properly
00:36:19  <mmalecki>yeah, -1 is a generic error
00:36:25  <mmalecki>(could also be an EOF)
00:37:01  <mordy_>bleh, wtd
00:37:16  <mordy_>i'm getting -1, UV_EOF is 1
00:37:25  <mordy_>which makes little sense as well
00:37:45  <mordy_>lemme check the 0.10 headers too and see what they say
00:37:45  <mmalecki>mordy_: you need to check last loop error to find out if this was an EOF
00:38:03  <mordy_>ahh ok
00:49:01  <mordy_>ok, so i've properly modified my code to handle UV_EOF
00:49:08  <mordy_>still, what does '0' mean and where do i get it
00:49:38  <mordy_>(this error/eof confusion is bliss compared to the openssl integration i've been doing for most of this week)
00:52:58  * Qardquit (Quit: Leaving.)
00:53:44  * bradleymeckquit (Quit: bradleymeck)
00:55:04  * calvinfoquit (Quit: Leaving.)
00:56:42  * calvinfojoined
01:07:02  <mmalecki>mordy_: hmm, where'd find info about '0'?
01:07:16  * sh1mmerjoined
01:10:13  * brunklequit (Quit: brunkle)
01:10:13  <mordy_>mmalecki: https://github.com/joyent/libuv/blob/master/include/uv.h#L390
01:11:59  <mmalecki>mordy_: ah https://github.com/joyent/libuv/blob/4ce5470f3ab110cb969bfb5c6a6cacb181bb6700/src/unix/stream.c#L1110-L1117
01:12:18  <mmalecki>hmm. this is somewhat confusing, as an API
01:12:44  <mordy_>uv has really strange semantics in a way sometimes
01:12:54  <mordy_>i'd expect 0 to be delivered as an EOF
01:13:00  <mordy_>like uh, any other socket API
01:13:50  <mmalecki>yeah, I have to admit, this is confusing
01:14:07  <mmalecki>if we get EAGAIN or EWOULDBLOCK, that should be an implementation detail
01:14:16  <mmalecki>curious what tjfontaine thinks about this ^
01:14:26  <mordy_>mmalecki: maybe it's when the alloc_cb returns an empty buffer
01:14:27  <mordy_>?
01:14:57  <mmalecki>mordy_: no, that's https://github.com/joyent/libuv/blob/4ce5470f3ab110cb969bfb5c6a6cacb181bb6700/src/unix/stream.c#L1077-L1081
01:16:12  <mordy_>hrm
01:16:14  * petka_quit (Quit: Connection closed for inactivity)
01:16:59  <mordy_>hrm, i see
01:17:28  <mordy_>the rationale, it seems like, is to indicate that the last allocated buffer did not contain any data
01:17:42  <mordy_>because it seems like alloc_cb is called directly in front of the actual read function
01:18:05  <mordy_>so if you didn't handle it inside that callback, the data would be "lost"
01:19:45  <mordy_>http://paste.scsys.co.uk/372995
01:20:02  <mordy_>the uvc_* stuff are compatibility macros for transition between 0.8 <-> 0.10 <-> 0.11
01:20:53  * ryancolejoined
01:23:34  * brsonquit (Ping timeout: 240 seconds)
01:27:28  * brsonjoined
01:59:16  * seldoquit (Remote host closed the connection)
02:07:45  * rossk_quit (Remote host closed the connection)
02:08:20  * rosskjoined
02:09:24  * calvinfoquit (Quit: Leaving.)
02:10:39  * rosskquit (Read error: Connection reset by peer)
02:11:29  * rosskjoined
02:13:24  * daviddiasjoined
02:17:53  * daviddiasquit (Ping timeout: 245 seconds)
02:29:54  * Ralithquit (Ping timeout: 276 seconds)
02:31:25  * thlorenzjoined
02:38:10  * thlorenzquit (Remote host closed the connection)
02:44:32  * kellabytejoined
02:59:46  * Ralithjoined
03:01:20  * calvinfojoined
03:02:30  * TooTallNatejoined
03:02:30  * TooTallNatequit (Client Quit)
03:07:42  * sh1mmerquit (Quit: sh1mmer)
03:17:52  * mikolalysenkojoined
03:23:39  * ryancolequit
03:28:51  * calvinfoquit (Quit: Leaving.)
03:29:32  * mrvisser_joined
03:29:58  * mrvisserquit (Ping timeout: 240 seconds)
03:30:24  * sh1mmerjoined
03:33:01  * rosskquit
03:35:41  * mikolalysenkoquit (Ping timeout: 264 seconds)
03:36:30  * brsonquit (Quit: leaving)
03:36:56  * sh1mmerquit (Quit: sh1mmer)
03:42:27  * mikolalysenkojoined
04:00:20  * AlexisMochajoined
04:00:51  * AlexisMocha_quit (Ping timeout: 258 seconds)
04:01:26  * daviddiasjoined
04:02:51  * AlexisMocha_joined
04:05:27  * AlexisMochaquit (Ping timeout: 276 seconds)
04:05:30  * daviddiasquit (Ping timeout: 240 seconds)
04:12:17  * WalrusPony1joined
04:14:43  * WalrusPonyquit (Ping timeout: 265 seconds)
04:21:42  * mikolalysenkoquit (Ping timeout: 276 seconds)
04:21:54  * bradleymeckjoined
04:36:46  * c4miloquit (Remote host closed the connection)
05:26:40  * AlexisMochajoined
05:26:54  * AlexisMocha_quit (Ping timeout: 240 seconds)
05:27:03  * dshaw_joined
05:33:47  * bajtosjoined
05:47:03  * seldojoined
05:50:05  * daviddiasjoined
05:50:58  * seldoquit (Ping timeout: 240 seconds)
05:53:43  * calvinfojoined
05:54:29  * daviddiasquit (Ping timeout: 252 seconds)
06:05:15  * WalrusPonyjoined
06:08:38  * WalrusPony1quit (Ping timeout: 255 seconds)
06:16:57  * c4milojoined
06:21:50  * c4miloquit (Ping timeout: 265 seconds)
06:23:37  * petka_joined
06:34:24  * AlexisMocha_joined
06:34:53  * AlexisMochaquit (Ping timeout: 265 seconds)
06:41:58  * mrvisser_quit (Remote host closed the connection)
06:47:29  * mrvisserjoined
06:56:21  * bradleymeckquit (Quit: bradleymeck)
07:02:15  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
07:08:16  * dshaw_quit (Quit: Leaving.)
07:13:18  <saghul_>trevnorris: you may find this useful: http://concurrencykit.org/
07:16:12  * bajtosquit (Quit: bajtos)
07:17:34  * mrvisserquit (Ping timeout: 240 seconds)
07:18:55  * janjongboomjoined
07:20:41  * AlexisMocha_quit (Ping timeout: 264 seconds)
07:20:48  * AlexisMochajoined
07:26:10  * AlexisMocha_joined
07:26:37  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
07:26:38  * AlexisMochaquit (Ping timeout: 245 seconds)
07:32:36  * calvinfoquit (Quit: Leaving.)
07:32:37  * bajtosjoined
07:35:21  * AlexisMochajoined
07:35:58  * AlexisMocha_quit (Ping timeout: 240 seconds)
07:38:00  * bajtosquit (Ping timeout: 276 seconds)
07:38:19  * daviddiasjoined
07:38:46  * dshaw_joined
07:40:26  * dshaw_quit (Read error: Connection reset by peer)
07:40:36  * dshaw_joined
07:42:38  * daviddiasquit (Ping timeout: 240 seconds)
07:49:21  * dshaw_quit (Ping timeout: 252 seconds)
07:49:56  * janjongboomjoined
07:54:50  * janjongboomquit (Read error: Connection reset by peer)
07:57:21  * janjongboomjoined
07:58:39  * dshaw_joined
08:05:14  * c4milojoined
08:10:06  * c4miloquit (Ping timeout: 265 seconds)
08:10:19  * dshaw_quit (Ping timeout: 240 seconds)
08:21:13  * janjongboomquit (Ping timeout: 265 seconds)
08:21:46  * janjongboomjoined
08:26:14  * kellabytequit (Quit: Connection closed for inactivity)
08:32:22  * daviddiasjoined
08:35:42  * daviddia_joined
08:36:51  * rendarjoined
08:37:00  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
08:39:15  * mrvisserjoined
08:39:45  * daviddiasquit (Ping timeout: 276 seconds)
08:49:33  * AlexisMochaquit (Ping timeout: 245 seconds)
08:50:00  * AlexisMochajoined
09:08:53  * janjongboomjoined
09:10:34  * daviddia_quit (Remote host closed the connection)
09:18:55  * daviddiasjoined
09:19:41  * AlexisMocha_joined
09:20:40  * AlexisMochaquit (Ping timeout: 265 seconds)
09:35:06  * bajtosjoined
09:38:25  * dshaw_joined
09:39:18  * bajtosquit (Ping timeout: 240 seconds)
09:42:34  * karupachanged nick to zz_karupa
09:44:21  * hzjoined
09:48:20  <Dirkson>uv_write(Request, ServerPlayerList[i]->UvStream, &UvBuffer, 1, WriteCleanupFake);
09:48:25  <Dirkson>uv_write(Request, ServerPlayerList[i]->UvStream, &UvBuffer, 1, WriteCleanup);
09:48:54  <Dirkson>I've written those two lines... But I get two callbacks to WriteCleanup , instead of one callback to each. What's up?
09:53:43  * c4milojoined
09:54:42  * dshaw_quit (Ping timeout: 240 seconds)
09:57:58  * c4miloquit (Ping timeout: 240 seconds)
10:00:00  * AlexisMochajoined
10:00:18  * AlexisMocha_quit (Ping timeout: 265 seconds)
10:16:25  * Kakera_joined
10:18:01  <saghul_>Dirkson: you need to use different request structs
10:19:04  <Dirkson>saghul_: Ahhhhh. Thanks
10:33:37  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
10:35:56  * bajtosjoined
10:40:14  * bajtosquit (Ping timeout: 240 seconds)
10:41:56  * janjongboomjoined
10:46:44  * janjongboomquit (Ping timeout: 255 seconds)
10:56:22  * janjongboomjoined
11:00:16  * hzquit (Disconnected by services)
11:00:21  * hzjoined
11:01:04  * janjongboomquit (Client Quit)
11:05:56  * AlexisMocha_joined
11:06:31  * AlexisMochaquit (Ping timeout: 265 seconds)
11:16:16  * AlexisMochajoined
11:16:24  * AlexisMocha_quit (Ping timeout: 276 seconds)
11:21:02  * janjongboomjoined
11:41:57  * c4milojoined
11:46:36  * c4miloquit (Ping timeout: 258 seconds)
11:50:01  * janjongboomquit (Ping timeout: 265 seconds)
11:52:22  * janjongboomjoined
11:56:29  * AlexisMochaquit (Ping timeout: 252 seconds)
11:56:35  * AlexisMocha_joined
12:02:54  * AlexisMochajoined
12:03:04  * AlexisMocha_quit (Ping timeout: 265 seconds)
12:10:48  * AlexisMochaquit (Ping timeout: 245 seconds)
12:13:29  * AlexisMochajoined
12:17:02  * AlexisMocha_joined
12:17:53  * AlexisMochaquit (Ping timeout: 245 seconds)
12:18:17  <MI6>joyent/node: Ben Noordhuis v0.10 * 885142a : src: fix _XOPEN_SOURCE redefinition warning - http://git.io/ZWw7Pw
12:19:33  * janjongboomquit (Ping timeout: 245 seconds)
12:21:09  * janjongboomjoined
12:23:47  * hzquit (Ping timeout: 260 seconds)
12:25:04  * dshaw_joined
12:29:02  * mikolalysenkojoined
12:29:06  * dshaw_quit (Ping timeout: 240 seconds)
12:30:17  * AlexisMocha_quit (Ping timeout: 264 seconds)
12:30:18  * AlexisMochajoined
12:32:25  * hzjoined
12:36:38  * AlexisMochaquit (Ping timeout: 245 seconds)
12:38:36  * AlexisMochajoined
12:42:08  * kellabytejoined
12:46:59  * AlexisMochaquit (Ping timeout: 252 seconds)
12:50:37  * AlexisMochajoined
12:54:13  * bajtosjoined
12:54:42  * AlexisMochaquit (Ping timeout: 240 seconds)
12:55:50  * hzquit
12:59:24  * AlexisMochajoined
13:03:42  * AlexisMocha_joined
13:03:43  * AlexisMochaquit (Ping timeout: 245 seconds)
13:04:43  * hzjoined
13:08:02  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
13:11:10  * daviddiasquit
13:11:44  * AlexisMochajoined
13:12:11  * AlexisMocha_quit (Ping timeout: 265 seconds)
13:17:56  * AlexisMochaquit (Ping timeout: 255 seconds)
13:18:27  * bradleymeckjoined
13:18:51  * janjongboomjoined
13:26:15  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
13:26:41  * AlexisMochajoined
13:30:04  * thlorenzjoined
13:30:04  * c4milojoined
13:30:54  * AlexisMochaquit (Ping timeout: 240 seconds)
13:31:02  * AlexisMochajoined
13:35:05  * c4miloquit (Ping timeout: 264 seconds)
13:36:23  * jmar777joined
13:43:36  * AlexisMochaquit (Ping timeout: 265 seconds)
13:45:23  * AlexisMochajoined
13:47:10  * rosskjoined
13:54:16  * piscisaureusjoined
14:09:46  * janjongboomjoined
14:09:54  * mikolalysenkoquit (Ping timeout: 240 seconds)
14:10:45  * janjongboomquit (Client Quit)
14:18:11  * thlorenzquit (Remote host closed the connection)
14:18:22  * c4milojoined
14:19:13  * thlorenzjoined
14:24:52  * mikolalysenkojoined
14:26:29  * dshaw_joined
14:26:45  * AlexisMocha_joined
14:27:30  * AlexisMochaquit (Ping timeout: 240 seconds)
14:30:42  * dshaw_quit (Ping timeout: 240 seconds)
14:32:59  * janjongboomjoined
14:39:34  * janjongboomquit (Ping timeout: 240 seconds)
14:56:14  * kellabytequit (Quit: Connection closed for inactivity)
15:05:37  * janjongboomjoined
15:14:29  * janjongboomquit (Ping timeout: 255 seconds)
15:17:44  * janjongboomjoined
15:25:53  * rjequit (Ping timeout: 258 seconds)
15:26:08  * rjejoined
15:27:23  * rmgjoined
15:28:12  * bajtosquit (Quit: bajtos)
15:30:49  * janjongboomquit (Quit: My MacBook has gone to sleep. ZZZzzz…)
15:32:38  * calvinfojoined
15:37:39  * sinclair|workquit (Quit: ChatZilla 0.9.90.1 [Firefox 29.0.1/20140506152807])
15:47:07  * dap_1joined
15:51:28  * calvinfoquit (Quit: Leaving.)
15:53:56  * kellabytejoined
15:56:26  * Qardjoined
15:56:53  * dshaw_joined
15:57:07  * janjongboomjoined
16:00:43  * janjongboomquit (Client Quit)
16:01:06  * dshaw_quit (Ping timeout: 240 seconds)
16:04:28  * bajtosjoined
16:05:44  * AlexisMocha_quit (Ping timeout: 258 seconds)
16:06:24  * janjongboomjoined
16:10:14  * hueniversequit (Ping timeout: 240 seconds)
16:13:49  <Ralith>Dirkson: the request struct is basically where libuv stores all the parameters you passed in (plus necessary internal data); you cannot reuse one while its associated operation is in progress.
16:14:29  * andrehjrjoined
16:18:50  * hueniversejoined
16:23:11  * calvinfojoined
16:26:53  * thlorenzquit (Remote host closed the connection)
16:33:59  * brunklejoined
16:43:21  * sh1mmerjoined
17:16:07  * AlexisMochajoined
17:23:02  * jmar777quit (Ping timeout: 265 seconds)
17:26:02  * wolfeidauquit (Remote host closed the connection)
17:26:27  * wolfeidaujoined
17:28:32  * anchnkjoined
17:29:03  * anchnkquit (Remote host closed the connection)
17:30:50  * quijotejoined
17:34:15  * jmar777joined
17:36:12  * quijotequit (Ping timeout: 258 seconds)
17:39:37  * jmar777quit
17:41:35  * quijotejoined
17:41:38  * mikolalysenkoquit (Ping timeout: 255 seconds)
17:45:22  * brsonjoined
17:47:14  * TooTallNatejoined
17:47:30  * andrehjrquit (Ping timeout: 240 seconds)
17:48:56  * c4miloquit (Remote host closed the connection)
17:49:29  * sh1mmerquit (Quit: sh1mmer)
18:02:16  * quijotequit (Ping timeout: 258 seconds)
18:02:53  <Dirkson>Ralith: Oh! That's good info.
18:03:59  * mikolalysenkojoined
18:06:14  * kellabytequit (Quit: Connection closed for inactivity)
18:09:33  * piscisaureusquit (Ping timeout: 245 seconds)
18:10:42  * piscisaureusjoined
18:15:55  * seldojoined
18:19:17  * andrehjrjoined
18:19:35  * thlorenzjoined
18:27:21  * brunklequit (Quit: brunkle)
18:28:27  * quijotejoined
18:31:16  * brunklejoined
18:32:56  * quijotequit (Ping timeout: 258 seconds)
18:40:51  * quijotejoined
18:41:13  * rendarquit (Ping timeout: 245 seconds)
18:41:45  * brunklequit (Quit: brunkle)
18:44:25  * seldo_joined
18:47:42  * brunklejoined
18:48:20  * seldoquit (Ping timeout: 252 seconds)
18:49:58  * mikolalysenkoquit (Ping timeout: 245 seconds)
18:50:37  * AlexisMocha_joined
18:52:17  * AlexisMochaquit (Ping timeout: 252 seconds)
18:53:23  * kellabytejoined
18:57:46  * AlexisMochajoined
18:58:06  * brunklequit (Quit: brunkle)
18:58:50  * andrehjr_joined
18:58:52  * andrehjrquit (Read error: Connection reset by peer)
18:59:05  * AlexisMocha_quit (Ping timeout: 264 seconds)
19:00:21  * bajtosquit (Quit: bajtos)
19:05:47  * AlexisMochaquit (Ping timeout: 255 seconds)
19:08:14  * kuebkjoined
19:09:58  * c4milojoined
19:14:17  * c4miloquit (Ping timeout: 252 seconds)
19:16:31  * brunklejoined
19:18:58  <felixge>tjfontaine: ping
19:25:39  * quijotequit (Ping timeout: 252 seconds)
19:26:48  * brunklequit (Quit: brunkle)
19:28:54  * mikolalysenkojoined
19:28:55  * TooTallNatequit (Quit: Computer has gone to sleep.)
19:35:36  * hzquit
19:49:02  * brunklejoined
19:49:25  * ryancolejoined
19:59:23  * brunklequit (Quit: brunkle)
20:01:11  * sh1mmerjoined
20:04:41  <Dirkson>I'm still having some REALLY strange behavior with trying to get different uv_writes to behave differently. For example, this ( http://paste.orangehattech.com/view/2875b668 ) code leaks memory through Request, even though I clean up each request in WriteCleanupBatch, and provide it with separate requests to work on.
20:04:49  <Dirkson>Ralith: Ping, since you showed some interest : )
20:05:04  <Dirkson>saghul_: Also ping, since you showed some interest
20:05:11  * c4milojoined
20:05:50  <Dirkson>http://paste.orangehattech.com/view/afe85f83 - The cleanup callbacks mentioned.
20:08:49  * brunklejoined
20:09:44  <Ralith>Dirkson: writes to different destinations won't necessarily complete in the order issued
20:10:05  <Dirkson>Ralith: Same destination, isn't it?
20:10:21  <Dirkson>Ralith: Or do you mean the streams? You probably mean the streams.
20:10:37  <piscisaureus>janjongboom!
20:10:43  <Dirkson>Ralith: Well, how /should/ I be getting this done, then? Seems silly to hand every write a separate copy of the same string.
20:11:12  <Ralith>Dirkson: reference-counting
20:11:58  <Dirkson>Ralith: Oh No
20:12:09  <Ralith>?
20:12:42  <Dirkson>Ralith: Whenever I talk about reference counting with a friend of mine, it usually becomes a full blown garbage collector in like 0.37 steps.
20:13:42  <Ralith>this case does not call for garbage collection
20:13:48  <Ralith>it does, however, call for reference counting
20:14:00  * dshaw_joined
20:14:28  <Ralith>it's a perfectly standard memory management technique
20:14:33  <Ralith>you're not applying it to your whole program
20:16:03  <Dirkson>Ralith: Sure sure : ) But even assuming I use reference counting for my own data, there's still the fact that libuv is treating my Request data weirdly. I'm making a new request data for every call of uv_write, and then freeing that request data in WriteCleanupBatch... But I'm still leaking memory like an overpressurized firehose. Those extra requests I'm creating /aren't/ being freed.
20:19:13  * brunklequit (Quit: brunkle)
20:21:41  <Ralith>Dirkson: if they're not being freed, what is?
20:22:09  <Dirkson>Ralith: What a good question
20:23:24  * quijotejoined
20:27:15  * mikolalysenkoquit (Ping timeout: 252 seconds)
20:28:08  * quijotequit (Ping timeout: 255 seconds)
20:28:49  * brunklejoined
20:39:18  * brunklequit (Quit: brunkle)
20:40:22  * andrehjr_quit (Quit: ["Textual IRC Client: www.textualapp.com"])
20:41:22  * AlexisMochajoined
20:48:10  * brunklejoined
20:48:26  <mordy_>hrm, looking here
20:49:24  <mordy_>Dirkson: where's the callback function?
20:49:31  <mordy_>also might be useful checking the return value of uv_write?
20:49:37  <Dirkson>mordy_: In the next pastebin : )
20:49:44  <mordy_>hrm
20:49:46  <Dirkson>mordy_: Oh, I can do that? What do the return values mean?
20:50:06  * ryancolequit (Read error: Connection reset by peer)
20:50:10  <mordy_>UV_EXTERN int uv_write(uv_write_t* req,
20:50:21  <mordy_>Dirkson: i believe 0 on success, nonzero on failure
20:50:30  <Dirkson>mordy_: Thanks : )
20:51:47  <mordy_>Dirkson: especially if you're sending out to multiple peers it's likely that some may have been disconnected; you should be calling uv_close and such on the socket once you get an error
20:51:53  <mordy_>and not just ignore the -1 return value
20:52:11  <Dirkson>mordy_: That's probably true.
20:52:11  * ryancolejoined
20:52:21  <mordy_>come to think of it, i don't know if i'm following that myself
20:52:22  <mordy_>hrm
20:52:33  <Dirkson>*laughs* :D
20:52:35  <saghul_>if the return value is < 0 then no callback will be made
20:52:47  <Dirkson>Oh. OH!
20:52:50  <Dirkson>saghul_: No wonder!
20:53:03  <Dirkson>saghul_: That explains the whole darn thing. I get tons of sigpipes, which I've been ignoring.
20:53:17  <mordy_>Dirkson: you wouldn't get -1 as a result of a sigpipe
20:53:18  <mordy_>also
20:53:28  <mordy_>why doesn't your app simply do signal(SIGPIPE, SIG_IGN)?
20:53:44  <mordy_>(why the hell is SIGPIPE ever sent these days anyway)
20:53:50  <Dirkson>mordy_: I do, but the sigpipes still fire, even if they do nothing
20:53:55  <saghul_>Dirkson: you probably get epipe in the write callback, not as a result of uv_write, I guess
20:54:18  <Dirkson>mordy_: I don't know, but it caused me to tear my hair out for 4 hours until I learned that a sigpipe wasn't a segfault :D
20:54:28  <mordy_>signals are evil
20:54:50  * calvinfo1joined
20:55:09  <Dirkson>mordy_: Couldn't figure out why my segfault-analyzing tools wouldn't analyze :D
20:55:39  <mordy_>signals: let's install undeterministic signalling from the kernel into a random thead into the application and then not provide any context with it. of course force the app to handle the signal or abort the application too, for added measure
20:55:53  <Dirkson>saghul_: Well, drat. uv_write never appears to return <0 in my testing.
20:56:02  * calvinfoquit (Ping timeout: 255 seconds)
20:56:16  <mordy_>Dirkson: f you had a previous uv_read which returned -1, you shouldn't perform any uv_write on it either
20:56:45  <Dirkson>saghul_: Very wrong. It helps if I run the testing suite I'm talking about
20:58:15  <mordy_>Dirkson: also, yeah, as mentioned, you're corrupting memory here
20:58:38  <mordy_>you're assuming the WriteCleanup will be called after all the WriteCleanupBatch invocations
20:58:42  <mordy_>but there's no such guarantee
20:59:36  <Dirkson>mordy_: Yup. Writing a wrapper to fix that behavior now : )
20:59:38  <Ralith>he's reading freed memory, which is different than corrupting it
21:00:08  <mordy_>Ralith: not directly, no
21:00:20  <mordy_>but it may end up causing the application to do weird things, including corrupting data
21:00:41  <Ralith>sure, it's UB
21:00:56  <Ralith>but he's not corrupting data any more than he is inadvertently launching a nuclear strike
21:01:00  <mordy_>and since this is C, UB pretty much infects the entire process/address space
21:01:20  <mordy_>but yeah
21:02:24  <mordy_>Ralith: well further more, it might result in an EFAULT
21:02:28  <mordy_>unlikely though
21:04:16  * AlexisMocha_joined
21:05:29  * AlexisMochaquit (Ping timeout: 255 seconds)
21:10:41  * tumdedumquit (Remote host closed the connection)
21:22:03  * AlexisMochajoined
21:22:28  * AlexisMocha_quit (Ping timeout: 245 seconds)
21:24:07  * quijotejoined
21:24:28  * tumdedumjoined
21:28:03  <trevnorris>saghul_: thanks
21:28:53  * quijotequit (Ping timeout: 255 seconds)
21:34:02  * AvianFluquit
21:35:41  * AlexisMocha_joined
21:36:14  * kellabytequit (Quit: Connection closed for inactivity)
21:36:32  * AlexisMochaquit (Ping timeout: 255 seconds)
21:38:13  * AvianFlujoined
21:42:24  * kuebkquit
21:57:18  * dshaw_1joined
21:57:57  * dshaw_quit (Ping timeout: 276 seconds)
22:02:43  * brunklequit (Quit: brunkle)
22:06:57  * AlexisMochajoined
22:07:01  * brunklejoined
22:08:02  * AlexisMocha_quit (Ping timeout: 255 seconds)
22:09:28  * dshaw_1quit (Quit: Leaving.)
22:11:49  * hzjoined
22:15:41  * Kakera_quit (Ping timeout: 255 seconds)
22:22:36  * cjbjoined
22:24:56  * quijotejoined
22:29:48  * quijotequit (Ping timeout: 276 seconds)
22:36:25  * sblomquit (Read error: Connection reset by peer)
22:36:56  * mrvisserquit (Remote host closed the connection)
22:41:48  * piscisaureusquit (Quit: ~ Trillian Astra - www.trillian.im ~)
22:45:49  * AlexisMocha_joined
22:46:54  * AlexisMochaquit (Ping timeout: 240 seconds)
22:50:43  * sblomjoined
22:54:42  * TooTallNatejoined
22:55:24  * c4miloquit (Remote host closed the connection)
22:55:38  * c4milojoined
23:06:58  * brunklequit (Quit: brunkle)
23:11:05  * mrvisserjoined
23:17:50  * andrehjrjoined
23:19:25  * brunklejoined
23:22:31  * quijotejoined
23:27:28  * quijotequit (Ping timeout: 265 seconds)
23:31:21  * mikolalysenkojoined
23:40:57  * AlexisMochajoined
23:42:05  * AlexisMocha_quit (Ping timeout: 255 seconds)
23:47:06  * rmgquit (Remote host closed the connection)
23:54:52  * thlorenzquit (Remote host closed the connection)
23:58:26  * brunklequit (Quit: brunkle)