01:48 ilbot3 joined 02:06 nebuchadnezzar joined 05:39 domidumont joined 05:44 domidumont joined 06:08 domidumont joined 06:12 rurban_ joined 07:29 zakharyas joined 07:51 Ven joined 08:37 Ven joined 09:07 Ven joined
jnthn moarning o/ 09:13
nwc10 good *, jnthn 09:14
konobi jnthn: saw something kinda cool that might be a useful tool for you... 09:15
www.joyent.com/blog/550-regression...yent-manta
jnthn Ooh, good to know about. Thanks :-) 09:18
09:58 zakharyas joined
dalek arVM: e21ef82 | jnthn++ | src/spesh/inline.c:
Inlining fix for lexical-caller exception throw.
10:26
arVM: 085c698 | jnthn++ | src/core/op (2 files):
Make throwpayloadlex as :noinline.

Since it needs its lexical chain to be in shape, like various other things that do lexical lookup. (We'll be able to be smarter in the future.)
jnthn Ouch, inlining and lexical handlers is...brainache 10:54
I might have to be smarter in the now to actually make this work at all :)
11:02 cognominal joined
jnthn lunch & 11:03
Damn, didn't magically realize an answer during lunch... 11:58
nwc10 have lunch again? 11:59
konobi jnthn: also... terralang.org is worth having a look at. interesting way to interleave JIT/Native 12:00
jnthn As in, JITting the C call directly into the machine code produced from the calling language? 12:03
konobi mmm... not entirely sure... it's kinda unique 12:06
jnthn Turns out it's not quite as bad as I expected because of things we can't inline yet :) 12:32
So it seems there's an easy enough solution for now
dalek arVM: 1185cab | jnthn++ | src/ (4 files):
Fix inlining causing wrong lexical handler lookup.

When we inline, then the inlinee's handlers should not be assumed to be relevant during lexical handler resolution. Note that this only holds up because we can't inline things we've closure-captured yet; once that can happen we'll need something smarter than this.
12:38
jnthn Now I'm down to an error reporting regression, and one test showing a real issue that may well be in Rakudo 12:40
It looks oddly like the problem I ran into when trying to make return a sub in Rakudo 12:41
m: constant $x = "µ @"; sub circumfix:<<$x>>($) { 42 } 12:45
camelia ( no output )
nwc10 j: constant $x = "µ @"; sub circumfix:<<$x>>($) { 42 } 12:52
camelia rakudo-jvm 40a953: OUTPUT«cannot connect to eval server: Connection refused␤»
nwc10 OK. Was curious.
jnthn It somehow explodes with "colon pair too complex" now 12:53
12:59 cognominal joined
nwc10 fails to make any sort of Unicode pun here as he can't figure out any character smaller than a period, and that's not really small enough for a joke to work 13:05
jnthn Somehow we're getting a control exception escaping and being caught. 13:09
nwc10 valgrind time? 13:10
jnthn Doubt it.
I mean, I can try but I'd be surprised if it's that kind of bug, from the symptoms so far.
Hm, and it's a return control exception...huh 13:13
oh, lol 13:14
timotimo somehow a return handler failed to get installed? or inlined? or something?
jnthn No 13:15
There was a CONTROL block
Inside the thing doing a return
Inside a sub doing return, sorry
And since return is now a proper control exception, as per spec, it now gets that in the CONTROL block 13:16
However, it was assuming that any control exception was probably a warning
timotimo :D
nwc10 this sounds like bloggage fodder
(Although the explanation here made sense with that last line, at least to me)
itneresting stuff
jnthn It'll be harder to accidentally do this in Perl 6 'cus, unlike in NQP, you have to actually match on the exception 13:18
Anyways, that nicely fixes another failing test
timotimo ah, OK 13:20
jnthn Unfortunately, I suspect this won't on its own be enough to fix the "turning return into a sub breaks things" bug 13:22
Indeed. 13:25
13:49 dalek joined 13:51 brrt joined 14:00 zakharyas joined
jnthn Think I've figured out that bug too though :) 14:01
timotimo waycool
jnthn Now spectesting with return as a sub
Then will break it out into multis and try that
Then will need to unbreak throwing the typed exception on return outside of routine 14:02
timotimo uh oh. i edited things via the vboxsf and the modes got changed on some of the files 14:06
... wrong channel
nwc10 and then will cook curry? 14:20
(do not delay curry if bug remains unsolved after sundown)
jnthn Not curry today :) 14:22
Probably not for a bit, in fact...though other spicy things soon :) 14:23
14:49 pyrimidine joined
diakopter TimToady: just rename the language MONKEY 14:52
14:54 brrt joined
diakopter [re: two days' ago HEY-HEY-WE'RE-THE-MONKEYS 14:54
] 14:55
[also, nobody said anything here yesterday o_O]
arnsholt nwc10: It's worth noting that sundown in Scandinavia these days is around 11 at night, so I do hope he has dinner a bit before that =)
jnthn m: say 7717886906 / 14223339978 14:56
camelia rakudo-moar 2bd421: OUTPUT«0.5426212773␤»
diakopter hopes that's a speedup calc
jnthn Yeah. `sub foo($a) { if $a { return 1 } }; for ^2000000 { foo(1) }` now runs in nearly half the CPU cycles it used to. 14:57
And still plenty of room for improvement yet. 14:58
diakopter such impredicativity might be proven by a smart someting or over
japhb Holy shazbot. That's amazing, jnthn!
timotimo to be fair, return was slow AF before :) 15:06
so it's likely still comparatively slow
like, compared to without return
jnthn The non-return case is faster now also, fwiw :) 15:10
japhb Oh, excellent 15:13
jnthn 'cus it's just using an exception handler (static) rather than setting up a lexotic
timotimo yays! 15:18
jnthn At some point I'd also like to teach the exception throwing optimizations in spesh to turn this into a set and goto in cases where it's possible. 15:20
But we'll need to move that opt after inlining then, which will probably end up needing to be part of a larger shuffling around.
timotimo sounds sensible, yeah
dalek arVM: dc3b64a | jnthn++ | src/core/exceptions.c:
A little cleanup and simplification.

Also paves the way for being able to properly differentiate between a return outside of any routine vs. a return from outside of an already returned routine.
15:22
jnthn Time for a break :) 15:26
15:28 rurban_ joined
japhb m: say 7717886906 / 2000000 # Cycles per iteration in jnthn's return microbenchmark 15:45
camelia rakudo-moar 2bd421: OUTPUT«3858.943453␤»
timotimo that's a lot still 15:47
i wonder how many cycles we burn just from compiling that piece of code without running it 15:48
16:50 Ven joined 16:56 flaviusb joined
[Coke] nwc10: any issues with the spaceybuild branch for you? 17:14
17:32 FROGGS joined 17:34 zakharyas joined 18:18 tomboy64 joined 18:46 FROGGS joined 19:07 FROGGS joined 19:08 cognominal joined 19:15 FROGGS joined 19:21 Ven joined 19:56 brrt joined 20:59 zakharyas joined 21:02 rurban_ joined 21:17 cognominal joined