Perl 6 - the future is here, just unevenly distributed

IRC log for #moarvm, 2014-08-30

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:16 cognome_ joined #moarvm
01:10 FROGGS_ joined #moarvm
01:20 colomon_ joined #moarvm
01:22 sergot joined #moarvm
01:24 lizmat_ joined #moarvm
01:50 colomon joined #moarvm
01:50 pmichaud joined #moarvm
01:50 tadzik joined #moarvm
05:09 jnthn TimToady: The exception object constructed by MVM_exception_throw_adhoc does track the soruce of the exception; if something isn't printing the backtrace, then it's a problem higher up...
05:16 JimmyZ joined #moarvm
05:17 JimmyZ good afternoon, jnthn :)
05:20 jnthn JimmyZ \o/
05:21 jnthn JimmyZ: In answer to your question from a couple of days ago: I'm in Shenzhen.
05:21 jnthn JimmyZ: I think that's your part of the world too? :)
05:22 * TimToady thought JimmyZ was somewhere near Beijing
05:23 JimmyZ yeah, I had been in Shenzhen for about 7 years, just leave there 4 months ago :P
05:24 jnthn Bah...when I was in Beijing you were in Shenzhen :P
05:26 * JimmyZ never went to beijing
05:27 jnthn Given the air quality I encountered there, that's probaably a good thing for your life expectancy ;)
05:28 JimmyZ aye :P, my friends who went to beijing has got some cough for a long time :/
05:48 JimmyZ_ joined #moarvm
05:51 JimmyZ joined #moarvm
06:56 itz joined #moarvm
07:13 mj41 joined #moarvm
08:13 JimmyZ_ joined #moarvm
08:20 FROGGS I wonder why that happens:
08:20 FROGGS Program received signal SIGBUS, Bus error.
08:20 FROGGS MVM_bigint_neg at src/math/bigintops.c:382
08:20 FROGGS 382MVM_BIGINT_UNARY_OP(neg, { sb = -sa; })
08:22 jnthn Does it happen with JIT disabled?
08:22 * jnthn wonders if that's one of the recently JITted bigint ops...
08:23 FROGGS jnthn: jit and spesh have no influence
08:24 jnthn Hm, ok. Then I've no idea.
08:25 FROGGS 386    if (MVM_BIGINT_IS_BIG(ba)) {
08:25 FROGGS (gdb) p *ba
08:25 FROGGS Cannot access memory at address 0x18000900000009
08:26 FROGGS ahh!
08:27 FROGGS it is the typo masak++ fixed (about s/-Inf/-Int/)
08:27 FROGGS m: say -Int
08:27 camelia rakudo-moar d8c834: OUTPUT«(signal )»
08:27 jnthn oops
08:28 jnthn Missing definedness or nullness check I guess
08:28 jnthn Probably definedness
08:28 FROGGS yeah
08:35 brrt joined #moarvm
08:35 brrt \o
08:35 FROGGS o/
08:36 dalek MoarVM: 9c670c9 | (Tobias Leich)++ | src/math/bigintops.c:
08:36 dalek MoarVM: check for type object int bigint unary ops
08:36 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/9c670c9455
08:38 FROGGS m: say +Int
08:38 camelia rakudo-moar d8c834: OUTPUT«use of uninitialized value of type Int in numeric context  in block <unit> at /tmp/EA9LkXVy_y:1␤␤0␤»
08:38 FROGGS that goes through .Numeric, while -Int does not
08:39 FROGGS hmmm
08:42 FROGGS ewww
08:42 JimmyZ_ joined #moarvm
09:01 JimmyZ_ joined #moarvm
09:19 FROGGS[mobile] joined #moarvm
09:28 brrt curcode y u no work
09:29 brrt oh, it has a deref
09:29 brrt why does it have that
09:32 * brrt suspices that this was copy-and-pasted somewhere
09:48 dalek MoarVM: b7987fa | (Bart Wiegmans)++ | src/ (4 files):
09:48 dalek MoarVM: JIT getcodeobj
09:48 dalek MoarVM:
09:48 dalek MoarVM: Was actually timotimo++'s patch, I included a fix for
09:48 dalek MoarVM: curcode which derefed *tc->cur_frame->code_ref, which
09:48 dalek MoarVM: isn't necessary.
09:48 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/b7987fae4b
09:53 timotimo oops; not quite sure why i deref'd that
09:53 timotimo oh, was the incorrect jitting of curcode in the released moarvm?
09:55 timotimo ah
09:55 timotimo it wasn't
09:55 timotimo phew :)
09:58 nwc10 jnthn: http://paste.scsys.co.uk/420304 seems to be all that is needed to get NQP working on Power
09:58 nwc10 but I'm not sure what commit message
09:58 timotimo now you're playing with power!
09:58 nwc10 other than something about it's a fix for c92d1a4cd5340d787ab5f8f42348573f99738c37
09:59 timotimo nwc10: but we use an MVM_OP_const_i64_16 in there
10:00 itz_ joined #moarvm
10:00 timotimo maybe the GET_I16 macro is busted instead?
10:00 nwc10 timotimo: no, that fix is correct. Pretty confident on that. What needs to be i16 is *just* the instruction stream
10:01 nwc10 the result_facts->value isn't in the instruction stream, and I'm inferring that it's still being read by other code which is unchanged
10:01 nwc10 on little endian, it doesn't matter
10:01 timotimo oh!
10:01 timotimo that's a very good point
10:02 nwc10 on big endian, .i16 and .i64 are at different ends of the union
10:02 nwc10 did take me a while to work it out
10:03 timotimo sorry about that :(
10:03 timotimo i was the one who introduced that
10:05 nwc10 no worries. what you did does look logical
10:05 nwc10 quite possibly I would have made the same mistake
10:08 itz joined #moarvm
10:12 jnthn nwc10: Thanks, will apply it in a bit. (got some other changes locally)
11:04 JimmyZ_ joined #moarvm
11:10 dalek MoarVM: 8e5f59e | jonathan++ | / (15 files):
11:10 dalek MoarVM: Add mechanism for objects to get a persistent ID.
11:10 dalek MoarVM:
11:10 dalek MoarVM: If we move objects about over time, the object address is not a safe
11:10 dalek MoarVM: value to use as for ObjAt. Add a mechanism for objects to get an ID
11:10 dalek MoarVM: that lasts a lifetime. If the object is already in gen2, we use the
11:10 dalek MoarVM: memory address as before. If not, we pre-allocate a gen2 slot for it
11:10 dalek MoarVM: and use that.
11:10 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/8e5f59ee95
11:12 itz_ joined #moarvm
11:15 JimmyZ_ joined #moarvm
11:17 d4l3k_ joined #moarvm
11:18 __rnddim__ joined #moarvm
11:21 xiaomiao joined #moarvm
11:22 hatsefla1s joined #moarvm
11:26 gcifuent1s joined #moarvm
11:36 dalek MoarVM: a5ae111 | jonathan++ | src/gc/ (2 files):
11:36 dalek MoarVM: Ensure gen2 collect copes with ID pre-allocs.
11:36 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/a5ae111ce3
11:40 Juerd joined #moarvm
11:42 itz joined #moarvm
11:58 ilbot3 joined #moarvm
11:58 Topic for #moarvm is now https://github.com/moarvm/moarvm | IRC logs at  http://irclog.perlgeek.de/moarvm/today
12:00 moritz_ joined #moarvm
12:01 ashleyde1 joined #moarvm
12:02 tadzik2 joined #moarvm
12:02 nebuchad` joined #moarvm
12:03 gcifuent1s joined #moarvm
12:13 nine Do I have to reinstall modules after recompiling MoarVM with --debug?
12:13 JimmyZ_ joined #moarvm
12:13 jnthn Shouldn't
12:13 jnthn Provided you didn't also re-build NQP and Rakudo, of course.
12:14 nine jnthn: err...I probably did
12:15 JimmyZ__ joined #moarvm
12:17 JimmyZ joined #moarvm
12:21 JimmyZ_ joined #moarvm
12:23 tadzik3 joined #moarvm
12:27 JimmyZ_ joined #moarvm
12:32 harrow joined #moarvm
12:35 gcifuentes joined #moarvm
12:41 nine I'm kind of stuck here. My tests call a method on a Perl 6 object from Perl 5 code and it works. It then calls the method again but MoarVM explodes with "Internal error: Unwound entire stack and missed handler" at the return statement in the called method.
12:42 d4l3k_ joined #moarvm
12:42 timotimo callbacks and exceptions don't mix well, but exceptions also include things like returning
12:44 timotimo so if a callback registered from NativeCall ends up running an "inferior runloop" and an exception is thrown from there, it'll only unwind the "inferior runloop's" stack, or something like that
12:45 nine timotimo: but there shouldn't be any exception. I can run both calls indiviudally just fine. Only if I run both in the same test script it explodes. Order doesn't matter.
12:45 timotimo my understanding of the situation is just not-poor enough to pretend to know what goes wrong, but far too wrong to come up with a proper fix
12:45 itz_ joined #moarvm
12:46 timotimo the worst thing is trying to gather/take across runloops
12:47 timotimo in that case ... not sure what's going wrong
12:47 nine The method I'm calling is just: method test(*@args) { return @args; }
12:48 nine The callback is: sub (Str $name, OpaquePointer $args) returns OpaquePointer { my @retvals = $value."$name"(|self!p5_array_to_p6_array($args)); return self.p6_to_p5(@retvals); CATCH { default { say $_; } } }
12:48 timotimo the optimizer will turn that into "test(*@args) { @args }" for you
12:49 timotimo hum.
12:50 masak the design of MoarVM has learned from that of Parrot, and tries really really hard not to have inferior runloops.
12:51 itz_ joined #moarvm
12:51 JimmyZ_ does luajit and jvm have inferior runloops?
12:51 timotimo aye, nativecall callbacks is the only situation we apparently cannot get around
12:51 nine masak: do I see that correctly from the stack trace that MoarVM exits the runloop before calling into native code?
12:52 timotimo "the stack trace"?
12:52 nine timotimo: https://gist.github.com/niner/108939b4982119b146da
12:53 timotimo it looks like the stack isn't healthy
12:53 JimmyZ joined #moarvm
13:08 ilbot3 joined #moarvm
13:08 Topic for #moarvm is now https://github.com/moarvm/moarvm | IRC logs at  http://irclog.perlgeek.de/moarvm/today
13:10 timotimo i'm glad to hear that!
13:10 timotimo also non-glad you've had to spend a long time hunting that down :(
13:12 nine timotimo: nothing compared to fixing all refcounting bugs in Inline::Python back then. Turned out that refcounting was handled wrongly in nearly every place. When I fixed it in one place, it broke in another. And I head to learn two slightly different refcounting systems (Python and Perl) at the same time. Compared to that this time it's trivial :)
13:13 timotimo oh
13:13 timotimo well, that's good then :)
13:14 nine That's also the reason why I'm reluctant to add any refcnt related code unless I really _know_ that it's needed and correct.
13:18 nebuchadnezzar joined #moarvm
13:31 nebuchadnezzar joined #moarvm
13:41 BinGOs joined #moarvm
13:45 jlaire joined #moarvm
13:45 nine joined #moarvm
13:45 nwc10 joined #moarvm
13:46 JimmyZ_ joined #moarvm
13:51 masak joined #moarvm
13:57 JimmyZ_ joined #moarvm
14:16 nine Ok, until we have working destructors it just doesn't make sense to try having correct refcounts. So adding SvREFCNT_inc everywhere really is the way to go now.
14:34 dalek MoarVM: 5a0ecd6 | jimmy++ | src/ (8 files):
14:34 dalek MoarVM: add const to MVMOpInfo type
14:34 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/5a0ecd67a8
14:46 JimmyZ_ joined #moarvm
14:46 dalek MoarVM: 5c71d91 | jimmy++ | src/core/bytecodedump.c:
14:46 dalek MoarVM: slightly refactor, no functional changes
14:46 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/5c71d918ef
14:49 cxreg2 joined #moarvm
14:50 brother| joined #moarvm
14:53 tokuhirom_ joined #moarvm
14:55 oetiker joined #moarvm
14:55 rurban joined #moarvm
14:56 btyler joined #moarvm
14:56 bcode joined #moarvm
14:57 hoelzro joined #moarvm
15:25 colomon joined #moarvm
16:10 nwc10 jnthn: progress. Some combination of things, including possibly PEBKAC. Have yet to identify actual cause
16:11 kjs_ joined #moarvm
16:12 nwc10 oh, that should be on #perl6. Re-splatting
16:20 FROGGS nine: you can make copies of P5 objects when you are not sure about refcounting
16:20 FROGGS nine: because often you do not know how long something will live in P6 land
16:28 brrt joined #moarvm
16:30 dalek MoarVM: 6542d36 | jimmy++ | / (2 files):
16:30 dalek MoarVM: update update_ops.p6
16:30 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/6542d3634e
17:24 mj41 joined #moarvm
17:25 FROGGS ==1925== Invalid write of size 8
17:25 FROGGS ==1925==    at 0x4F774DD: MVM_fixed_size_alloc (fixedsizealloc.c:65)
17:35 kjs_ joined #moarvm
17:46 FROGGS[mobile] joined #moarvm
17:49 brrt left #moarvm
17:52 colomon joined #moarvm
18:13 kjs_ joined #moarvm
18:29 bcode joined #moarvm
18:51 zakharyas joined #moarvm
19:38 dalek joined #moarvm
21:22 zakharyas joined #moarvm
21:41 ggoebel1111110 joined #moarvm
22:35 danaj joined #moarvm

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary