<< 30-04-2014 >>

00:05:56*nande joined #nimrod
00:30:39*DAddYE_ quit (Remote host closed the connection)
00:52:47*Demos quit (Read error: Connection reset by peer)
00:53:51*dom96 quit (Ping timeout: 252 seconds)
00:53:51*Amrykid quit (Ping timeout: 252 seconds)
00:57:22*springbok joined #nimrod
01:01:01*Amrykid joined #nimrod
01:01:18*Demos joined #nimrod
01:02:31*dom96 joined #nimrod
01:15:33*njoejoe joined #nimrod
01:17:45njoejoeis it true that the honey badger is nimrod's mascot?
01:19:56Varriountnjoejoe: Yes. Although the design hasn't been finalized yet.
01:20:50Varriountnjoejoe: This is the prototype. http://reign-studios.net/philipwitte/nimrod/mascot.png
01:22:01njoejoesweet! snakes (of all kinds...) beware! :-)
01:22:45Varriountnjoejoe: Where did you hear about the mascot, by the way?
01:23:34njoejoehttps://github.com/gradha/quicklook-rest-with-nimrod
01:24:04njoejoeand the youtube video he links to is hilarious
01:24:27Varriountnjoejoe: Actually, that page predates the decision of Nimrod's mascot, although it did help with the idea.
01:25:14VarriountI've actually looked into replicating Gradha's plugins for Windows explorer, however integrating with the Window's shell is a bit... complicated.
01:28:00njoejoeyeah i wouldn't envy that job. i'm on linux so haven't tried quicklook myself
01:28:16VarriountFor one thing, it means implementing C++ interfaces, which I don't know how to do in Nimrod. :/
01:32:18DemosVarriount: hint: check out the bits of code in the windows header that compile when you have C_INTERFACE defined
01:33:17*DAddYE joined #nimrod
01:35:58VarriountDemos: And how would I know which bits were compiled?
01:36:38Demos#ifdef? if you have a full project VS can dim the non-compiled parts
01:36:51Demosbut you will see like #ifdef C_INTERFACE .....
01:37:08VarriountDemos: I'm looking at how Pascal does it.
01:37:16Demosyou get structs with like one member that is just vtbl and you wrap that
01:37:29Demossame abi as the C++ version I bet
01:37:44Demosyou could also use IDispatch, but that is not really how you want to do it in native code
01:37:56*DAddYE quit (Ping timeout: 252 seconds)
01:38:55njoejoehow to get data from readBuffer() into a string? https://gist.github.com/anonymous/eda0623f4d143d797cdc
01:39:37Varriountnjoejoe: Are you trying to implement a getUserInput() like procedure?
01:40:31*brson quit (Ping timeout: 252 seconds)
01:40:39Varriountnjoejoe: Also, cast to an array of chars.
01:42:16njoejoenot getuserInput like... just experimenting with reading data.
01:42:17*brson joined #nimrod
01:43:13Varriountnjoejoe: Well, you could allocate an array instead of using an unmanaged allocation, and cast as needed.
01:46:01njoejoetrying lc = cast [array[char]]( buf).countLines but it doesn't like that syntax
01:46:47Varriountnjoejoe: One moment.
01:48:16*bjz joined #nimrod
01:51:19*wooya joined #nimrod
01:52:19Varriountnjoejoe: https://gist.github.com/Varriount/6c20d6f47add09c694ff
01:52:24VarriountHi wooya, bjz
01:52:32bjzo/
01:53:09fowlVarriount, did you try that?
01:53:37Varriountfowl: No. But it passed nimrod's check command.
01:53:43VarriountI have to let my dog out.
01:55:05fowlVarriount, njoejoe, (addr buf) is not correct, use addr buf[0] or buf.cstring
02:03:53*dom96 quit (Ping timeout: 252 seconds)
02:05:13EXetoCDemos: no, nnkTypeClassTy is for user-defined type classes apparently
02:05:24EXetoCbut it's just a matter of using macros.dumpTree to find out
02:05:53EXetoCno wait, you said user-defined.
02:06:03Demosright, I want to elminate | and & in favor of code that generates user defined typeclasses
02:06:18EXetoCwhile also mentioning '|'. but the terminology is confusing
02:07:11*wooya quit (Ping timeout: 240 seconds)
02:07:14njoejoethanks Varriount and fowl . It compiles now! I tried addr buf[0] but still buf.countLines() is coming up with 0. let me look closer
02:07:58EXetoCthose are user-defined yes, but are called just "type classes", and then you have "user-defined type classes" which is that new feature (type y = generic c ...)
02:09:01DemosI know what they are. I was asking if it was feasable to replace '|' and '&' with macros generateing user defined typeclasses
02:09:01*dom96 joined #nimrod
02:10:55fowlDemos, no because those types can go anywhere (proc x(y: int|string)) and not just in a type section
02:11:14fowlDemos, what is & btw, is that a thing?
02:11:31DemosI thought it was, maybe not though
02:11:47fowlhm i can see how it could be used to combine type classes
02:11:51Demosright I guess we would need some kind of lambda typeclasses
02:11:55fowlbut saying type1 & type2 doesnt make sense
02:13:33EXetoCfowl: you can't do something like "type createTypeClass(...))"?
02:13:35*bystander joined #nimrod
02:14:31fowlEXetoC, you mean get the type of a function call?
02:15:15EXetoCactually, you can't just inject something into the tree like that, right?
02:16:44fowlEXetoC, im not sure what you mean, you have a bigger example?
02:17:47*bystander quit (Client Quit)
02:18:34EXetoCno I'm only referring to AST construction, which is what this concerns
02:20:02fowlohhh
02:20:10EXetoCas in "type createTypeClass("x", int, char))" rather than "type x = int|char"
02:20:19fowlso createTypeClass is a macro which takes something like int | char
02:20:43fowlEXetoC, possibly. ive never tried a macro in a type section before
02:21:05fowlyou could certainly do it outside (declTypeClass(x, int|char))
02:21:30fowlEXetoC, but tbh this is not very useful, we dont need to use type classes for this, type x = int|char works
02:22:10EXetoCyes but his motivation is to reduce the complexity of the compiler
02:23:20fowlwhos?
02:23:30fowloh
02:23:37Demosyeah
02:24:00EXetoCand not being able to inject nodes from anywhere would be too big of a limitation
02:24:06Demosaraq wants my summer project to be rewriting sigmatch.nim
02:24:15Demoswhat if I used that getCallsite thing
02:24:54fowlDemos, make a superCallsite() function to access the level above the callsite (:<
02:24:54EXetoC'callsite' I think. I don't think these are regarded as call sites, but maybe I'm wrong
02:25:11Demosoh :(
02:25:37Demoswell I could transform it within sigmatch, not as much of a simplification but still something
02:26:19renesacDemos, while you are at it, try fixing unsigned integer handling too :)
02:26:34EXetoCI don't think you need to access the call site. this only concerns the node itself, doesn't it?
02:26:54EXetoCso you'd need some way of injecting a node from anywhere in the tree
02:30:39*dom96 quit (Ping timeout: 252 seconds)
02:30:53EXetoCwell, you could explicitly modify the parent node. The inability to go higher up than the callsite is by design IIRC, and I suppose this would count as that
02:31:45*Amrykid quit (Ping timeout: 252 seconds)
02:31:59*bjz quit (Quit: Textual IRC Client: www.textualapp.com)
02:32:02*Amrykid joined #nimrod
02:32:23fowlrenesac, what aspect of it is broken
02:33:35Demosanother option is to change the parser, but I think I will start just messing with sigmatch's input
02:34:10*DAddYE joined #nimrod
02:36:55*bjz joined #nimrod
02:37:22renesachttps://github.com/Araq/Nimrod/issues/936
02:37:35*bjz quit (Remote host closed the connection)
02:37:55*bjz joined #nimrod
02:38:01renesacI also can't index arrays with uints, and I should be able with uints types smaller than int.
02:38:18*DAddYE quit (Ping timeout: 240 seconds)
02:41:31*dom96 joined #nimrod
02:49:26*DAddYE joined #nimrod
02:56:30*brson quit (Quit: leaving)
03:45:35*BitPuffin quit (Ping timeout: 240 seconds)
03:54:24*xenagi quit (Quit: Leaving)
04:28:58*BitPuffin joined #nimrod
04:44:18Skrylarhmm time to make an image api ;f
04:45:41*darithorn quit (Ping timeout: 252 seconds)
04:49:40SkrylarDemos / Varriount / BitPuffin: does a pipe model sound good for loading images?
04:50:27Skrylarwhat i was thinking is to have different stack-based objects, so you set up a "Load PNG -> x type of buffer -> x-to-y-converter -> byte output" or such
04:51:04Skrylarwith a kind of 'pull' model so you can load multiple images in to the same byte buffer and shoot them off to GL without reallocs
04:53:40fowlrenesac, im looking for another unsigned issue, the one wiht for loops
04:54:04renesacwhat issue?
04:54:11renesacof the loop wrapping around?
04:54:16fowlyea
04:54:41renesacI discovered it is a very old bug
04:55:07renesachttps://github.com/Araq/Nimrod/issues/148
04:55:25renesacI wonder how well the compiler track the max and minimum value of variables
04:55:35BitPuffinSkrylar: sounds typical
04:56:38renesacit is just a matter of optimizing where you can prove that you can, and doing the sane thing otherwise
04:57:22fowlrenesac, the `..` iterator adrianv suggests can be constrained to uints so it doesnt affect signed ones
04:57:47renesacthis problems happens with signed integers too
04:58:04renesacit overflows and continues smaller or equal to it's maximum value
04:58:31fowloh
04:59:39SkrylarBitPuffin: hm? i haven't seen one of those
04:59:58BitPuffinSkrylar: well I meant typical for image processing
05:00:02SkrylarBitPuffin: i thought the typical api was to just have a "LoadPNG(...)" file and then have to do everything else yourself
05:01:43BitPuffinSkrylar: well not for image loading perhaps
05:01:58BitPuffinSkrylar: but image processing
05:02:02BitPuffinlike piping things around
05:02:04fowlis there a benchmarking module?
05:02:37*nande quit (Read error: Connection reset by peer)
05:02:40renesacfowl, I was making one
05:02:56renesachttps://github.com/ReneSac/Benchmark
05:02:56fowli see it! its on google
05:03:08fowlrenesac, you're famous!
05:03:23renesacI think it is broken right now
05:03:27renesacthe version on github
05:03:39renesacmaybe I should commit my unfinished changes...
05:04:06Skrylarnot to be a nitpicking derp, but when nimprof works on windows one can use that too :S
05:04:11fowlit needs a template renesac
05:04:14Skrylaradmittedly, yeah, benchmark frameworks have benefits
05:04:25renesacI'm making a 'timeit' like template
05:04:33renesacwhat template you want?
05:04:55fowlsomething simple
05:05:03fowltimeit(iterations): body
05:05:14fowler benchmark()
05:05:27renesacit has a timeit name
05:05:33fowloh you probably cant use that since its the module name
05:05:57renesacI wanted a 'bench' function or template eventually
05:06:06renesacthat does more than just time the overall speed
05:06:20renesacmaybe registering information about the gc/memory usage, etc
05:06:32renesacI don't know yet
05:08:03renesacI need to wrap the higher precision timers to use in the bench module
05:08:09renesacunlike python, nimrod is fast
05:09:08renesacsmall snippets are faster than what cputime() has precision
05:09:28renesacor maybe simply print timeit results differently
05:14:10fowlwhats timeit
05:15:50fowlrenesac, laps should be preallocated for efficiency
05:16:07renesachttps://docs.python.org/3.4/library/timeit.html
05:16:20renesacfowl, there is no api for that
05:16:38fowloh
05:16:54fowlrenesac, what do you mean?
05:17:18renesachow should I prealocate?
05:17:34fowlnewseq[t](1024)
05:18:00renesacthen I can't use ".add()"
05:18:09renesacit complicates the logic quite a bit
05:18:18fowlno, you use an integer index
05:18:33renesacyeah, it complicates the logic
05:18:46fowli believe in you
05:18:48renesacand I would need to store that integer index somewhere
05:18:53renesacbloating the struct
05:19:02fowlthats 0 overhead
05:19:13renesachow so?
05:19:29fowlwell stopwatch instances are rare, and you use them imperatively
05:19:29renesacI wanted to set the capacity, not the lenght
05:19:47fowlthey're not on the heap, being allocated spuriously
05:20:00renesacbut the struct would still have to contain that integer index
05:20:48fowlif you want to use add you can just set the length of the seq to 0
05:21:03fowlafter creating it
05:21:31fowli just like imperative programs :(
05:21:44fowlstore an index, loop while true, go nuts
05:23:54renesacfowl, assuming that setting the lenght to zero woldn't trigger a reallocation
05:24:05renesacto shrink the seq
05:25:02fowlrenesac, knowing
05:25:45fowlrenesac, thats how you preallocate a seq, and a function similar to newStringOfCap should be added for it
05:26:44fowlsorry, i thought this was common knowledge >_>
05:27:28renesacyeah, I already talked with araq about the 'new of cap'thing
05:27:49renesacI like better an optional parameter for 'newSeq', but he likes a new proc
05:29:44Skrylarokay, one thing that bothers me with seqs
05:29:50Skrylarthe capacity is hidden
05:30:16SkrylarRust vectors do have a ".capacity" and ".size" set of operators
05:30:46Skrylarthere is newString(size) and newSeq() iirc
05:31:42fowlnewseq[t](size)
05:32:10renesacand there is 'setLen'
05:32:22Skrylarnewseq has some silliness issues on occasion
05:32:37Skrylari seem to remember bah.newSeq(amt) blowing up, but newSeq(bah, amt) worked
05:32:56renesachttps://github.com/ReneSac/Benchmark <-- updated
05:33:43renesacI may change from using floats to using another time representation
05:33:54renesaclike a tuple with seconds and nanoseconds
05:34:03renesacor something like that
05:36:59renesacI need to put it in babel too
05:37:20fowllets start an unofficial repository
05:38:02renesac?
05:38:15fowlfor babel packages.json
05:38:50renesacwhy?
05:38:52fowlnvm, im realizing i dont have a reason to, besides to be a rebel
05:39:00renesac:P
05:39:49renesacfowl, is 'timeit' the template you had in mind?
05:41:05fowl# the minimum time is the most consistent.
05:41:22fowlwouldnt you use the average time?
05:41:42renesacno, other timmings can be affected by cold cache, other processes, etc
05:41:57renesactimeit also uses the minimum time, and I agree with that
05:42:26renesacbut now I'm giving the laps seq, so you can calculate your own statistics too, even when using timeit
05:42:48renesacif you want
05:44:28fowlthsi looks good
05:45:56renesacI'm not sure if nimrod needs the 'setup' parameter that python timeit has
05:56:43fowlrenesac, i think this unsigned loop issue needs a solution more than it needs an efficient solution, but i will test all the options in that issue with your benchmark thing
06:05:37*njoejoe quit (Quit: Page closed)
06:06:18*Jesin quit (Remote host closed the connection)
06:09:18*gsingh93 quit (Quit: Connection closed for inactivity)
06:11:17renesacfowl, I think it is not precise enough for this... but you can try
06:11:36renesacand as I said, the big problem is that it isn't unsigned only, it affects all nimrod for-loops
06:12:38renesacthat is why efficiency is so important
06:12:42renesacgood nigh
06:14:08renesacactually, precision is not so important if you just give the timming for each repetition instead of trying to give the time per loop as `$` for timeit currently does
06:14:51*DAddYE quit (Remote host closed the connection)
06:15:47Demosfor benchmarking you want a precise timer
06:33:33Skrylarprecise timers are hard to get though
06:33:46Skrylara lot of them are based on rdtsc which doesn't work in SMP systems
06:33:52*DAddYE joined #nimrod
06:43:13Demosdoes it even matter though if it is out of synch on different cores
06:43:34Demosyou are measureing the time some code takes to run, so you just measure each bit of code and sum the times at the end
06:43:42Skrylarno, its not that its out of sync on cores
06:43:56Skrylarit was something about how if CPU 1 activates, and CPU 2 does something, they both 'share' the rdtsc counter
06:44:11Demosoh, OK never mind
06:44:11Skrylarwhich means if a background process gets some cpu time during your test, the timer is thrown way off
06:44:34Skrylardisabling all but one core and rebooting is the only way to get a usable result out of rdtsc nowadays
07:01:07*oxful joined #nimrod
07:35:58AraqOrionPK: the bug is not that easy to fix, but I'll have a workaround by tonight
07:37:56Araqalternatively you can write your procs so that the codegen doesn't need more than 40 registers :P
07:50:41*wan quit (Quit: leaving)
08:05:54*DAddYE quit (Remote host closed the connection)
08:06:21*DAddYE joined #nimrod
08:10:42*DAddYE quit (Ping timeout: 240 seconds)
08:19:18*runvnc quit (Ping timeout: 240 seconds)
08:40:32*Demos quit (Read error: Connection reset by peer)
09:21:08*BitPuffin quit (Quit: WeeChat 0.4.3)
09:22:40*runvnc joined #nimrod
09:55:53*BitPuffin joined #nimrod
09:58:55Skrylarlater i get to bind the webp headers. wheee.
11:12:48AraqSkrylar: who has more babel bricks? you or fowl ? ;-)
11:30:57*faassen joined #nimrod
11:39:33Skrylarprobably fowl
11:39:40*springbok_ joined #nimrod
11:39:50Skrylarnone of my stuff is actually in babel, and i tend to clump
11:40:56SkrylarskUnicode is stuff i should get around to merging with stdlib, skTypeface grabs glyphs from gdi/freetype, Skylights is "everything non-GUI a program needs" and Syl is "the GUI"
11:41:41*springbok quit (Ping timeout: 264 seconds)
11:48:40Araqplease put your stuff on babel
12:01:55*BitPuffin quit (Quit: WeeChat 0.4.3)
12:02:15*BitPuffin joined #nimrod
12:27:08*springbok_ is now known as springbok
12:27:32*springbok quit (Changing host)
12:27:32*springbok joined #nimrod
12:32:55Araqhi springbok welcome
12:33:09springbokmorning
12:54:58EXetoC"await sock.connect("127.1.0.1", TPort(27017))" the proc returns after that even though more statements follow
12:57:13EXetoChttps://gist.github.com/EXetoC/d32a327c7af0a06d2745
13:02:18*BitPuffin quit (Ping timeout: 240 seconds)
13:07:47AraqEXetoC: afaik exception handling doesn't really work with 'async' so maybe it raises something that gets lost?
13:15:30*darkf quit (Quit: adjacent)
13:20:34*nande joined #nimrod
13:35:36EXetoCright
13:36:54OrionPKAraq oh yeah? any details?
13:37:14EXetoCI don't know how it can be considered ready, at least in general. for example, I'm trying to get MongoDB not to disconnect and that requires some trial and error
13:37:29OrionPK40 registers?!
13:38:14AraqEXetoC: it's not considered to be ready
13:38:25Araqjust recently we got it crash free ...
13:40:24AraqOrionPK: that's the arbitrary limit in the VM codegen
13:40:28EXetoCI guess I misinterpreted "ready for prime time". I'll keep trying to do something practical with it
13:41:06Araqthe VM has 255 registers but after 40 the register allocator decides to be more aggressive with re-using registers
13:41:27Araqhence the 'if false' affecting codegen
13:41:28EXetoCand the nnkDiscardStmt case has an out-of-bounds bug which I'll report soon
13:41:29OrionPKaraq interesting... but the code that I put in the ticket isnt that sophisticated
13:41:47OrionPKwouldnt this potentially affect a lot of macros
13:42:02AraqI don't kow the details yet, OrionPK
13:42:06OrionPKmmk
13:42:25Araqbut a lot of macros work with the new engine ...
13:42:33OrionPKya
13:42:38OrionPKobviously :)
13:43:25AraqEXetoC: I'm sorry you got a wrong impression. I thought we had updated the news message
13:44:04OrionPKaraq I am using parseutils pretty heavily
13:44:24*[1]Endy joined #nimrod
13:46:23EXetoCAraq: it's fine. I'm doing things of little importance as always
13:46:41EXetoCnot using 'await' seems to be fairly painless
13:47:10AraqOrionPK: afaict parseutils is not the problem
13:47:16EXetoCthat might change at some point, but all I need is a convenience proc for now
13:48:42OrionPKwell araq, happy to keep you on your toes ;P
13:49:23AraqI just wish we had no bugs
13:49:24OrionPKi'd like to put the templates lib out on babel once my tests are passing again
13:49:33Araqthen I could implement new features all the time ...
13:49:36OrionPK:D
13:50:10Araqand we haven't run out of ideas yet. at all.
14:05:31*nande quit (Read error: Connection reset by peer)
14:10:46*nande joined #nimrod
14:21:11*isenmann quit (Quit: Leaving.)
14:23:22*BitPuffin joined #nimrod
14:27:31renesacif those 255 registers are exceeded, do the VM push things to a stack?
14:37:52*Jesin joined #nimrod
14:43:57dom96hello
14:44:08dom96EXetoC: This is no bug. You forgot to call runForever()
14:46:50EXetoCok
14:47:31*menscrem joined #nimrod
14:47:54menscremhi all
14:47:57dom96Perhaps I shouldn't have said it's ready for prime time. I do want you to use it *now* though.
14:48:10dom96hi menscrem
14:51:14*Skrylar quit (Ping timeout: 276 seconds)
14:53:45*darithorn joined #nimrod
15:22:56dom96I wonder what the best way to parallelize the async stuff is.
15:32:20OrionPKdont await them
15:32:39OrionPKdo async procs return a task handle of some sort?
15:33:14dom96they return a future
15:33:45dom96by parallelize I'm talking about distributing them over multiple threads so that all cores can be used.
15:34:18OrionPKah
15:34:32OrionPKlike a threadpool like concept?
15:35:57dom96yes
15:37:08OrionPKmaybe await automatically puts tasks into the threadpool queue, where the queue defaults to the size of logical processors
15:38:45dom96From what I have read it seems that IOCP has been designed to be used with multiple threads.
15:39:24dom96It distributes the events evenly among threads.
15:40:44*bjz quit (Ping timeout: 265 seconds)
16:00:38*untitaker quit (Ping timeout: 240 seconds)
16:01:41*BitPuffin quit (Ping timeout: 250 seconds)
16:06:07*untitaker joined #nimrod
16:07:48*BitPuffin joined #nimrod
16:10:49*Jehan_ joined #nimrod
16:11:59*DAddYE joined #nimrod
16:28:47*DAddYE quit (Remote host closed the connection)
16:32:23*DAddYE joined #nimrod
16:49:32*BitPuffin quit (Ping timeout: 276 seconds)
16:51:52*Matthias247 joined #nimrod
17:02:08*BitPuffin joined #nimrod
17:02:36*superfunc joined #nimrod
17:02:57superfuncDoes the standard library use GC?
17:03:34dom96yes
17:04:57superfuncthanks dom
17:06:40*brson joined #nimrod
17:11:14superfuncDo you think it hurts the language's viability as a systems language?
17:14:39EXetoCit shouldn't. the language allows it to be disabled at both run-time and compile-time. the standard library might end up being allocation-agnostic some time in the future
17:14:51EXetoCbut some people have a narrow-minded view of garbage collection
17:14:57superfuncI agree
17:15:09superfuncI think the "It is GC
17:15:17superfuncd so lets ignore it for sys prog
17:15:23superfuncis ridiculous.
17:17:05EXetoCyup. we have a pretty performant GC already AFAIK
17:17:18EXetoCseveral in fact, one of which is a realtime GC
17:18:55*DAddYE_ joined #nimrod
17:19:04superfuncpeople complain about D for a similar reason IIRC
17:19:26superfuncThe only real way to combat that, is to write high performance programs in it, which I hope to complete this summer
17:19:56EXetoCD seems to have a pretty bad GC though, but they have made the standard library less dependent on it over the years
17:22:45*DAddYE quit (Ping timeout: 252 seconds)
17:36:25*q66 joined #nimrod
17:36:25*q66 quit (Changing host)
17:36:25*q66 joined #nimrod
17:39:30OrionPKanyone know if the nimrod-code/sdl2 lib supports joystick/gamepads?
17:39:52*Mat3 joined #nimrod
17:39:58Mat3good afternoon
17:40:47OrionPKah nm, looks like you pass it in w/ init
17:41:54superfunc nice, I just started playing with SDL2 port recently
17:42:08superfuncwill probably be writing some useful high level wrappers as I work on my project
17:57:25Araqsuperfunc: D's design is very hostile to any efficient GC implementation though. Nimrod is in a completely different league here.
17:58:51EXetoCdom96: so it works so far, though I'm only doing basic things like I said. I wonder how debuggable it is when exceptions are raised though
17:59:16EXetoCI found something practical to use it for. I'm writing an interface for the mongodb wire protocol rather than using an existing API
17:59:37dom96I think stack traces could use some improvement.
18:00:17superfuncAraq: Thanks. I assumed this was the case.
18:00:36dom96And there is still that restriction that you cannot catch exceptions inside the async procs.
18:01:24EXetoCwe don't have anything for binary serialization I think, so maybe I can work on that too
18:01:39EXetoCa pluggable marshal.nim has come up before. maybe I should look into that
18:03:03dom96Araq: How should async be parallelized?
18:04:22EXetoCand then somehow add support for endianness
18:07:12*njoejoe joined #nimrod
18:07:44Araqdom96: dunno, you only need a simple load balancer
18:08:04dom96Araq: I need to share the dispatcher between threads on Windows.
18:08:19dom96shared refs would be very helpful
18:08:26AraqI know :P
18:08:35Araqbut we won't get them anytime soon
18:09:17dom96how should I allocate the ref then?
18:09:32*Demos joined #nimrod
18:09:56Araqdepends, I need to see the code
18:16:03njoejoedom96: are you working on making jester async? I will gladly help testing it. btw, I ran into a nice little article on control flow and async with node.js: http://book.mixu.net/node/ch7.html
18:17:17dom96njoejoe: Not currently. Thinking of writing an article on my blog about how the new async stuff works.
18:18:24njoejoei'll be first in line to read it :-)
18:21:34EXetoCdom96: when does it become more complicated to poll the state of the future in a loop? possibly with just a simple generic proc shortcut
18:22:17*springbok quit (Ping timeout: 252 seconds)
18:23:44dom96EXetoC: Futures have a callback field, it would be easier to use that and likely more efficient too.
18:24:05dom96But then you have "callback hell".
18:26:19dom96What you have in mind (if I understand it correctly) would go around the callback hell, but you would block the current thread waiting for the future to finish.
18:26:23Araqdom96: how do you know it needs to be shared?
18:27:42EXetoCdom96: I was only using the other fields before
18:28:20EXetoCbut then you need to manage arbitrary instances of PFuture
18:28:32dom96Araq: http://www.drdobbs.com/cpp/multithreaded-asynchronous-io-io-comple/201202921?pgno=1
18:29:17EXetoC*variations
18:52:02renesacAraq, you basically need a faster tree thing for the interior pointer search, right?
18:52:12renesachave you looked at b+trees in memory?
18:53:16Araqas I said, no I haven't
18:53:52renesacI've been wanting to write one, but haven't got around doing that
18:54:06renesacmostly for fun though...
18:55:06AraqI think the fastest is a sorted array
18:55:13Araq*fastest way
18:56:00renesacand as for the GC performance, if you get unique/borroed pointers working, the compiler can optimize a lot of code to elide the GC
18:58:04Araqwell escape analysis is not that hard
18:58:41*gsingh93 joined #nimrod
18:59:01Jehan_Unique/borrowed pointers do add a lot of complexity and hurt reusability, though.
18:59:07renesacAND it becomes a big selling point against rust (but they will probably come saying that nimrod analysis isn't as advanced as rust's, or something)
19:00:24Jehan_It depends on who you ask. The cost of obsessively avoiding GC is a price that I am generally not willing to pay, for example.
19:01:04renesacJehan_, the idea is that it would enable transparent optimization by nimrod compiler
19:01:43Demosrust just looks /really/ complex, and once you start doing things where memory management is actually hard the unique/borrowed pointers become really difficult to use
19:01:48Matthias247yes, the compiler could detect for temporaries that a unique pointer is sufficient. Or even a stack allocation
19:01:55Jehan_I know. The problem is that it's not free.
19:02:38renesacit would be like using the GC (deffered referencing counting), but the compiler can totaly ignore counting the references behind your back if it can prove correctness of borrowing/transfering ownership
19:02:39Jehan_The major benefit of having automatic memory management is that you don't have to clutter APIs with assumptions about memory management, ownership, etc.
19:03:08Demosdo you even always want unique pointers for temporaries? with a GC you could better batch the free operation... Not sure though
19:03:12renesacif it can't, then you have today's performance
19:03:19Jehan_Rust pretty much destroys this. Mind you, they have good reasons for the tradeoff they're making, but it's a tradeoff that I am not interested in.
19:04:55renesacI'm proposing a new tradeof: where you are not sure if you are using the gc or not
19:05:11renesacbut you work as if you were using it
19:07:54Jehan_I honestly am not clear why people are so concerned about avoiding garbage collection. The application domains where it matters (and you still need automated memory management) are far and few between.
19:08:04Jehan_s/clear/sure/
19:08:40renesacpeople are usually traumatized by the random collecting pauses
19:08:45renesacand higher memory usage
19:08:58*Mat3 quit (Ping timeout: 240 seconds)
19:09:27Jehan_That's because people haven't seen a lot of decent GC implementations.
19:09:28renesacboth of which nimrod GC seems to reasonably avoid
19:09:38Jehan_Nobody has ever worried about pauses in OCaml, for example.
19:10:15Jehan_Which uses a generational minor collector with a bump allocator and an incremental major collector.
19:10:38renesacdo we have some benchmark that taxes the GC implemented in nimrod?
19:11:06Jehan_The reason why Java etc. are having problems is that they have to work with multiple threads on a huge shared heap, which is a much harder problem than single threaded GC.
19:11:23DemosThe other thing is that the big GC'd languages allocate everything on the heap just because they can
19:11:57Jehan_Well, Java also doesn't have value types, which is a huge problem.
19:12:12Demostrue, but even C# programs tend to use the heap a whole lot
19:12:18Jehan_1000x1000 matrix of complex numbers in Java => GC nightmare.
19:12:33Jehan_And honestly, for most applications it doesn't matter.
19:12:44Demosand then half the point of dynlangs is to have everything be the same size, so you need a lot of heap allocation there as well
19:12:58Jehan_I mean, Github can use Ruby on Rails without performance problems.
19:13:13Araqcitation needed :P
19:13:28AraqI bet they use many more servers than they need to
19:14:14Jehan_Oh, probably.
19:14:45Jehan_But the thing is, they're probably sacrificing an order of magnitude or two of performance and still manage.
19:15:14Demosnot having a GC is good for when you need to be a foundational library with a very clean ABI. But I dont think rust is really aiming for that either, since lending across languages is gunna be a bad time
19:15:23Demoss/clean/clear
19:15:47Araqthe bigger problem is that Ruby's inefficiency doesn't buy you anything, IMHO
19:16:33AraqIME dynamic typing simply is not productive
19:16:40Jehan_Incidentally, Erlang has a pretty neat trick here. Start a new process (which is actually a light-weight thread) for a temporary computation, never garbage collect, then throw the entire heap of the process away.
19:17:54Jehan_You can even use a special allocator for that situation that just increments the end of storage pointer. Its sort of like a poor man's region system.
19:17:58DemosI think dynamic types are appealing since it means all your functions are generic and you can have heterogeneous lists and stuff
19:18:20Demoswell "generic"
19:18:29renesacit is also much easier to get started
19:19:05Demosthere is a case to be made for dynamic types with run-time type checking annotations
19:19:14Demoskinda like nimrod's typeclasses but at runtime
19:19:48DemosI think pyret does that
19:20:19Jehan_I think the reason why dynamic languages are popular is that (1) they're easier to learn for non-computer scientists and because (2) historically, type systems of mainstream languages have been very inexpressive.
19:20:46Jehan_When until 2004 or so you had to use typecasts in Java all over the place, people reasonably wondered why not just use Python or Ruby anyway.
19:20:53Araqand (3) they are dead simple to implement
19:21:09renesacyeah
19:21:11Araqpeople tend to ignore this fact ;-)
19:21:30Jehan_Oh, yeah. But generally at the price of performance. Writing an efficient compiler for a dynamically typed language is not easy.
19:21:59Jehan_People like Mike Pall or Gilad Bracha do not grow on trees, alas.
19:22:10renesacJehan_, that problem comes only after many years
19:22:28Jehan_Which problem?
19:22:32renesacwhen the language is actually starting to get used in big projects, or cientific computation like python
19:22:46renesacworring about the interpreter performance
19:23:23renesacone don't makes a new dynamic language thinking on performance (except if you are a Julia dev)
19:23:24Jehan_I had that problem back in the 1990s using Python. :)
19:24:03renesacyou just want to make a new nice and simple language
19:25:18Jehan_I'm not sure about that. Back when many of the popular interpreted languages were invented, their performance was actually a fairly big concern.
19:25:47Jehan_I know that the Lua people spent quite a bit of effort on optimizing their VM.
19:27:21Jehan_And I know that Python performance was a concern in the 1990s, too (because I talked to Guido van Rossum about it).
19:27:27renesacFrom the start, Lua was designed to be simple, small,
19:27:27renesacportable, fast, and easily embedded into applications
19:27:34Araqone good argument against dynamic languages is how well JITs work on them :P
19:27:58Araqpeople can't cope with dynamic languages, they write mostly static programs anyway
19:28:34Araqotherwise JITs wouldn't be as effective as they are
19:29:06renesacif writing generic programs in static languages was so simple...
19:29:09Jehan_That argument doesn't really apply to tracing?
19:29:11renesacof course, it is changing now
19:29:40njoejoeas a ruby guy, i have to say that "easy to use" is #1. But concurrency is a big problem in ruby which is why I'm looking at nimrod. I have high hopes that dom96 can make an easy to use async jester.
19:29:40Jehan_renesac: What I said above about inexpressive type systems in mainstream languages.
19:29:48renesacbut any typesystem will allow only a subset of correct programs
19:29:55renesacyeah
19:29:57Jehan_At least Go is now getting pushback for not having parametric polymorphism.
19:30:58AraqJehan_: I'm not even sure that argument applies at all :-)
19:31:04Araqbut it's an interesting thought
19:31:34Jehan_An example of something that's still difficult to do in a typesafe fashion: The stack that YACC uses.
19:32:47Matthias247I think the c++ way of using templates is a mess. However I think not having generics at all like Go is also not helpful
19:32:56Araqrenesac: the "subset of valid programs" is a feature, not a problem
19:33:39Jehan_C++ templates aren't a mess per se, it's just how they need to interact with the rest of a fairly complex language that makes them hard.
19:33:55renesacAraq, still, it may be a burden to get things running fast (but yes, you have much more help from the compiler)
19:34:05DemosC++'s templates are actually pretty sane, they can interact badly with other stuff and the syntax is utterly painful
19:34:30renesacC++ template programming was discovered, not designed
19:34:31Matthias247the understandability of the code is ...
19:34:32renesac:P
19:34:36Matthias247and the error messages :)
19:34:51AraqI believe in the principle of least power. Btw that's also why using recursion for iteration is wrong, IMHO.
19:34:51Jehan_renesac: I'm also not concerned that once in a blue moon I may have to subvert the typesystem, as long as I don't have to do it all the time.
19:34:53Matthias247renesac: yes, that's it
19:35:18Matthias247if I see something like std::enable_if< if stop reading
19:35:18Jehan_The covariance problems of Eiffel's generic types never bothered me, because you rarely encountered them in practice.
19:35:51Araqha, to me they suggest that inheritance is deeply flawed no matter how you look at it.
19:37:05Jehan_Doesn't have anything to do with inheritance per se, it's just that the combination of parametric polymorphism and subtyping polymorphism leads to weird problems.
19:37:18*Matthias247 still hopes for concepts coming for the rescue :)
19:37:37Matthias247Nimrod and C# already do the right things there
19:37:43Jehan_For example, F-bounded polymorphism is a solution, it just weirds out non-type-theorists. :0
19:37:55Araqif I have A <: B and then neither array[A] <: array[B] nor array[B] <: array[A], that means it's a worthless relation. And this is the case for value based datatypes.
19:38:39renesachttp://okmij.org/ftp/Computation/Subtyping/ <-- for more brokenness regarding inheritance
19:38:46AraqAnd no amount of type theory can patch over that.
19:39:25Demosit seems nimrod's typeclasses can get you 90% of the way there
19:40:01Demosnot actually sure how F-bounded polymorphism is different... But I have not used a langauge with it in a long time
19:40:32*brson quit (Ping timeout: 246 seconds)
19:41:36Araqand indeed subtyping mostly works for references/pointers and so most languages don't have value based objects
19:43:22DemosI think parametric polymorphism is often simpler to understand than subtype in any case, probably eaiser to use correctly as well
19:43:40Jehan_Araq: Not sure why it's necessary for A <:B to have F[A] <: F[B] (or the inverse).
19:44:07Jehan_Not every function is a homomorphism.
19:45:06Araqit's an academic argument I guess, but <: doesn't compose well.
19:45:57Jehan_Neither do a lot of important concurrency mechanisms, e.g. transactions.
19:46:11Jehan_Composition is desirable, but not always attainable.
19:46:39Jehan_Composability*
19:48:31Araqwell it doesn't compose well and is quite complex at the same time without giving you much. Concurrency mechanisms on the other hand are at least immediately useful.
19:48:55Araqbut ymmv of course
19:49:13Jehan_Yeah. I think this is something where one can easily agree to disagree. :)
19:57:48*brson joined #nimrod
19:57:48Jehan_By the way, if anybody is interested: http://codegolf.stackexchange.com/questions/26371/how-slow-is-python-really-part-ii
19:58:43Jehan_I have a roughly 80x speedup in Nimrod without much effort (and without tricks or parallelizing code).
20:05:42*Jesin quit (Quit: Leaving)
20:16:53*gsingh93 quit (Ping timeout: 276 seconds)
20:18:00*menscrem quit (Quit: Page closed)
20:21:09*gsingh93 joined #nimrod
20:22:55Matthias247C# 0.135s <-- congrats to all the guys wo are only measuring the startup times of VMs ;)
20:25:12*shodan45 joined #nimrod
20:33:33EXetoC-.-
20:33:44EXetoCthe most important metric of course
20:34:43njoejoeJehan_: are you going to post your solution on there?
20:35:06Jehan_Nah, it's not good enough to be competitive without further iterations.
20:35:51njoejoei think 80x is pretty good! :-)
20:41:20dom96Not in comparison to C++'s 508x :O
20:42:55Jehan_dom96: That has nothing to do with C++ and with the implementation using bit strings rather than vectors.
20:42:59Jehan_https://gist.github.com/rbehrends/113d2759d36a1e7bb6c8
20:43:15Jehan_If I went the bitstring route, I could probably squeeze out similar performance.
20:43:43Jehan_In the end, Nimrod compiles to C in a way that is essentially like native C for anything that doesn't require memory management.
21:04:06dom96Jehan_: Oh yeah, I know. I'm not sure others would see it that way though.
21:04:49Jehan_dom96: Probably. Most of these benchmark games aren't apple to apple comparisons, anyway.
21:06:48dom96Jehan_: Although maybe it would be worth submitting it anyway, even if to advertise Nimrod a little bit.
21:08:08Jehan_Not sure it's worth it. Too limited an audience. I think what Nimrod really needs for advertising is the infamous killer app/lib.
21:08:59Jehan_The only nice part about my code is that I don't actually shy away from using a solid RNG rather than one with dubious properties for speed.
21:09:18Jehan_I still get decent speed because I milk most of the bits out of each invocation.
21:10:13njoejoeJehan_: yes, and I think that killer app/lib is jester with async so easy the programmer doesn't have to think about it
21:11:02Jehan_Does it beat the alternatives? Genuine question, I don't have the first clue about web apps.
21:13:54Matthias247depends. There are fast web frameworks out there. But most people like the really slow ones (php, ruby, python based) ;)
21:14:18njoejoejester as it is now is very easy to use and very fast compared to alternatives, but it needs async (and maybe websocket dsl).
21:14:37Jehan_ASP.NET?
21:15:14Jehan_Again, don't know it, but would think it should be fast and have async support.
21:15:42dom96Jehan_: What was Python's killer app/lib?
21:15:55Matthias247don't know about current state of asp but .net in generel is capable of a quite good performance
21:16:06Jehan_dom96: Waiting a couple of decades for adoption? :)
21:16:21dom96heh
21:16:22Jehan_Python's selling point was always that it was simple, clean, easy to teach.
21:16:37Jehan_Once computers became powerful enough for interpreted languages, it became attractive.
21:17:52*Jesin joined #nimrod
21:18:00njoejoeI have no experience with ASP.NET but I highly doubt it is as nice to use and succinct as jester
21:18:39dom96The biggest problem with ASP.NET IMO is that it's not cross platform.
21:18:44dom96Mono doesn't really count.
21:18:56Jehan_Why doesn't Mono count?
21:20:29dom96Because it's always behind the Microsoft implementation and it also far slower as far as I know.
21:21:07Jehan_It is still plenty fast. Source: I use Mono on and off.
21:21:34Jehan_My main problem with Mono is that IF I run into a bug in the JIT compiler, it's extremely hard to deal with.
21:21:48*superfunc quit (Ping timeout: 240 seconds)
21:21:52Jehan_That's incidentally why I'm using Nimrod, even though it's rough around the edges still.
21:22:11Jehan_The implementation is simple enough that I can easily fix bugs myself if needed.
21:22:20DemosI thought python's killer feature was really good tools for doing library bindings
21:22:30Matthias247I also tried one of my c# apps on linux with mono and it really run straightforward without problems. Was really suriprised
21:22:36Jehan_When whining to Araq about them doesn't help. :)
21:22:49Matthias247and a colleague is even using mono for doing cross-plattform mobile apps with xamarin
21:23:22Jehan_And yeah, Mono is slower than Microsoft's implementation, but unless you're into high performance stuff, not really enough for it to matter.
21:23:28dom96Perhaps I should reevaluate my stance on Mono.
21:23:40Jehan_And you do get some pretty comprehensive batteries as part of the deal.
21:24:43Matthias247that's the nicesting thing. there's probably no better standard library than the .net one
21:24:46Demoshttps://onedrive.live.com/redir?resid=BE38BDD0FF029113!20910&authkey=!AIpV1BaS3wgpM_Y&v=3&ithint=photo%2c.PNG
21:24:54DemosI did not even have to do anything to get that working!
21:26:28Jehan_The big problem with Mono, as I said, is if you run into a bug.
21:26:54Jehan_Not that it happens often, but if you do, you're kinda dependent on Xamarin to get it fixed.
21:27:17dom96Demos: Visual Studio supports C debugging? :O
21:27:33Demosnote that that was a nimrod source file!
21:27:42Demoswith the correct line numbers
21:27:47Jehan_The same goes in theory for the JVM, but Java has such a huge userbase that this problem is exceedingly rare.
21:28:03Matthias247Jehan_: I even found one in microsofts implementation of the .net library :) Which didn't get fixed :(
21:28:35njoejoeDemos: what's that? breakpoints and watches of nimrod code? holy cow, that's amazing. do i have to run windows to get that?
21:28:44Jehan_But in general I'm very cautious of languages that depend on JIT compilers, even if they are attractive.
21:29:07Demoswell not really, but gdb is not that fun to use
21:29:09Jehan_Trying to debug the code generation of a JIT compiler unless you're extremely familiar with it can be … painful.
21:29:21Demosjust compile with --debuginfo --linedir:on and some stuff may work
21:29:44Demosit does not break on exceptions
21:29:47Demoswhich I think I can gix
21:29:49Demos*fix
21:30:00Demoswhere do we put compiler intrinsics in the standard lib?
21:30:51EXetoCoh, GDB debug information
21:30:51OrionPKDemos whattttt is that picture
21:31:19Demosthat is me after attaching visual studio's debugger to a nimrod program
21:31:33OrionPK:D
21:31:34Demosbeing suprised that stuff works as well as it does
21:31:36OrionPKawesome
21:31:42OrionPKwhere's the syntax highlighting? :P
21:31:52Demosnot installed.....
21:32:17*[1]Endy quit (Ping timeout: 276 seconds)
21:32:39Demosthere is a syntax highlighting plugin on my github but it is much too complex. I tried to get the nimrod compiler to do the highlighting, which works but I think a regex would have been a better plan
21:33:00AraqI still think we should clearly say "ENDB is not maintained anymore and .injectStmt is superior anyway"
21:33:13*gsingh93_ joined #nimrod
21:33:35Jehan_It isn't?
21:33:47Araqwell barely
21:34:00dom96what is injectStmt and why is it better?
21:34:01DemosI tried this because endb failed to work
21:34:14Demoswhere would I put code to emit an intrinsic on unhandled exceptions
21:34:26Jehan_Not sure that injectStmt is really an adequate alternative. :)
21:34:53Demoswell debugInfo, injectStmt, lineDir, and genMapping should do it
21:36:12*gsingh93 quit (Ping timeout: 245 seconds)
21:36:59Jehan_Just with 90% less usability. :)
21:37:11AraqJehan_: oh but it is. use the new -d:corruption, get the ID of the corrupted object, injectStmt some check and see where it's overwritten
21:38:06Jehan_Well, if I need a debugger, I generally need more than just some information about the state of the program when it crashed.
21:38:30Jehan_E.g., I may need to single step through a routine to see if it actually does what I think it does.
21:38:39DemosJehan_: which you can do
21:38:47Demosas demonstrated by that screenshot
21:39:14dom96endb is/was much better
21:39:39Jehan_And inspect non-trivial data structures without lot of painfully complex GDB commands?
21:39:51Araqwell my debugging has changed I think
21:40:01Demosspeaking of, genmapping is broken
21:40:06Jehan_Mind you, I rarely need that in Nimrod.
21:40:08dom96Araq: Most people don't debug corruptions.
21:40:10Demosuses the old style c file names
21:40:23AraqI used to use breakpoints, now I don't. I only need watchpoints.
21:40:29Jehan_Usually, once I have the stacktrace of a bug, it's obvious where I screwed up.
21:40:36Demoswait no it does not
21:40:42Araqand traditional debuggers suck at watchpoints
21:41:20OrionPKsomeone should write a blog post demonstrating how inject stmt is superior
21:41:57Jehan_Speaking of potentially unsupported features, how experimental exactly is --symbolfiles:on?
21:42:14Araqit used to work and then zahary broke it and never fixed it
21:42:37Jehan_Ouch, that's too bad.
21:42:43Araqspent 2 weeks implementing it and compile times were non existant anymore
21:42:59Jehan_Nimrod really does slow down once you get beyond a couple hundred KLOC.
21:43:16*springbok joined #nimrod
21:43:37Jehan_Yup, it was pretty amazing when I tried it (in 0.9.2, I think).
21:46:15dom96damn. It seems my buffered recv implementation is incorrect.
21:48:33dom96Araq: We need to figure out how to deal with exceptions in async code.
21:49:02Jehan_What are you doing right now?
21:49:18DemosOo {.emit: "__debugbreak();".}
21:49:28Araqlast time I thought about it, it's not that hard to do with the C backend and impossible with the C++ backend ...
21:49:37Demosnow I just need to figure how to unmangle the variable names
21:49:56Araqlocals are not mangled if the compiler can avoid it, Demos
21:50:03Demosthe usual thing to do is kill the entire process if an exception were to go across threads
21:50:09dom96I think I figured out a way of transforming a try stmt inside an async proc into something which handles the error correctly without having to generate a second try stmt
21:50:27AraqI think that's not even possible
21:50:32Demosyeah, I noticed, but they are still a bit funny
21:50:55dom96Jehan_: The try statement is currently unsupported in async procs because you cannot have a yield inside of a try statement in closure iterators.
21:51:04Demosand having the callstack display nimrod style decls would be nice
21:51:19dom96Interestingly C# only recently started supporting exceptions in async procs too
21:51:31AraqDemos: just use writeStackTrace() at strategic places
21:52:20Jehan_Araq: Does the compiler get tripped up by local names like linux?
21:52:34Demosyeah, I dont really want to parse that and then figure how to get VS to find it
21:52:52Jehan_dom96: Gotcha.
21:52:59dom96Araq: Would a single try statement be the end of the world?
21:53:03AraqJehan_: not sure what you mean
21:53:41Jehan_Some C compilers on Linux have -Dlinux= by default. Solaris has something similar.
21:54:08Araqdom96: no, go ahead please
21:55:32AraqJehan_: oh yeah the preprocessor is bad for the non-mangled names we generate
21:55:57*gsingh93- joined #nimrod
22:02:44*brson quit (Quit: leaving)
22:03:32*springbok quit (Changing host)
22:03:32*springbok joined #nimrod
22:34:32*Skrylar joined #nimrod
22:41:08*gsingh93_ quit (Ping timeout: 246 seconds)
22:41:14Matthias247dom96: they had exception support for async/await all the time. What is new is that you can now also await in catch blocks - but I think there aren't too many use cases for that
22:42:10*gsingh93 joined #nimrod
22:43:13*gsingh93_ joined #nimrod
22:44:48dom96Matthias247: were you able to await inside of a 'try' previously?
22:45:05*xenagi joined #nimrod
22:45:59Matthias247dom96: yes. I think that is the basic requirement. To fetch the optional exception value returned by a Task
22:46:45Matthias247if the task returns a value then await normally finishes. If it returns an exception then await throws and it jumps in the associated catch block
22:46:52AraqMatthias247: interesting. I tried it in visual studio and the compiler prevented it. I must have been mistaken.
22:47:55Matthias247I'll try again :)
22:51:36*gsingh93- quit (Remote host closed the connection)
22:53:12Matthias247Araq, dom96: works just as expected: http://pastebin.com/SqSht0xc
22:53:33*gsingh93- joined #nimrod
22:54:13AraqMatthias247: for c# 4.0 ?
22:54:29Matthias247Araq: 4.5 is required for async/await
22:55:16Araqoh yeah, right
22:56:00*meguli_ joined #nimrod
22:57:13Skrylarmeep
22:57:55Matthias247however I'm not sure if I find async/await a good thing. I worry about most people won't recognize that the state after the await can be totally mutated because any amount of other code runs in between - even on the same thread
22:58:58*meguli__ joined #nimrod
23:00:18*meguli_ quit (Ping timeout: 240 seconds)
23:04:08*meguli__ quit (Quit: Page closed)
23:05:55Jehan_Matthias247: That's a general question of dealing with/avoiding race conditions on shared memory.
23:07:18Matthias247Jehan_: the funny thing is that these are not the classical memory race conditions that you have with real multithreading. It's just an asynchronicity that you don't expect
23:08:36Jehan_Underneath, it's still a data race.
23:08:47Jehan_Well, to me at least it's a distinction without a difference.
23:09:01Matthias247if you have a pure callback based API then the users expect that the callback is invoked at some other time and things can happen in between
23:09:16Matthias247but that has other issues
23:09:22*darkf joined #nimrod
23:10:18*shodan45 quit (Quit: Konversation terminated!)
23:24:19*q66 quit (Quit: Leaving)
23:32:24*Jesin quit (Quit: Leaving)
23:35:28VarriountMeep
23:37:17EXetoCbeep
23:42:39*superfunc joined #nimrod
23:46:29VarriountSolution to all multi-threading related problems - Don't use multiple threads
23:48:04EXetoCKISS
23:49:18*superfunc quit (Ping timeout: 240 seconds)