»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg camelia perl6: ... | irclog: irc.perl6.org | UTF-8 is our friend!
Set by sorear on 25 June 2013.
00:01 PZt joined, btyler joined 00:12 Psyche^_ joined 00:16 Psyche^ left 00:22 araujo left 00:23 araujo joined, araujo left, araujo joined 00:44 tgt left 00:53 thou left
dalek rl6-roast-data: 50d053e | coke++ | / (5 files):
today (automated commit)
01:06
01:37 eternaleye left 01:43 eternaleye joined 01:54 FROGGS left 03:16 woosley left 03:31 woosley joined 03:38 woosley left 03:42 panchiniak_ joined 03:43 panchiniak_ left 03:55 woosley joined 04:05 colomon left 04:10 preflex left, preflex_ joined, ChanServ sets mode: +v preflex_ 04:11 preflex_ is now known as preflex 04:13 colomon joined 04:17 raiph left 04:57 raiph joined 05:07 SamuraiJack joined 05:21 [Sno] left 05:35 fridim_ left 06:24 [Sno] joined 06:26 salv0 left
moritz \o 06:28
06:44 BenGoldberg left 06:52 xinming left, xinming joined 07:04 salv0 joined 07:08 kaleem joined 07:11 FROGGS joined
FROGGS o/ 07:23
07:26 bonsaikitten is now known as DrEeevil 07:39 ssutch left
moritz FROGGS: do you have any performance numbers for the JSON optimization patch? 07:43
FROGGS moritz: just that it was about 5.7s to parse the projects.json, and about 5.4s afterwards 07:45
moritz FROGGS: ok, thanks
FROGGS :o)
07:48 raiph left 07:55 dmol joined
dalek kudo/nom: e4385f8 | (Elizabeth Mattijsen)++ | t/spectest.data:
Remove winner.t for now, will get merged if needed
07:58
kudo/WINNER: 38f32bb | (Elizabeth Mattijsen)++ | t/spectest.data:
Make sure we test winner.t in WINNER branch
07:59
moritz tadzik: panda bootstrap is broken for me 08:01
==> Testing Shell::Command
test stage failed for Shell::Command: Tests failed
and later 08:02
Compiling lib/JSON/Tiny/Actions.pm to pir
build stage failed for JSON::Tiny: Failed building lib/JSON/Tiny/Actions.pm
why does it even go on when one failed?
lizmat and good *, #perl6!
moritz good moarning, lizmat
lizmat starting to work on tomorrow's release now
as I will be on the road most of the 2nd half of the day
and touristing in Copenhagen and Malmö tomorrow 08:03
tadzik moritz: yeah, the reason is that sometimes a non-zero exit status is returned even if everything went fine
that's why there are no other error messages from the command ran
when I tried to debug it, it started working perfectly and I couldn't reproduce it anymore :./
will try again today
moritz Out of memory: Kill process 11330 (perl6-p) score 215 or sacrifice child 08:06
Killed process 11330 (perl6-p) total-vm:1908136kB, anon-rss:1748792kB, file-rss:224kB
"or sacrifice child" now I'm slightly scared
DrEeevil ... ulimit? ;)
moritz DrEeevil: the problem with ulimit is that it doesn't mix with the JVM 08:07
FROGGS morning lizmat
DrEeevil moritz: the JVM has some funny ass-umptions about this universe 08:08
lizmat morning moritz, FROGGS!
08:08 zakharyas joined 08:14 nnunley left
timotimo how did all of S17 not get tested on rakudo.jvm today? :( 08:17
lizmat I have no idea... 08:18
problem is, "make spectest" on the jvm currently starts not testing files 1/3 the way through 08:19
08:19 zakharyas1 joined
lizmat also, there are currently some unstoppable threads started by the spectest 08:19
specifically for the ":every" supplies 08:20
that would interfere with tests following it when using the eval server
08:21 zakharyas left 08:25 salv0 left, salv0 joined
moritz uhm, ufo is a bit b0rked 08:27
env PERL6LIB=/home/mlenz/p6/ufo/blib/lib:/home/mlenz/p6/ufo/lib: prove -e 'perl6' -r t/
erm no, I'm b0rked 08:28
never mind :-)
08:33 baest_ is now known as baest
moritz ... and now ufo hangs :( 08:35
lizmat
.oO( Plan Nine From Outer Space )
08:38 labster left 08:42 labster joined
dalek kudo/nom: fd69fc5 | (Elizabeth Mattijsen)++ | docs/ChangeLog:
Some ChangeLog updates, tomorrow we have a release
08:44
FROGGS ohh, good point 08:46
dalek kudo/nom: 3b9ee86 | (Elizabeth Mattijsen)++ | docs/announce/2013.11.md:
Create stub for announcement 2013.11
kudo/nom: 95407f1 | (Elizabeth Mattijsen)++ | docs/announce/2013.11.md:
Made 2013.11 announcement up-to-date
09:01
lizmat would appreciate a set of eyes on the announcement / ChangeLog for omissions / errors 09:02
moritz has trouble believing that this "Elizabeth Mattijsen" had the least number of commits among all the contributors this month 09:07
lizmat probably a copy/paste error :-) 09:08
moritz I think 'grondilu' und L. Grondin are actually the same
and the 'foo' there should probably removed
lizmat and who/s foo?
moritz well, the script looks for strings like 'TimToady++'
and adds those ++'ed folks to the list of contributors 09:09
so I guess somebody wrote $foo++
dalek kudo/nom: 4fdd34d | moritz++ | docs/announce/2013.11.md:
[announce] clean up contributor list
lizmat ++foo is faster than foo++ by 10%"
hehe 09:10
09:13 btyler left
dalek kudo/nom: 1f34257 | (Tobias Leich)++ | docs/ChangeLog:
logged changes of run/shell and infix:<...>
09:21
kudo/nom: 8e6b19a | (Tobias Leich)++ | docs/ChangeLog:
typo
kudo/nom: 7f6b885 | (Elizabeth Mattijsen)++ | docs/release_guide.pod:
We also need File::Slurp, I just found out
09:22
FROGGS -These are only some of the changes in this release. For a more detailed list, see "docs/ChangeLog". 09:23
+These are only some of the changes mentioned in this release. For a more detailed list, see "docs/ChangeLog".
?
err
no
nvm
dalek kudo/nom: 180fcac | (Elizabeth Mattijsen)++ | docs/announce/2013.11.md:
Mention run/shell in announcement
09:24
09:24 iSlug joined
lizmat I intend to bump the NQP revision tomorrow morning 09:28
09:29 xinming_ joined
timotimo oh, oh, oh, should i get eqat into the stage0 and use it all over nqp to make it three times faster! (if it didn't do anything but substr+eq checks, that is) 09:30
FROGGS timotimo: if you intend to do it, then do it now, so there is time to test 09:31
for a certain definition of "now" :o)
09:33 xinming left
timotimo hm. should i worry about getting WINNER into rakudo before its release this month? 09:34
FROGGS no idea... my feeling is that there will be still a lot of movement and renaming
timotimo mhm 09:36
maybe i could get for -> $a, $b? working in nqp-parrot at least? 09:37
(which also causes better error messages in the case of having a too-short list for $a, $b, $c, even without "?"
so that would be nice)
FROGGS will a user hit that issue? 09:38
09:38 arnsholt_ is now known as arnsholt
timotimo hopefully not 09:38
except if they're a nqp user
FROGGS k
timotimo and developing a new language compiler i suppose
stage0 upgrades are so expensive :( 09:39
FROGGS yeah :/
timotimo yeah, i'll keep waiting until somebody really needs a new stage0 for something very worthwhile, and *then* i'll spread eqat all over nqp
09:39 denisboyun joined
timotimo it's already in the code the regex compiler creates, for example, so that's a step in the right direction 09:39
and the "lexreg optimisation" i made is mostly a cause for compilation failure, rather than any meaningful performance improvement 09:40
optimising rakudo seems hard. there seems to be a big thing that's slow that i'm just not getting my hands on. i suppose invocations are kind of costly? due to how awesome our signatures can get? 09:42
or method calls or something.
moritz due to parrot creating a GCable or two for every invocation
so allocations + GC 09:43
timotimo so is that a thing we'd have to change parrot for or can we get around some of that overhead by tweaking nqp/rakudo?
moritz I think parrot is hopeless here
timotimo: though iirc bigint allocation is also a bit slow 09:44
timotimo okay. and moarvm is already doing better, yes?
moritz timotimo: implementing a pool of allocated bigints might be helpful
timotimo hm. so if a bigint is no longer in use we can re-use an old one? or how do you propose the pool to work?
or are bigints immutable?
yeah, they certainly are 09:45
moritz well, under the hood they aren't
the mp_int construct
timotimo would i have to teach parrot to move garbage collected mp_ints into a pool to be overwritten the next time a bigint is created? 09:46
moritz maybe it can be solved at the NQP level somehow 09:48
iirc jnthn had some ideas
timotimo it seems i'd have to interact closely with the GC on that
ah. i wanted to come up with a benchmark to measure how much it's worth to skip known-length constructs after an "alt" regex.
09:49 darutoko joined
dalek p: af22bef | (Timo Paulssen)++ | src/vm/parrot/QAST/Compiler.nqp:
use eqat or ord for length-one literals in regex.
09:50
timotimo that was worded awkwardly 09:54
09:54 dakkar joined 09:55 denisboyun left
moritz use ord for length-one substrings, and eqat for longer substrings 09:56
09:57 jnthn left
timotimo yes 09:59
moritz rages against $work code he can't wrap his head around 10:01
timotimo oh, i wonder if "add $foo, 1" is slower than "inc $foo" 10:03
10:03 berekuk joined
timotimo well, no reason to have an add 1 instruction generated if it could just as well be inc. 10:11
FROGGS if it does the same, yes 10:13
10:16 berekuk left 10:21 fhelmberger joined 10:26 brrt joined 10:33 jnthn joined, darutoko left
jnthn Hello, #perl6 10:34
moritz good antenoon, jnthn 10:35
timotimo huh, do we never generate literal zerowidth nodes in qregex?
jnthn timotimo: No, 'cus literal doesn' support zerowidth, iirc 10:36
timotimo it's easy for it to do so, though
at least the part in QAST/Compiler
10:37 darutoko joined
FROGGS hi jnthn 10:37
timotimo if there's any <?before 'foo'> in nqp's or rakudo's grammar, that could be turned from a subrule call into a simple inlined literal
probably not worth much, though.
jnthn True, they could. 10:40
And making it work is "just" not adding
timotimo the way i see it, it'd be enough to put a "unless $node.subtype eq 'zerowidth'" after the ... yes
jnthn Be sure to support the negate case too if that ain't already done.
timotimo negate is in there already 10:41
negate zerowidth doesn't need additional work, right?
jnthn It actually avoids a call to before *and* before calling the thunk...
No, not if negate is in there already.
timotimo good
jnthn So long as you only do it for things that are precisely a literal I think you're fine. 10:42
Though...
r: 'i like food' ~~ /<?before foo> food/; say $/ 10:43
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«「food」␤␤»
jnthn r: 'i like food' ~~ /<before foo> food/; say $/
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«「food」␤ before => 「」␤␤»
jnthn timotimo: Note ^^ difference. Make sure yo check that the before call is non-capturing. 10:44
Need to look at .name iirc
timotimo sounds good
jnthn Just checking the before call is zerowidth won't but it because
r: 'i like food' ~~ /<foo=?before foo> food/; say $/
camelia rakudo-parrot 180fca: OUTPUT«「food」␤ foo => 「」␤ before => 「」␤␤»
..rakudo-jvm 180fca: OUTPUT«「food」␤ before => 「」␤ foo => 「」␤␤»
jnthn oh hmm :) 10:45
bbi10 10:46
timotimo there's actually a few befores in rakudo's grammar that could be sped up this way 10:48
there's also a few mentions of <?before \S> for example, which could just become a zerowidth enumcharlist/en^H^Hcharrange 10:51
but many before's have alt or altseq in them
of course <?before \s | '#'> could just as well be turned into a zerowidth combined character class 10:52
that'd be a bit more advanced and applicable less often
FROGGS timotimo: it would if a # in <?[ ]> would work :/ 10:53
timotimo :)
oh, $node.subtype could already be ignorecase for literal, that's probably why it doesn't have a zerowidth option 10:54
so it could only be either of the two :(
ah, moar already had code in place to support zerowidth literals 10:57
10:58 brrt left
jnthn \S is a cclass, not enumcharlist 11:08
timotimo ah, right 11:09
in that case, it goes back to the cached multilevel bitmap thingie moritz and i started prototyping outside of nqp
11:15 rindolf joined 11:22 salv0 left, salv0 joined 11:36 markov joined 11:39 denis_boyun joined 11:53 iSlug left, iSlug joined 11:56 odoacre_ left 11:58 denis_boyun left 12:07 kurahaupo2 left
lizmat onwards to Copenhagen 12:10
I'll be trying to cut the release tomorrow morning, about 20 hours from now
be sure to make your code work (TM) :-)
cu all later&
FROGGS I'll do some testing and let you know :o) 12:11
12:11 lizmat left 12:14 robinsmidsrod left, tgt joined, tgt left 12:16 robinsmidsrod joined 12:34 woolfy left 12:35 xenoterracide left 12:37 xenoterracide joined 12:52 telex left 12:54 mstwu00 joined 12:56 telex joined
timotimo say, jnthn, couldn't i just in general wrap whatever's inside the <?before > into something like a concat that has zerowidth? 13:01
i don't see why that wouldn't work for everything
jnthn timotimo: concat really is very very simple 13:02
13:02 FROGGS left
jnthn timotimo: I mean, it doesn't make a mark or anything 13:02
timotimo well, i just want something that can do zerowidth and contain other things, so maybe not concat specifically 13:03
13:04 FROGGS joined
jnthn timotimo: I'd not over-optimize the complicated cases 13:07
timotimo: Anything that captures is gonna get icky fast 13:08
timotimo: I'd just look for cases where <?before single_thing> where single_thing is easy to zero-width already, for the time being...
timotimo: The more that happens inside the before, the less significant its overhead comes.
13:10 denisboyun joined
timotimo right. 13:10
curiously, /^<?before foobar>/ generates a concat of a scan and a literal inside the before 13:11
that can't be right?!
jnthn timotimo: It's just that scan ends up in everything, I think...
timotimo oh, hm.
jnthn timotimo: It'll never actually scan 'cus from will never be -1
timotimo should i throw it away if i do this specific optimisation? 13:12
jnthn We could actually suppress generating that in the case we know we can never possibly scan.
Yes, you can.
timotimo thanks :)
jnthn You'll have a pass to throw away too
timotimo i do
can i do the same thing if the name was "after"? because the qregex will be flipped so that it matches in reverse? or something like that? 13:15
it kind of irks me that i can't combine subtype zerowidth with subtype ignorecase 13:21
jnthn I'd leave "after" alone... 13:23
It's uncommon and yeah, it's evil...
The string has to be flipped as well as the regex.
13:23 xenoterracide left
timotimo well, i'll get the already-flipped qast where i'm at 13:25
but i'll leave it alone for now.
13:26 prevost joined
timotimo tries to compile the first prototype 13:27
+@$a_qast_node should work, right? 13:29
as in +@$a_qast_node == 1
moritz nqp: my $a := ['a', 'b']; say(+@$a) 13:30
camelia nqp-jvm: OUTPUT«Confused at line 2, near "say(+@$a)"␤ in panic (gen/jvm/stage2/NQPHLL.nqp:379)␤ in comp_unit (gen/jvm/stage2/NQP.nqp:922)␤ in TOP (gen/jvm/stage2/NQP.nqp:820)␤ in parse (gen/jvm/stage2/QRegex.nqp:1251)␤ in parse (gen/jvm/stage2/NQPHLL.nqp:1378)␤ in …»
..nqp-moarvm: OUTPUT«Confused at line 2, near "say(+@$a)"␤panic␤»
..nqp-parrot: OUTPUT«Confused at line 2, near "say(+@$a)"␤current instr.: 'panic' pc 16308 (gen/parrot/stage2/NQPHLL.pir:6020) (gen/parrot/stage2/NQPHLL.nqp:426)␤»
moritz nqp: my $a := ['a', 'b']; say(+$a)
camelia nqp-moarvm, nqp-jvm, nqp-parrot: OUTPUT«2␤»
jnthn +@($a_qast_node) # works 13:31
YOu need the parens
timotimo ah 13:32
good to know
well, nqp still compiles 13:34
(turns out it never actually ran the optimization) 13:38
13:38 ajr joined 13:39 ajr is now known as Guest19081, Guest19081 is now known as ajr_ 13:40 PacoAir joined 13:44 tgt joined
timotimo wrote QAST::QRegex instead of QAST::Regex %)^H^Hm) 13:45
er, those backspaces were swallowed apparently
13:54 stevan_ left 13:55 kaleem_ joined
timotimo jnthn: i think i'm running into trouble because i'm simply throwing away a QAST::Block. at least it now gives me errors like Could not find sub cuid_14_1384955545.6123 13:55
13:56 kaleem left 14:01 tgt left
jnthn timotimo: ah, yeah...you can't just toss those out of the tree as they will already have made it into the SC... 14:02
timotimo: The Rakudo optimizer just empties them of content and adds a QAST::Op.new( :op('die'), QAST::SVal.new( :value('Optimized out code executed!') ) ) or so 14:03
14:04 btyler joined 14:05 kbaker_ joined
timotimo ah, ok 14:05
where do i throw it, then?
can it become just an extra child for cclass, literal, enumcharrange, ... that won't be looked at by the actual QRegex compiler, but will still be compiled for the SC? 14:06
jnthn I'd just throw it in the QAST::Stmts [0] of the surroudning block. 14:07
timotimo hm, do i even have access to it where i am? :\
jnthn I dunno, where are you? 14:08
An optimizer really should know what block it's currently in... :)
At worst you can shove it in a $*CUR_BLOCK when you are walking the tree...
timotimo actually, i'm in the actions of p6regex 14:09
jnthn I thought you were implementing optimizations?
timotimo but the code could just as well live in the optimizer
jnthn s/could just as well/should/
timotimo that gives me another problem, though
how do i re-use the optimizations in rakudo?
jnthn Factor them into a QRegex::Optimizer class, and use that in both NQP's and Rakudo's optimizer, maybe. 14:10
timotimo that sounds sane.
jnthn Could go with a role, but I think simple delegation is saner in this case. 14:11
timotimo probably is, yeah 14:12
i thought the benefit of putting it in the actions is that i don't have to manually walk the whole tree to find the few instances where i can do my optimization
14:12 jnap joined
timotimo well, before i move it over, i want to get it to at least work :) 14:13
so i'll do the current_block dynamic variable trick you told me about and see if i can get it to work, then i'll clean it up
jnthn Well, but the optimizer already goes walking the tree.
timotimo it doesn't descend into qregex i believe 14:14
jnthn Right, it currently says "oh, regexes, I don't know how to optimize those" :) 14:15
timotimo there's something called $*RX that seems to be helpful to my current subgoal 14:17
oh. it's NQPMu at that particular moment >_> 14:18
jnthn argh ffs I need to teach the folks who made WPF a class in API design and making the easy things easy or something :/
uh, ww :) 14:19
jnthn has enough other things to rant about here without ranting about WPF here too... :)
timotimo ah, i didn't look closely enough, it's actually %*RX and it just stores information, not the block i'm in 14:20
i should move the code to the optimiser now.
fwiw, i already have a regex optimizer stubbed in a different branch 14:21
colomon had the smoke tester results script running for so long he doesn't remember how to reboot it (after the power outage) 14:24
timotimo hum. i even jogged today, but they're still not shipping my new laptop :( 14:25
tadzik maybe pushups will help :P 14:27
14:27 btyler left, rindolf left
timotimo my wrists are not fond of push-ups 14:28
14:29 kaleem_ left
colomon masak: HTML::Template started failing smoke tests this week 14:34
14:36 darutoko left, bluescreen10 joined 14:48 mstwu00 left 14:49 nnunley joined 14:54 btyler joined 14:59 thou joined 15:02 tgt joined, FROGGS left 15:07 kaare_ joined 15:15 FROGGS[mobile] joined 15:16 stevan_ joined 15:19 stevan_ left 15:20 stevan_ joined
timotimo now i'm getting Method 'backtrack' not found for invocant of class 'NQPMu' so i think i'm not transferring something over that i should. 15:22
the dump unfortunately seems to elide something
masak colomon: I'll have a look. thanks. 15:26
15:27 darutoko joined
masak colomon: I just ran the tests on Rakudo 853e255 and they all passed. 15:40
compiling 180fcac now to run them again.
jnthn An appropriate sha-1 if it's now broken... 15:43
It used to work, then it did a 180, f'ing cac!
masak jnthn: excuse me? 15:45
jnthn :)
masak: cac(k) is slang for "crap" :)
masak oh! 15:46
is it perchance baby language too?
for the same thing.
jnthn Actually I mostly heared it used by teenagers :P
*heard
So basically, yeah, baby language :P
masak :P 15:47
timotimo i had another QAST::QRegex in there >_<
can we get a parameter on NQPMu that tells us what expression caused the NQPMu to get created? >_< 15:48
jnthn timotimo: We could just fix it to while about undeclared symbols... 15:49
*whine
timotimo i guess we could 15:50
jnthn Which I've no idea why it doesn't.
'cus we don't/won't have listops in NQP
15:54 Gwyxx is now known as SL-RHanson 15:57 FROGGS[mobile] left 15:58 FROGGS joined
timotimo i seem to have made it work 16:03
16:03 bluescreen10 left
timotimo not sure how to get the NQP Regex Optimizer into the rakudo optimizer though 16:06
could someone verify if nqp passes its qregex tests and its regex-interpolation tests?
jnthn Well, where'd you put it?
timotimo NQP/Optimizer ;)
jnthn Oh... 16:07
Maybe stick it in QRegex library?
No, not there
NQPP6QRegex I mean
FROGGS rp: use NQP::Optimizer:from<NQP>
camelia rakudo-parrot 180fca: OUTPUT«===SORRY!===␤"load_bytecode" couldn't find file 'NQP/Optimizer.pbc'␤»
timotimo well, wherever i put it, the optimizer of NQP needs to find it, too :P
FROGGS: not like that :)
jnthn Along with P6Regex::Grammar and P6Regex::Actions, you'll have P6Regex::Optimizer
FROGGS :o)
timotimo the rakudo optimizer is also in nqp
but that sounds good. 16:08
jnthn Yes, but NQP and Rakudo both use NQPP6QRegex :)
timotimo will i need to call back into the main language optimizer if i encounter a Block, btw?
jnthn Also, that is the most acronym library name...
timotimo: Up to you...
japhb_ r: constant %foo = ().list; say %foo.perl;
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«().list␤»
japhb_ ^^ Is that a bug, or me being silly?
timotimo it seems like both 16:09
jnthn japhb_: It's me not really grokking how constant is meant to work and wanting a model rather than just hacking something... :)
tadzik r: my %foo = ("a", 5); say %foo.perl
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«("a" => 5).hash␤»
jnthn japhb_: So right now it doesn't impose any context or check anything...
tadzik looks legit to me
japhb_ Ah.
tadzik r: my %foo = ("a", 5).list; say %foo.perl
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«("a" => 5).hash␤»
tadzik oh
jnthn Oh...it does .hash it?
I didn't now that :) 16:10
tadzik well, it's a hash container
I'd expect that :)
japhb_ tadzik: That was actually golfed down quite a bit.
16:10 daxim left
tadzik but constant doesn't trigger it 16:10
jnthn Right, I just didn't thing that it'd been tweaked to do it.
Oh...sorry, you wrote my
And I read constant.
Well, yeah, we could simply .list or .hash the RHS depending on sigil
tadzik r: my constant %foo = ("a", 5).list; say %foo.perl
camelia rakudo-parrot 180fca, rakudo-jvm 180fca: OUTPUT«("a", 5).list␤»
timotimo t/nqp/49-regex-interpolation.t ........ 1/? Unrecognized regex metacharacter + (must be quoted to match literally) at line 2, near "b+" - i did a wrong :(
tadzik best of both worlds? :P
jnthn timotimo: looks like 16:11
16:11 ajr_ left
jnthn Those tests pass for me on Moar and did on other backends last I knew. 16:11
timotimo d'oh
# got: Unrecognized regex metacharacter + (must be quoted to match literally) at line 2, near "<+upper>+" 16:13
masak r: my %h = 4
camelia rakudo-parrot 180fca: OUTPUT«Odd number of elements found where hash expected␤ in method STORE at gen/parrot/CORE.setting:8810␤ in block at /tmp/_8sZDgKNUk:1␤ in any at /tmp/_8sZDgKNUk:1␤ in any at gen/parrot/stage2/NQPHLL.nqp:1146␤ in any eval at gen/parrot/stage2…»
..rakudo-jvm 180fca: OUTPUT«Odd number of elements found where hash expected␤ in method STORE at gen/jvm/CORE.setting:8785␤ in block at /tmp/w9Z82qaM0f:1␤ in any eval at gen/jvm/stage2/NQPHLL.nqp:1086␤ in any evalfiles at gen/jvm/stage2/NQPHLL.nqp:1292␤ in any command_…»
timotimo huh?
masak re constant hash: I'd very much expect 'constant' to give the above warning just as much as 'my'.
timotimo i must have left something in some other file or something
masak submits rakudobug
FROGGS masak++ 16:14
tadzik r: constant %h = 4
camelia ( no output )
tadzik phihihi
jnthn That one is, like, so already in RT.. 16:15
masak I will look for it.
p: constant %h = 1, 2; say %h.WHAT 16:17
camelia rakudo-parrot 180fca: OUTPUT«(Parcel)␤»
masak that's rt.perl.org/Ticket/Display.html?id=111944
I will attach the current complaint to it.
16:18 ajr joined, ajr is now known as Guest15521 16:19 Guest15521 is now known as ajr_, fhelmberger_ joined
dalek p: bdbb63a | (Timo Paulssen)++ | src/vm/parrot/QAST/Compiler.nqp:
tiny performance tweaks in the parrot regex compiler
16:21
timotimo another tiny snippet of regex fasterness for you :)
16:22 beastd joined, fhelmberger left 16:23 daxim joined, iSlug left 16:24 fhelmberger_ left 16:25 [Sno] left
japhb_ (another fasterness)++ 16:25
tadzik timotimo: does that bring some noticable win, ooc?
japhb_ masak++ # RT wrangling 16:26
timotimo tadzik: that commit i just pushed?
tadzik aye
timotimo probably not more than a centillion
tadzik :)
timotimo er, centillionth 16:27
tadzik still nice
timotimo maybe a bajillionth
it's an optimisation that doesn't cost any run- or compiletime, though
so it's a strict win, no matter how little
tadzik yep 16:28
timotimo that's what i'm all about, you see? :P
i ignore the big flaws and just improve the tiny details 16:29
tadzik timotimo++ :)
16:37 kaleem joined
timotimo jnthn: should all Regex nodes have min and max? or should they be made available once you set either of them with a role like compile_time_value does? 16:38
because it seems like only quant actually needs it
masak colomon: aha! 16:39
colomon: two "Failed to parse the template" errors.
my bet is that something has changed with grammars between those two revisions. 16:40
investigation pending -- currently spread over washing clothes and baking cinnamon buns :)
jnthn timotimo: I think only quant needs them, but not sure we have enough QAST::Regex nodes to be worth the mixin overhead...
16:41 stevan_ left
timotimo should i measure? :) 16:41
diakopter anyone going to the london perl workshop?
timotimo i'm going through all Regex nodes anyway
jnthn Could do, but remember that you have different cost models on different VMs.
diakopter: Not me. 16:42
16:43 ajr_ left
timotimo jnthn: yeah, i'll leave it be then. 16:44
16:45 raiph joined, ajr_ joined
diakopter anyone else going to LPW? 16:54
timotimo by not changing any negated things, i get the tests to stay passing. sadface :( 16:56
16:56 ajr_ left 16:58 ajr_ joined 16:59 prevost left
timotimo oh, i was apparently wrong 16:59
i think my handling of cclass may be wrong still. 17:00
17:01 rurban1 joined
timotimo oh no, it takes 120 seconds instead of 104! 17:06
(well, maybe i shouldn't be running 10 different things at the same time ... ) 17:07
17:07 kaleem left
jnthn
.oO( Pessimization )
17:08
dalek -pb: 82af612 | (Geoffrey Broadwell)++ | lib/PB/Model/Generator.pm:
Add speculative comment in PB::Model::Generator
-pb: b1569a3 | (Geoffrey Broadwell)++ | lib/PB/Binary/Writer.pm:
Refactor and extend write-message()

Factor out wire type map and value encoding, and sketch support for repeated fields (no packed handling yet, though).
timotimo japhb_: cool :)
17:08 zakharyas1 left
japhb_ :-) 17:08
jnthn <multi-lang-pun>If you *pes*simize it, it goes slow as a dog...</multi-lang-pun> 17:09
17:11 ajr_ left 17:12 ajr_ joined
timotimo the "before" optimization doesn't save a noticable amount of time in stage parse of the setting unfortunately 17:12
but currently i'm skipping negated befores and cclasses 17:13
well, most of the befores had already been optimized to be call-less befores 17:14
i'm thinking i should revert the changes from <?before '['> to <?[\[]> again, so that it'll be a literal check instead of a enumcharlist, because that should just get the ord and do an integer comparison 17:15
jnthn timotimo: Well, or just make an enumcharlist of 1 char turn into a literal... :) 17:16
As a more general opt.
timotimo ah, sure 17:17
would you be fine with that optimisation going into the Actions instead of the Optimizer? 17:20
that's also where it decides to create charrange instead of enumcharlist.
jnthn I think I'd prefer that one goes into the optimizer, so it can work on enumcharlists however they happen to come about... 17:21
timotimo well, at that point i already know if there's just a single range, rather than multiples
and don't have to go through the string and compare all the ords 17:22
17:23 jeff_s1 left
jnthn timotimo: Yes, I'm not saying move the range one. 17:24
timotimo ah, oops :)
jnthn timotimo: I'm saying put the one char enumcharlist -> literal one in the optimizer.
timotimo i'm confused. now i'm getting "Missing or wrong version of dependency 'gen/parrot/stage2/QRegex.nqp'"?! 17:25
ah, whoops
i still had a compilation running in the background that probably blocked the file
17:26 jeff_s1 joined 17:31 kbaker_ left
timotimo ah, i see! 17:31
i need to merge the negatedness of the cclass with the negatedness of the before 17:32
jnthn Yes, if you want it to not not be right...
timotimo so .. :negate($one.negate != $other.negate), is that right?
17:32 ajr_ left
timotimo no, that gives 1 for 0 0 17:33
jnthn xor?
timotimo yeah, i need that one
nqp: say(nqp::xor(1, 1))
camelia nqp-jvm: OUTPUT«java.lang.NullPointerException␤ in (gen/jvm/stage2/NQPCORE.setting:672)␤ in print (gen/jvm/stage2/NQPCORE.setting:671)␤ in say (gen/jvm/stage2/NQPCORE.setting:678)␤ in (/tmp/mL_PQi91OW:1)␤ in (gen/jvm/stage2/NQPHLL.nqp:1100)␤ in eval (gen/jvm/sta…» 17:34
..nqp-moarvm: OUTPUT«Error while compiling op xor (source text: "nqp::xor(1, 1)"): No registered operation handler for 'xor'␤frame_name_1109␤»
..nqp-parrot: OUTPUT«␤»
17:34 zakharyas joined
timotimo wow, oopsie-daisies 17:34
nqp: say(1 ^ 1)
camelia nqp-jvm: OUTPUT«Confused at line 2, near "say(1 ^ 1)"␤ in panic (gen/jvm/stage2/NQPHLL.nqp:379)␤ in comp_unit (gen/jvm/stage2/NQP.nqp:922)␤ in TOP (gen/jvm/stage2/NQP.nqp:820)␤ in parse (gen/jvm/stage2/QRegex.nqp:1251)␤ in parse (gen/jvm/stage2/NQPHLL.nqp:1378)␤ in…»
..nqp-moarvm: OUTPUT«Confused at line 2, near "say(1 ^ 1)"␤panic␤»
..nqp-parrot: OUTPUT«Confused at line 2, near "say(1 ^ 1)"␤current instr.: 'panic' pc 16308 (gen/parrot/stage2/NQPHLL.pir:6020) (gen/parrot/stage2/NQPHLL.nqp:426)␤»
17:34 ajr joined 17:35 ajr is now known as Guest92921
timotimo nqp: say(nqp::bitxor_i(1, 1)) 17:35
17:35 Guest92921 is now known as ajr_
camelia nqp-moarvm, nqp-jvm, nqp-parrot: OUTPUT«0␤» 17:35
timotimo there we go. just hope they'll always be 0 or 1 :)
17:39 [Sno] joined 17:40 ajr__ joined 17:41 ajr_ left
timotimo yeah, the performance difference isn't very noticable :( 17:44
17:44 beastd left
timotimo oh well. i'll try to integrate the regex optimizer into rakudo now 17:44
dalek kudo-star-daily: 6b43502 | coke++ | log/ (5 files):
today (automated commit)
17:46 zakharyas left, ajr__ left
FROGGS preflex: tell lizmat Here are spectest results gist.github.com/FROGGS/9304a3aba8a6f9a4cc04 17:46
preflex Consider it noted.
17:49 ajr_ joined, Rotwang joined 17:50 jeff_s1 left
timotimo how do i test something related to capturing with befores? 17:54
i'm not sure what i need to be aware of there ...
FROGGS does that capture at all? I thought not 17:55
timotimo i may be able to make it capture and it'd break if i'm not careful enough in the optimization
17:55 ajr_ left
timotimo oh, crud, i still have some broken tests in here 17:56
17:56 iSlug joined
timotimo didn't the tests all pass just a bit ago? :\ 17:56
17:57 ajr joined, ajr is now known as Guest51083
FROGGS timotimo: nqp-p passes here 17:58
timotimo yes, it's my optimization causing trouble with parsing regexes apparently 17:59
FROGGS btw, I tend to create diffs locally if I fiddle with it longer...
git diff >201311201900.diff 18:00
timotimo i commit instead :)
FROGGS hummm 18:03
nqp-j fails one qregex test, where nqp-p does not:
t/qregex/01-qregex.t (Wstat: 0 Tests: 748 Failed: 1)
Failed test: 492
18:03 jeff_s1 joined
FROGGS is that known? 18:03
timotimo can you look what test that is? 18:05
18:05 kurahaupo joined
moritz test 492 :-) 18:07
18:07 REPLeffect joined, jeff_s2 joined 18:09 jeff_s1 left
timotimo i can't see a harmful transformation that's being done :\ 18:09
so it's a fiendish transformation, most likely
FROGGS ok 491 - negated allows ws
not ok 492 - negated character range
not ok 493 - illegal character range# TODO reversed character range
timotimo oh? 18:10
could i have b0rked that?
18:10 darutoko left
timotimo i recently touched character ranges. 18:10
18:10 Guest51083 left
timotimo can you put if $node.negate { return self.enumcharlist($node) } at the beginning of method charrange in src/vm/jvm/QAST/Compiler.nqp and see if it's still broken, please? 18:12
18:12 ajr_ joined
timotimo oh, i see what's going on 18:13
18:13 jeff_s1 joined
timotimo there's an ifge that should be a ifgt 18:13
feel free to attempt that fix and commit it if you have a moment
i think i need a nap :|
18:13 ssutch joined
dalek p/simplify_before: aadd31e | (Timo Paulssen)++ | src/vm/ (2 files):
teach parrot and jvm about zerowidth literals
18:13
p/simplify_before: 0e3b819 | (Timo Paulssen)++ | src/QRegex/P6Regex/Actions.nqp:
first draft of a before-assertion simplifier.
p/simplify_before: 060b723 | (Timo Paulssen)++ | src/ (2 files):
NQP RegexOptimizer for before assertions
p/simplify_before: 06b8477 | (Timo Paulssen)++ | src/NQP/Optimizer.nqp:
less debug output
p/simplify_before: 29a6eb5 | (Timo Paulssen)++ | src/NQP/Optimizer.nqp:
need to factor in both negations.
p/simplify_before: 0de4547 | (Timo Paulssen)++ | src/QAST/Regex.nqp:
more dump output for Regex nodes.
timotimo if you want to, you can play around with this branch. it won't run all spectests successfully, though :(
18:14 jeff_s2 left 18:19 rindolf joined, ajr_ left
[Coke] apparently does not have rights to update post-commit hooks on nqp & parrot. can someone who does remove the sends to #parrot ? 18:29
FROGGS [Coke]: I'd think that these commit go to dalek and dalek itself must be tweaked 18:30
[Coke] FROGGS: no, it's a post-commit hook on github. 18:31
FROGGS I have no admin rights either though to actually check that
[Coke]: but the IRC hook is for one channel only 18:34
[Coke] FROGGS: no, you can specify multiple channels.
the hook posts to dalek. dalek posts to IRC. 18:35
the hook that posts to dalek specifies any number of channel/server combos.
FROGGS room - Supports single or multiple rooms (comma separated). Also supports room passwords (room_name::password). Prefixing '#' to the room is optional.
yeah
[Coke] so github is the thing that needs changing.
FROGGS jnthn: can you have a look?
jnthn: or give me admin rights :o) 18:36
18:37 iSlug left
Rotwang hi 18:38
I'm trying to comprehend this code: github.com/grondilu/libdigest-perl.../Digest.pm 18:39
what is: my \foo ?
18:40 jeff_s1 left, jeff_s1 joined
FROGGS Rotwang: a declaration of a sigil-less variable 18:41
[Coke] sigil-less variable.
you can then use it later as a bare foo
Rotwang cool, although it looks ugly 18:43
FROGGS true :o)
TimToady the alternative is to blow up if anybody ever defines a 'foo' type 18:46
18:46 berekuk joined
TimToady or come up with a less ugly method of saying "this isn't meant to be a type constraint" 18:47
FROGGS the alternative is to use $foo
TimToady no
that itemizes
\foo is just a bare parcel binding without itemization
FROGGS ahh, it is not just about style?
TimToady no
it just happened that after we added it to signatures to do parcel binding, it works for 'my' too :) 18:48
FROGGS well I have just the rosettacode examples in mind where you said that it would look more like a mathematical formula in the end
TimToady we could, instead, add another declarator, I suppose, but we'd still need to have the \ in siggies, so it doesn't help that much
or something to do what \ does
FROGGS but yeah, I knew about its behaviour in signatures... just wasn't aware that it had that meaning in Digest.pm 18:49
TimToady in fact, it doesn't exactly create a variable, just an alias
r: my \foo = 42; foo = 43;
camelia rakudo-jvm 180fca: OUTPUT«Cannot modify an immutable value␤ in block at /tmp/ZJnxNYBYe6:1␤ in any eval at gen/jvm/stage2/NQPHLL.nqp:1086␤ in any evalfiles at gen/jvm/stage2/NQPHLL.nqp:1292␤ in any command_eval at gen/jvm/stage2/NQPHLL.nqp:1196␤ in any command_eval at…»
..rakudo-parrot 180fca: OUTPUT«Cannot modify an immutable value␤ in block at /tmp/R4WPDfJCR9:1␤ in any at /tmp/R4WPDfJCR9:1␤ in any at gen/parrot/stage2/NQPHLL.nqp:1146␤ in any eval at gen/parrot/stage2/NQPHLL.nqp:1133␤ in any evalfiles at gen/parrot/stage2/NQPHLL.nq…»
FROGGS I don't think replacing \ by something else makes it better :o)
TimToady as you see, foo doesn't vary :)
it's our SSA form of assignment currently 18:50
FROGGS mhm
japhb TimToady, What is the linguistics term for languages like German that tend to build long compound words?
FROGGS .oO( my *FOO = 42 )
TimToady hmm, agglutinative maybe?
japhb
.oO( It's linguistics, it can't be OT in #perl6 ... )
FROGGS japhb: I like that btw, and I find split-up-words very disturbing 18:51
well, maybe not "very", but still
japhb One's natal language's customs are comforting, I think. 18:52
FROGGS possibly :o)
TimToady well, it helps to have some standardish word endings so that the internals of the word tend to be self-clocking
18:53 berekuk left
TimToady the greeks had standard enough word endings that they didn't need word spacing at all, or didn't think they needed it :) 18:53
japhb Wikipedia has an entire category tree for agglutinative languages. 19 sub-categories and 370 pages directly at the top level. 18:54
TimToady in german most of your verbal prefixes would end -en
.oO( sitzen Sie down und watchen die Blinkenlights )
18:55
FROGGS hehe
jnthn [Coke]: Remove the hooks for reporting of commits to nqp and *parrot*? Doesn't #parrot want to know about Parrot commits? Or did you mean NQP and Rakudo? 18:56
[Coke]: Done the nqp one, anyways...
TimToady my father used to quote: "Die Kuh hat über die fence gejumped, und hat der Cabbage verdamaged." 18:57
er, Fence
FROGGS ewww
that is bad Germish 18:58
arnsholt TimToady: At least most people don't have to worry about rendering boustrophedon digitally =)
18:58 SamuraiJack left
TimToady well, mixed ltr and rtl languages are worse 18:58
arnsholt I wouldn't call German agglutinative, though
TimToady that's mostly used on verbs, if I recall
eskimo and such 18:59
arnsholt Compounding isn't orthogonal to agglutinativity, but at a bit of an angle
TimToady well, you probably remember a lot more linguistics than I do :)
FROGGS Klingon certainly is
arnsholt I'd class German as more analytic than agglutinating, but with some variability in word order 19:00
TimToady my `foo = 42;
that would be slightly prettier
FROGGS true
TimToady and only recognized in siggies 19:01
so we're still kinda reserving ` for user, er, use
arnsholt japhb: Oh, and English makes compound words quite frequently as well. It's just that they're mostly written with spaces in between, so they're not as obvious on the page
jnthn doesn't look better than \ to me :)
uh
`
...also my ` key is sticky, so don't change it :P 19:02
TimToady snerks
FROGGS *g*
then we need to get rid of all C-s
jnthn: don't you have a new laptop? 19:03
jnthn FROGGS: Yeah, but working on my desktop at the moment
TimToady y'know, new keyboards are really cheap these days
FROGGS jnthn: well, keyboards tend to have a plug
TimToady: not the primus maximus or what it was called
jnthn I didn't realize my ` key was icky until just now :) I don't type those too often... :)
FROGGS about 1.800 €
TimToady obviously you don't exercise it enough 19:04
FROGGS usually a perler is used to `
TimToady you don't have to reach for qx :P
FROGGS that reminds me that qx is broken atm :/ 19:05
(it does not pass %*ENV along)
[Coke] jnthn: no, remove the rakudo & nqp notifications -to #parrot-. leave parrot/parrot notifications alone.
jnthn [Coke]: Rigth, that's what I guessed you meant, but wanted to check :) 19:06
[Coke] jnthn++ excellent guesser.
[Coke] holds up a single finger.
[Coke] gives up on charades and #dayjobs.
dalek kudo/nom: 8e6b19a | (Tobias Leich)++ | docs/ChangeLog:
typo
kudo/nom: 7f6b885 | (Elizabeth Mattijsen)++ | docs/release_guide.pod:
We also need File::Slurp, I just found out
kudo/nom: 180fcac | (Elizabeth Mattijsen)++ | docs/announce/2013.11.md:
Mention run/shell in announcement
jnthn uh, bother, wrong button... 19:07
Anyway, done :)
19:07 berekuk joined, tgt left
FROGGS umm, my Inline module still depends on File::Spec, which is broken and rubbish nowadays 19:08
jnthn FROGGS: Didn't File::Spec make it into core?
japhb The IO::Spec API is damn near the same, and in core.
FROGGS jnthn: yes :o) 19:09
japhb (In fact, it's slightly simpler)
FROGGS I know I know... I just need to update the META.info I guess
ohh dear, just the META.info required it, not even the code -.- 19:10
btw, is "github:FROGGS" a nice auth? 19:12
japhb_ Certainly looks good to me. 19:14
I think github definitely rises to the ranks of cpan as being a well known account authority for Perl programmers. 19:15
FROGGS cool, just need to wait for projects.json being generated and then I can test
not only for Perl, but yes
japhb_ Well sure. 19:16
FROGGS I trust github where I don't trust sourceforge for example
japhb_ ditto
FROGGS soureforge is more like: here after the ad please download one of a bunch of zipfiles
19:19 berekuk left
TimToady crumb, getting a (hopefully painless) migraine--but I can't see what I'm typing very well... 19:19
so afk for a bit...
FROGGS ó.ò
see you
19:20 lizmat joined
lizmat is finally on the ferry to Rødbyhavn 19:22
preflex lizmat: you have 1 new message. '/msg preflex messages' to read it.
19:25 iSlug joined
jnthn lizmat: OH, I think that's the one they shove trains on too :) 19:25
lizmat yup, they do, although not on this particular one, afaik 19:26
jnthn :)
It putt-putts its way over the sea from Puttarden, iirc :) 19:27
19:27 tgt joined
jnthn *Puttgarden 19:27
lizmat seems I'm losing my internet: there's no Wifi on board that works
see you on the other side 19:28
19:28 lizmat left 19:42 iSlug left 19:44 sqirrel joined 19:58 raiph left 19:59 lizmat joined
lizmat hi fron Denmark 19:59
commuting again& 20:00
20:00 lizmat left
dalek p: d959560 | dwarring++ | examples/rubyish/ (6 files):
fixed rubyish object attribute scoping. adding recursion tests
20:03
jnthn lizmat must be in Lolland :D 20:04
nwc10 In #perl6, every day is Punday 20:07
looks like nqp commits now correctly don't show up on #parrot 20:08
How long until someone commits something to Rakudo?
jnthn No, no, that's what it's actually called!
en.wikipedia.org/wiki/Lolland
20:08 kaare_ left 20:11 dakkar left 20:15 berekuk joined 20:25 berekuk left
moritz was there a parrot release yesterday? 20:25
20:26 sqirrel left, labster left
jnthn moritz: I didn't see an email about it 20:27
moritz no release-ish commits or tags either 20:28
masak hopes for a Moar release soon :> 20:29
FROGGS masak: hoping is not enough! :P 20:30
timotimo bleeeh, i'm still super tired :( 20:31
FROGGS :/
20:31 cooper left
timotimo but i've got the commit to fix charrange. 20:31
20:32 rindolf left 20:34 kurahaupo left 20:35 cooper joined
timotimo t/nqp/19-file-ops.t ................... Failed 8/40 subtests - is this known? (on jvm) 20:35
moritz yes, I've seen that
timotimo OK 20:36
arnsholt Yeah, happens on my machine as well
And one or two fails in a different file 20:37
moritz runs j-test 20:38
FROGGS a qregex test fails, 492 or so
timotimo t/qregex/01-qregex.t .................. ok 20:39
nope :)
FROGGS \o/
timotimo t/jvm/02-pipes.t ...................... Failed 1/7 subtests - this is known, too
FROGGS timotimo++
timotimo ?
FROGGS hmmm 20:40
ahh, fails here too
dalek p: c293015 | (Timo Paulssen)++ | src/vm/jvm/QAST/Compiler.nqp:
for !charrange, it had to be ifgt, not ifge.
20:41
20:42 berekuk joined 20:50 aindilis` left 20:52 raiph joined 20:59 aindilis joined 21:06 denis_boyun__ joined, denisboyun left
Rotwang what is main difference between Blob and Buf? 21:07
FROGGS IIRC one of them is specced immutable while the other is not 21:08
but atm both are
timotimo yeah, but it's # TODO: override at_pos so we get mutability
:)
Rotwang thanks 21:09
21:10 eternaleye left
timotimo huh. restricting my optimisation from turning negated literals into things (why would that even happen?) causes a segmentation fault while parsing the setting o_O 21:12
FROGGS uhh 21:15
timotimo gist.github.com/timo/0fc6de61754e18ae6825 - dunno what's causing it 21:16
don't even know what thaw does
21:20 berekuk left
FROGGS damn, I want to open( "$*VM<config><cc> -c -xc -", :w, :p ), but open() prepends the cwd to cc >.< 21:24
on linuxes I could `which` to get an abspath to cc, but how do I do that on windows? 21:25
meh
timotimo when not optimising for literal befores, i get a tiny speed-up it seems 21:26
dalek p/simplify_before: 51192c4 | (Timo Paulssen)++ | src/vm/ (2 files):
teach parrot and jvm about zerowidth literals
21:29
p/simplify_before: 795d519 | (Timo Paulssen)++ | src/QRegex/P6Regex/Actions.nqp:
first draft of a before-assertion simplifier.
p/simplify_before: 5c4d88d | (Timo Paulssen)++ | src/ (2 files):
NQP RegexOptimizer for before assertions
p/simplify_before: 12d5660 | (Timo Paulssen)++ | src/NQP/Optimizer.nqp:
less debug output
p/simplify_before: 387e382 | (Timo Paulssen)++ | src/NQP/Optimizer.nqp:
need to factor in both negations.
p/simplify_before: e4e9ac8 | (Timo Paulssen)++ | src/QAST/Regex.nqp:
more dump output for Regex nodes.
p/simplify_before: 342e93b | (Timo Paulssen)++ | src/NQP/Optimizer.nqp:
remove apparently dangerous literal optimization
lue FROGGS: is there no :abs adverb for &open or anything? also, you could try open( qx"$*VM<config><cc> -c -xc -", :w, :p ), seeing as you seem to be executing cc 21:34
qqx rather 21:35
FROGGS qqx just does an open, readall, close
and then returns the slurped output 21:36
I need to open cc as a pipe, to print to it C source
21:38 labster joined
FROGGS there is no :abs... 21:39
21:44 jeff_s1 left, Mouq joined 21:45 benabik joined 21:47 jeff_s1 joined 21:53 benabik left
lue FROGGS: the only other thing I can think of is to count the number of directories in CWD and prefix that many ../ to the string. 21:54
japhb r: say $*VM<config><cc>
camelia rakudo-parrot 180fca: OUTPUT«cc␤»
..rakudo-jvm 180fca: OUTPUT«(Any)␤»
FROGGS lue: and then I had a ../../../cc ? this would not find my cc either :o) 21:55
I just use the nqp:: ops now :/
japhb: yeah, I'll care about that when we have NativeCall there 21:56
japhb FROGGS, Oh, I was just checking whether the cc defaulted to having paths of its own. 21:57
I wasn't (intentionally) pointing out the JVM difference.
FROGGS ahh
lue FROGGS: try "; $*VM<config><cc>" as the start of the string
FROGGS well no, cc and friends usually come without path
japhb lue: >.<
FROGGS gah
no :o) 21:58
japhb Little Johnny Tables strikes again
lue I understand you don't want STDERR clogging things up. Try 2>/dev/null; then :) 21:59
timotimo is unsure what to do with nqp/simplify_before now
maybe i should try measuring some times
22:02 berekuk joined
FROGGS lue: I like that better :o) github.com/FROGGS/p6-Inline-C/comm...0d67afa223 22:02
22:04 denis_boyun joined, denis_boyun__ left
FROGGS ==> Testing Inline 22:04
t/c.t .. ok
All tests successful.
\o/
'love it
lue :) 22:05
22:06 btyler left 22:07 xenoterracide joined, benabik joined, benabik left
lue I don't see anything in S32::IO that requires a CWD prefix from open. If it is in fact supposed to happen, I'd like :abs/:rel adverbs, where :rel does the CWD prefixing and :abs doesn't. 22:08
(maybe :rel would take a value, default to $*CWD)
Ah, here it is in S16: * When a IO::Path object is created, if the string it is given is not an 22:09
absolute path, then $*CWD is prepended to it.
FROGGS :/ 22:10
I'm not sure but I think the $*CWD only messes up when opening a pipe 22:11
so maybe this should be special-cased
22:15 raiph left
timotimo my super biased benchmark seems to suggest that using simple befores is now quite a couple of times faster. exact numbers in a minute. 22:16
22:16 denis_boyun left
timotimo matching "foobarfoobar " x 1000 ~ " bazbaz" against /<?before \s> \s bazbaz/ 22:17
previously: 19.5s for 100 rounds
22:18 lizmat joined
timotimo now: 26.0s for 10_000 rounds 22:18
22:18 raiph joined
lizmat checks backlog while enjoying the view on Copenhagen from the 7th floor 22:18
jnthn :) 22:19
lizmat: Glad you made it.
lizmat yeah, we just missed the ferry in Puttgarden and had to wait ~ 1 hour :-( 22:20
22:20 berekuk left
timotimo so yeah, it seems like there's some overhead to calling a subrule and then a thunk in addition 22:20
timotimo runs the rakudo spectest suite to make sure nothing obvious is broken 22:21
jnthn: do you think i can merge this into nom?
the overhead of running the optimizer over regexes may not yet be worth the payoff
except if you hit a pathological case like mine 22:22
and literals are currently b0rked in a way that befuddles me
22:23 Rotwang left
timotimo (but the optimizer will not try to do that any more) 22:24
jnthn timotimo: Hmm...not now, I think. Release very soon.
timotimo: Maybe let's look at doing it after release...I can perhaps find a moment to review it too ;)
timotimo that would be great :)
22:25 btyler joined
timotimo jnthn: do you think the analysis overhead makes up for the winnings of turning an alt or altseq of single-character literals into an enumcharlist? 22:32
dalek ecs: 724cff7 | (Elizabeth Mattijsen)++ | S17-concurrency.pod:
Fix TAB pollution
22:33
22:36 PacoAir left 22:37 denisboyun joined 22:41 BenGoldberg joined 22:42 denisboyun left
jnthn timotimo: Well, better question is, does that ever occur in real code? 22:43
timotimo: Removing the scan from a regex whose first thing is a ^ is probably a more worthwhile optimization... 22:44
timotimo huh, is that even going to give a speed improvement? 22:45
i thought scan is going to immediately finish if its "from" isn't -1?
22:48 berekuk joined
timotimo t/spec/S05-modifier/perl5_5.rakudo.parrot Failed tests: 5, 7, 9 - uh oh 22:48
jnthn timotimo: Yeah, but it is -1 in /^foo/ 22:49
timotimo oh!
so it'll scan across the whole source text, even though it's going to fail at every spot except the beginning? 22:50
jnthn Yeah. It fails quickly (integer comparison) each time but it's still stupid to bother :) 22:52
timotimo well, if you have a hundred thousand bytes to scan through, it may take a bit :P 22:53
well, i'm glad there's lots of things to improve >_< 22:56
japhb Was the 100_000 bug ever fixed? 23:03
Memory allocation histograms would probably be very revealing. 23:04
Cut off the long tail of that histogram, and I bet Rakudo gets a LOT happier. 23:05
Is there a way in jvm or parrot to produce such a histogram relatively easily?
timotimo someone, i think it was hoelzro or dwarring, recently experimented with something on JVM 23:06
lizmat jnthn: coming back to our concurrency / locking issues we talked about yesterday 23:07
timotimo it led us to find out that the linepos cache was being regenerated for each and every BEGIN block, which caused a full re-scan of the source code about 130 times for the setting compilation 23:08
lizmat pretty sure we need some way to either make sure array's are push/pop safe from different threads
or we need to be able to mark them as safe
otherwise, something as simple as registering a tap on a Supply might fail
23:09 woolfy joined
jnthn lizmat: I'm pretty sure I threw in appropriate locking to not have the issue in that case (on the basis that it's OK to use low level things when you're implementing the high level things) 23:09
lizmat otoh, I now see that the push/pop in Supply are actually protected by a lock
indeed
ok, false alarm there :-) 23:10
23:10 dmol left
jnthn The other one to consider is iterating, given we have laziness :) 23:10
japhb timotimo, Was the 130x rescan bug fixed? 23:11
jnthn That that comes into play with push too...
japhb: I thougth it was but when I looked at the code doing it the other day I became a little less convinced it is, but I was very tired...
(Stuff changed to address the issue, I just couldn't quite convince myself that the code actually *did* address the issue) 23:12
japhb jnthn, understood.
That should be a relatively easy thing to check, should it not?
23:13 berekuk left
jnthn Think so 23:13
timotimo japhb: yeah, the line pos cache was just passed on to Compiler.compile if it was available and it didn't have to rescan any more
japhb (Meaning, it shouldn't be hard to instrument the rescan)
jnthn Right.
timotimo i'll do that right now.
japhb timotimo, Thank you. 23:14
jnthn timotimo: My concern was that I don't think we ever create a data structure to re-use.
timotimo: That is, we never bind an empty thing to the otuermost line pos cache contextual.
japhb Who are the JVM coders? jnthn, arnsholt, who else? I'm wondering if one of them knows how to get a memory alloc histogram out of it.
jnthn Or if we do I couldn't see where. 23:15
japhb Actually,
japhb searches online
jnthn japhb: jvisualvm *may* do it...
23:17 sivoais left
timotimo jnthn: no need to put in an empty datastructure, because if it's not truthy, it'll be regenerated 23:17
23:18 rurban1 left, rurban1 joined
jnthn timotimo: Yes, but if you don't, and you redeclare the contextual in the compile method, it will only store the computed thing in that contextual, *NOT* the outer one. 23:19
as in, further down the callchain
Where it could be re-used
timotimo oh!
yes, i see multiple rebuilds of the linepos array, actually.
23:19 stevan_ joined
timotimo i'll see if it's still in the 100s for the setting 23:19
i thought it might be dangerous to just let an inner compile call leak into the outer dynamic variable because what if you call eval on some file or string? 23:20
yeah, you were right 23:21
japhb D'oh 23:22
timotimo it's a good thing you notified the authorities, mister!
jnthn: a suggestion for how to make passing the cache on safe? cache the WHICH of $target as well? 23:23
jnthn timotimo: I think the trick is to look at definedness in method compile 23:24
timotimo actually, it seems like in the setting we only build one linepos array
jnthn timotimo: If you're passed something defined, bind it to the contextual
timotimo but in bootstrap and metamodel, for example, we build multiple 23:25
jnthn And not, then bind an empty nqp::list() there
And in the thing that builds the cache, only create and bind a data structure iff it's not defined, and if it's defined but false, populate *that* empty data structure.
timotimo where do i put the my $*LINEPOSCACHE then?
jnthn Still in method compile 23:26
timotimo ok
23:26 sivoais joined
japhb From a bit of searching, it looks like jmap and jhat are the first port of call when looking for aggregate heap info, standard since 1.6 JDK 23:26
diakopter eh
jnthn method compile(blah blah, :$lineposcache, blah) { my $*LINEPOSCACHE := nqp::defined($lineposcache) ?? $lineposcache !! nqp::list_i(); ... }
diakopter japhb: jvisualvm is the tool 23:27
timotimo yeah
japhb shrugs
<--- very not a Java person
jnthn <--- not one either, just learned JVM instruction set, and indy :P 23:29
timotimo i wonder if there's a trick to find a \r or \n very quickly in a whole 64 bit area with some fancy integer arithmetic or something
huh. i still get multiple regenerations of the lineposcache 23:32
src/Perl6/Actions.nqp
linepos cache regenerated in 4.71963596343994 seconds
this is surprising
given that the setting only takes 0.002s for the linepos cache
it doesn't seem like your change changed much, or maybe i misimplemented it 23:33
but in the setting it only gets called once and is surprisingly fast
even in the metamodel where it gets regenerated like 20 times, it only takes 0.0002s each
well, 0.0005s, but whatever. 23:34
i'll go to bed now 23:35
good night!
23:37 sizz_ left 23:38 stevan_ left
jnthn Grr, didn't get to hack on p6store *again*. :( 23:40
23:42 btyler left 23:44 stevan_ joined