00:07 Ben_Goldberg joined 01:08 BenGoldberg joined 01:23 jnap joined 02:57 cognominal joined 03:38 ssutch joined 05:17 jnap joined 06:18 jnap joined 07:18 jnap joined
jnthn diakopter: Some of them are done that way... Others simply occur quite often and so it's to help keep the AST/code smaller. 08:00
08:06 odc joined
nwc10 I infer that on the latter there is a trade-off for portability to new platforms, and possibly maintainability? 08:11
and JIT-ability?
diakopter conceivably 08:13
08:19 jnap joined 08:20 jnap1 joined 08:22 jnap joined 08:39 FROGGS joined
jnthn nwc10: Yeah, though the ahndful that actually are desugars can be implemented portably too... 08:56
FROGGS moarning 08:57
diakopter moorning
09:23 jnap joined 09:50 tgt joined 10:22 ssutch joined 10:24 jnap joined 10:53 ssutch joined
timotimo how do i get the MVMStringIndex of the nth grapheme? 11:24
11:25 jnap joined
timotimo (i'm trying to figure out the correct way to invoke traverse_substring once for the first grapheme, then for the rest of the string. it seems like i need to figure out the location of the second grapheme for that) 11:27
timotimo has a first prototype without proper grapheme counting 11:34
it has a FIXME in it, though, and it's better than just throwing an exception when it's run :)
diakopter timotimo: what do you mean 11:35
handling grapheme clusters you mean?
timotimo yes
diakopter p6 doesn't go by grapheme 11:36
clusters
timotimo oh, so tclc for a multi-charcode-grapheme will be stupid?
diakopter b/c NFG is spec'd as NFC+remapping
no, don't implement grapheme clusters :P
timotimo OK 11:37
MoarVM op 'tclc' is unknown as a core or extension op - what could i have missed?
i added it to the list of ops and ran the update script, then added it to the case in interp.c
diakopter reconfigure 11:38
timotimo ah, ok
11:39 FROGGS[mobile] joined
timotimo FROGGS[mobile]: don't start tackling tclc on your mobile now, i almost have a functioning patch ready! :) 11:40
aaw, i segfault 11:41
FROGGS[mobile] timotimo++ 11:42
timotimo given strands and such, maybe it would have been actually acceptable to turn it into a substr x 2 + concatenate in the HLL 11:43
hrmpf. /me builds without optimize 11:48
FROGGS[mobile] ohh, you must be patient 11:54
timotimo hehe. 11:57
i'm not sure where i went wrong, so i'll re-implement based on substr, tc, lc and concat.
FROGGS[mobile] hmmm, the bunny must be somewhere in the pepper 12:01
timotimo m) 12:02
jnthn You need that much pepper to make bunny tasty? 12:21
timotimo: Did you "make install" your updated Moar?
timotimo i got past the problem :) 12:22
now i'm getting "cannot numify this" from the qast compilation process (because i decided to, for the time being, implement tclc in terms of substr, tc, lc and concat. 12:23
12:26 jnap joined
timotimo ah, i had the last two arguments to InstructionList.new reversed 12:28
i don't think i understand correctly how to return the value of a register from my op properly 12:38
Invalid MAST node in instruction list (must be Op, ExtOp, Call, Label, or Annotated) 12:40
so i created the MAST code for the operand with $qastcomp.as_mast(@operands[0], :want($MVM_reg_str)) 12:41
and then i nqp::pushed(@ops, $the_operand_code.instructions)
is that wrong?
jnthn you want push_ilist I think 12:42
timotimo thanks 12:44
afk for a bit now
13:02 FROGGS joined
FROGGS tclc is line 3341 btw 13:10
timotimo yup 13:14
timotimo builds it with QAST instead of MAST 13:15
nwc10 I assume that QAST has 2 advantages over MAST
1) you can test it on an existing working backend
2) it's portable to any future backends (eg JS, and anything else anyone wants to do) 13:16
FROGGS huh, Error while compiling op call: Cannot find method 'uniprop'
timotimo there: much easier
nwc10 I have
Error while compiling op tclc: No registered operation handler for 'tclc'
FROGGS nwc10: I commented that out, to know what will be next
nwc10 aha right 13:17
FROGGS so I can hack while he hacks :o)
timotimo :)
the code i have now should be right.
yup, works 13:20
FROGGS hmmm 13:23
timotimo: I think uniprop is more like your expertise 13:24
timotimo it is?
maybe. where do i have to look?
FROGGS grep for it in nqp
/home/froggs/dev/nqp/src/vm/jvm/QAST/Compiler.nqp:5437: method uniprop($node) {
/home/froggs/dev/nqp/src/vm/parrot/QAST/Compiler.nqp:1677: method uniprop($node) {
timotimo OK
ah, it's regex compilation 13:25
i'll start working on it in a bit.
FROGGS k, I'll stub it locally, to see what is next :o)
or..., I'll stub it and push 13:26
13:27 jnap joined
FROGGS ahh damnit, it really wants to execute uniprop :o( 13:46
timotimo FROGGS: d'oh, the uniprop op isn't mapped in moarvm itself 13:49
so once i implement method uniprop, it'll carp about the missing is_uprop op
oh, wait 13:50
FROGGS timotimo: there is no such op for parrot/jvm either
timotimo it may just be hasuniprop
FROGGS that sounds good
timotimo good.
FROGGS hasuniprop w(int64) r(str) r(int64) r(int64) r(int64) 13:51
MVM_string_offset_has_unicode_property_value 13:52
(MVMThreadContext *tc, MVMString *s, MVMint64 offset, MVMint64 property_code, MVMint64 property_value_code)
timotimo yeah.
what's the reason for the value_code?
FROGGS I guess in parrot land the line 1680 just checks the bounds? 13:53
I dunno
timotimo i need to find that mapping first ...
FROGGS parrots version just take three args... 13:54
timotimo hm
MVM_UNICODE_PROPERTY_GENERAL_CATEGORY ...
so it wants a category passed as the second argument
actually, it wants the property code as second arg ... and then the name again? 13:55
FROGGS ahh! 13:56
case MVM_CCLASS_UPPERCASE:
return MVM_string_offset_has_unicode_property_value(tc, s, offset,
MVM_UNICODE_PROPERTY_GENERAL_CATEGORY, UPV_Lu);
the "u" in UPV_Lu is for uppercase
case MVM_CCLASS_HEXADECIMAL: 13:57
return MVM_string_offset_has_unicode_property_value(tc, s, offset,
MVM_UNICODE_PROPERTY_ASCII_HEX_DIGIT, 1);
so, there is a general category that you can query specific stuff, and then there are additional categories that you check for truthness I think
timotimo yeah 13:59
i have a piece of code that may work
FROGGS how does that cope with what we generate in cclass_elem?
timotimo er ... wha? 14:02
it doesn't, that's a different piece, no?
uniprop is for things like ... how do you even spell that
<:Letter> 14:03
FROGGS I do think it is related to /home/froggs/dev/nqp/src/QRegex/P6Regex/Actions.nqp:578: $qast := QAST::Regex.new( $uniprop, :rxtype<uniprop>,
timotimo mhm? 14:04
i don't see what your problem is :)
FROGGS rp: say "abc" ~~ / [:Letter] /
camelia rakudo-parrot e5fd34: OUTPUTĀ«===SORRY!=== Error while compiling /tmp/R8FWCKhsb0ā¤Unrecognized regex modifier :Letterā¤at /tmp/R8FWCKhsb0:1ā¤------> say "abc" ~~ / [:Letterā] /ā¤Ā»
FROGGS rp: say "abc" ~~ / <:Letter> /
camelia rakudo-parrot e5fd34: OUTPUTĀ«ļ½¢aļ½£ā¤ā¤Ā»
FROGGS O.o
timotimo huh 14:05
that's not right
yeah 14:06
you need <:Letter> instead
rp: say "abc123" ~~ / <:Letter>+ /
camelia rakudo-parrot e5fd34: OUTPUTĀ«ļ½¢abcļ½£ā¤ā¤Ā»
FROGGS I mean, you must translate "Letter" to two int64
timotimo yes
i'm doing that now :)
FROGGS timotimo: I did <:Letter> in the last one
timotimo a code and a value, there's two ops for that
ah
sorry, i didn't look property
properly*
FROGGS rp: say "abc" ~~ / <:Letter-[a]>+ / 14:07
camelia rakudo-parrot e5fd34: OUTPUTĀ«ļ½¢bcļ½£ā¤ā¤Ā»
FROGGS that is why it is in cclass_elem :o)
timotimo aaaaand i forgot to move the position by one :)
FROGGS hehe 14:08
+1
there you go :P
timotimo thanks :) 14:10
FROGGS where are you doing that mapping? in moarvm or nqp? 14:13
timotimo it still seems to hang :\ 14:15
in nqp
Error while compiling op p6shiftpush: No registered operation handler for 'p6shiftpush'
good luck! :)
14:18 lizmat joined
FROGGS yay! 14:18
timotimo++
timotimo aaw, i was hoping you'd maybe implement it :P 14:25
timotimo compiles
FROGGS nah, my brane is not available enough 14:26
timotimo OK
FROGGS have to care about my son right now, so it is nice to have a 2min hack + 5min compile task
14:28 jnap joined
timotimo about to hit the next op we need to stub 14:30
FROGGS p6arrfindtypes
arr!
timotimo yarr 14:31
jnthn I think it's about arrays, not pirates :P 14:32
timotimo comments the line out to find the next op we'd stumble upon 14:34
probably p6listiter 14:35
p6setfirstflag
perhaps p6invokeflat? 14:36
FROGGS I'd vote for p6listiter too
timotimo: you can do shitpfusch if you want :o) 14:37
timotimo i'm not sure where i have to look to find example code ... 14:38
FROGGS rakudo/src/vm/jvm/runtime/org/perl6/rakudo/RakOps.java:228: public static SixModelObject p6shiftpush(SixModelObject a, ... 14:39
timotimo i was thinking more along the lines of moarvm source, but i'll figure it out :) 14:40
FROGGS ahh, maybe look what push_o does? 14:41
yeah, it is p6listiter
line 7138 now 14:42
timotimo :)
how do i check if a MVMObject is null?
or would it actually be the null pointer?
jnthn For now it's just the null pointer, yeah 14:43
timotimo okay
jnthn Taht's why we're so awesome at segfaulting.
timotimo :)
i set the number of slots in a list with MVM_repr_set_int, right? 14:44
jnthn uh, no
I think set_elems
if there is one...
Otehrwise see how setelems op is implemented
14:45 BenGoldberg joined
timotimo there is none, apparently. but i'll have a look 14:47
now i need to splice some, too ... 14:48
jnthn: what's the equivalent to GlobalExt.EMPTYARR on moarvm? 14:52
jnthn timotimo: Creating a new BOOTArray somewhere 14:53
And stashing it
Probably in a static
See in p6init or so
Make sure to add it as a perm root
timotimo OK 14:54
jnthn But creating it is just MVM_repr_alloc_init
timotimo ah, there's already a few examples 14:56
that also takes care of the perm-root
ah, now i get it, that code was to make the array empty 14:59
jnthn right
yarrrrr, empty 15:00
15:00 tgt joined
FROGGS next is p6sort, which might be a nice thing to implement 15:01
timotimo "nice" 15:02
failed to load library 'dynext/libperl6_ops_moar.so' 15:03
:(
timotimo tries to clean again
jnthn
.oO( not .so good... )
15:04
FROGGS just take it more lib-erally 15:05
timotimo oh, i called bind_pos_o wrong 15:07
FROGGS now it hangs :o( 15:11
stubbing sort might not be enough
ahh, it did not 15:12
getcfh is next 15:13
I'll implement that
timotimo it takes quite a bit of time to reach the crash now
FROGGS yeah
that is line 12970 15:14
jnthn++ needs to make it die faster :P
timotimo wow, that's quite a lot more lines than earlier today
when we were at like 3k
FROGGS well, there are not soo many ops left 15:15
timotimo well, many left to actually implement :)
FROGGS yeah, one by one :o) 15:16
nice and easy
timotimo i'll be AFK for a bit now. 15:20
FROGGS k, see ya :o)
timotimo need to drive my car around a bit after getting a kickstart by the ADAC 15:21
if you don't get around to it by then, i'll see if i can easily implement p6listiter like jnthn said 15:23
FROGGS k 15:24
15:28 jnap joined 15:34 jnap joined
jnthn wonders how long until "say 'hello moar'" :) 15:39
FROGGS I'd like to say "today" 15:40
15:45 benabik joined
FROGGS No registered operation handler for 'socket' 15:46
jnthn We could exclude the socket stuff from the makefile for now...
It's not like we need it for a bit.
FROGGS good point 15:47
15:52 odc joined 16:03 crab2313 joined
FROGGS Program received signal SIGSEGV, Segmentation fault. 16:12
0x00007ffff7a1fbb0 in write_ref_func () from /home/froggs/dev/MoarVM/../nqp/install/lib/libmoar.so
:(
that is when stripping INET.pm from Makefile
jnthn oh...that means we got lots further at least. 16:13
Means we made it to doing the serialization
Which is about the last thing we do
FROGGS so, this is "it"? the light at the end of the tunnel? 16:14
I rerunning with an unoptimized moar 16:15
jnthn Well, after that we gotta make it through the assembler. 16:17
In theory that should be fine
FROGGS we'll meet our great Assembler? :P 16:23
(I'm sorry)
jnthn :P 16:25
.oO( pain in the assembler... )
FROGGS gist.github.com/FROGGS/061f5586d6da72478ee2 16:33
ref points to unreadable memory 16:35
jnthn hm, wtf... 16:37
hotel & 16:45
timotimo will join you in coding again soon 17:16
FROGGS \o/ 17:29
17:37 lizmat joined
timotimo yays 17:51
okay, p6listiter is still up for grabs? 17:54
wow, either what i just made i stotally wrong or it was really easy :) 17:56
17:57 jnap joined
moritz timotimo: jnthn mentioned it might not be too hard :-) 17:57
timotimo yeah, but when jnthn says something's "not hard" it may still be hard for me :P 17:59
i'm not really sure how to test if it's correct, though. 18:00
jnthn It's mostly not hard 'cus I already did the implementation of what it does, iirc, just didn't wire that static function doing it up to an op body...
timotimo well, there'll be enough fallout when we actually run perl6 source code rather than just compiling it 18:01
and we'll certainly stumble over enough mistakes i made :P
FROGGS: did you look further into the serialisation stuff? 18:02
so it's trying to serialize an object's body, but the object doesn't have an STable at that position 18:04
in the last attribute
18:05 woolfy joined
timotimo maybe get_obj_at_offset is poking into something that's not supposed to be a pointer to an object 18:05
dalek arVM: 187b36b | jonathan++ | src/6model/reprs/P6opaque.c:
Fix P6opaque serialization in mixin case.

Untested, but makes it match what happens in all the other REPR funcs.
18:06
timotimo ah, there we go :)
jnthn ;)
Well, I made sure it didn't blow up NQP tests.
Got a Rakudo on Moar build running at the moment. 18:07
But there's a good chance this was it
It would certain cause us to go looking at random memory off the end of an object.
*certainly
timotimo hm. should i build an unoptimized moarvm now?
i guess i could.
i would never have gotten the idea to call real_data on data >_< 18:09
jnthn Only some of us know how to keep it real...
:P
To explain what it does: if we mix in to an object, and its size needs to change, then we can't actually resize the original, so we allocate a new piece of memory and point to it. 18:10
And that then stores things.
This is what real_data is.
timotimo so, the more we mix in, the more pointers we have to follow in a row to get at the real real real data? 18:11
jnthn No, it doesn't chain. 18:12
moritz when it comes to the second level, we could just replace the old data with a pointer to the new real data
jnthn Just reallocs to the new size.
timotimo OK
jnthn Right, that's what it does.
Though we may need to revisit that in the future wrt thread safety.
timotimo captain jnthn, engage the thread safety shield!
18:13 crab2313 joined
jnthn wow, it completes stage mast...sloooowly 18:14
timotimo i wonder how excruciatingly long it will take for my debug build ...
jnthn Then dies in the assembler.
At Frame 2868, Instruction 75, op 'hasuniprop' has invalid number (4) of operands; needs 5.
timotimo oh, whoops 18:15
that's totally my fault then.
jnthn Also means it's assembled 2867 frames before bailing :)
timotimo \o/
how many frames are there going to be, approximately?
jnthn I dunno :) 18:16
but did we not get a long way into stage mast without hitting the uniprop thing?
If so it means we should be about equally far into the assembler...
timotimo right
i forgot to pass the string that's supposed to be looked at :) 18:17
patch inbound
jnthn yay
timotimo i'll compile it before i push, though 18:18
actually, that's not necessary
there you go
if you have an optimized build, you'll easily overtake me in the build process
jnthn building 18:19
timotimo --output=gen/moar/stage2/NQPP6QRegex.moarvm gen/moar/stage2/NQPP6QRegex.nqp
... ... ...
jnthn At this rate we may assemble before I go for dinner :)
timotimo i'll probably be afk for a big part of the evening, though 18:20
jnthn I doubt I'll be that productive this evening given how my early night yesterday failed to lead to a lot of sleep... :/
Anyways, Rakudo build in progress... 18:21
timotimo my sleep attempts were also pretty fail last night :(
jnthn Damn, I need to optimize this thing. :)
timotimo starting to build rakudo now, too.
jnthn yeah, in stage parse... :) 18:23
timotimo i'm looking forward to you optimizing this thing :3
the stuff i implemented so far is not optimal 18:24
Stage start : 0.000 <- if only every stage was this fast
jnthn is into mast now :) 18:25
timotimo still parsing 18:27
Stage parse : 264.067 18:28
could be worse ...
jnthn While it's slow, it does at least stay below a gig all the way...
so far at least
timotimo that's a welcome change :3
800 MB RSS
at the moment
jnthn Stage mbc : 0.544 18:29
...at least it assembles fast :P
And...we got a CORE.setting.moarvm out :)
timotimo fwiw, i think i'm missing a few free_register's here and there
OOOOH YEAH :D
\o/
900 MB Res 18:30
FROGGS[mobile] do we get a perl6-m now?
TimToady but does it say 'hi' yet? 18:31
jnthn No, 'cus something is wrong with the thingy that makes the runner, but that should be an easy fix
If you inovke manually...
SIG_ELEM_DEFAULT_FROM_OUTER NYI
While loading the setting :)
So, we get some way into setting loading.
FROGGS[mobile] nice!
jnthn Well, we do all the deserialization and stuff, this is running its main body.
timotimo then it'll want to do the datetime decoding thingie. did FROGGS[mobile] stub or implement that? 18:32
FROGGS[mobile] stubbed, I think
timotimo OK, that'll be hit definitely 18:33
jnthn Yeah, I imagine so.
Anyway, another nice point to have reached.
timotimo peak memory usage seems to be 950 MB
jnthn I suspect that's the lowest of the various backends. 18:34
timotimo and as always the libuv assertion error and the coredump happens ...
18:34 jnap joined
timotimo do we have a fix for that in the pipeline? 18:35
FROGGS[mobile] nope
timotimo okay, i'll be off now for a bit 18:37
ttyl :)
FROGGS[mobile] o/ 18:38
18:38 ssutch joined
jnthn is gonna go do dinner 18:40
And, given we got a CORE.setting.moarvm out, maybe a celebratory stout :)
jnthn has a bottle of Perl wine to drink once we get it to say hello... ;)
bbl &
18:53 woosley joined
diakopter all this progress in the backlog, but no commits reported here 19:15
timotimo yeah, most of the stuff happened in nqp/ or rakudo/ 19:20
TimToady what branch of nqp should it be using? 19:21
moritz master
TimToady okay--mine blew up between stage0 and stage1, but trying a rm of the usual suspects 19:22
or does the moar need a special branch? 19:24
19:24 grondilu joined 19:27 grondilu left
TimToady still fails, see gist.github.com/TimToady/7697075 19:30
bothers me that the subcommand ends with --gen-moar= 19:31
or does that just mean "take the default" 19:32
has anyone else run into trouble trying to compile stage1/QRegex? 19:33
timotimo you only need rakudo/moar-support, all other parts work with their master branches 19:35
19:35 jnap joined
nwc10 It seemed to hang for me after 19:36
Stage optimize : 86.350
Is it actually taking "forever" (eg >15 minutes) for the next stage?
19:37 ingy joined
TimToady tries again with an explicit --gen-moar=master 19:38
timotimo Stage optimize : 59.377 19:44
Stage mast : 324.086
nwc10: that's for me. it'll take about 30% longer
nwc10 OK. Thanks 19:45
tadzik oooh, so rakudo on moar is now working?
nwc10 tadzik: it hasn't acchieved "hello world" yet
TimToady identical failure on QRegex, except now the command ends --gen-moar without the = 19:46
TimToady wonders what he's doing different from everyone else... 19:47
nwc10 isn't using a --gen-moar
I configured MoarVM as 19:48
perl Configure.pl --prefix=/home/nicholas/Sandpit/moar-g
and the other two as
perl Configure.pl --backends=moar --prefix=/home/nicholas/Sandpit/moar-g
and did make test install for MoarVM and NQP
timotimo moar-g? 19:52
19:53 tgt joined
diakopter nwc10: Sandpit? tarpit? 19:54
Sarlacc pit?
timotimo i don't have --gen-moar, either, i just manually configured and built it
my moar is configured with ../../install, my nqp is ../install, my rakudo is no prefix (== install/), and they are all stacked into each other 19:55
TimToady it seems as though it's trying to generate moar down in nqp/gen; could there be some kind of chdir failure from doing multiple backends? 20:02
trying to generate only the moar backend, --gen-moar still fails to compile QRegex 20:09
jnthn back 20:23
TimToady: Since when, to the degree you know? 20:24
jnthn did find nice Indian, but the stout-serving bar on the route back was packed with nowhere to sit, which didn't seem like much fun after standing teaching all day... 20:25
nwc10 This is expected? 20:27
Stage mast : 487.015Stage mbc : 1.976
moar: 3rdparty/libuv/src/unix/loop.c:150: uv__loop_delete: Assertion `!((((*(&(loop)->active_reqs))[0]) == (&(loop)->active_reqs)) == 0)' failed.
gah, naughty terminal
no error, other that assertion failure
awww 20:28
better luck tomorrow?
TimToady jnthn: /me posted a gist earlier of the failure on stage1/QRegex 20:29
jnthn TimToady: Yes, asking if this is a new problem, or at least, when (roughly) were you last able to build? 20:37
I can't get much from the gist, sadly. The invocation looks correct.
TimToady I've never tried to build moar under nom before 20:38
jnthn Oh...but you previously build NQP on Moar, or never?
TimToady I've been able to build jvm and parrot all along together
just adding in moar as a backend doesn't seem to get past QRegex no matter what I delete 20:39
jnthn OK. That means I can't tell if it's a recent regression for you, or if it's always been an issue... 20:40
If you can get hold of a gdb backtrace, that may help.
TimToady I haven't ever built the bootstrapped nqp
just the cross-compiled one
jnthn OK. I'm guessing you aren't building on anything unusual?
TimToady x86_64 Linux 20:41
jnthn Yeah, that's "boring" and probably what others are using who can build. Hm.
TimToady Linux Mint, which is an Ubuntu
moritz which is what I use at $work
TimToady 32 or 64-bit? 20:44
TimToady is using the 64-bit Linux 20:45
moritz 64 bit
TimToady weird, well, maybe I'll have a chance to get it to a gdbable state later, but today is mostly gonna be familyschtoff 20:46
nevertheless, \o/ at the progress 20:47
jnthn Ah. Turns out that getting the SC repossession stuff in place is actually a blocker. 'cus CORE.setting fiddles with the types BOOTSTRAP creates. 21:23
21:37 jnap joined 22:38 lizmat_ joined, jnap joined
timotimo will you be able to do that tonight? 22:38
that would be amazing 22:39
22:47 lizmat joined 22:55 woolfy joined 23:39 jnap joined 23:56 jnap joined