Perl 6 - the future is here, just unevenly distributed

IRC log for #moarvm, 2017-11-10

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

All times shown according to UTC.

Time Nick Message
00:27 timotimo good post indeed
00:27 timotimo jnthn++
02:56 ilbot3 joined #moarvm
02:56 Topic for #moarvm is now https://github.com/moarvm/moarvm | IRC logs at  http://irclog.perlgeek.de/moarvm/today
06:59 domidumont joined #moarvm
07:04 domidumont joined #moarvm
07:12 geospeck joined #moarvm
08:06 Ven joined #moarvm
08:10 brrt joined #moarvm
09:07 brrt joined #moarvm
09:08 zakharyas joined #moarvm
09:08 brrt joined #moarvm
09:38 scovit joined #moarvm
10:09 zakharyas joined #moarvm
10:20 robertle joined #moarvm
11:00 Ven joined #moarvm
12:50 Ven joined #moarvm
13:00 dogbert2 jnthn: should I report the CLOSE phaser test problem (valgrind screams) against MoarVM or Rakudo ?
13:00 * dogbert2 leans towards MoarVM
13:21 jnthn Probably MoarVM
13:21 jnthn Though nothing new was added to MoarVM at all in the process of fixing the issue
13:21 jnthn So it's not a new problem, just uncovering an existing one
13:29 dogbert2 agreed, timotimo suspected a missing MVMROOT
13:31 dogbert2 perhaps some part of the MoarVM codebase is exercised a bit more after your recent Rakudo fixes
13:32 dogbert2 nine: did you ever create a PR for the list manipulation bug you found a few days ago?
13:42 AlexDaniel joined #moarvm
14:06 dogbert2 jnthn: https://github.com/MoarVM/MoarVM/issues/749
14:24 zakharyas joined #moarvm
14:29 MasterDuke jnthn: do you have any further thoughts/comments on https://github.com/MoarVM/MoarVM/pull/689 ?
14:29 zakharyas joined #moarvm
14:45 brrt joined #moarvm
14:54 jnthn MasterDuke: Will check it when I get a spare moment :)
14:55 MasterDuke thanks, no particular hurry, just following up on stuff i have open
14:58 committable6 joined #moarvm
15:18 domidumont joined #moarvm
15:35 MasterDuke any particular reason MVM_STRING_MAX_STRANDS is only 64?
15:36 MasterDuke MVMStringBody.num_strands is an MVMuint16
15:43 jnthn Yes, it's so we collapse them after a while
15:43 jnthn Otherwise, a repeated concat will end up copying an every-lengthening array of strands
15:43 jnthn *ever-lengthening
15:45 MasterDuke heh, yep, just nearly locked up my computer after bumping that up to 32k
16:10 brrt joined #moarvm
17:25 MasterDuke `if (a->body.storage_type == MVM_STRING_STRAND) fprintf(stderr, "last strand of a = |%s|\n", MVM_string_utf8_encode_C_string(tc, (a->body.storage.strands[a->body.num_strands - 1]).blob_string));`
17:25 MasterDuke ^^^ should print just the last strand of `a`, right?
17:26 timotimo yeah; don't forget to MVM_free, though
17:26 MasterDuke even when debugging?
17:39 domidumont joined #moarvm
17:51 timotimo what's a memory leak or two between friends …
18:12 MasterDuke huh. string a = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
18:12 MasterDuke but the last strand of a = 'for (1, 10, 100) -> $limit {my $x; my $y = "x" x 100; $x ~= $y for (1..$limit); say "$limit: ", now - ENTER now}'
18:14 MasterDuke guess i'm not taking the strand's start and end into account
18:30 MasterDuke m: my $x; my $y = "x" x 10; $x ~= $y for (1..100_000); say now - INIT now
18:30 camelia rakudo-moar 2dcefa1c3: OUTPUT: «1.55922485␤»
18:31 MasterDuke m: my $x; my $y = "xxxxxxxxxx"; $x ~= $y for (1..100_000); say now - INIT now
18:31 camelia rakudo-moar 2dcefa1c3: OUTPUT: «0.05816356␤»
18:35 MasterDuke heh. concat checks if the last strand of the lhs == the rhs, in which case it just bumps the repetitions. but in the first case the last strand is just "x", not "xxxxxxxxxx"
18:35 timotimo because different repetition count?
18:35 ugexe The good news is the getppid() fix for windows landed in libuv for 1.16.1; the bad news is there is a regression on windows for shell I just noticed that is caused by the last bump to libuv v1.15.0
18:35 ugexe regression caused by https://github.com/libuv/libuv/commit/b21c1f900c55572917d64c5e208c3eb8850ffd18
18:36 ugexe perl6 -e "say shell(q|echo 42|).exitcode" - causes this to only print 0 (the 42 never gets printed)
18:36 MasterDuke timotimo: well, because it's checking a strand vs the whole string
18:36 ugexe but seems like since its just a flag that it can be tweaked in moarvm possibly
18:44 MasterDuke so i don't think we ever concat strings by just += repetition, e.g., "a" x 3 ~ "a" x 4 -> "a" x 7
18:51 MasterDuke but i wonder if that would be too much special casing to implement? `if (rhs->num_strands == 1 && last strand of lhs == first strand of rhs) result->body.storage.strands[lhs->body.num_strands - 1]).repetitions += rhs->body.storage.strands[0]).repetitions`
18:57 geospeck joined #moarvm
19:11 MasterDuke can there be a string of one strand where the strands start and end don't encompass the whole blob_string?
19:12 timotimo that sounds just like a substr of another string?
19:12 MasterDuke yeah, guess so
19:12 timotimo oh, i get why you're getting the source code as the strand there
19:13 timotimo it's convinced the best way to represent "x" is to have it be a substring of the whole source code
19:13 timotimo could that be it?
19:14 MasterDuke maybe. that would explain why when i took start and end into account it was fine
19:15 timotimo right
19:16 timotimo one single character substr'd out of a huge string is kind of an edge case where i say we should build a buffer instead
19:16 MasterDuke huh. looks like there's no convenience function to extract a strand as a standalone string
19:16 timotimo additionally, at some point we'll want to store very short strings inside the pointer or something :)
19:16 timotimo aye, strands don't normally have interesting semantic value
19:18 MasterDuke right, but it is annoying if i want to see if the "base" of one strand is equal to the "base" of another
19:19 timotimo true that
19:19 MasterDuke i've got to manually substring both strands
19:20 timotimo do we have an eqat that has a start point for both strings?
19:20 MasterDuke don't think so
19:20 MasterDuke there's MVM_string_equal_at, but it just takes two strings and a length
19:21 MasterDuke s/length/offset/
19:22 MasterDuke afk for a bit
19:36 dogbert17 joined #moarvm
19:37 dogbert17 ZOFFLOP: t/spec/S10-packages/basic.t (test #83)
19:46 dogbert17 heh ww
22:26 releasable6 joined #moarvm
23:25 Geth ¦ MoarVM: MasterDuke17++ created pull request #750: Optimize MVM_string_concat when the RHS is a...
23:25 Geth ¦ MoarVM: review: https://github.com/MoarVM/MoarVM/pull/750

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