Perl 6 - the future is here, just unevenly distributed

IRC log for #moarvm, 2017-01-29

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

All times shown according to UTC.

Time Nick Message
00:00 MasterDuke (and i couldn't make it a multi)
00:00 MasterDuke and switching a bunch of things to use my find_symbol2, but it didn't seem to make much of a difference
00:00 TimToady WANTEDOUTERBLOCK was a hack because of single-pass assumptions in find_symbol, so we should fix that
00:01 TimToady basically, wanted propagation can descend down into blocks we've already left in the main parse pass
00:03 TimToady we should have some kind of a tail-shared structure for blocks instead of a strict stack there that pops too soon
00:04 jnthn Blocks to have an annotation that points to their enclosing block
00:04 TimToady $*WANTEDOUTERBLOCK lookup by itself causes about 1% of our current overhead
00:04 TimToady don't recall offhand why following those didn't work
00:04 TimToady seem to recall trying...
00:05 TimToady something sets them too late, iirc
00:07 jnthn I may be misremembering, but I thought they were set at the moment the inner QAST::Block comes into existence
00:08 jnthn Time for me to go rest... 'night
00:08 TimToady g'night
00:09 TimToady (might've been simply that doing that many hash lookups was a lot slower than using the stack)
00:10 TimToady ((but I do seem to recall it crashing when I tried))
01:19 geekosaur joined #moarvm
01:40 pyrimidine joined #moarvm
01:52 ggoebel joined #moarvm
02:48 ilbot3 joined #moarvm
02:48 Topic for #moarvm is now https://github.com/moarvm/moarvm | IRC logs at  http://irclog.perlgeek.de/moarvm/today
03:56 agentzh joined #moarvm
05:11 agentzh joined #moarvm
07:34 domidumont joined #moarvm
07:48 pyrimidine joined #moarvm
10:19 Ven joined #moarvm
10:35 agentzh joined #moarvm
12:23 pyrimidine joined #moarvm
12:36 geekosaur joined #moarvm
13:14 vendethiel joined #moarvm
13:15 MasterDuke jnthn: just doing some more testing with radix and jitting. i set MVM_JIT_LOG for a run with radix (which i created cases for in src/jit/graph.c) and radix2 (an identical copy of radix which i created an nqp op for to make testing easier)
13:15 MasterDuke and the log is exactly identical
13:16 MasterDuke which i guess is no real surprise, since everything is being interpreted
13:16 MasterDuke any suggestions for what to test next?
13:18 jnthn MasterDuke: Are you testing that with NQP?
13:19 jnthn If so, did you try putting the code under test inside of a sub and calling that?
13:19 MasterDuke yeah. oh right, there was some different behavior when i tested something from rakudo instead
13:19 jnthn It looks like for some reason the program mainline in NQP doesn't end up getting OSR'd
13:20 MasterDuke ah! i was thinking about doing that (put in a sub) that last night and then fell asleep at the keyboard, thanks for the reminder
13:21 jnthn :)
13:25 MasterDuke heh. so the OSR section say none. but there is an OSR graphic by the sub and we're now at 20% jitted
13:26 lizmat MasterDuke: the --profile is sometimes incorrect on some OSR / JIT info
13:26 lizmat you should probably check the MVM_JIT_LOG to be sure
13:26 jnthn Curious :S
13:26 jnthn I also get really weird rendering of the profiler UI in Firefox, where it shows all tab content one below the other
13:27 MasterDuke how do i know if something was jitted in the log?
13:28 jnthn If it's in there and there's no BAIL, iirc
13:29 MasterDuke the log is now different between using radix and radix2, but the string 'radix' isn't in either log
13:30 MasterDuke but just timing a large number of iterations is showing radix noticeable faster than radix2
13:32 MasterDuke at 20m iterations, radix (which i jitted) is now 1s faster than radix2
13:35 MasterDuke at 1m iterations, perf stat -B is showing ~240m fewer instructions and 25m fewer branch misses for radix vs radix2
13:36 MasterDuke and a profile of radix2 shows 20% spesh vs 20% jit for radix
13:47 pyrimidine joined #moarvm
13:51 samcv jnthn, i keep getting that error ===SORRY!===
13:51 samcv When invoking 5694 'parameterize', provided outer frame 0x55734b0873e0 (58 '!protoregex_nfa') does not match expected static frame 0x55734ba90718 (5695 '')
13:51 samcv how do i stop it
13:51 samcv i cannot launch my program :(
13:52 MasterDuke does --ll-exception show where it's happening?
14:00 samcv MasterDuke, https://gist.github.com/b6dfe9f89158a14b2c487351208a9934
14:03 MasterDuke oof, that's long and complicated. looks like you're doing something with roles?
14:03 samcv does augmenting count as roles?
14:04 samcv yeah if i uncomment this it stops erroring
14:04 MasterDuke don't really know, i haven't done much with either. brokenchicken might have some idea
14:04 samcv dammit
14:06 brokenchicken ?
14:06 brokenchicken idea of what?
14:06 brokenchicken Of that error? No idea.
14:07 MasterDuke samcv: maybe paste code that's causing it somewhere?
14:07 samcv well it's a whole lot of code
14:07 samcv my UCD rewrite
14:13 Geth MoarVM: MasterDuke17++ created pull request #514: JIT MVM_radix() like MVM_bigint_radix()
14:13 Geth MoarVM: review: https://github.com/MoarVM/MoarVM/pull/514
14:30 Geth MoarVM: samcv++ created pull request #515: Make radix 50% faster with Unicode Nd, add East_Asian_Width prop.
14:30 Geth MoarVM: review: https://github.com/MoarVM/MoarVM/pull/515
14:30 samcv kewl
14:33 MasterDuke ah, i thought you were going to be able to change `ch = atoi(MVM_unicode_codepoint_get_property_cstr(tc, ch, MVM_UNICODE_PROPERTY_NUMERIC_VALUE));` into ` ch = MVM_unicode_codepoint_get_property_int(tc, ch, MVM_UNICODE_PROPERTY_NUMERIC_VALUE));`
14:35 MasterDuke to get rid of the atoi() completely
14:37 agentzh joined #moarvm
14:45 ggoebel joined #moarvm
15:15 zakharyas joined #moarvm
15:22 FROGGS joined #moarvm
15:24 pyrimidine joined #moarvm
15:32 samcv eventually
15:33 samcv when the rewrite of ucd2c.pl i scomplete
15:33 samcv tho if it used the data my script that works already has we could do that
15:33 samcv and we'd use numeric_value_Numerator
15:33 samcv which would store integer values, (all the digits have 1 as denominator so it is fine)
15:34 samcv idk maybe we can merge the scripts before the whole rewrite is complete idk
15:34 samcv though that little change already makes it 50% faster, so making it not use atoi will make it prolly another 100% faster
15:34 samcv maybe more
15:36 MasterDuke cool
15:38 samcv same with decomposition and such
15:39 samcv i keep getting weird errors
15:40 samcv for $rev-hash.keys.sort(+*)  i am getting Too many positionals passed; expected 0 arguments but got 1
15:40 samcv wtf
16:06 domidumont joined #moarvm
16:20 pyrimidine joined #moarvm
16:45 geekosaur joined #moarvm
17:50 geekosaur joined #moarvm
18:34 agentzh joined #moarvm
19:03 agentzh joined #moarvm
19:18 pyrimidine joined #moarvm
19:43 pyrimidine joined #moarvm
20:08 agentzh joined #moarvm
20:47 agentzh joined #moarvm
21:29 pyrimidi_ joined #moarvm
22:13 agentzh joined #moarvm
22:34 geekosaur joined #moarvm
22:50 pyrimidine joined #moarvm
23:05 MasterDuke timotimo: i find this interesting. the (almost exactly) same code in nqp vs perl6 takes half the time in nqp, even though it's only speshed vs jitted in perl6
23:05 MasterDuke nqp: 'sub a() { my $f := nqp::open("small_compile.sql", "r");my str $l; my int $s := 0; while $l := nqp::readlinefh($f) { ++$s }; return $s }; say(a())'
23:05 camelia nqp-moarvm: ( no output )
23:06 MasterDuke perl6: 'use nqp; sub a() { my $f := nqp::open("small_compile.sql", "r"); my str $l; my int $s = 0; while $l = nqp::readlinefh($f) { ++$s }; return $s }; say(a())'
23:06 camelia rakudo-jvm fb4f16: OUTPUT«WARNINGS for <tmp>:␤Useless use of constant string "use nqp; sub a() { my $f := nqp::open(\"small_compile.sql\", \"r\"); my str $l; my int $s = 0; while $l = nqp::readlinefh($f) { ++$s }; return $s }; say(a())" in sink context (line 1)␤»
23:06 camelia ..rakudo-moar 5b3ac8: OUTPUT«WARNINGS for <tmp>:␤Useless use of constant string "use nqp; sub a() { my $f := nqp::open(\"small_compile.sql\", \"r\"); my str $l; my int $s = 0; while $l = nqp::readlinefh($f) { ++$s }; return $s }; say(a())" in sink context (line 1)␤»
23:06 MasterDuke whoops, didn't mean to actually run those
23:07 MasterDuke the perl6 version adds `use nqp`, and turns two binds into assigns, because you can't bind to native types in perl6
23:12 MasterDuke 44.25%  moar     libmoar.so          [.] MVM_string_utf8_decodestream
23:12 MasterDuke 22.10%  moar     libmoar.so          [.] find_separator.isra.6
23:13 MasterDuke 5.67%  moar     libc-2.24.so        [.] _int_free
23:13 MasterDuke ^^^ nqp version
23:13 MasterDuke 26.02%  moar     libmoar.so            [.] MVM_string_utf8_decodestream
23:13 MasterDuke 13.93%  moar     libmoar.so            [.] find_separator.isra.6
23:13 MasterDuke 5.32%  moar     libmoar.so            [.] MVM_interp_run
23:13 MasterDuke ^^^ perl6 version
23:34 njmurphy joined #moarvm

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