Welcome to the main channel on the development of MoarVM, a virtual machine for NQP and Rakudo (moarvm.org). This channel is being logged for historical purposes.
Set by lizmat on 24 May 2021.
00:02 reportable6 left 00:06 reportable6 joined 00:38 evalable6 joined 02:37 linkable6 joined
timo m: my int $a = 5; sub do_it($x, $y is rw) { $a += $y }; say so do_it all(1, 2, 3, 4), $a; say $a 03:06
camelia True
80
timo m: my int $a = 5; sub do_it($x, $y is rw) { $y += 1 }; say so do_it all(1, 2, 3, 4), $a; say $a
camelia True
9
timo rw args with autothreaded subs is funky
04:40 squashable6 left 04:41 squashable6 joined 04:55 squashable6 left 04:57 squashable6 joined 05:05 squashable6 left, squashable6 joined 06:00 frost joined 06:02 reportable6 left 07:02 unicodable6 left, bloatable6 left, statisfiable6 left, sourceable6 left, committable6 left, quotable6 left, tellable6 left, greppable6 left, linkable6 left, releasable6 left, bisectable6 left, notable6 left, benchable6 left, squashable6 left, shareable6 left, evalable6 left, nativecallable6 left, coverable6 left 07:03 greppable6 joined, sourceable6 joined, bloatable6 joined 07:04 coverable6 joined, evalable6 joined, statisfiable6 joined 07:05 unicodable6 joined, quotable6 joined, shareable6 joined, notable6 joined 08:04 linkable6 joined, releasable6 joined, nativecallable6 joined 09:03 squashable6 joined 09:04 tellable6 joined, bisectable6 joined 09:05 committable6 joined, benchable6 joined 10:04 reportable6 joined 10:33 dogbert11 left 11:09 sena_kun joined 12:03 reportable6 left 14:04 reportable6 joined 14:52 frost left
MasterDuke timo: github.com/rakudo/rakudo/issues/17...-900393108 15:26
hm, just adding `uv_mutex_unlock(&body->head_lock); uv_mutex_unlock(&body->tail_lock);` before the destroys still gives the abort in the destroy 15:35
huh. we never unlock mutexes before destroying them 15:56
[Coke] during cleanup, do we want to unlock them? Would that potentially allow some other bit of code to continue when we were trying to shut down? 15:57
nine MasterDuke: no you can't just unlock those mutexes. You have to do it on the thread that locked them
There's just no way around proper thread cleanup. And that can only happen if those threads cooperate. 15:58
MasterDuke nine: have you looked at that issue? seems like there might be a problem with workers not getting cleaned up
nine MasterDuke: haven't looked at that specific issue, but I have working thread cleanup in github.com/MoarVM/MoarVM/commit/af...ec9e7516d0 and github.com/rakudo/rakudo/commit/8d...65155a13e0 16:04
MasterDuke cool, i'll see if those make a difference in this case 16:05
nine Those commits are on the moar_asan_fixes branches
MasterDuke prob won't be able to until later tonight 16:06
16:12 linkable6 left, evalable6 left 16:13 evalable6 joined 17:25 sena_kun left 18:03 reportable6 left 18:04 reportable6 joined 18:14 linkable6 joined 19:31 discord-raku-bot left, discord-raku-bot joined
nine Good news: I have a fully working dispatcher based implementation of nqp::hllize and nqp::hllizefor! 19:38
Bad news is that we have a miscompilation on master that makes many tests fail with this new implementation :/
In foo(what => Int.^name) the call to the HOW method gets compiled into QAST::Op+{QAST::SpecialArg}(p6callmethodhow name :named<what>) <wanted> :before_promotion<?> :statement_id<2> name 19:40
See that :named<what>? That shouldn't be there and it confuses the lang-hllize dispatcher
19:45 discord-raku-bot left 19:46 discord-raku-bot joined
nine Apparently caused by method arglist in Perl6::Actions: $_[2].named($name); 20:07
And I seem to have a fix :) 20:18
timo i wonder what other sitations this miscompile happens in? only with .^ i assume? 20:19
nine Well, it happens there because we re-use the existing QAST::Op carrying that named annotation. The fix accordingly is to create a new node and take only the stuff we need. 20:26
Could happen with other desugars as well
timo mhm 20:28
Geth MoarVM/new-disp: a9782fd5b0 | (Stefan Seifert)++ | 6 files
Add gettypehllrole op to facilitate writing hllization code in HLLs
20:29
MoarVM/new-disp: 7897ff04e4 | (Stefan Seifert)++ | 7 files
Add lang-hllize dispatcher

This dispatcher checks if hllization is actually needed and if it is, delegates to a registered hllization dispatcher for the target language. This will replace the existing nqp::hllize and nqp::hllizefor ops.
MoarVM/new-disp: 4f04eef208 | (Stefan Seifert)++ | src/disp/boot.c
Give lang-hllize dispatcher an optional argument for language name

This makes lang-hllize suitable as a replacement for the nqp::hllizefor op.
timo i don't mean to offload "my" work onto you, but do you have an idea for the junction autothreading thing, nine? 20:57
23:04 evalable6 left, linkable6 left 23:05 evalable6 joined