Perl 6 language and compiler development | Logs at colabti.org/irclogger/irclogger_log/perl6-dev | For toolchain/installation stuff see #perl6-toolchain | For MoarVM see #moarvm
Set by Zoffix on 27 July 2018.
MasterDuke any idea why i'm getting 'Attempt to read past end of string heap when reading string length' on my rebased default-nqp-to-int branch? 02:01
nine: i add a new entry to MVMStringConsts in my MoarVM branch that goes along with my default-vars/ops-to-int NQP branch. could that have caused some conflict with your recent mbc work? 02:18
06:25 squashable6 left, reportable6 left, coverable6 left, quotable6 left, undersightable6 left, shareable6 left, bisectable6 left, benchable6 left, statisfiable6 left, bloatable6 left, nativecallable6 left, evalable6 left, committable6 left, greppable6 left, notable6 left, releasable6 left, unicodable6 left 06:26 bisectable6 joined, benchable6 joined, notable6 joined, p6bannerbot sets mode: +v bisectable6 06:27 releasable6 joined, greppable6 joined, shareable6 joined, p6bannerbot sets mode: +v benchable6, p6bannerbot sets mode: +v notable6, quotable6 joined 06:28 unicodable6 joined, p6bannerbot sets mode: +v releasable6, p6bannerbot sets mode: +v greppable6, p6bannerbot sets mode: +v shareable6, undersightable6 joined, ChanServ sets mode: +v undersightable6, p6bannerbot sets mode: +v quotable6, p6bannerbot sets mode: +v unicodable6, statisfiable6 joined, ChanServ sets mode: +v statisfiable6 06:29 p6bannerbot sets mode: +v undersightable6, evalable6 joined, bloatable6 joined, ChanServ sets mode: +v bloatable6, nativecallable6 joined, ChanServ sets mode: +v nativecallable6, p6bannerbot sets mode: +v statisfiable6, reportable6 joined, ChanServ sets mode: +v reportable6 06:30 squashable6 joined, ChanServ sets mode: +v squashable6, committable6 joined, p6bannerbot sets mode: +v evalable6, p6bannerbot sets mode: +v bloatable6, p6bannerbot sets mode: +v nativecallable6, p6bannerbot sets mode: +v reportable6, coverable6 joined 06:31 p6bannerbot sets mode: +v squashable6, p6bannerbot sets mode: +v committable6, p6bannerbot sets mode: +v coverable6 07:37 timotimo left 07:42 timotimo joined, p6bannerbot sets mode: +v timotimo
nine MasterDuke: don't see how 08:07
09:28 ufobat joined 09:29 p6bannerbot sets mode: +v ufobat 10:28 Kaiepi left, Kaypie joined 10:29 p6bannerbot sets mode: +v Kaypie 10:34 Merfont joined, Kaypie left 10:35 p6bannerbot sets mode: +v Merfont 11:46 llfourn left
MasterDuke i don't understand why NQP builds ok, but even the empty program dies with that error 11:52
12:01 ufobat left 12:35 lucasb joined, p6bannerbot sets mode: +v lucasb
Geth rakudo: 304feae9f0 | (Elizabeth Mattijsen)++ | src/core/Str.pm6
Make Str.trim-trailing about 10-20% faster

Depending on string and amount of whitespace
12:52
lizmat is feeling rather dim today 13:01
m: my $a = 42; my $b = q/a = $a/; say $b # is there an easy method on $b to make that say "a = 42" ?
camelia a = $a
nine lizmat: I assume not as interpolation is part of compilation 13:02
lizmat right, I have the string 'a = $a' and I want a method to turn interpolate the $a in the string 13:03
can't eval it, as it's not legal code 13:05
this in light of rt.perl.org/Public/Bug/Display.html?id=133772 13:06
nine m: use MONKEY-SEE-NO-EVAL; my $a = 42; my $b = q/a = $a/; say EVAL qq["$b" 13:07
camelia 5===SORRY!5=== Error while compiling <tmp>
Couldn't find terminator ] (corresponding [ was at line 1)
at <tmp>:1
------> 3 42; my $b = q/a = $a/; say EVAL qq["$b"7⏏5<EOL>
expecting any of:
]
nine m: use MONKEY-SEE-NO-EVAL; my $a = 42; my $b = q/a = $a/; say EVAL qq["$b"]
camelia a = 42
nine lizmat: ^^^
13:20 dct joined, p6bannerbot sets mode: +v dct
lizmat nine: yeah... but using EVAL... meh 13:21
MasterDuke nine: got any other idea about the string heap error? 13:23
fwiw, here's the complete backtrace: gist.github.com/MasterDuke17/9f61f...619867b95e 13:24
nine MasterDuke: writing bytecode includes quite a few calculations of positions. You change how NQP does math, so that's what I'd suspect. 13:25
MasterDuke nine: that makes sense, but the results should be the same 13:26
nine There may be some subtle difference 13:29
Btw. I can't find that branch? 13:30
MasterDuke nine: github.com/MasterDuke17/nqp/tree/t...lt_int_fix is where i am now (amidst some rebasing and such) 13:32
github.com/MasterDuke17/MoarVM/tre...mrt_intify is the MoarVM branch
13:40 dct left
MasterDuke nine: do you happen to remember if any of the calculations *should* be done as num? 13:44
nine Ok, can clearly repro. I'm not terribly surprised why compilation succeeds but nqp-m -e '' breaks: First the stage0 compiler is used to compile the current sources into the stage1 compiler. Then the stage1 compiler is used to compile the same sources into stage2. As your branch subtly breaks the compiler, stage2 is the first part to be broken. And the first time that runs is in your ./nqp-m -e '' 13:46
MasterDuke: they absolutely shouldn't
MasterDuke nine: that's good (that they shouldn't)
nine: my branch did pass `make m-test` in NQP a while ago 13:47
well, the original branch did, but i think its state has been lost during my rebase attempts 13:48
hm, github.com/perl6/nqp/blob/master/s....nqp#L2327 might need changing 13:51
nine So there actually is one calculation that's supposed to use floats, yes indeed. 13:58
And it's used all over the place
MasterDuke size()? 13:59
nine Oh, indeed! Just change that line to: my uint32 $aligned := nqp::ceil_n(nqp::div_n($size, 8)) * 8; 14:04
MasterDuke nine++, now it builds and there's just one failed test during a `make m-test` 14:08
heh, and that was just the plan off by one! 14:11
now to get back to trying to get rakudo to build with this branch... 14:13
gets all the way to stage optimize, didn't remember it got that far: Stage optimize : Unhandled exception: Cannot invoke this object (REPR: Null; VMNull) at SETTING::src/core/Mu.pm6:549 (<ephemeral file>:Str) 14:17
nine Encouraging results :) 14:18
MasterDuke yep, but not that easy to debug... 14:50
timotimo: is ^^^ something the debugserver could help with? 14:57
jnthn lizmat: I'd probably write it like {q/a = $^a/} and then invoke the block, if that's an option :) 15:04
MasterDuke heh. rakudo builds if i set --optimize=0, but then the install fails with: ===SORRY!=== This type cannot unbox to a native integer: P6opaque, Failure 15:45
15:49 Merfont left
MasterDuke ah ha! Signature.count is a Num, that might be it... 15:49
15:49 Kaypie joined 15:50 p6bannerbot sets mode: +v Kaypie
b2gills m: say {q:s/a = $^a/}(42) 16:01
camelia a = 42
nine The optimizer does a surprising number of calculations. But nothing supsicious 16:05
MasterDuke i think this is the problematic line: github.com/rakudo/rakudo/blob/mast....nqp#L3111 16:10
nine Looks so innocent :) 16:12
Why is Signature's count a Num anyway? Doesn't feel right 16:13
MasterDuke istr it's so slurpies can be inf or something like that 16:14
nine Yep, exactly that
MasterDuke i once tried to change it and it wasn't a single-line fix 16:15
ooooh, rakudo built and installed 16:16
16:23 ufobat joined 16:24 p6bannerbot sets mode: +v ufobat
MasterDuke hmm, make m-test (aside from a couple fails to investigate) seems to hang during t/09-moar/NAME__UnicodeData.t 16:39
b2gills I wonder if Signature.count could be -1 for Inf in NQP land 16:46
MasterDuke i think negatives are already used 16:48
but it was a while ago i looked at it, so not 100% sure 16:49
mostly unrelated, but my branch(es) make the rakudo compile take at least 5s longer, which i wouldn't have expected 16:50
nine MasterDuke: smrtintify is not JITed 16:54
That probably breaks JIT compilation of a lot of frames 16:56
MasterDuke arg, right. nine++ again 16:57
nine I wondered the same thing previously :)
MasterDuke hm, i thought another Signature.count related fix was needed, but now the install hangs with 100% cpu at: 17:16
home/dan/Source/perl6/install/bin/moar --libpath="blib" --libpath="/home/dan/Source/perl6/install/share/nqp/lib" --libpath="/home/dan/Source/perl6/install/share/nqp/lib" perl6.moarvm --nqp-lib=blib -e "for @*ARGS.head(*-1) { given (@*ARGS[*-1] ~ '/' ~ .IO.basename.Str) { say 'rm -f ' ~ .Str; .IO.unlink if .IO.e } }" blib/Perl6/ModuleLoader.moarvm blib/Perl6/World.moarvm blib/Perl6/Grammar.moarvm blib/Perl6/Ops.moarvm blib/Perl6/Actions.mo 17:17
17:53 lucasb left 18:20 ufobat left 18:28 ufobat joined 18:29 p6bannerbot sets mode: +v ufobat 18:46 Kaypie is now known as Kaiepi
MasterDuke anyone have an idea why changing the nqp::iseq_i here github.com/rakudo/rakudo/blob/mast...ode.pm6#L8 to nqp::iseq_n would cause the hang i mentioned above? becuase i think that should be a correct change 20:17
nine MasterDuke: the 1 there is now an int, isn't it? 20:22
MasterDuke nine: hm, i thought it would Just Work, but maybe not 20:24
nine I've never been completely sure what to expect. The only version I'm certain about is the spesh log
MasterDuke odd that there was no error, just a hang 20:26
huh, changed to 1e0 and it still hangs
20:38 Kaiepi left, Kaiepi joined 20:39 p6bannerbot sets mode: +v Kaiepi
AlexDaniel releasable6: status 21:00
releasable6 AlexDaniel, Next release will happen when it's ready. 4 blockers. 113 out of 239 commits logged (⚠ 41 warnings)
AlexDaniel, Details: gist.github.com/cb7f223f2a23785764...eb28db7f23 21:01
MasterDuke timotimo: how should i use the debug server to see what's going on during that install command? 21:29
getting a lot of: Tried to get the result of a broken Promise ....... 21:33
when i do a dump 21:37
22:28 llfourn joined 22:29 p6bannerbot sets mode: +v llfourn 23:12 ufobat left