»ö« 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 FROGGS left 00:02 sqirrel left 00:12 grondilu left 00:39 abnorman left 01:11 grondilu joined
grondilu What does SC stand for in MoarVM? 01:11
as in "SC Dependencies Table" 01:12
timotimo serialization context is my guess 01:13
01:30 grondilu left 02:00 xinming left 02:01 xinming joined 02:05 orafu left, OuLouFu joined, OuLouFu is now known as orafu 02:10 cbk joined 02:21 logie joined 02:37 logie left 02:54 stevan_ left 02:56 btyler joined, stevan_ joined 02:57 nebuchadnezzar joined 03:28 _jaldhar joined, dayangkun joined 03:33 preflex_ joined, ChanServ sets mode: +v preflex_ 03:34 preflex_ is now known as preflex 03:40 prevost joined 03:41 eternaleye joined 03:43 prevost left 03:44 leprevost joined 04:19 btyler left 04:48 SamuraiJack joined 04:55 birdwindupbird joined 05:26 _jaldhar left 05:28 crab2313 joined 05:29 _jaldhar joined 05:47 zacts left 06:04 leprevost left 06:48 iSlug joined 06:49 iSlug left, iSlug joined 06:51 crab2313_ joined 06:56 fridim_ left 07:17 domidumont joined 07:24 dmol left, dmol joined 07:33 rGeoffreeey joined 07:34 fhelmberger joined
rGeoffreeey In about 19 hours I will be doing a lightning talk at OSCON on the State of the Onion and want to include a slide with some of the highlights of the current status of Perl6. Does anyone have a bullet point or two to include? 07:34
arnsholt JVM backend for Rakudo is a good candidate I think 07:39
07:39 kaleem joined 07:40 FROGGS joined, domidumont left
lizmat MoarVM with Perl 5 interop might be a good bullet point 07:40
nwc10 JVM backend for Rakudo passes >99% of the spectests that Parrot backend for Rakudo does 07:41
lizmat (aka running "standard" Perl 5 in a separate thread inside MoarVM)
07:41 domidumont joined 07:42 SmokeMac_ joined, SmokeMachine left
FROGGS rGeoffreeey: note that the p5interop has a request for a grant and is of course not yet done 07:43
nwc10 whereas the >99% is here and now
FROGGS right
next step is to "port" the module ecosystem
lizmat experimental thread support on the JVM ? 07:45
FROGGS maybe, but an outsider might think: "what? Perl 6 has no threads yet? Perl 5 has it for ages!" 07:46
rGeoffreeey keep in mind I have not been following perl6 other than the occasional comment heard at a conference, so you need to keep things simple for me
FROGGS s/has/had/
nwc10 rGeoffreeey: you might want to read recent posts on 6guts.wordpress.com/ 07:47
I think that that will be more coherent than this channel :-/ 07:48
FROGGS rGeoffreeey: and this too: www.josetteorama.com/all-about-perl...rt-1-of-3/
nwc10 experimental *proper* threads. None of the ithread pains.
FROGGS yeah, that's true 07:50
same goes for proper native call interface compared to XS
and this one isnt experimental, but yet only available on rakudo on parrot
rGeoffreeey so to translate for me, MoarVM is like Parrot, the thing under the hood that runs the language? And Perl 6 can do on MoarVM 92% of what it can do on Parrot? 07:52
FROGGS well
lizmat JVM and MoarVM are 2 different projects 07:53
FROGGS rakudo runs on nqp, which has parrot and jvm as a backend
lizmat grr need to go now, back in a few hours
&
FROGGS rakudo on nqp on jvm passes >99% of the tests that rakudo on nqp on parrot does
bonsaikitten hrm, I may have to adapt packaging if you guys continue like that :) 07:54
FROGGS and MoarVM is a new backend, and rakudo does not yet run on it
nwc10 rGeoffreeey: aha. step back. Rakudo is a compiler. It targets multiple backends. Much like gcc is a compiler that targets x86, ARM, PPC etc
FROGGS I think the interview explains the backend stuff well
nwc10 it's also not a perfect compiler yet - there are some spec tests that it doesn't pass (anywhere) 07:55
but the progress of the JVM backend is being measured against the parrot backend
so it's >99% of the way to "as good as the parrot backend"
rGeoffreeey Thank you all for the input, I will read the interview when I wake up. It is about 1am here and time to call it quits for the night. If anyone wants to supply a few bullet points for a sldie I will scroll back when I get up. 07:57
FROGGS k, we'll do
rGeoffreeey Before Larry speaks I am giving 5 minutes to show what conferences have happened in the last year, and next, the new monger groups in the last year (11), that we have regular perl5 releases, and a few other things. 07:58
08:02 tomaw joined 08:03 rGeoffreeey left, rGeoffreeey joined 08:04 crab2313 left, crab2313_ left 08:12 eiro joined 08:14 dmol left 08:20 dmol joined 08:28 sqirrel joined 08:35 BenGoldberg left 08:40 dakkar joined 09:01 kresike joined
kresike hello all you happy perl6 people 09:01
FROGGS hi kresike 09:02
kresike FROGGS, o/ 09:07
09:09 risou_awy is now known as risou
masak greetings, #perl6. 09:31
FROGGS masak! \o/ 09:32
welcome back!
JimmyZ masak: welcome back!!
masak is on a really slow connection, so don't expect eloquence 09:34
tadzik that's masak!
FROGGS no eloquence at all \o/
09:34 daxim joined 09:36 wk joined, wk is now known as Guest39864
jnthn morning, #perl6 09:44
yoleaux 24 Jul 2013 23:59Z <FROGGS> jnthn: Is this approach (wip) reasonable or totally off? gist.github.com/FROGGS/6a22741986d134ab5011
00:01Z <FROGGS> jnthn: I'm asking if the switch there belongs to that location, I know that I need to clean that up...
jnthn finally got a decent amount of sleep...
tadzik I woke up today, thinking "wow, nice, I woke up before the alarm went off!"
but it was 8:30. There was no alarm set 09:45
it's good that the $flight is in the evening
jnthn FROGGS: atpos_o is not meant to autobox.
FROGGS: If you use typed arrays you have to use them with the correct instructiom.
*instruction
09:46 jlaire joined
FROGGS jnthn: then something else is wrong(-ish) 09:46
JimmyZ guesses it's in 74-nfa.t 09:47
jnthn FROGGS: Perhaps so. On Parrot things were quite lax; I cleaned many things up in the NQP codebase for on JVM.
masak I'm not 100% back, just "back enough". :)
FROGGS jnthn: because t/nqp/74-nfa.t fails with: MVMArray cant box native int or so
jnthn FROGGS: But maybe some of the code in nqp-src was nabbed before that.
FROGGS JimmyZ++ :o)
jnthn Yeah, then somethere is using list_i when it meant list, or atpos when it meant atpos_i. 09:48
Take a look at if things are out of sync somewhere with latest NQP or so.
masak backlogs something like two weeks
FROGGS jnthn: the failing thing is $matching[0]
which does atpos
how should it know that it has to do atpos_i? should the postcircumfix make that decision? 09:49
jnthn FROGGS: Um, where are we looking? 09:50
In NQP, you generally write nqp::atpos_i out explicitly. Things in NQP are *much* more primitive than in Rakudo.
FROGGS this fails: github.com/perl6/nqp/blob/master/t...-nfa.t#L29 09:51
09:51 cbk left
FROGGS because [0] dispatches to atpos(_o) 09:51
jnthn Did you try running the test on NQP JVM?
FROGGS when $matching is an MVMIntArray
jnthn: no
jnthn Please do.
FROGGS eye sir
:o)
jnthn If it fails there also, then the test itself is to blame :)
Generally, MoarVM should have semantics aligned with 6model on JVM rather than 6model on Parrot. 09:52
FROGGS ok 3 - we can match a simple string
VMArray representation does not implement at_pos_boxed
:/
jnthn Right.
That's the same underlying error. 09:53
So, the test should use nqp::atpos_i
09:53 Woodi joined
FROGGS instead of the postcircumfix? 09:53
I think I understand
JimmyZ Parrot does autobox everywhere
jnthn JimmyZ: Yeah, I know. 09:54
JimmyZ yeah, I meant I don't like the action :P 09:56
jnthn Thing is that in real Perl 6, we know when we have a native array or not, so penalizing every array access for the (identifiable) cases where we don't know is bad performance wise. 09:58
FROGGS so you mean parrot is somewhat slow? :P 09:59
JimmyZ thinks so 10:00
jnthn In MoarVM I'm designing for letting us exploit what type info we have, e.g. the design is aimed at a gradually typed language (which Perl 6 is), not a dynamically typed one. Parrot's design call is I guess sane if you're just thinking dynamic.
dalek p: fb241ae | (Tobias Leich)++ | t/nqp/74-nfa.t:
use atpos_i if we have an integer-array, jnthn++
10:01
JimmyZ I see Moarvm avoids recursion frame call stack overflow 10:02
jnthn Yeah, we are generally making extremely shallow use of the C stack :)
JimmyZ and parrot didn't
jnthn However, we may want to create a way to artificially limit how deep you can go. Writing an infinite recursion and finding you filled a few gigabytes of memory with call frames is probably not very user friendly ;) 10:03
JimmyZ I tested fib(100), and didn't see memory inc 10:04
JimmyZ decommutes
nwc10 at least you can check on heap overflow 10:05
jnthn ;)
10:25 Woodi left 10:26 Woodi joined
ggoebel lizmat: The other 2 parts of the 3 part interview: 10:42
www.josetteorama.com/all-about-perl...rt-2-of-3/
www.josetteorama.com/all-about-perl...rt-3-of-3/
lizmat back, just after a cloudburst dropped ~20mm of water in ~15 minutes 10:49
*our* feet are still dry
some of our neighbours not
good thing: temperature dropped from 27 to 21 in the same period 10:50
jnthn wow
lizmat I've only seen it rain this hard during monsoon season in India
jnthn
.oO( and I thought the rain nether lands there... )
lizmat but then it was more like hours on end like that, not 15 minutes
FROGGS lizmat: do you really mean 20mm? 10:51
lizmat yes, I mean 20mm, as in 20l per square meter
jnthn hopes the end of the hot weather won't make him a very wet and cloudy vacation... 10:52
lizmat up in Switzerland, you'd get snow :-)
meters of it :-) 10:53
jnthn hah, yes!
nwc10 presumably metres of snow in the French-speaking areas :-)
jnthn Well, I have had a walk canceled by snow in in a July there before :)
10:56 crab2313 joined
lizmat see? see? 10:58
10:58 rindolf joined
lizmat r: multi a ($a) { say "single" }; multi a (@a) { say "multi ", @a.elems }; multi a (*@a) { say "slurp ",@a.elems }; a([1,2,3]) # why is it choosing the multi candidate instead of the single candidate ? 11:01
camelia rakudo 9ba5dd: OUTPUT«multi 3␤»
lizmat is that specced somewhere, that a [] flattens? 11:02
masak lizmat: because "positional" scores tighter than "scalar".
11:02 dmol left
masak (in reply to why it chooses that) 11:02
lizmat: "scalar" could be anything, including "positional". when you write a @ sigil, you are being specific. specific means tight.
lizmat r: my @a; push @a,[1,2,3]; say @a.perl 11:03
camelia rakudo 9ba5dd: OUTPUT«Array.new([1, 2, 3])␤»
lizmat but why does it flatten the, in my eyes, array ref ? 11:04
jnthn Flattening is, for better or worse, not encoded in the type system really.
colomon jnthn: so, my much improved STEP program runs out of memory on jakudo when given 32G. but the weird thing is, it happens *after* the parse of the entire file is done. at that point, the primary thing happening in the code is simply iterating over the hash created during the parse / actions…. 11:05
jnthn And multi-dispatch cares for "does the type match"
colomon: Weird. Does memory grow a lot while doing that?
colomon jnthn: you cannot tell -- jakudo allocates all the memory you give as the max limit when the program run starts 11:06
jnthn oh.
Probably reserves rather than allocates...
colomon yes
whatever, the memory usage jumps to 32G (or whatever) instantly 11:07
jnthn Maybe you can get top or something to show what is reserved and committed?
lizmat r: my @a; @a.push(Array.new(1,2,3)); say @a.perl
camelia rakudo 9ba5dd: OUTPUT«Array.new(1, 2, 3)␤»
jnthn colomon: Yeah but if we can get differrent numbers out...
lizmat ok, that means I cannot use MMD for .push with @values, because I cannot distinguish inside the method between the @a and [] 11:08
jnthn This is why the extra iscont check in one of the postcircumfix candidates, fwiw. 11:09
you could have a (\a) candidate and examine it
lizmat tries to grok that
jnthn if nqp::istype(a, Iterable) && !nqp::iscont(a) { #`(iterate over it) } else { #`(push dat item) } 11:10
11:12 sqirrel left
lizmat ….testing... 11:12
11:17 cognominal joined
masak tadzik: ooc, are you aware of an actual picture on the Internets of an actual sad panda? 11:19
11:19 crab2313 left
tadzik masak: like this? fc01.deviantart.net/fs71/f/2011/323...4gn0jt.jpg 11:20
:P
jnthn masak: lolfunnymeme.com/wp-content/uploads/sadpanda.jpg
tadzik or maybe the "what have I done" gif
i.imgur.com/3xPms.gif
panda should open that image whenever it crashes 11:21
jnthn *lol*
masak likes lolfunnymeme.com/wp-content/uploads/sadpanda.jpg the best :) 11:22
it's so... fluffy! 11:23
jnthn github.com/Arcterus/rakudo has a patch for fixed size arrays
tadzik yeah, it
's cute
11:23 rindolf left
jnthn github.com/Arcterus/rakudo/commit/...5672bc969f of note 11:24
tadzik gist.github.com/tadzik/6078844
jnthn tadzik: lol
11:25 pmurias joined
lizmat jnthn: looks interesting! 11:26
jnthn I've supervised it a bit; done by a guy who had to contribute to an open source project for a school course :) 11:27
lizmat no pull request yet?
jnthn lizmat: No, I think "new to GitHub" :) 11:28
lizmat also: why the Whatever class, shouldn't that be Shape class or so?
pmurias pmichaud_: ping
jnthn lizmat: I think S09 has @foo[*] as meaning "whatever shape" 11:29
lizmat: so afaik that's spec-compliant
lizmat but we have Whatever in so many other contexts as well 11:30
11:30 sqirrel joined
jnthn I think that's the point of Whatever :) 11:30
The universal "I don't care" indicator
FROGGS .tell crab2313 this might fix your issue: github.com/MoarVM/MoarVM/commit/351339dfdc 11:33
yoleaux FROGGS: I'll pass your message to crab2313.
masak moritz++ lizmat++ # Edinburgh
lizmat masak: yw 11:34
JimmyZ Wrap up Perl 5 Interop for Rakudo Perl 6 on MoarVM news.perlfoundation.org/2013/07/hag...ation.html # FYI
masak [backlog] hm, both Pod and heredocs are "special because they are line-oriented". if on one line I do a q:to'EOF' and on the next line a =comment, who wins? the heredoc or the Pod? 11:38
masak guesses the heredoc, but can't rationally motivate it
I would also accept the answer "it dies at parse time because what in the *world* do you think you are doing?" 11:40
11:41 dayangkun left
masak (masak's Law)++ # "For every DWIM there's an equal and opposite WAT" 11:42
moritz++ TimToady++ # promoting it :)
lizmat I still think that's derived from the Law of Conservation of Misery 11:46
cycling (the rains are gone)& 11:47
masak lizmat: it might be. which in turn sounds like a corollary of Murphy's Law. 11:51
lizmat: but as derived laws go, I think it still says something useful. 11:52
lizmat Yes, I should have added a :-)
masak it's like it's placing language features on a sphere, and pointing out that every point has an antipode.
and you may still come out ahead, because most of the time you'd be coding near the DWIMmed feature, and not near the antipode. 11:53
but the antipode is still there... and we tend to realize that only months or years down the road. masak's law tells us to look out for it up front.
example: .[-1] in Perl 5. awesome feature. I saw someone defend it in the backlog. 11:54
the antipode being what TimToady pointed out: it's a discontinuity, and worse, it's assymmetric.
lizmat even worse than asymmetric ! 11:55
masak so the WAT in that case is that when you need order and structure the most, the discontinuity will jump up and bite you.
lizmat really gone now&
in the ass! :-)
11:55 dmol joined
masak oh dang, yes. there really is just one 's' in "asymmetric". :) 11:55
jnthn haha 11:56
masak but there are to 'p's in "appreciate" and "appropriate" and "append".
jnthn
.oO( assymmetric: one butt cheek bigger than the other :P )
masak English is hard :)
jnthn: do yourself a favor and YouTube search for "my neighbors ass" by Tim Minchin ;)
's* 11:57
jnthn *lol*!# 11:58
colomon jnthn: I haven't conclusively proved it yet, but I'm leaning heavily to the problem with my code being either in Hash.kv or the for statement. At the very least it takes an incredibly long time for the line "for $step-data.entities.kv -> $id, $object" to get to the first iteration…
masak oh! the 'a-' in 'asymmetric' is Greek and means "not", doesn't it. whereas the 'a-' in those other words is Latin and means '(on)to'. 11:59
that would explain the... asymmetry. :)
colomon or so you'd assume... 12:00
jnthn colomon: I wonder if this points to a gather/take issue maybe?
colomon: .pairs uses that.
masak colomon! \o/ 12:01
colomon jnthn: maybe? I'm trying to golf it right now.
12:03 logie joined
colomon no longer needs this at the moment for $work -- he found one of the trouble faces a different way. 12:03
jnthn away for an hour or two 12:05
colomon gist.github.com/colomon/6079027 # java.lang.StackOverflowError with default jakudo stack size 12:06
masak hehe. $utterance ~~ /:i <<arglebargle>>/ tends to strongly raise the prior of $utterer eq '[Coke]' in the backlog ;)
colomon update: it's Hash.kv that's done it 12:08
doing it
gist updated, still gets java.lang.StackOverflowError 12:09
masak that's the error you get when you need to look for an answer over at Stack Overflow :P 12:10
colomon no, no, no, that's the error you get when StackOverflow is wrong about the code you wrote 12:11
12:11 dmol left
masak moritz++! # coming to YAPC::EU! 12:11
12:11 dmol joined
masak YAPC::EU++ # wrapping around moritz! 12:12
moritz: that is seriously good news!
\o/
12:13 logie left 12:17 skids left
masak mst++ # greeting newbies and trolling about $| 12:19
masak is all out of breath from backlogging 12:20
colomon is starting to think we've got some really serious issues with rakudo and big lists.... 12:22
masak diakopter++ # news.perlfoundation.org/2013/07/hag...ation.html 12:23
colomon: "I like big lists and I cannot lie..." :P 12:24
ribasushi masak: what's the $| trolling about...? 12:26
colomon masak: I tried establishing that everything else worked by just creating an array of the keys to use instead of .kv. But it appears that pushing182500 small strings onto an array takes several orders of magnitude longer than storing the same strings as keys in a hash. 12:27
12:29 Guest1337 joined
masak ribasushi: just irclog.perlgeek.de/perl6/2013-07-23#i_7362962 -- I smiled when I saw it :) 12:30
fwiw, S16 doesn't even *mention* buffering. S28 says $*OUT.autoflush() and S32/IO concurs, defining it as an rw method. 12:32
S16--
masak is now caught up with le backlog 12:33
dinner &
colomon rn: say time 12:36
camelia rakudo 9ba5dd: OUTPUT«1374755780␤»
..niecza v24-88-g1f87209: OUTPUT«1374755783.7686591␤»
[Coke] rGeoffreeey++ keeping p6 in the loop.
12:37 logie joined
colomon is starting to think having his music server be on the same system as he is running rakudo sanity tests may be a bad idea... 12:39
looks to me like we've got some sort of terrible O(N^2) issue with push 12:40
in jakudo, at any rate. but I'm suspicious it's in parrakudo too. 12:41
memory usage is out of control, too
12:49 logie left
colomon actually, it's drastically worse than O(N^2) 12:53
pushing 1825 Ints to the array took 1 second. 12:54
pushing 18250 Ints ran for 10 ten minutes before I killed it because it was consuming all the memory on my system 12:55
also, I appear to have completely forgotten how to cook omelets.
moritz pushing 10x as many elements would take 100x as many seconds for O(N^2) 12:56
oh, 10 minutes. I read "10s"
12:56 domidumont left 12:57 domidumont joined
colomon I just switched the program to use a second hash instead of the array. took 3 seconds instead of 10+ minutes 13:03
13:03 logie joined, Guest1337 left
colomon any time emulating an array with a hash is faster than using a hash, you've got some serious performance issues 13:04
sorry, faster than using an array 13:05
moritz indeed
nwc10 colomon: if 1825 takes (about) 1 second, what do 3650 and 5475 take?
curious what the power is in the O()
and 7300 (if I got that right)
colomon nwc10: give me a moment, I'm going to golf 13:06
nwc10 excellent
13:06 ribasushi joined
dalek rlito: d7ea076 | (Flavio S. Glock)++ | / (4 files):
Perlito5 - reset strict flags in do-file
13:08
13:08 domidumont left
colomon nwc10: 1825 * 1 = 1s * 2 = 6s * 3 = 15s * 4 = 53s 13:10
13:10 sqirrel left
moritz r: say log 53, 4 13:12
camelia rakudo 9ba5dd: OUTPUT«2.8639602272816␤»
colomon also, the difference between pushing 1825 * 2 Ints and 1825 * 4 Ints is a full gigabyte of memory. 13:13
r: say 1000000000 / (1825 * 2) 13:14
camelia rakudo 9ba5dd: OUTPUT«273972.602740␤»
colomon 273K per Int
FROGGS wow, imagine how many digits one can put in 13:15
I guess that is why they are called "BigInts"
colomon all the Ints involved could each fit in 4 bytes
13:16 ajr joined, ajr is now known as Guest4380 13:17 PacoAir joined
colomon gist.github.com/colomon/6079526 # golfed push performance issue 13:18
[Coke] r: sleep 10 ; say time - BEGIN time; # 13:20
camelia rakudo 9ba5dd: OUTPUT«10␤»
13:27 ribasushi left, ribasushi joined
dalek osystem: feefc4d | tadzik++ | META.list:
Add File::Find and Shell::Command separated from File::Tools
13:30
13:30 rGeoffreeey left 13:33 domidumont joined
pmurias push is a method of Any in rakudo? 13:39
colomon by point of comparison -- it takes 53 seconds to push 1825 * 4 Ints onto an array. It takes 21 seconds to generate 1825 * 100 pairs of random numbers, using the first in each pair as the key, the second as the value, use a second hash to store the keys just generated as values, and then go through all those generated values and sum them. 13:41
13:41 btyler joined
colomon (that's in jakudo, trying it in rakudo now) 13:42
parrakudo, I mean
13:44 daxim left, daxim joined
colomon parrakudo seems to also have issues with pushing, but not nearly to the extent that jakudo has 13:45
well… it's just back a factor of two or so on the curve. 1825 * 8 takes 46s and uses 2.x gigs of memory 13:46
13:46 pmurias left 13:48 skids joined 13:49 jaldhar_ joined, _jaldhar left
timotimo if this regression is fixed, maybe perl6 can be performant :) 13:49
oh 13:50
JimmyZ r: say time - BEGIN time;
camelia rakudo 9ba5dd: OUTPUT«0␤»
timotimo self.gimme(*) called multiple times will not cause extra computation, will it? 13:51
because push will self.elems, which does self.gimme(*) to get the number of elements
r: my @l; @l.push(^100); my $start = time; for ^200 { @l.gimme(*); 1 }; say time -$start; 13:52
camelia rakudo 9ba5dd: OUTPUT«0␤»
timotimo r: my @l; @l.push(^100); my $start = time; for ^1000 { @l.gimme(*); 1 }; say time -$start;
camelia rakudo 9ba5dd: OUTPUT«0␤»
timotimo r: my @l; @l.push(^100); my $start = time; for ^5000 { @l.gimme(*); 1 }; say time -$start;
camelia rakudo 9ba5dd: OUTPUT«0␤»
timotimo seems good
r: my @l; @l.push(^100); say @l.elems
camelia rakudo 9ba5dd: OUTPUT«100␤»
timotimo r: my @l; @l.push(^5000); my $start = time; for ^5000 { @l.gimme(*); 1 }; say time -$start;
camelia rakudo 9ba5dd: OUTPUT«0␤»
colomon for what it's worth: 1825 * 8 pushes take 46s in parrukdo, 0.03s in Niecza 13:54
JimmyZ and how about jvm? 13:55
colomon 1825 * 4 pushes take 53s on JVM, not going to bother trying 1825 * 8
timotimo add_core_pirop_mapping"("bindpos", "set", "1QiP", 1 :named("inlinable")) <- this should not give any trouble at all, should it?!
JimmyZ colomon: you could try vargrind, parrot support it 13:56
jnthn back 13:57
JimmyZ *Valgrind 13:58
timotimo bind_pos_boxed on javakudo does set_size_internal, which seems sane. at less that 8192 slots it will double every time the number of slots is used up 14:00
jnthn It grows by doubling each time up to a certain size, then adds 4096 each time 14:01
timotimo right
er 14:02
what's this
gfldex r: gist.github.com/gfldex/6079954
camelia rakudo 9ba5dd: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤ in method list at src/gen/CORE.setting:1388␤ in any !reduce at src/stage2/QRegex.nqp:667␤ in any !cursor_pass at src/stage2/QRegex.nqp:631␤ in regex list at /tmp/M_LfCiLkSC:8␤ in regex element at /tm…
gfldex n: gist.github.com/gfldex/6079954
camelia niecza v24-88-g1f87209: OUTPUT«Unhandled exception: Excess arguments to KERNEL Any.list, used 1 of 2 positionals␤ at <unknown> line 0 (KERNEL Any.list @ 1) ␤ at /tmp/xOzH23mHMd line 9 (Confusion.list @ 22) ␤ at /tmp/xOzH23mHMd line 8 (Confusion.element @ 12) ␤ at /tmp/xOzH23mHMd lin…
timotimo if (ssize < 8) ssize = 8
gfldex std: gist.github.com/gfldex/6079954
camelia std c2215f0: OUTPUT«ok 00:01 52m␤»
gfldex i believe my gist to be a newbug 14:03
14:03 crab2313 joined
timotimo ah, that just means never make a list smaller than 8 entries. mmkay. 14:03
14:03 rindolf joined
timotimo i don't see something obviously wrong yet 14:04
colomon jnthn: so, how do we profile rakudo these days?
jnthn --profile 14:05
timotimo: It's just making sure...yes, that.
jnthn is reproducing measurements here 14:06
timotimo jnthn: mind if i reimplement memmove in the VMArrayInstance*java files in terms of System.arraycopy?
jnthn timotimo: Please do.
timotimo: That was suggested recently in a commit comment
timotimo don't think it'll give us much in this case, but every little bit helps, no? why profile if i can just optimize instead!
jnthn timotimo: Plesae check it for other suggestions, if you get chance. 14:07
timotimo: unshift may benefit from similar things, fwiw.
timotimo i thought unshift would use the "the array doesn't have to start at the start" mechanic?
at least set_pos_boxed will check if there's space at the beginning and move everything over to the beginning if space is needed towards the end 14:08
jnthn Right 14:09
wow, .push on Rakudo Parrot is really a pig.
14:10 byte48 joined
colomon jnthn: but it's worse on Rakudo JVM, according to my tests here 14:11
14:11 chinaXing joined
jnthn colomon: 42s on Rakudo JVM here, vs 46s on Rakudo Parrot. 14:11
Both suck. 14:12
timotimo i can't find the thing you're refering to :(
FROGGS hmmm, nqp::push is pretty fast on nqp@parrot, but not on nqp@jvm nor on moarvm
timotimo the commit that has suggestions
nwc10 a suckling pig! om nom nom.
colomon really? I got Rakudo JVM taking longer on only half the number of elements
nwc10 Oh, wait. Fail
14:12 risou is now known as risou_awy
jnthn colomon: Maybe our benchmarks differ 14:13
14:13 risou_awy is now known as risou
colomon or our rakudo builds… the ones I've been testing on are probably at least a day or two stale 14:13
FROGGS my @a; my $i := 0; while ($i := $i + 1) < 1000000 { nqp::push(@a, $i) } # 0.383s nqp/parrot, 2.126s nqp/jvm, 5.892s nqp/moarvm (precompiled)
jnthn FROGGS: Unoptimized moarvm build, I presume? 14:14
FROGGS jnthn: yes
hold on
colomon does p6listitems copy the list? 14:15
jnthn colomon: Would have to look at it to find out...
colomon nqp::p6listitems, I mean
jnthn perl6.bat -e "my @a; my $n = now; for 1 .. (1825 * 4) { @a.push($_) }; say now - $n"
42.221
perl6.exe -e "my @a; my $n = now; for 1 .. (1825 * 4) { @a.push($_) }; say now - $n"
46.9360014
(the .bat is on JVM, the .exe is on Parrot)
FROGGS 0.294s nqp/moarvm (optimized, no debug, gcc instead of clang)
MoarVM++ 14:16
jnthn uh, compiling it optimized makes it go from 5.8s to 0.29s?!
(C compilers)++
14:16 sqirrel joined
colomon jnthn: actually, the timing difference we're seeing might be memory size dependent? I was showing jakudo using twice as much memory, but if that makes my machine go to swap faster, that could easily explain the timing difference 14:17
gfldex is Grammar supposed to tell the user that he/she forgot to implement an action method or should it spit out a confusing, if a rule/token name happens to be a method name in Any?
*confusing error message
colomon you don't have to implement every action method 14:18
jnthn colomon: Could be
tadzik although you could pwrobably change GrammarHOW to warn you :)
14:19 benabik left
gfldex r: gist.github.com/gfldex/6079954 14:19
camelia rakudo 9ba5dd: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤ in method list at src/gen/CORE.setting:1388␤ in any !reduce at src/stage2/QRegex.nqp:667␤ in any !cursor_pass at src/stage2/QRegex.nqp:631␤ in regex list at /tmp/oNU9xNLrk9:4␤ in regex element at /tm…
14:19 benabik joined
gfldex Core.setting:1388 is Any.list in that case 14:19
gfldex heads off to find the rakudobug form and a sharp pencil 14:20
14:29 pmurias joined
pmurias re push slowness, does it persist when not using push and just inserting the element at the end of the array? 14:30
timotimo will try
holy moly
that makes it finish *instantly*
even when using @keys[@keys.elems] = $_ it's instant 14:31
skids what about push(...); 1;? 14:33
timotimo good catch. that is very fast as well 14:34
takes just 2 seconds
skids so it is the construction of the return value of the for loop.
timotimo we never should have trusted sink!
jnthn *sigh* yes, it's the sink think 14:35
I thought I put us in an optimization for not constructing the result list in sink context?
timotimo even with --target=optimize there's the whole sink thing, but it's all in a want for void context ... or am i looking at the wrong thing? 14:36
14:37 Psyche^ joined
jnthn ohhh 14:37
$past := QAST::Op.new(
:op<callmethod>, :name<eager>, $past
);
statement_control:sym<for> always calls eager
timotimo ... yeah
timotimo noticed that often before but never thought it would be bad :P
jnthn Well, push returns the entire list. 14:38
timotimo oh
it makes a list of all the lists that push had
and flattens them?
colomon woah 14:39
jnthn Right.
jnthn tries compiling a fix to that.
timotimo wow, whoops
[Coke] nice catch, folks. 14:40
colomon can confirm -- adding 1; at the end of the list speeds things up enormously
14:40 Psyche^_ left
timotimo wow, that *is* pretty bad 14:40
jnthn I also got a couple of other small optimizations to .push that we can try.
timotimo that's release a 2013.07.1 compiler release with just that fix bad.
gfldex r: class Foo {}; say nqp::can(nqp::getlex('Foo'), 'list');
camelia rakudo 9ba5dd: OUTPUT«1␤»
14:40 nyuszika7h left
timotimo in the mean time, i'll spectest my array copy replacement and hope the spec tests would bring a wrong usage of that to light 14:40
jnthn timotimo++ 14:41
gfldex is there a nqp::can variant that doesn't follow the inheritance chain?
jnthn No
But you can look in .^method_table
timotimo jnthn: the only thing i worry about is that arraycopy takes int for all the parameters and our memmove method takes longs ...
14:41 nyuszika7h joined
jnthn Which is "this class only" 14:41
timotimo: That's fine, just cast 'em...
timotimo *how* can that be fine? what if we have a humongous array?
gfldex how do i do that in nqp?
colomon looks to be (part of) the problem with categorize as well -- it's a double for loop with interior push, all in sink context 14:42
jnthn darn, my patch didn't help...
gfldex is nqp illiterate
timotimo i'd imagine that's the trouble with p6doc's htmlize using up ridiculous amounts of memory, too ...
jnthn gfldex: nqp::existskey($foo.HOW.method_table($foo), 'methname')
Note it's not gonna be so fast as nqp::can
What do you need it for, ooc?
gfldex to fix gist.github.com/gfldex/6079954 14:43
jnthn: NQPCursorRole::!reduce is using nqp::can on an action class 14:44
masak finds www.josetteorama.com/all-about-perl...rt-2-of-3/ a really good read
jnthn gfldex: Yes, but we rely on inheritance working
masak jnthn++
gfldex jnthn: that will force the user to implement any action method that has the same name then any method in Any 14:45
if that method's name also shows up as a rule/token in the grammar in question
14:45 Kiralexis joined
timotimo i wonder if in for ^1024 { ... } $_ will be marked as Int by our clever optimizer. or if it should. 14:47
jnthn gfldex: Only if we don't find a different fix :) 14:48
timotimo remember how every grammar derives things like <ident>, too? we don't want to force the user to implement all those as well 14:50
gfldex that's a different problem
timotimo OK
14:51 rGeoffreeey joined
timotimo rGeoffreeey: when is that thing where you want to tell a bit about the status of perl6? can we get an emergency rakudo hotfix release before then? 14:52
r: [1, 2, 3, 4].gimme(*).say 14:53
camelia rakudo 9ba5dd: OUTPUT«4␤»
timotimo jnthn: maybe instead of calling .eager, .gimme(*) could be called on for's result?
jnthn timotimo: Working on some fixes here... 14:54
timotimo good, i'll let you concentrate :)
jnthn timotimo: Hotfix release matters only for basing a Star release off it
timotimo: I suspect this issue has been in a Star release, but also we have lots of other stuff landed since then like the Buf changes
nwc10 I would also be very surprised if anyone actually installs the compiler release from the release tarball.
timotimo i was thinking to release just the fix you're going to come up with 14:55
nwc10 What (I suspect) matters are git HEAD, and the Star distribution.
pmurias jnthn: if I want to check // working with more complex things should I create a new test file?
timotimo is no star going to be made this month?
[Coke] we already know some people think we've been hit by a bus when we don't do a monthly star release. *sadface* 14:56
jnthn OK, I got it down to 1.32s on JVM here.
(from 42s)
nwc10 stupids question maybe, but
1) are there other places in the grammar with the same problem? 14:57
2) when did it sneak in?
timotimo initiates balcony time
rGeoffreeey timotimo, the talk is at 19:00 Pacific time, 11 hours from now. I am just going for very high level bullet points, so any changes between now and then shouldn't be a problem for me
14:57 stevan_ left
pmurias jnthn: if I put things like 'class' into the earlier ones the test will be inaccesible to new implementations, if I put that in a new file we will have one more test file 14:58
timotimo ah. well, the thought i had was: "will people come and install the latest compiler release and see how terrible for loops tend to perform"
but i suppose it's a non-issue
masak r: say (1..10).gimme(5)
camelia rakudo 9ba5dd: OUTPUT«No such method 'gimme' for invocant of type 'Range'␤ in block at /tmp/qKF_pLi0sp:1␤␤»
jnthn pmurias: "working with more complex things"?
nwc10 timotimo: yes, it's a reasonable thing to question.
masak r: say [1..10].gimme(5)
camelia rakudo 9ba5dd: OUTPUT«10␤»
masak huh.
oh. number of elements available? 14:59
jnthn masak: You called .gimme directly on a Range the first time...
OK, I should spectest these patches I have here on both JVM and Parrot. It'll be a little bit before I can push. 15:00
15:00 risou is now known as risou_awy
pmurias jnthn: // doing the correct thing while passed a freshly created object 15:00
15:01 bbkr joined
jnthn pmurias: Are we talking about nqp or Rakudo here? 15:01
pmurias jnthn: nqp 15:02
bbkr hi. what is P6 syntax for capturing command line output - like P5 my $x = `ls` ?
jnthn qx/ls/ 15:03
bbkr jnthn: thanks
15:04 benabik left 15:06 benabik joined
gfldex r: class Foo {}; my Foo $foo; say "I have no", $foo.^parents; say "but I implement", $foo.list; 15:06
camelia rakudo 9ba5dd: OUTPUT«I have no␤but I implement␤»
gfldex magic \o/ 15:07
jnthn gfldex: .^parents(:all) # yes, I knew this'd catch people when TimToady++ wanted .^parents to default to lying... :)
bbkr currently perl6 has --target= option. and I can for example do --target=PIR, then use pbc_to_exe to build executable. is there a way to simply request executable without worrying which VM rakudo is running on? 15:08
jnthn Grr, I see spectest fails...
15:08 chinaXing left
jnthn bbkr: Not yet 15:08
bbkr thanks again 15:09
jnthn oh, I broke spectests 'cus I did something stupid 15:13
diakopter stupid--
FROGGS that makes it less stupid then 15:14
diakopter stupid++
FROGGS meh
15:14 Guest4380 left 15:15 ajr joined, ajr is now known as Guest16560 15:18 kaare_ joined 15:23 bluescreen10 joined
timotimo it doesn't seem like my arraycopy thing made any new spectest failures, but it's hard to spot new ones among the old ones. i shall run a pre-change spectest and just diff the output. 15:23
jnthn My spectest run on JVM after I unstupided the patch is looking a bit better
FROGGS .oO( Unstupify! ) 15:24
diakopter timotimo: any performance test results?
FROGGS let's wave our wand-hands
15:24 bluescreen100 joined
diakopter
.oO( Uncruciate )
15:25
timotimo diakopter: i'd probably have to come up with a proper benchmark first. i suppose mixed shifts and pushes would do the trick?
kresike bye folks 15:26
15:26 kresike left, pmurias left, domidumont left 15:27 kaleem left, bluescreen10 left
[Coke] wonders if we will eventually get a "useless use of sink context" 15:29
15:31 smash_ joined, ajr_ joined 15:32 Guest16560 left
skids
.oO(useless use of sink == washing a handful of mud)
15:32
jnthn timotimo: Here is another place to use array copy: github.com/perl6/nqp/blob/master/s...e.java#L87 15:35
timotimo: If you didn't already. Taht one will help push more, I suspect
timotimo: If this is gonna help, anyway
15:41 SamuraiJack left
timotimo i imagine the sun people came up with some ridiculously clever way to make arraycopy work well on overlapping regions 15:43
although, maybe they also have ways to make such a for loop dispatch to an arraycopy after a little bit of jitting. 15:44
15:52 rGeoffreeey left
timotimo benchmark about to be run 15:53
no visible change. but at least the code is a bit nicer now ...
i'm actually not quite sure if those arrays ever shrink 15:54
it does not. but i think it should 15:55
something like "if the number of used slots shrinks below 1/3rd, it should be halved in size" or something. sonds sensible?
dalek kudo/nom: 49404ef | jnthn++ | src/Perl6/Actions.nqp:
Fix for loops in sink context to actually be sunk.
15:56
kudo/nom: f173b55 | jnthn++ | src/core/MapIter.pm:
Proper sink handling on JVM backend.
kudo/nom: cc9cf16 | jnthn++ | src/core/ (2 files):
Minor optimizations in List/Array.
jnthn timotimo: Please dont' do that.
timotimo: Because we have code that relies on 15:57
nqp::setlems($foo, $big-number);
nqp::setlems($foo, 0);
Then pushes
To not go resizing all the time.
And you'd undo that.
timotimo how about i put the code in shift and pop only?
that would allow setelems $bignum and pushes to work no-problem 15:58
but actually shrink arrays appropriately if they're being shifted trom
actually, you know what? i could probably make it an == instead of <= comparison, because shift and pop will only ever pop off one. in that case, it would only trigger if there were once more than that many elements in the list 15:59
timotimo cooks some dinner now
jnthn colomon: Feel free to give the things I just pushed a try
colomon jnthn++ 16:00
[Coke] hey! obra made boingboing: boingboing.net/2013/07/25/scratch-b...board.html
daxim still nothing on keyboard.io/ :( 16:02
I know these slides 16:03
jnthn colomon: Was there something else especially slow?
colomon yes, %hash.kv on a big hash
daxim podcast.bulknews.net/post/49915262884 16:04
colomon well, maybe more extremely stacky than slow, but same effect.
jnthn: gist.github.com/colomon/6079027
16:04 rGeoffreeey joined
[Coke] daxim: looks like the background is supposed to be this: launchrock-assets.s3.amazonaws.com...69.jpg?_=0 16:04
colomon might have been fixed by your latest changes, but since the problem showed up in the stack, I'm guessing not. 16:05
daxim that's prototype #6, I believe
FROGGS jnthn: will 49404ef959 change for-loops behaviour when it is the last statement in a sub? 16:06
daxim I want something with a couple more keys - but still keep the ergodox-workalike layout
jnthn FROGGS: no
FROGGS k
jnthn FROGGS: As last statement in a sub is not in sink context
FROGGS I see
colomon jnthn: that's insanely better 16:09
jnthn \o/
colomon 1825 * 8 is 2 seconds, where 1825 * 4 used to be 53 (this under JVM)
afk # noms
jnthn Wow, the hash one explodes on JVM due to the gather/take issue 16:10
bbkr any idea why --target=pir produces pir file that crashes with "Missing or wrong version of dependency 'src/Perl6/Grammar.nqp'" error? are there any special directives/options to pass?
[Coke] bbkr: are you building rakudo? 16:11
(I find I get those unless I realclean because of dep issues)
bbkr no, I'm trying to make executable as listed here: perlgeek.de/blog-en/perl-6/my-first....writeback
from sample hello world code
moritz that hasn't been working for years :(
FROGGS bbkr: I'd guess you should do `make install` in rakudo's dir first 16:12
have to*
bbkr same result after "make install" 16:13
FROGGS :/
lizmat jnthn: what's the rationale of STORE_AT_POS, when apparently this only gets called at one location ever? 16:14
something for the future?
jnthn lizmat: hMM 16:15
timotimo isn't it called from all the things in Any?
16:15 fhelmberger left
jnthn lizmat: Not sure 16:15
lizmat hMM ?
timotimo nope, i was wrong.
lizmat hmmm… with a big M ?
jnthn yes :)
lizmat seems like a useless extra sub call for each .push 16:16
16:16 estrabd joined
lizmat also: from jnthn's push() fixes, spectest has gone down from ~3180CP seconds to ~3140 16:16
CPU
diakopter moritz: deprecated article needs DEPRECATED stamp 16:17
jnthn lizmat: Well, note that it is the thing that makes push in a List and push in an Array do different things.
lizmat: We have to preserve taht difference.
lizmat ok
aha, and Array doesn't have it's own .push 16:18
*its
I guess it would be an optimization that would be too early to copy .push into Array and get rid of that sub call ?
too early as in premature 16:19
jnthn yeah
Adding the extra single arg candidate for push, or something smiliar to that, may be worth it though.
lizmat ok, I'll pursue that line of thought then
timotimo jnthn: are you still convinced i should not implement array shrinking on pop and shift? 16:22
dalek kudo/nom: 207cdaf | (Elizabeth Mattijsen)++ | src/core/List.pm:
Subtle change in fail message
16:23
TimToady P5 gets along very well with the idea that past behavior probably indicates future needs, so if you needed the space before, it's better to hang onto it than to reallocate it 16:24
in the rare cases you need to reclaim, the user can copy 16:25
jnthn colomon: I'm working on faster hash iteration 16:27
16:27 rindolf left
timotimo hmm. i was thinking of cases like ... while @list.shift 16:27
TimToady of course, P5 is nuts about that sort of stuff; it'll even notice you're shifting and pushing the same array as a rotation, and allocate something like 10 times more space to cut down on the copying
jnthn timotimo: Generally those lists a throw-away 16:28
16:28 FROGGS left
jnthn *&are 16:29
16:32 rGeoffreeey left
timotimo okay, i'll drop the case then :) 16:32
16:36 Guest39864 left
daxim paste.scsys.co.uk/263755?tx=on # rakudo-jvm 2013.07 build fails after step "tools/build/create-jvm-runner.pl" 16:41
error message is "Unhandled exception: java.nio.file.NoSuchFileException: ModuleLoader.class"
[Coke] daxim: what is "nqp-jvm" ? 16:42
diakopter nqp-jvm: say 1 16:43
camelia nqp-jvm: OUTPUT«Confused at line 2, near "say 1"␤ in panic␤ in comp_unit␤ in TOP␤ in parse␤ in parse␤ in <anon>␤ in compile␤ in eval␤ in evalfiles␤ in command_eval␤ in command_line␤ in MAIN␤ in <anon>␤ in <anon>»
diakopter nqp-jvm: say("slap")
camelia nqp-jvm: OUTPUT«slap␤»
[Coke] diakopter: that is most unhelpful.
lizmat sanity check: we don't have infinite Parcels, do we?
[Coke] let me rephrase my question for the pedants.
diakopter ?
[Coke] which version of nqp do you have installed as nqp-jvm?
diakopter [Coke]: sorry :( I didn't look at daxim's paste
(the "slap" was to self for forgetting nqp needs parens) 16:44
dalek p: 24c14a7 | (Timo Paulssen)++ | src/vm/jvm/runtime/org/perl6/nqp/sixmodel/reprs/VMArrayInstance (7 files):
use java.lang.System.arraycopy for memmove.
16:45
p: 3e222b8 | (Timo Paulssen)++ | src/vm/jvm/runtime/org/perl6/nqp/sixmodel/reprs/VMArrayInstance (7 files):
use System.arraycopy in one more place in VMArray.
daxim [Coke], nqp-jvm is /usr/bin/nqp-jvm, a product of the nqp-2013.07 source code with the ConfigureJVM toolchain. I had to rename it from nqp because it conflicts with nqp from the Configure/pir toolchain
timotimo i'll see how much ram htmlify now swallows up. 16:46
[Coke] daxim: what is in your copy of "perl6" ?
daxim shebang and this line: exec java -Xms100m -Xbootclasspath/a:/usr/share/java/nqp-runtime.jar:/usr/share/java/asm-4.1.jar:/usr/share/java/asm-tree-4.1.jar:/usr/share/java/jline-1.0.jar:./rakudo-runtime.jar:./perl6.jar:.:blib -cp .:blib:/usr/bin perl6 "$@" 16:47
[Coke] (also, did anyone ever get installations of rakudo-jvm working?)
er, of nqp-jvm
16:47 FROGGS joined
[Coke] (nevermind, I guess that does work, although not usually done ina system dir) 16:47
daxim yes, see my specfile: build.opensuse.org/package/view_fi...c?expand=1 16:48
the build system sucks balls, though. I hope the configures are merged in the next release
[Coke] daxim: you're changing stuff before you do the build. are you sure those changes aren't breaking anything? (I'm still digging) 16:49
daxim no, quite the opposite
these changes make it work
16:50 rindolf joined, jaldhar_ is now known as jaldhar
daxim I probably should comment what each patch accomplishes, but I didn't expect there would be so many needed when I started out 16:50
16:50 cbk joined
[Coke] why are they needed? 16:51
that is, I'm just building right from source, which doesn't have any of those changes.
daxim yeah, you're not packaging; you just install into $builddir/install 16:52
which is fine for a developer, but I'm redistributing software here that must follow certain conventions
16:52 bbkr left
daxim i.e. %{_javadir} and crap like that 16:53
lee_ colomon: hmm after building latest jvm-rakudo my push test just hangs seemingly forever
if i add a say @a.elems before pushing it hangs at 7300 16:54
my @a; for 0..(1825 * 4) { say @a.elems; @a.push($_); } # probably doing something wrong here 16:55
[Coke] daxim: what version of java are you using, OOC? 16:56
daxim java-1_7_0-openjdk
lee_ yeah it just hangs at 7300 and memory continues growing and using 300% of CPU 16:57
16:59 rGeoffreeey joined
colomon lee_: what nqp are you using? 17:00
lee_ fb241ae, i'll try updating that 17:01
i believe it is from last night
[Coke] daxim: does blib/Perl6/ModuleLoader.jar exist? 17:04
daxim yes 17:06
there's also a /usr/share/java/ModuleLoader.jar
17:08 spider-mario joined
colomon lee_: hmmm, that's the same one I have, actually. 17:08
lee_: what was your push test?
17:08 dakkar left
lizmat jnthn: why isn't List.push implemented in terms of nqp::push ? 17:10
lee_ colomon: pasted it above
lizmat jnthn: the reason I'm asking, is that I just realized that the way .push is currently implemented is not at all thread safe
jnthn lizmat: Good question. 17:11
lizmat: I had pondered that a bit also; it'd require push being duplicated in Array to get it right, I suspect.
17:11 fridim_ joined
timotimo hmm. htmlify still reaches 4gb resident memory after just 40 pod files 17:12
lizmat well, if that's the price to get it working in a threaded environment, it's a price I don't mind paying
jnthn lizmat: Feel free to investigate; I just did a few initial improvements.
timotimo: Does it do hash iteration? 17:13
timotimo i don't think so, but let me look
colomon lee_: 7300 with yours, yep. WTH?
lee_ colomon: does it hang after that?
colomon lee_: I didn't give it long, but it certainly went from printing several a second to not printing any more, just like it hit a brick wall 17:14
timotimo no. what it does do is for (0..* Z @source) (i made that part so that it would show how many files it's gone through and how many are missing)
maybe that's unoptimized? but i can hardly see that
the return value of spurt should be a bool, no?
or does it return the spurt'd string? 17:15
jnthn bool I think
colomon lee_: this is crazy
17:15 ajr_ left
timotimo doesn't see any obvious flaws 17:15
colomon rn: say 1825 * 4
17:15 ajr joined
camelia rakudo 207cda, niecza v24-88-g1f87209: OUTPUT«7300␤» 17:15
jnthn I have some work here that gets hash iteration to use a new HashIter that I'm working on instead of using gather/take
colomon oh
jnthn It should deal wiht the stack overflow colomon sees
lee_ colomon: my @a; for 0..2 { @a.push($_) } # returns 0 1 2 0 1 2 0 1 2 in REPL 17:16
timotimo hm, i *think* the memory usage used to be a bit extremer before, though
17:16 ajr is now known as Guest56028, Guest56028 is now known as ajr_
[Coke] daxim: trying a build with those specific versions... (don't see anything obvious in your ./perl6 that would cause the issue) 17:16
(though there are ordering differences and you have extra path info that I don't)
colomon lee_: 7300 is the last element. but why is it taking so long to return after the loop is done?
17:17 jaldhar left
lee_ colomon: ah, i think i see. being in the repl forces it to sink context? 17:17
17:17 jaldhar joined
lee_ er, maybe not 17:17
colomon out of sink context
that maybe what I'm seeing, too, it's the last thing in the script I created from your code.
that's totally it 17:18
17:18 jaldhar left, ajr_ left, jaldhar joined
lee_ yeah, if i plop a 1; at the end it returns much faster 17:18
colomon rn: my @a; for 0..(1825 * 4) { @a.push($_); } 17:19
lee_ (a 1; after the for loop)
camelia rakudo 207cda: OUTPUT«(timeout)»
..niecza v24-88-g1f87209: ( no output )
17:19 xinming left, birdwindupbird left
colomon rn: my @a; for 0..(1825 * 4) { @a.push($_); };1; 17:19
lee_ rn: my @a; for 0..(1825 * 4) { @a.push($_); } 1;
timotimo it goes up to 7.4gb :(
lee_ hehe
camelia rakudo 207cda, niecza v24-88-g1f87209: ( no output )
rakudo 207cda: OUTPUT«===SORRY!===␤Confused␤at /tmp/6M73ABocSX:1␤------> @a; for 0..(1825 * 4) { @a.push($_); } ⏏1;␤ expecting any of:␤ postfix␤ statement end␤ statement modifier␤ statement modifier loop␤ horizo…
..niecza v24-88-g1f87209: OUTPUT«===SORRY!===␤␤Strange text after block (missing comma, semicolon, comment marker?) at /tmp/aONRQ9Cf3F line 1:␤------> y @a; for 0..(1825 * 4) { @a.push($_); }⏏ 1;␤␤Parse failed␤␤»
17:19 rGeoffreeey left
jnthn timotimo: Is that before or after the sink patch? 17:20
timotimo after
i think before, too, though
jnthn wait, are you actually evaluating it in sink context?
At the REPL, just writing my @a; for 0..(1825 * 4) { @a.push($_); }; for example has to build up all the result lists
timotimo as opposed to assigning the result of a loop to a variable, either directly or through any amount of sub calls?
colomon timotimo: try @source.kv rather than 0..* Z @source ? 17:21
17:21 xinming joined
timotimo 7.7gb maxrss :( 17:21
colomon: good point
jnthn r: say [+] 1..(1825 * 4)
camelia rakudo 207cda: OUTPUT«26648650␤»
jnthn Out of sink context, you're constructing a result array of that many elements.
timotimo i see no assignment going on that shouldn't. 17:23
and fwiw, the thing that generates a list of pairs using a breadth-first-search gather/take with dir is still getting up to the same amount of ridiculous ram usage it had before
340M before, 1820M after reading the 153 files out of the directories 17:24
skids has had to add 1; at the end of included modules to avoid fun with sink/nosink. Reminded him of perl5's require requirement. 17:26
moritz skids: and I already changed for-loops to be eager again 17:28
17:28 sqirrel left
skids Wasn't a for loop in this case, the last thing in the module was a role. Punned it without the 1; IIRC. 17:29
moritz urk. 17:30
jnthn moritz: Yes, they were eager, but eager != sink :) 17:32
timotimo should @todo = @todo cause any excess memory reserved for the VMArray to be freed and a new, fitting memory chunk to be allocated? 17:34
hm, nah, that wouldn't explain that much memory usage at all 17:36
dalek kudo/nom: fe35215 | (Elizabeth Mattijsen)++ | src/core/List.pm:
Applied same optimization logic to other List methods
17:41
lizmat will look at .push again when back from Wolverine 3D :-)
&
17:44 btyler left 17:45 rGeoffreeey joined
[Coke] timotimo: no. 17:52
dalek rl6-roast-data: e88ad8b | coke++ | / (4 files):
today (automated commit)
17:53
18:00 btyler joined
[Coke] daxim: did a build with those particular versions with no errors on an OS X box. 18:01
(developer style, obviously)
daxim well, then you spent a lot of time not reproducing the problem I'm having
[Coke] ... Yes. 18:02
I do see that the generated ./perl6 from that "era" matches the one you have much more closely.
I can try out your patches that made it "work" for you and see if I can figure out if one of those is tied to the issue. 18:03
daxim yes please
[Coke] Do you have a script you're running to do the build?
hoelzro good evening Perl 6 folk! 18:05
jnthn o/ hoelzro 18:06
daxim yes, osc
[Coke] (also, if you have a script for building the nqp-jvm, that would also be helpful)
daxim if you can't run osc, just follow the shell script parts of the specfile in order 18:07
jnthn colomon: Think I've worked out all the spectest fails in my re-work of hash iteration. 18:09
daxim the spec files are at build.opensuse.org/package/show/ho...parrot/nqp and build.opensuse.org/package/show/ho...rot/rakudo each
hoelzro so I some ideas about my issues with MAIN(Str $value) and passing '10' on the command line
colomon jnthn: oooooo
jnthn colomon: Verifying that on Parrot now, then will make sure it doesn't blow up Rakudo JVM
colomon: It adds a HashIter over using gather/take 18:10
hoelzro could MAIN be modified so that it checked an argument's type before coercing it to something it recognizes?
jnthn Also seems to elimiante a previous Parrot/JVM difference hack and maybe (if they don't go away) makes some todo tets pass
hoelzro: I think the problem you've got is Rakudo not yet providing the IntStr type
18:11 kaare_ left
hoelzro so what exactly does the IntStr type provide? something that can hold either an Int or a Str, I assume? 18:11
[Coke] daxim: why does the nqp spec file build the parrot version and the java version?
jnthn hoelzro: it's roughly class IntStr is Int is Str { } or so
daxim because the source archive provides those build targets 18:12
TimToady n: @*ARGS = '10'; sub MAIN (Int $i) { say $i.WHAT }
camelia niecza v24-88-g1f87209: OUTPUT«(IntStr)␤»
TimToady hoelzro: prior art ^^
[Coke] so if someone is trying to build rakudo-jvm, they get rakudo-jvm, nqp-jvm, and nqp-parrot? 18:13
hoelzro ok, so maybe IntStr would solve my problem
but let's say I wanted to implement 'echo'
TimToady you can always process your own args 18:14
daxim no. when nqp is built, it produces nqp, nqp-devel and (since yesterday) nqp-jvm
hoelzro I suppose so
but to me, this isn't just about capability; it's about surprise
[Coke] where nqp == "nqp on parrot", which is what I was trying to say above. ok.
TimToady but using val() semantics allows multidispatch to MAIN 18:15
there is now way to avoid surprise when the command line does not supply sufficient type info
*no
hoelzro let's say that as a newbie to Perl 6, I implemented echo as such: sub MAIN(Str $value) { say $value }
Kiralexis 2/away
hoelzro if I call echo True, it'll fail, complaining that I didn't provide a value
that confused me when I saw it 18:16
so what's the right way to handle this?
TimToady n: @*ARGS = 'True'; sub MAIN ($i) { say $i.WHAT }
camelia niecza v24-88-g1f87209: OUTPUT«(Str)␤»
TimToady val doesn't do enums
hoelzro I haven't tried this in niecza yet 18:17
TimToady n: @*ARGS = '22/7'; sub MAIN ($i) { say $i.WHAT }
camelia niecza v24-88-g1f87209: OUTPUT«(RatStr)␤»
hoelzro I'm just making my feeling on this Rakudo feature known
=)
TimToady and in any case, it'd have to be a BoolStr :) 18:18
hoelzro and then, if I call 'echo 10'?
TimToady n: @*ARGS = '10'; sub MAIN (Str $i) { say $i } 18:19
camelia niecza v24-88-g1f87209: OUTPUT«10␤»
TimToady still works as a Str
that's what the MI is for
hoelzro if that works in Rakudo, that's fine with me =) 18:20
TimToady the only other approach I've considered seriously is making Str an ancestor class of everything numeric, but that also seems problematic
trouble is, it's a DWIM, and that invokes masak's law
the WAT of the MI solution is that a multi dispatching to both Int and Str will fail 18:21
hoelzro in thinking about this, I also thought it might be nice to able to provide special traits to MAIN to override/augment how argument parsing works 18:23
but maybe that would be better suited to an actual option parsing routine?
18:23 zby_home_ joined
TimToady that is the way that MAIN makes hard things possible :) 18:25
18:25 sjohnson joined
[Coke] daxim: is your JAVADIR set to /usr/share/java ? 18:26
18:26 sjohnson left, gtodd joined
daxim is that an environment variable? if yes, then no. 18:26
[Coke] er, sorry, misread. how is %{_javadir} set? 18:27
daxim that's an rpm macro, expanded at when the spec file is parsed
[Coke] ok. what's it set to (I'm running these by hand, not inside whatever build system you're using.) 18:28
?
jnthn colomon: On JVM, that thing that stack overflowed before now compltes in 2.18s. 18:29
colomon \o/
[Coke] wherever you installed nqp?
daxim /usr/share/java
[Coke] jnthn++
colomon jnthn++ indeed!
18:29 rindolf left
daxim the jars go to /usr/share/java, the bins to /usr/bin 18:29
jnthn Running spectest on JVM now; back after a quick visit to the shop 18:30
[Coke] daxim: can you show me your /usr/bin/nqp-jvm script? 18:31
18:31 rGeoffreeey left 18:32 ajr joined 18:33 ajr is now known as Guest55969
daxim exec java -Xbootclasspath/a:/usr/share/java:/usr/share/java/nqp-runtime.jar:/usr/share/java/asm-4.1.jar:/usr/share/java/jline-1.0.jar:/usr/share/java/nqp.jar -cp /usr/share/java nqp "$@" 18:33
plus shebang
18:42 SamuraiJack joined
[Coke] daxim: FYI, the description on nqp's jvm package mentions PIR still. 18:42
18:43 Guest55969 is now known as ajr_
daxim do you have a better description? 18:44
18:44 omeranon joined
[Coke] s/PIR/java/ is probably sufficient. 18:45
18:49 skids left
[Coke] daxim: ok. the problem appears to be that nqp cannot handle being split into a bin dir and a jar dir. 18:51
I don't know if this is a systemic thing, or just a result of the rakudo.jvm makefile.
18:52 gtodd left
daxim that's a "must" for packaging. I'll put the rakudo-jvm target on ice until next release 18:52
18:57 daxim left
[Coke] I would recommend opening a rakudobug to track this. 18:57
19:02 sqirrel joined
jnthn Also, coordinate with donaldh++ who is working on these things. 19:03
dalek kudo/nom: 787295d | jnthn++ | src/core/ (2 files):
Re-work hash iteration to use a HashIter.

This replaces the existing gather/take approach with maps over them, which for .kv/.keys/.pairs is much more efficient as we never create a load of Pair objects only to throw them away. Seems not to regress any spectests on JVM or Parrot, and makes some TODO tests pass, most likely because 'for %h.vk -> $k, $v is rw { ... }' is probably fixed.
19:06
[Coke] jnthn: wish I had know that several long builds ago. ;)
[Coke] jnthn++ # moar java!
jnthn [Coke]: Know...donaldh++ has a make-install branch? :)
Sorry, I'm not always good at knowing who knows what :) 19:07
colomon: Please give 787295d a spin
colomon jnthn: I've been eagerly awaiting it.
19:08 ORFJackal joined
jnthn LHF for others: maybe pull HashIter out into a HashIter.pm for consistency and update the Rakudo/Parrot makefiles; look into untodo'ing some tests :) 19:08
timotimo: Another run of p6bench may be interesting with these latest changes 19:09
ORFJackal jnthn, I heard from Raiph Mellor that you would like a chat; see his comment at blog.orfjackal.net/2013/07/lambda-e...ava-7.html 19:12
[Coke] jnthn: not your job, no worries. ;) 19:14
jnthn ORFJackal: Looking...
ORFJackal: Ah, I'd heard about Retrolambda :) 19:16
ORFJackal word travels fast nowadays :)
jnthn ORFJackal: Is it doing Just Enough of invokedynamic for what is needed by Java 8 lambdas?
ORFJackal it basically produces similar bytecode as if you would use anonymous inner classes instead 19:17
19:17 preflex left, mtk left, Kiralexis left 19:18 crab2313 left, Kiralexis joined, preflex joined, mtk joined, PerlJam joined, ivan``_ joined, crazedpsyc joined, TimToady joined, kshannon joined, gfldex joined, mathw joined, bakedb joined, arnsholt joined, hubbard.freenode.net sets mode: +v preflex
ORFJackal it takes the invokedynamic instruction produced by JDK 8 for lambdas, and replaces it with a normal method invocation for instantiating the class 19:19
jnthn OK. We're using invokedynamic for a bunch of things; I guess my question is whether this is a general way to get code using invokedynamic to run on JVMs without it, or if it looks for Java 8 lambda-like uses of invokedynamic and just tweaks thsoe?
19:19 pmurias joined 19:20 xinming left, benabik left, nyuszika7h left, cognominal left, kingbeast left
jnthn guesses the latter, having read more carefully now :) 19:20
ORFJackal it looks for only lambda related invokedynamic
the relevant code is at github.com/orfjackal/retrolambda/b...a#L97-L110 19:21
19:21 xinming joined, benabik joined, nyuszika7h joined, cognominal joined, kingbeast joined, masak joined, Ulti joined, odoacre_ joined, scottp joined, rom1504 joined, simcop2387 joined
ORFJackal in lambda's case it's enought to replace the invokedynamic with a single invokestatic call, because it knows how LambdaMetafactory works 19:22
jnthn Yeah. )
ORFJackal in the general case invokedynamic is much more flexible, because it can dispatch the method call dynamically to lots of places
colomon jnthn: certainly makes my golfed test work better! 19:23
19:23 pmurias left 19:24 smash_ left, gabriel_ left, awwaiid left, sivoais left
jnthn Yes, we've got a bunch of usages like that. However, it occurs to me that the approach - recognize specific uses of invokedynamic that our code-gen spits out and then tweak them using knowledge of what they do - could be used. 19:26
ORFJackal Yes, that might work, if you know the implementation details of the bootsrap method. I doubt that any generic solution would be possible - at least not with same performance. 19:28
19:29 zamolxes joined, smash joined, integral joined, integral left, integral joined, awwaiid joined, cosimo joined, sivoais joined
jnthn Yes, there is a small-ish set of bootstrap methods that we use. 19:29
19:29 diakopter joined, mls joined, frettled joined, p5eval joined, huf joined 19:30 pmurias joined, gabriel_ joined, rhr joined
ORFJackal Are the call sites constant or dynamic? 19:30
jnthn Dynamic.
Which makes it a bit more fun :) 19:31
19:31 sjohnson joined
ORFJackal :) 19:31
What are your motivations of getting rid of invokedynamic?
19:31 sjohnson left, sjohnson joined
ORFJackal Is Java 7 too high a minimum requirement? 19:32
jnthn Only motivation really running in places where it's not available yet, as an option rather than as a default. 19:33
ORFJackal Like Android and others?
jnthn Yeah. Which would be kinda cool, though I'm not sure how useful. :) 19:34
ORFJackal True.
jnthn And probably it's only a matter of time before invokedynamic is more widespread...
19:34 djanatyn joined, araujo joined 19:35 silug joined, charsbar_______2 joined, rafl joined
ORFJackal I agree. Java 6 is already EOL, so Java 7 should sooner or later be everywhere. 19:35
...except some mobile stuff.
geekosaur .oO { famous last words }
cognominal before Perl 7? /me ducks 19:36
ORFJackal :)
I wonder if some companies still use Java 5 in production. 19:37
jnthn ORFJackal: Out of curiosity, is there a good place you know to follow the invokedynamic improvements going into JDK8?
19:37 sqirrel left
jnthn (short of the openjdk mailing lists...) 19:38
ORFJackal I was just about to mention them ;)
There is groups.google.com/forum/#!forum/jvm-languages which seems to be filled with likeminded people
I'm not reading it actively, but that's the place I would look for if I want to hear about such things 19:39
Then there is the JVM Language Summit conference. I don't know whether their presentations are published online, but it's worth finding out. 19:41
jnthn Hm, that forum shows no posts since April...
ORFJackal openjdk.java.net/projects/mlvm/jvmlangsummit/ "Talks from previous years are hosted by the Oracle Technology Network: 2011, 2012. Some older talks are also available at InfoQ (2008 & 2009) and on the wiki (2010)."
tadzik "already EOLd". Like Perl 5.8, for example? :P
ORFJackal :) 19:42
19:42 nemesys joined
jnthn ORFJackal: Thanks for the pointers :) 19:43
ORFJackal np
19:44 vk_ joined 19:54 nemesys left 19:56 SamuraiJack left 19:59 SamuraiJack joined 20:01 prevost joined 20:03 domidumont joined
FROGGS r: use MONKEY_TYPING; augment class Buf { } 20:03
camelia rakudo 787295: OUTPUT«===SORRY!===␤Cannot augment Buf because it is closed␤at /tmp/CfA_3P5c45:1␤------> use MONKEY_TYPING; augment class Buf ⏏{ }␤ expecting any of:␤ scoped declarator␤ generic role␤»
FROGGS star: use MONKEY_TYPING; augment class Buf { }
camelia star 2013.02: ( no output )
20:03 SamuraiJack left
FROGGS is that by design? 20:03
jnthn Yes; Buf is a role, not as class, per spec. We used to have that wrong. 20:04
FROGGS hmmmm 20:05
r: say "a".encode.WHAT 20:07
camelia rakudo 787295: OUTPUT«(utf8)␤»
20:08 domidumont left
[Coke] I cannot imagine we are upgraded to java 7 here at work anytime soon. :P 20:09
*upgrading
FROGGS I'd think that we are stuck with the version that was popular in 2008
20:16 benabik left 20:17 corecatcher joined 20:18 benabik joined
timotimo jnthn: i'm going to go do a benchmark run. should i do both rakudo.jvm and rakudo.parrot against older rakudo.jvm and rakudo.parrot? 20:22
20:23 zby_home_ left
jnthn timotimo: yeah 20:27
[Coke]: Did you do an ecosystem test run since the Buf signedness fixes I did? 20:28
[Coke] that was days ago, yes? everything seems fine-ish on the jvm.
er, wait, ecosystem. star?
jnthn [Coke]: The modules tests 20:29
[Coke] the way the daily star tests pick what to run is currently useless - it picks the versions that are selected in star.
so any commits newer than that are ignored. :)
made sense when we got started, because even those were broken. 20:30
jnthn ah, ok
[Coke] but now It needs to move to latest-and-greatest, I think.
jnthn *nod*
[Coke] I'll get that done this weekend.
jnthn OK
PerlJam [Coke]++
jnthn I'll be gone by then, but will be back well before any release involving Buf... :)
[Coke] wonders if there's enough working to get started on a rakuduo.jvm* 20:31
corecatcher evening, are there any other LHF except those few issues at github? 20:33
jnthn [Coke]: I expect a bunch of modules may well work 20:34
FROGGS corecatcher: there are tickets in RT too
jnthn [Coke]: We're missing a few foundational pieces like NativeCall that will probably block a bunch of stuff.
timotimo corecatcher: rakudo.org has a section "bugs" on the top where you can find a pre-made search for LHF in the RT
PerlJam timotimo: currently showing 0 results. 20:36
timotimo hm
let's make some ;)
PerlJam NYI is showing 0 too 20:37
blocking on tests has bunches though.
those should be LHFish
corecatcher FROGGS: url?
FROGGS corecatcher: ^^rt.perl.org/rt3/Public/Search/Simp...lled%27%29 20:38
sorry for the long url
corecatcher np, thx
FROGGS err, remove that ^^
[Coke] FROGGS, corecatcher : rakudo.org/tickets/ is a decent launch page to avoid having to remember the long urls. 20:40
20:40 ajr_ left
dalek kudo/sized-arrays: e124a6a | Arcterus++ | / (11 files):
Add support for shaped arrays
20:40
kudo/sized-arrays: fe86822 | Arcterus++ | / (86 files):
Merge remote-tracking branch 'upstream/nom' into nom

Conflicts: src/vm/jvm/runtime/org/perl6/rakudo/Ops.java
kudo/sized-arrays: ec7842b | Arcterus++ | src/core/Array.pm:
Fixed error with 'use' statements
kudo/sized-arrays: 6493e48 | jnthn++ | / (11 files):
Bring Arcterus++ sized array work into a branch.

Can evaluate/tweak it from here.
timotimo cool :)
jnthn: i built rakudo.parrot and rakudo.jvm for bench now and i'll run timings now 20:43
jnthn \o/
timotimo++
20:43 dmol left
timotimo jnthn: any particular version you'd like me to compare it to? 2013.07? 20:43
jnthn timotimo: That'll do just fine. 20:44
timotimo i'll have to build them, too ...
i can give you a comparison to older revisions in the mean time
PerlJam timotimo: sounds like a blog post in the making too :) 20:45
timotimo only if the results are meaningful.
also, i'm kind of stealing japhb's thunder ;) 20:46
corecatcher omg, these bugs are all years old - either not up2date anymore and need to be verified? :)
timotimo hehe. some are just waiting for a test case to be written and checked into perl6/roast 20:47
20:47 wk joined, cognominal left, wk is now known as Guest37729 20:48 fridim_ left
PerlJam timotimo: you could talk about the lightning (benchmark setup) and let japhb talk about the thunder (results) 20:48
jnthn corecatcher: There's a load of fixed bugs that need test cases, as timotimo just mentioned. They typically contain a good example of what code the test case should contain and the correct result, so it's quite easy to convert them into tests and then get the ticket clsoed. :)
timotimo japhb had a benchmark setup talk at yacp::na
20:48 cognominal joined
jnthn corecatcher: This is a very useful thing to be doing. :) 20:48
PerlJam timotimo: I know. The more points of view on a subject, the more meaningful it becomes to people. :) 20:49
20:49 rGeoffreeey joined
corecatcher haha, i do recognize dirty work, but yes its useful 20:49
20:51 BenGoldberg joined
jnthn timotimo: I wouldn't worry about stealing thunder here; most of the time, I think people's reaction to "hey, I used your thing and did something cool/useful" is "yay", not "oh noes I wanted to say that" ;) 20:51
dalek kudo-js: bc60823 | (Pawel Murias)++ | / (5 files):
Implement subcapture, fix //.

That makes basic protoregexes work. Pass test 32.
timotimo :)
jnthn I'm gonna be offline Sat - Sat; if there's anything anybody would especially like me to look at or unblock before I go, please do say :)
timotimo do you have opinions on nodality? although i guess that can wait a week or two. i can just as easily pass my time with pod6 work 20:52
colomon \o/
lizmat jnthn: I guess variable traits is out of the question? 20:53
:-)
colomon jnthn: my giant task? The one that ran overnight and then failed? The one I'd never gotten to go successfully? completed in 12 minutes with your new code. 20:54
timotimo oooooh yeah!
you were the one completing lots and lots of rosalind examples but never being able to run them on rakudo, weren't you?
maybe it's time to retry some of those :D
colomon timotimo: not I 20:55
jnthn That was grondilu
timotimo oh
jnthn colomon: That's on JVM? :)
timotimo in that case ... we should notify grondilu :) 20:56
colomon yes
jnthn Overnight and failing to 12 minutes and successful is WIN :)
colomon WIN WIN WIN
jnthn++
timotimo yoleaux: tell grondilu there's been a radical fix for 'for' loops in rakudo a few hours ago that may make a lot of the rosalind things you weren't able to run yet work. care to give it a try? :)
BenGoldberg r: for ( gather { take 1; die 'eager' } ) { .say; last }; say 'lazy'; 20:59
camelia rakudo 787295: OUTPUT«eager␤ in block at /tmp/asrUcCyH7j:1␤␤»
lizmat sees some spectest failures after doing a git pull just now 21:00
checking...
some TODO's passed :-) 21:01
timotimo benchmarking takes forever :| 21:02
21:02 domidumont joined
jnthn BenGoldberg: That one's know...it's for's fault, I believe. 21:02
timotimo BenGoldberg: feels like you've been showing us the same known bug a few times now ;) 21:03
doesn't seem like you really know how to fix it quickly, jnthn? else it would already have been done perhaps? ;) 21:04
21:04 byte48 left
jnthn timotimo: I'm not sure about nodality... 21:04
timotimo: Yeah, it really needs pmichaud tuits...
timotimo that's okay
jnthn timotimo: I can touch iterator stuff but I take it in the wrong direction as often as the right one... :) 21:05
timotimo random walk, eh?
jnthn lizmat: Variable traits...hmmm :)
dalek ast: f4c5ed8 | (Elizabeth Mattijsen)++ | S (3 files):
Unfudge TODO's passing after jnthn's work of today
timotimo you're bound to reach the goal that's n steps away in n^2 steps i believe
21:06 xinming left, xinming joined
lizmat checking remaining new failure in t/spec/S32-exceptions/misc.t 21:06
21:08 ORFJackal left
timotimo rakudo.parrot has finished its benchmark run 21:08
21:09 domidumont left 21:11 dmol joined
lizmat r: use fatal; (1+2i).Num 21:11
camelia rakudo 787295: OUTPUT«Can not convert 1+2i to Num: imaginary part not zero␤ in block at src/gen/CORE.setting:10863␤ in method coerce-to-real at src/gen/CORE.setting:8986␤ in method Num at src/gen/CORE.setting:8992␤ in block at /tmp/9YHX3Mi5ag:1␤␤»
lizmat seems this doesn't throw like it should ?
jnthn lizmat: It doesn't? 21:12
jnthn looks confused
corecatcher hm, rt.perl.org/rt3/Public/Bug/Display...l?id=88708 that bug has a test in roast/S03-operators/range.t:294
so it might be closed?
timotimo do you want to create an account with bitcard and close it or should i do it for you? 21:13
21:13 iSlug left
timotimo wonders if the irclog has a magic link for that test corecatcher linked 21:13
corecatcher for the sake of lazyness, do it for me ;)
timotimo sure :) 21:14
lizmat looks further
quite a number of tests in that file
corecatcher might rather grep for the RT numbers and check each of them
jnthn colomon: I assume the test is passing? :)
oops
corecatcher: ^^
FROGGS r: 1..4..7 21:15
camelia rakudo 787295: OUTPUT«===SORRY!===␤Operators '..' and '..' are non-associative and require parenthesis␤at /tmp/MrHfpf0d1G:1␤------> 1..4.⏏.7␤ expecting any of:␤ postfix␤ dotty method or postfix␤»
FROGGS gnight
jnthn 'night, FROGGS
lizmat gnight, FROGGS!
jnthn: this test fails "throws_like 'use fatal; (1+2i).Real', X::Numeric::Real, target => Real;"
timotimo weird. when i ./t/fudgeandrun that test file, it won't properly fudge a test that trips up rakudo 21:16
but yeah, the test passes
PerlJam corecatcher: the test also references RT #77572, so I guess RT#88708 is a dup?
21:17 spider-mario left
timotimo i will close both. 21:17
21:17 arcterus joined, arcterus left
timotimo done 21:18
jnthn lizmat: How does it fail?
lizmat not ok 482 - .target matches (Real)
use of uninitialized value of type Real in string context in any at src/gen/Metamodel.nqp:1461
use of uninitialized value of type Real in string context in block at t/spec/packages//Test/Util.pm:143
# Got:
# Expected:
21:18 arcterus joined
timotimo great! :D 21:18
jnthn um :) 21:19
lizmat: Dunno if you can golf it to anything?
timotimo oh, jnthn, i have an issue that i think i need you to look at, but it may be hairy enough to not go in before saturday and i don't think anything except my ADT module depends on it getting fixed. does that sound interesting at all?
lizmat r: use fatal; (1+2i).Real # jnthn, this was the gold 21:20
camelia rakudo 787295: OUTPUT«Can not convert 1+2i to Real: imaginary part not zero␤ in block at src/gen/CORE.setting:10863␤ in method coerce-to-real at src/gen/CORE.setting:8986␤ in method Real at src/gen/CORE.setting:8989␤ in method Real at src/gen/CORE.setting:911␤ in block at /tmp/wy…
lizmat golf
corecatcher r: sub f { f(|$) }; say "alive"
camelia rakudo 787295: OUTPUT«===SORRY!===␤Unsupported use of $) variable; in Perl 6 please use $*EGID␤at /tmp/QMHU4XPbmE:1␤------> sub f { f(|$)⏏ }; say "alive"␤»
corecatcher r: sub f { f( |$ ) }; say "alive" 21:21
jnthn r: use fatal; try (1+2i).Real; say $!.perl
camelia rakudo 787295: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name␤at /tmp/XIl00tvlRU:1␤------> sub f { f( |⏏$ ) }; say "alive"␤ expecting any of:␤ argument list␤ prefix or term␤ prefix or meta-prefix␤»…
rakudo 787295: OUTPUT«X::Numeric::Real.new(target => Real, reason => "imaginary part not zero", source => Complex.new(1, 2))␤»
jnthn lizmat: Yeah, but that exception object looks correct to me; it's got Real in there...
lizmat: What kind of comparison is thrwos_like doing?
21:22 xinming left
lizmat checking 21:23
my $got = $_."$k"(); 21:24
my $ok = $got ~~ $v,;
21:24 xinming joined
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say $v.perl } 21:25
camelia rakudo 787295: OUTPUT«Real␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say $v }
camelia rakudo 787295: OUTPUT«(Real)␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say Real ~~ $v } 21:26
camelia rakudo 787295: OUTPUT«False␤»
lizmat huh?
jnthn huh indeed
star: my %h = a => Real; for %h.kv -> $k, $v { say Real ~~ $v } 21:27
camelia star 2013.02: OUTPUT«True␤»
lizmat uh oh
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::iscont($v); say Real ~~ $v }
camelia rakudo 787295: OUTPUT«1␤False␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::iscont($v); say Real ~~ nqp::decont($v) }
camelia rakudo 787295: OUTPUT«1␤False␤»
jnthn Thought it couldn't be that.
PerlJam r: my %h = a => Real; for %h.kv -> $k, $v { say $v ~~ Real } # just checking
camelia rakudo 787295: OUTPUT«True␤»
21:27 rGeoffreeey left, rGeoffreeey_ joined, rGeoffreeey_ is now known as rGeoffreeey
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::iscont($v); say $v.ACCEPTS(Real) } 21:28
camelia rakudo 787295: OUTPUT«1␤False␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::istype(Real, $v) }
camelia rakudo 787295: OUTPUT«0␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::istype(Real, nqp::decont($v)) }
camelia rakudo 787295: OUTPUT«0␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::istype(Real, Real) }
camelia rakudo 787295: OUTPUT«1␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::istype($v, Real) }
camelia rakudo 787295: OUTPUT«1␤»
jnthn wtf
21:29 FROGGS left
BenGoldberg r: say nqp::istype(Real, Real) 21:29
camelia rakudo 787295: OUTPUT«1␤»
21:29 arcterus left
BenGoldberg r: my %a = a => Real; for %h.kv -> { say nqp::decont($v) } 21:30
camelia rakudo 787295: OUTPUT«===SORRY!===␤Variable '%h' is not declared␤at /tmp/nKyABJQLEz:1␤------> my %a = a => Real; for %h.kv⏏ -> { say nqp::decont($v) }␤ expecting any of:␤ method arguments␤ postfix␤»
BenGoldberg r: my %h = a => Real; for %h.kv -> { say nqp::decont($v) }
camelia rakudo 787295: OUTPUT«===SORRY!===␤Variable '$v' is not declared␤at /tmp/34JzKZJpE0:1␤------> Real; for %h.kv -> { say nqp::decont($v⏏) }␤ expecting any of:␤ postfix␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, $v { say DUMP($v) }
camelia rakudo 787295: OUTPUT«▶Real␤»
BenGoldberg r: my %h = a => Real; for %h.kv -> $k, $v { say nqp::decont($v) }
camelia rakudo 787295: OUTPUT«(Real)␤»
BenGoldberg r: my %h = a => Real; for %h.kv -> $k, $v { say Real }
camelia rakudo 787295: OUTPUT«(Real)␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, \v { say Real ~~ v }
camelia rakudo 787295: OUTPUT«False␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, \v { say nqp::iscont(v); say Real ~~ v } 21:31
camelia rakudo 787295: OUTPUT«0␤False␤»
jnthn r: my %h = a => Real; for %h.kv -> $k, \v { say nqp::iscont(v); say Real ~~ nqp::decont(v) }
camelia rakudo 787295: OUTPUT«0␤False␤»
jnthn Really weird.
oh, I wonder...
r: say Real ~~ Real.item
camelia rakudo 787295: OUTPUT«False␤»
jnthn Now, that's a golf.
21:32 ajr joined
BenGoldberg r: my @a := gather { .take for 1..Inf }; @a.infinite.say; my @b; push @b, @a; 21:32
camelia rakudo 787295: OUTPUT«(timeout)Nil␤»
21:32 ajr is now known as Guest84800
BenGoldberg Inside .push, the return value of .infinite is not checked for being Nil 21:33
21:33 Guest84800 is now known as ajr_
jnthn lizmat: the "my $! is default(Nil)" in the traits.pm will create a bootstrapping issue, but also is not going ot influence anything other than precisely the $!/$_/$/ symbols in the main body of the setting itself... 21:33
lizmat ok, I'll take them out :-) 21:34
jnthn lizmat: Don't worry, done locally in my var-traits branch.
lizmat ok
BenGoldberg: Nil means, we don't know 21:35
so it's potentially *not* infinite, so it *may* finish
BenGoldberg I know that, but... isn't there a way to implement .push lazily?
jnthn That's called .plan, though it's NYI 21:36
BenGoldberg Perhaps when, inside of .push, .infinite returns Nil, it should throw an error saying that you should be using .plan instead? 21:41
jnthn lizmat: Yes, looks like I'll have us a first cut of variable traits tonight
lizmat that would be great news!
I'll fudge that test for now, it is weird 21:42
jnthn lizmat: no, I think I know how to fix it
lizmat ah, ok
jnthn lizmat: Leave it for now, I tyr and do it in a moment after these var traits.
lizmat okidoki
jnthn Just building it on Parrot at the moment
lizmat: In fact, if you have a moment, try this patch: gist.github.com/jnthn/6084057 21:45
lizmat trying
jnthn Thanks...then I can focus on the var traits :)
corecatcher please close that one, you'll see rt.perl.org/rt3/Public/Bug/Display...?id=118835 21:46
jnthn ooh yays
corecatcher hm, lots of spam in the recent queue
21:46 dmol left
jnthn lizmat: Just done as a test of var traits an implementation of "is default"...and it seems to work \o/ 21:47
lizmat jay, that would mean one step closer to get Nil really working for Any as well
jnthn: success on that particular test, running full spectest now just to make sure 21:50
jnthn lizmat: ok :) 21:53
timotimo about 50% of the rakudo-jvm benchmark run is done. 21:54
21:55 colomon joined 21:56 pmurias left
dalek kudo/nom: 117beb2 | (Elizabeth Mattijsen)++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Make Real ~~ Real.item work, suggested by jnthn++
21:59
lizmat jnthn: verified and committed 22:00
and it's yet another day, gnight #perl6! 22:01
colomon jnthn: trying same giant task on parrakudo, it's been running for 45 minutes now. so it seems like jakudo has a pretty big advantage here at the moment. 22:04
jnthn r: say 45 / 12 22:06
camelia rakudo 787295: OUTPUT«3.75␤»
dalek kudo/var-traits: b54c12b | jnthn++ | src/core/traits.pm:
Remove unrequired default decls.

We ignored these before; now we pay attention to them, and hit a bootstrap issue.
kudo/var-traits: 4766065 | jnthn++ | / (5 files):
First pass at getting variable traits in place.
kudo/var-traits: cd4831d | jnthn++ | src/core/Variable.pm:
Implement default trait on variables.

Again, a first pass, but seems to basically work.
22:06 prevost left 22:07 kingbeast left 22:13 skids joined
timotimo timing the 32/42th benchmark now 22:17
22:22 rGeoffreeey left, jaldhar left 22:23 jaldhar joined 22:32 Shozan joined, Guest37729 left
timotimo 40/42 ... 22:32
22:33 broquain1 joined, _sri joined, pnu_ joined, avarab joined, avarab left, avarab joined, [Coke]_ joined, Some-body_ joined, Gothmog__ joined, BooK_ joined, patspam_ joined 22:34 BinGOs_ joined, jferrero_ joined, ingyfoo joined, corecatcher left 22:35 corecatcher joined, Gothmog__ is now known as Gothmog_, Some-body_ is now known as DarthGandalf, _ilbot joined, hugme joined, ChanServ sets mode: +v hugme 22:36 corecatcher left, camelia joined 22:37 ChanServ sets mode: +v camelia, cognominal__ joined, cognominal left, vk_ left 22:38 groky joined
timotimo jnthn: how would you like some benchmarks? :) 22:39
22:40 btyler left
jnthn timotimo: Well, I have some beer here. I can drink it in celebration or commiseration :P 22:42
timotimo t.h8.lv/p6bench/before-after-for-an...h-fix.html - don't decide on the outcome before reaching the end.
22:43 btyler joined
timotimo i think i still need to fix the trim_string benchmark for perl5. 22:43
22:43 colomon left
jnthn Which sha-1's are which? 22:44
22:44 BinGOs_ is now known as BinGOs, BinGOs left, BinGOs joined
jnthn ah, figured it 22:45
The 78' is latest
22:45 kingbeast joined
timotimo indeed 22:46
22:46 Khisanth joined
timotimo it made things a bit better all in all. there is no benchmarks for hash iteration alas 22:46
want me to come up with one? :)
or maybe you suggest one, i run it.
jnthn timotimo: Yeah, still plenty of work to go on the benchmarks... 22:50
timotimo: Well, could take something like what colomon's original report had...
timotimo i just made a for loop that sets {$_} = $_ and then .kv -> $k, $v 22:51
22:56 bluescreen100 left
timotimo stackoverflow at Failed to run command: ./perl6 -e my %h; for ^4096 { %h{$_} = $_ }; for %h.kv -> $k, $v { $k == $v }; 22:57
but that's a decent benchmarking code? (4096 is the SCALE)
BenGoldberg r: my $foo = do { .say for( 1..5 ) }; say $foo; 22:58
camelia rakudo 117beb: OUTPUT«1␤2␤3␤4␤5␤True True True True True␤»
BenGoldberg In non-sink context, 'for' acts like 'map' ? 22:59
jnthn BenGoldberg: yes
timotimo: uh, stack overflow?!
timotimo: The thinkg I did earlier fixed the stack overflow... 23:00
timotimo that's the old version
23:00 broquaint joined
jnthn timotimo: oh... 23:00
:)
timotimo there's no comparison unless i run the old version as well ;)
jnthn ;)
:D
23:00 broquain1 left, nyuszika7h left 23:01 nyuszika7h joined
timotimo ah, it's done. will build charts now 23:01
t.h8.lv/p6bench/hash-iterate.html - there we go 23:03
wow look at the jvm go
23:03 corecatcher joined
jnthn yeah :) 23:04
Though we got notably better on Parrot too
timotimo yeah, a bit 23:07
23:07 ajr_ left
timotimo anything else you'd like comparison'd? 23:08
23:09 bluescreen10 joined 23:13 colomon joined
jnthn timotimo: push in a for loop in sink context could be a worthwhile benchmark 23:17
timotimo: So we can spot the regression should it happen again.
23:19 rGeoffreeey joined
timotimo can you give me an example? i'm not sure i can make that happen well. { my @a; for ^SCALE { @a.push($_) }; }? 23:24
yeah, that should do it. 23:25
23:26 estrabd left
jnthn That does it, yes 23:27
But something after the for loop maybe to ensure the sink context 23:28
23:28 estrabd joined
timotimo well, i'll just check if it works at all. 23:29
23:35 PacoAir left
gfldex std: my @foo of Str|Num; sub f(@foo of Str|Num){} 23:35
camelia std c2215f0: OUTPUT«===SORRY!===␤Unable to parse signature at /tmp/ZzbasnVd6z line 1:␤------> my @foo of Str|Num; sub f⏏(@foo of Str|Num){}␤Couldn't find final ')'; gave up at /tmp/ZzbasnVd6z line 1:␤------> my @foo of Str|Num; sub f(@foo of Str…
gfldex is that NYI or am I asking for something silly?
jnthn of expects a type name 23:42
Declare a subset type if you wish to do something like that.
Then use of on that.
'night, #perl6
gfldex ===SORRY!=== 23:50
Invalid typename 'HTML-nodes' in parameter declaration. Did you mean 'HMTL-nodes'?
that's either a bug or rakudo is mocking me :)
23:53 rGeoffreeey left 23:55 felipe joined
timotimo jnthn: posted a charts link in #moarvm, but it doesn't seem right 23:56