»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend! Set by masak on 12 May 2015. |
|||
00:03
lilgreen left
00:08
captain-adequate left
|
|||
tony-o | nah | 00:18 | |
here is the one liner i was using | 00:19 | ||
my HTTP::Server::Threaded $s .=new; $s.handler(sub ($r,$s) { $s.close("sup"); }); $s.listen; | |||
and then: ab <whatever> 127.0.0.1:8091/ | |||
00:26
tinyblak joined
00:28
laouji joined
00:29
jepeway joined
00:39
laouji left
00:40
laouji joined
00:41
AlexDani` left
00:42
laouji left
00:46
tinyblak left
00:50
laouji joined
00:59
tinyblak joined
01:01
Akagi201 joined
01:06
BenGoldberg_ joined
01:11
yeahnoob joined
01:13
kurahaupo1 joined
01:49
Gardner joined
01:50
dayangkun joined
01:51
atweiden left
|
|||
timotimo | t/07_chunkedrequestecho.t ......... ok - and then it just doesn't do anything any more | 01:52 | |
01:57
Gardner left,
aborazmeh joined,
aborazmeh left,
aborazmeh joined
|
|||
gagalicious | is there a perlbot here? | 02:04 | |
perlbot : how are u? | |||
02:21
yqt left
02:22
noganex joined
02:25
noganex_ left
|
|||
[Coke] | m: say "hi" | 02:30 | |
camelia | rakudo-moar 28a769: OUTPUT«hi» | ||
colomon | paultcochrane++ | 02:32 | |
02:35
nys left
02:38
rmgk_ joined,
rmgk left,
rmgk_ is now known as rmgk,
prevost joined
02:45
gerry__ joined
02:50
gerry__ left
|
|||
BenGoldberg_ | m: say 'I am a ' ~ $*PERL ~ ' bot.' | 02:50 | |
camelia | rakudo-moar 28a769: OUTPUT«I am a Perl 6 bot.» | ||
03:00
lizmat joined
03:13
kurahaupo1 left
03:21
BenGoldberg_ left
|
|||
dalek | kudo/nom: d6430c1 | lizmat++ | docs/ChangeLog: Fix probable typo |
03:33 | |
lizmat | std: my @a = *[1,2.3] | 03:37 | |
camelia | std 28329a7: OUTPUT«ok 00:00 140m» | ||
lizmat | m: my @a = *[1,2.3]; say @a | 03:38 | |
camelia | rakudo-moar 28a769: OUTPUT«WhateverCode.new» | ||
lizmat | m: my @a = *[1,2.3]; say @a.perl | ||
camelia | rakudo-moar 28a769: OUTPUT«[WhateverCode.new]<>» | ||
lizmat | feels to me that *[...] makes more sense as a flattening indicator than :[...], because we also use it for slurpies | ||
skids | I can see that but I think I may have actually used *[] in a whatever already. | 03:40 | |
lizmat | skids: so what does that mean? | 03:41 | |
03:41
aborazmeh left
|
|||
lizmat | camelia's output didn't tell me much... | 03:41 | |
skids | m: my @lperms = [^16], { [ (7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8)[$_.values] ] } ... *[0] == 4; @lperms.say | ||
hrm. | |||
camelia | rakudo-moar 28a769: OUTPUT«(timeout)» | 03:42 | |
skids | weird that works in production... | 03:43 | |
oh, thats an old file. | |||
Used to work. Broke at some point and I had to work around it. | 03:44 | ||
m: ($(1,2),$(2,3)).grep(*[1] == 2).perl.say # simpler example. | 03:46 | ||
camelia | rakudo-moar 28a769: OUTPUT«($(1, 2),)» | ||
03:47
gerry__ joined,
labster joined
|
|||
skids | Dunno, ban "\_" as a term and use underscore? | 03:50 | |
gagalicious | pastebin.com/60jK1bEk <-- i have some characters like <202e> etc that is seen from inside vim editor... i would like to remove them using the perl substitution but it doesnt work. help. | 03:51 | |
labster | hm, just managed to segfault my REPL on the second expression. | 03:52 | |
skids | oh that's P5 code. | 03:53 | |
03:56
tinyblak left
|
|||
skids | So, assuming :[] do we also get @foo:[1,2,3] or is that a syntactic mess? | 03:58 | |
(as a flattening slice) | |||
labster | .u 202E | ||
yoleaux | U+202E RIGHT-TO-LEFT OVERRIDE [Cf] (<control>) | ||
TimToady | subscripts already flatten | ||
the assumption is that you're slicing, and that indices typically want to be integers, not sublists | 03:59 | ||
skids | Ah, so that's one flattening context that will remain. | 04:00 | |
04:01
gerry__ left
|
|||
skids | heheh. crazy up-too-late idea. Make term<_> a magical "identity array" and _[] falls out naturally. | 04:03 | |
Oh I guess that really only works for hashes. | |||
04:05
kaare_ joined
|
|||
skids | Maybe the inside-flattener belongs inside the circumfix. | 04:09 | |
04:10
diana_olhovik_ joined,
prevost left
04:11
lizmat left
|
|||
skids | m: $[|1,[2,3]].perl.say | 04:12 | |
camelia | rakudo-moar d6430c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Hau1DX6rlfArg-flattening | is only valid in an argument listat /tmp/Hau1DX6rlf:1------> 3$[|7⏏051,[2,3]].perl.say» | ||
skids | Isn't that semantically an argument list? | ||
Oh, guess not because adverb part of the capture oes outside. | 04:14 | ||
04:22
Peter_R left
04:23
Peter_R joined
04:27
steve_mc left
04:31
silug left
04:35
telex left,
skids left
04:36
telex joined
04:40
steve_mc joined
|
|||
tony-o | m: $[1,2,3].perl.say | 04:41 | |
camelia | rakudo-moar d6430c: OUTPUT«(Any, Any, Any)» | ||
gagalicious | pastebin.com/60jK1bEk <-- i have some characters like <202e> etc that is seen from inside vim editor... i would like to remove them using the perl substitution but it doesnt work. help. | ||
tony-o | m: |$[1,[2,3]].perl.say | 04:42 | |
camelia | rakudo-moar d6430c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/mdEyy57bSRArg-flattening | is only valid in an argument listat /tmp/mdEyy57bSR:1------> 3|7⏏5$[1,[2,3]].perl.say» | ||
04:44
silug joined
04:47
spider-mario left
04:48
spider-mario joined
04:55
gerry__ joined
04:56
kurahaupo joined
04:57
kurahaupo left
04:58
kurahaupo joined
05:04
kst left
05:05
diana_olhovik_ left
05:08
Woodi left,
Woodi joined
05:17
gerry__ left
05:18
gerry__ joined
05:19
kurahaupo left
05:20
gerry__ left,
gerry__ joined
05:21
quester joined
05:25
gerry__ left
05:29
gerry__ joined
05:31
gerry__ left
05:34
tinyblak joined
05:47
gerry__ joined
05:49
diana_olhovik_ joined
05:56
Woodi left
05:59
kaare_ left,
kaare_ joined
06:04
tinyblak left
06:05
_mg_ joined
06:13
gfldex joined
06:20
domidumont joined
06:22
tinyblak joined
06:25
domidumont left,
domidumont joined
06:26
RabidGravy joined
06:28
kst joined
|
|||
dalek | line-Perl5: 7e03fc9 | (Stefan Seifert)++ | t/lib/P5 (2 files): Add missing test files Thanks to quester++ for reporting |
06:28 | |
masak | morning, #perl6 | ||
06:29
brrt joined
|
|||
masak | tony-o: we use `flat` outside of argument lists, and `|` in argument lists... for some reason... | 06:29 | |
[ptc] | masak: o/ | 06:32 | |
yoleaux | 11 Jun 2015 23:15Z <japhb> [ptc]: rakudo commit ba5fab6 sets a default for :$abs_tol = 0, but then immediately dies unless $abs_tol > 0. This seems unintentional. In fact, I don't see why either $abs_tol or $rel_tol == 0 is a problem; it's just the degenerate equality case, rather than approximation. | ||
06:33
Woodi joined
|
|||
[ptc] | japhb: actually, the is-approx implementation was just a proposal to be discussed. | 06:33 | |
japhb: unfortunately, in the end not much discussion happened. I based the implementation on that which Python uses in SciPy and it seemed a sensible way to do it. | 06:34 | ||
japhb: I'm most certainly open to improvements to the current is-approx implementation | |||
japhb: the reason I proposed the change at all was because the previous implementation was producing inconsistent results. E.g. very small numbers were always approximately equal even if being wildy different | 06:39 | ||
06:44
gerry__ left
06:46
abraxxa joined
06:47
gagalicious left
06:52
espadrine_ joined,
kaare_ left,
gagalicious joined
06:55
Sqirrel left,
kaare_ joined
06:56
Sqirrel joined
06:57
kaare_ left,
kaare_ joined
06:59
gfldex left
07:01
Woodi left,
Ven joined
|
|||
labster | m: multi sub prefix:<|> (\a) { a.flat }; say (|[1,2,3]).perl | 07:02 | |
camelia | rakudo-moar d6430c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/jvrQI4RBsSArg-flattening | is only valid in an argument listat /tmp/jvrQI4RBsS:1------> 3i sub prefix:<|> (\a) { a.flat }; say (|7⏏5[1,2,3]).perl» | ||
07:04
tinyblak_ joined
|
|||
labster | n: multi sub prefix:<|> (\a) { a.flat }; say (|[1,2,3]).perl | 07:05 | |
camelia | niecza v24-109-g48a8de3: OUTPUT«sh: mono: command not found» | ||
dalek | line-Perl5: a1c1d93 | (Stefan Seifert)++ | / (2 files): Check for presence of Filter::Simple P5 module in build scripts Should give the user a somewhat more usefull error message than just test failures. Thanks to quester++ for the suggestion! Fixes GH#25 |
07:07 | |
07:07
tinyblak left
07:08
brrt left
07:09
Woodi joined
07:12
kurahaupo1 joined
07:18
brrt joined
07:26
darutoko joined
|
|||
masak | m: multi sub prefix:<|||> (\a) { a.flat }; say (|||[1,2,3]).perl | 07:26 | |
camelia | rakudo-moar d6430c: OUTPUT«[1, 2, 3]<>» | ||
07:30
FROGGS joined
|
|||
labster | masak: Yeah, the grammar hates me. | 07:30 | |
FROGGS | :S | 07:33 | |
good morning | |||
labster | good morning FROGGS | ||
07:38
rindolf joined
07:49
zakharyas joined
07:55
bjz joined
07:56
brrt left
07:57
kurahaupo1 is now known as kurahaupo
08:01
espadrine_ left
08:05
brrt joined
08:11
spider-mario left,
laouji left
08:25
laouji joined
08:35
zengargoyle left,
bin_005 joined
08:51
espadrine_ joined
08:58
g4 joined,
g4 left,
g4 joined
09:00
lizmat joined,
lizmat left,
quester left
09:03
brrt left
09:04
brrt joined
09:06
Celelibi left
09:07
kurahaupo left
09:08
Celelibi joined
09:11
proteusx is now known as acsigusz
09:16
brrt left
09:20
Ven left,
mr-foobar left
09:31
espadrine joined
09:32
espadrine_ left
09:39
yeahnoob left,
AlexDani` joined
09:40
AlexDani` is now known as AlexDaniel
09:41
mr-foobar joined
09:50
Ven joined
09:51
_mg_ left
09:55
cognominal joined
09:58
kurahaupo joined
|
|||
RabidGravy | m: my @a; @a[0] = 65537; sub foo( @h where * <65536) { say @h}; foo(@a) | 10:00 | |
camelia | rakudo-moar d6430c: OUTPUT«65537» | ||
RabidGravy | clearly the whatever there refers to something other than the individual elements | 10:01 | |
is there a way of doing that but constrain the values of the elements? | |||
10:04
kurahaupo left
|
|||
psch | m: my @a; @a[0] = 65537; sub foo( @h where *.grep(* > 65536) == 0) { say @h}; foo(@a) | 10:05 | |
camelia | rakudo-moar d6430c: OUTPUT«Constraint type check failed for parameter '@h' in sub foo at /tmp/Z8RhiiJLsX:1 in block <unit> at /tmp/Z8RhiiJLsX:1» | ||
psch | intuitively i wanted "where all(*) < 65536", but that doesn't compile | 10:06 | |
m: my @a; @a[0] = 65537; sub foo( @h where all(*) < 65536) { say @h}; foo(@a) | |||
camelia | rakudo-moar d6430c: OUTPUT«Cannot call Real(Whatever: ); none of these signatures match: (Mu:U \v: *%_) in sub foo at /tmp/OZUK2M2gWA:1 in block <unit> at /tmp/OZUK2M2gWA:1» | ||
psch | like that | ||
not sure it should, though, Junctions again :P | |||
oh, also the working one probably wants >= | 10:07 | ||
m: my @a; @a[0] = 65537; sub foo( @h where { @^a.grep(* < 65536) == @a}) { say @h}; foo(@a) # or like this | 10:09 | ||
camelia | rakudo-moar d6430c: OUTPUT«Constraint type check failed for parameter '@h' in sub foo at /tmp/_ZOK3qCo4w:1 in block <unit> at /tmp/_ZOK3qCo4w:1» | ||
psch | the all(*) approach does have something, though, but i guess it's an order-of-execution problem | 10:10 | |
i.e. we can't Junction before we have a parameter but have to, so we try to Junction the Whatever and that breaks..? | 10:11 | ||
something like that, i'd guess | |||
aha | 10:12 | ||
but with placeholders it works | |||
m: my @a; @a[0] = 65537; sub foo( @h where { all(@^a) < 65536 }) { say @h}; foo(@a) # or like this | |||
camelia | rakudo-moar d6430c: OUTPUT«Constraint type check failed for parameter '@h' in sub foo at /tmp/g9QhtiWp2k:1 in block <unit> at /tmp/g9QhtiWp2k:1» | ||
psch | RabidGravy: ^^^ that? | ||
RabidGravy | yeah, that :) cheers | 10:13 | |
psch | now who to bug about the Whatever not doing the right thing there... | ||
or maybe just for clarification if that *is* the right thing :s | |||
10:17
Akagi201 left
|
|||
jnthn | Teaching so can't stay long but: no, the * ain't expected to work there, that's not a context where it auto-curries. But why introduce a parameter at all? "where all(@h) < 65536" works | 10:22 | |
That is, just use the nmae of the parameter itself | |||
psch | oh, that works? | 10:23 | |
that's probably even better, i thought of where taking a closure | |||
but yeah, the actual parameter should still be reachable anyway | |||
m: my @a; @a[0] = 65537; sub foo( @h where all(@h) < 65536 ) { say @h}; foo(@a) # or like this | |||
camelia | rakudo-moar d6430c: OUTPUT«Constraint type check failed for parameter '@h' in sub foo at /tmp/ymKUSc5BM3:1 in block <unit> at /tmp/ymKUSc5BM3:1» | ||
psch | jnthn++ | ||
jnthn | yeah, we take care in the binder to put the symbol in place early enough to be sure it works :) | ||
psch | jnthn: can i pick your brain later regarding my path towards standalone executable jars? | 10:24 | |
jnthn | psch: Can try after teaching; let's see how I feel | ||
psch | jnthn: i'm trying to be able to run precompiled .class files directly, via the RakudoEvalServer | ||
RabidGravy | I'd rather do "subset Short of Int where * < 65536; sub foo(Short @a) { ... }" but that doesn't appear to work either | ||
psch | jnthn: sure, thanks :) | ||
jnthn | (I'm still digging my way back to full health.) | ||
RabidGravy: Array types are nominal | 10:25 | ||
That is, you'd have to pass an array declared as a Short array | 10:26 | ||
You do know that native arrays work, yes? :) | |||
my int16 @arr | |||
lunch & | |||
10:27
dayangkun left
|
|||
RabidGravy | ooh, that might work. I didn't now that would but that's even better | 10:27 | |
except it doesn't crap out early enough | 10:29 | ||
m: my int16 @a; @a[0] = 65537; sub foo(int16 @h) { say @h}; foo(@a) | |||
camelia | rakudo-moar d6430c: OUTPUT«1» | ||
psch | well, it overflows | 10:31 | |
RabidGravy: maybe redesigning further up is the better approach. as in, where does it come up that you might have data outside of your range and can you prohibit it there? | 10:33 | ||
except this might already *be* that spot, in which case i'd go with the where clause | 10:34 | ||
RabidGravy | well it's more where it goes | ||
it goes into a CArray[int16] which then gets passed to a short * in a native function | 10:35 | ||
allowing it to wrap not good | 10:36 | ||
psch | just modulo MAX_VALUE :P | ||
clipping is an artistic choice | |||
yeah, no, i guess the where clause does what you need then | 10:37 | ||
10:39
_mg_ joined
|
|||
RabidGravy | they are like to be gigantic arrays, I think for the time being its document the constraint and the wrapping behaviour and leave the actual constraint to the user | 10:47 | |
though that's not too shabby: | 10:51 | ||
m: my @a = (^65538); sub foo( @h where all(@h) <65536) { say @h}; foo(@a) | |||
camelia | rakudo-moar d6430c: OUTPUT«Constraint type check failed for parameter '@h' in sub foo at /tmp/otDajGzfZk:1 in block <unit> at /tmp/otDajGzfZk:1» | ||
10:55
Khisanth joined
10:58
bin_005_r joined,
bin_005 left,
silug left
|
|||
psch | m: our Int sub f { fail "a" }; f() # RT #64990 | 11:00 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...l?id=64990 | ||
camelia | rakudo-moar d6430c: OUTPUT«Earlier failure: a in block <unit> at /tmp/ei0jX01kk7:1Final error: Type check failed for return value; expected 'Int' but got 'Failure' in any return_error at src/vm/moar/Perl6/Ops.nqp:639 in sub f at /tmp/ei0jX01kk7:1 in block…» | ||
psch | naively i'd say p6typecheckrv always allows Failure as matching the type check, but that feels iffy | 11:01 | |
FROGGS | psch: but I think something like that was agreed on... | 11:07 | |
I remember jnthn talking about it | |||
m: my Int sub f { fail "a" }; f() | 11:08 | ||
camelia | rakudo-moar d6430c: OUTPUT«Earlier failure: a in block <unit> at /tmp/fvgswF03l8:1Final error: Type check failed for return value; expected 'Int' but got 'Failure' in any return_error at src/vm/moar/Perl6/Ops.nqp:639 in sub f at /tmp/fvgswF03l8:1 in block…» | ||
FROGGS | m: sub f returns Int { fail "a" }; f() | ||
camelia | rakudo-moar d6430c: OUTPUT«Earlier failure: a in block <unit> at /tmp/mEED5q4MyN:1Final error: Type check failed for return value; expected 'Int' but got 'Failure' in any return_error at src/vm/moar/Perl6/Ops.nqp:639 in sub f at /tmp/mEED5q4MyN:1 in block…» | ||
11:09
Sqirrel left
11:12
Sqirrel joined
|
|||
psch | i think those examples should all go through p6typecheckrv | 11:12 | |
i'll give it a try and see what roast says | |||
11:13
silug joined
11:25
brrt joined
11:28
bjz left
11:29
bjz joined
11:31
cdc left
11:36
tinyblak_ left
11:38
skids joined
11:39
bin_005_r left
11:40
brrt left
11:45
skids left
11:54
brrt joined
11:57
tinyblak joined
11:59
_mg_ left
12:01
Akagi201 joined
12:13
Ulti left,
Ulti joined,
Ulti left,
Ulti joined
12:14
Ven left
12:16
andreoss joined
|
|||
andreoss | use ...::from<java> is intended to be perl6-jvm's only? | 12:19 | |
psch | andreoss: exactly, moar can't interpret jvm bytecode | 12:20 | |
nine | Unless someone writes some Inline::Java for Perl 6 | 12:21 | |
Ulti | psch well in theory it could instead do something like Inline::Perl5 for the JVM when on moar | ||
psch | oh, yes, that's probably true | 12:22 | |
Ulti | or even just talk to rakudo on the JVM to do it :) | 12:23 | |
psch | i brought the latter possibility up somewhen in the past, iirc | ||
Ulti | like you could probably cross EVAL? | ||
psch | i.e. "if r-m encounters :from<Java> and we have r-j installed should we do something RPC-ish?" | ||
i don't remember what the reply was | 12:24 | ||
in any case, jvminterop is still somewhat lackluster | |||
Ulti | I guess the point is really why would you bother | ||
you can just run on the JVM implementation | |||
psch | well, with lexical use i can imagine use cases that want moar (i.e. "fast") most of the time and only fall back on jvm if absolutely neccessary | 12:25 | |
but that should probably more be motivation to make r-j faster... :s | |||
nine | If you want to split your application between moar and the jvm, you can easily implement it with some IPC mechanism (probably some RESTy thing nowadays) | 12:26 | |
psch | oh, yes, IPC not RPC | 12:27 | |
RPC is one way of doing IPC | 12:28 | ||
psch makes a note | 12:29 | ||
nine | Since we're talking Java here, it should probably be XMLRPC ;) | 12:30 | |
12:30
andreoss left,
andreoss joined
|
|||
[Coke] | **, #Perl6 | 12:33 | |
andreoss | j: say 1 | ||
camelia | rakudo-jvm d6430c: OUTPUT«1» | ||
andreoss | j: use java::lang::String:from<Java>; my String $x .= new; say $x.perl; | 12:34 | |
camelia | rakudo-jvm d6430c: OUTPUT«Method 'dispatch:<.=>' not found for invocant of class 'java.lang.String' in block <unit> at /tmp/89KMTsRmbQ:1» | ||
psch | j: use java::lang::System:from<Java>; System.println("works") | ||
camelia | rakudo-jvm d6430c: OUTPUT«Method 'println' not found for invocant of class 'java.lang.System' in block <unit> at /tmp/BRLJeM6enn:1» | ||
psch | ah shucks | ||
andreoss | j: use java::lang::String:from<Java>; my String $x ; say $x.^methods; | ||
camelia | rakudo-jvm d6430c: OUTPUT«Method 'parents' not found for invocant of class 'Perl6::Metamodel::JavaHOW' in any methods at gen/jvm/Metamodel.nqp:466 in block <unit> at /tmp/XTVBraDBL8:1» | ||
psch | j: use java::lang::System:from<Java>; System.get_out.println("works") | ||
camelia | rakudo-jvm d6430c: OUTPUT«works» | ||
psch | andreoss: it's *really* bare bones at the moment | ||
as in, most of the MOP stuff is missing | |||
andreoss: the working stuff is pretty much only what you can find in t/03-jvm/01-interop.t in the rakudo directory | 12:35 | ||
12:36
Akagi201 left
12:37
Akagi201 joined,
abraxxa left
|
|||
andreoss | are there plans for December release for JVM interop? | 12:37 | |
psch | i'm poking at it when i feel competent, which has been rare the last few weeks, but i wouldn't rely on it | 12:38 | |
especially considering it's not really a Perl 6 thing, but a Rakudo thing | |||
12:38
abraxxa joined
|
|||
andreoss | psch:thanks | 12:39 | |
[Coke] | JVM is not mandatory for December, no. | 12:45 | |
nine | [Coke]: regarding your p5helper.dylib issue. I'm somewhat at a loss, since I cannot test this myself. Does perl6 configure.pl6 give you any clue? | 12:46 | |
[Coke] | nine - I'm installing via panda. any idea how to get that from a panda session? | 12:50 | |
if not, I'll try to build it by hand. | |||
nine | [Coke]: sorry, no idea. | ||
Installing manually might give us valuable hints anyway | 12:51 | ||
[Coke] | nine: configure fails miserably. | ||
Perl v5.18.0 required--this is only v5.16.3, stopped at -e line 1. | |||
I wonder why panda doesn't fail there. | 12:52 | ||
nine | Panda does not run configure.pl6 but only what's in Build.pm | ||
[Coke] | um. | 12:53 | |
nine | I only noticed this morning that Build.pm is missing the Perl 5 version check and added it. | ||
[Coke] | not pushed yet? | ||
I just ran Build.pm and it succeeded. | 12:54 | ||
nine | [Coke]: pushed it as commit a1c1d93b4dfaeeb3150a8f2f622cd7f091d0923d | ||
[Coke]: how did you run Build.pm's build method? | |||
[Coke] | incorrectly? Let me try via panda. | 12:55 | |
yup, much better. thank you. | 12:56 | ||
nine | I really should try to figure out this ppport.h thing. Should make it possible to support older perls. | 12:57 | |
[Coke] | is the perl you have in your path the perl that used at runtime? or is it whatever perl is in your path then? | ||
12:58
aborazmeh joined,
aborazmeh left,
aborazmeh joined,
aborazmeh left
|
|||
nine | At runtime it should use the libperl of the perl found in $PATH during configure/Build time | 12:59 | |
[Coke] | perl6 -e 'use Inline::Perl5; my $p5 = Inline::Perl5.new(); $p5.run("print 3333");' | 13:02 | |
^^ should that print something? | |||
ah, I probably want print $p5.run("3333"); | 13:03 | ||
but where does the output from .run go? | |||
nine | A definite maybe. | ||
[ptc] | domidumont: ping | 13:04 | |
nine | It should, but output buffering may be a problem. Try $p5.run(q{print "3333\n"}); | ||
[Coke] | nine: works | ||
hoelzro | good morning, #perl6 | 13:09 | |
[ptc] | hoelzro: o/ | ||
hoelzro | o/ [ptc] | ||
13:19
_mg_ joined
|
|||
PerlJam | good morning | 13:21 | |
hoelzro | morning PerlJam | 13:22 | |
PerlJam | hoelzro: What's new in your world? | 13:24 | |
13:24
yqt joined
|
|||
hoelzro | PerlJam: giving a Perl 6 talk in Milwaukee on Thursday, and banging my head against a wall on RT #125407 | 13:24 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...?id=125407 | ||
hoelzro | yourself? | ||
PerlJam | still recovering from helping my wife with an annual gymnastics competition. (my first time not being in the audience) | 13:25 | |
psch | hoelzro: i looked at AST dumps from those examples, and it's just weird :s | ||
13:26
isBEKaml joined,
lizmat joined
|
|||
hoelzro | PerlJam: does your wife compete, or was she there to help things along? | 13:26 | |
psch: yes, indeed | |||
my research has lead me into the far-off land of EXPR | 13:27 | ||
13:27
elimik31 joined
|
|||
PerlJam | hoelzro: She's the director of the local organization (Sokol). Every year they do it at a different location in Texas. This year it was here. | 13:27 | |
hoelzro | ah, ok | 13:28 | |
13:28
Ven joined
|
|||
PerlJam | RT #125407 is a weird one | 13:29 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...?id=125407 | ||
13:30
lizmat left
13:31
skids joined
13:33
FROGGS left
|
|||
psch | the obvious assumption is that some prec state gets carried over into the next statement in the wrong case | 13:33 | |
but i think that'd be in EXPR, and... :S | |||
domidumont | [ptc]: yes ? | 13:40 | |
hoelzro | psch: that's where I'm looking right now | 13:41 | |
and digging into it, and the notion that there may be a bug lurking in there, disturbs me | 13:42 | ||
psch | hoelzro: yeah, i saw that, belatedly. i have no idea how to make sense of EXPR, i'll readily admit... | ||
13:43
abraxxa left
13:44
abraxxa joined
|
|||
isBEKaml | p: my @a = <1 2 3>; all(@a) > 5; none(@a) > 5; | 13:48 | |
m: my @a = <1 2 3>; all(@a) > 5; none(@a) > 5; | |||
camelia | rakudo-moar d6430c: OUTPUT«WARNINGS:Useless use of ">" in expression "all(@a) > 5" in sink context (line 1)» | ||
13:48
elimik31 left
|
|||
isBEKaml | m: my @a = <1 2 3>; say all(@a) > 5; say none(@a) > 5; | 13:49 | |
camelia | rakudo-moar d6430c: OUTPUT«all(False, False, False)none(False, False, False)» | ||
13:50
laouji left
|
|||
[ptc] | domidumont: I just wanted to ask a question regarding rpath overrides and lintian, however I think I worked it out | 13:52 | |
domidumont: I just updated moarvm so that it builds for version 2015.05 | |||
domidumont | [ptc]: ok, cool | ||
[ptc] | domidumont: nqp 2015.05 should be on its way sometime soon as well | 13:53 | |
domidumont | [ptc]: are you working in sync with Daniel ? (I'd rather avoid duplicated work) | ||
[ptc] | domidumont: not as far as I know... I'd like to avoid duplicated work as well | 13:54 | |
domidumont: my plan was to send an email to the list letting everyone know about the updates | |||
domidumont: is he in this irc channel? | 13:55 | ||
domidumont | [ptc]: yes as nebuchadnezzar | ||
[ptc] | domidumont: ok, thanks | ||
13:56
brrt left
|
|||
domidumont goes back to angularjs :-/ | 13:56 | ||
[ptc] | domidumont: he'd already updated the source to the upstream 2015.05 version, I just patched the things which needed patching in order to get debuild to work | 13:57 | |
13:58
abraxxa left
13:59
abraxxa joined
|
|||
domidumont | [ptc]: no problem. | 14:00 | |
[ptc] | .tell nebuchadnezzar I've patched the files in the moarvm package so that debuild builds correctly, and pushed the changes to alioth. Just wanted to let you know :-) | 14:03 | |
yoleaux | [ptc]: I'll pass your message to nebuchadnezzar. | ||
colomon | [ptc]++ | 14:05 | |
14:05
itz joined
14:11
bbkr left,
Ven left,
smls joined,
tinyblak left
14:13
abraxxa left
|
|||
smls | jnthn or timotimo: Does github.com/perl6/gtk-simple/pull/11 look alright? | 14:13 | |
14:13
abraxxa joined
|
|||
dalek | k-simple: e55d10c | smls++ | lib/GTK/Simple.pm6: Provide a 'spacing' property for GTK::Simple::Box This is analogous to the 'border_width' property of GTK::Simple::Container. |
14:14 | |
k-simple: 09a6cac | smls++ | lib/GTK/Simple.pm6: Allow setting the 'text' property in GTK::Simple::Entry.new GTK::Simple::Label.new(text => 'foo') works, so GTK::Simple::Entry.new(text => 'foo') should too. |
|||
k-simple: f9fbfb9 | timo++ | lib/GTK/Simple.pm6: Merge pull request #11 from smls/master two small additions |
|||
tadzik | timotimo++ standing guard | ||
smls | thanks :) | ||
tadzik | smls++ | ||
smls | Oh, and in case someone is looking for an array munging benchmark with *lots* of room for Rakudo improval: rosettacode.org/wiki/Perfect_shuffle#Perl_6 | 14:15 | |
^^ takes 1.1 seconds in Perl 5, but over 14 minutes in Rakudo | 14:16 | ||
s/improval/improvement/ # my brain is weird :P | 14:20 | ||
timotimo | yw | 14:22 | |
smls: run a profile please? :) | 14:23 | ||
smls | how? never done it before :) | ||
14:23
abraxxa left
|
|||
timotimo | perl6 --profile foobar.p6 | 14:23 | |
smls | ok | ||
14:23
abraxxa joined
|
|||
dalek | osystem: 53cea7c | RabidGravy++ | META.list: Add Audio::Sndfile |
14:24 | |
RabidGravy | there | ||
that took longer than I expected | |||
tadzik | oh :) | ||
RabidGravy | not particularly useful just at the moment unless you're into generating your own sounds or writing a convertor | 14:26 | |
14:31
isBEKaml left
|
|||
smls | RabidGravy: nice | 14:32 | |
14:33
isBEKaml joined,
isBEKaml left,
isBEKaml joined
|
|||
timotimo | i'd be very interested to see what exactly makes that perfect shuffle thing slow | 14:34 | |
14:34
telex left
|
|||
timotimo | i think i'd say it's Z | 14:34 | |
14:34
telex joined
|
|||
PerlJam | I was guessing it's all the copying of those array elements. | 14:34 | |
timotimo | hmm | 14:35 | |
smls | The [<] @deck probably doen't short-circuit, but replacing it with @deck eqv @original doesn't make much of a difference in performance so I kept it. | 14:36 | |
timotimo | huh, it could learn to short-circuit if it can't already | ||
< is a simple chain op | |||
and those are always and-ed together, so METAOP_REDUCE could very well learn about it | 14:37 | ||
bbiab | |||
smls | but the [] reduce-metaop does not preserve short-circuiting behavior | ||
14:37
rindolf left
|
|||
smls | according tio the specs | 14:37 | |
14:37
_mg_ left
14:39
yqt left
|
|||
moritz | I guess it can't presevere the short-circuiting of thunking ops like && and || | 14:40 | |
and that's what the specs mean | |||
but [<] is free abort on first False | 14:41 | ||
14:41
lolisa joined
|
|||
smls | ah, makes sense | 14:41 | |
timotimo: gist.githubusercontent.com/smls/76...rofile.htm | 14:42 | ||
moritz is building funny pipeline DAGs with gocd | |||
14:53
rindolf joined
|
|||
timotimo | smls: 404 :( | 14:56 | |
oh, wait | |||
moritz | moritz.faui2k3.org/tmp/perfect_shuf...ofile.html # rendered as actual HTML | 14:58 | |
timotimo | smls: using "div" instead of / for the mid point can remove the tiny bit of time spent working with rational numbers | 14:59 | |
moritz | but the big time sink is list iteration, again :( | ||
timotimo | oh how surprising ... the top allocated thing is Scalar, the top allocators are gimme, reify, REIFY and an <anon> that's just reify again | 15:00 | |
15:00
FROGGS joined
|
|||
timotimo | and for some reason we are hitting the slow path binder :\ | 15:00 | |
15:02
yqt joined
15:03
rurban joined
|
|||
timotimo | i'd love to see a version that just allocates an appropriately sized list and throws the values into it from the source array, just to see how many orders of magnitude that's faster | 15:04 | |
15:05
isBEKaml left,
isBEKaml joined
|
|||
timotimo | holy wat | 15:09 | |
oh, lazyness strikes again | |||
we spend 30.6% of time inside perfect-shuffle and 68% in STORE (just looking at the frame for the loop that calls perfect-shuffle) | 15:10 | ||
but that's just because perfect-shuffle gets to defer a bunch of work to reifying the list | 15:11 | ||
psch | $ ./perl6-j -e'our Int sub f { fail "a" }; say f() ~~ Failure' | ||
True | |||
...that took longer than expected :s | |||
now how do i do that on moar..? | |||
15:11
isBEKaml left
|
|||
moritz | wait, what? | 15:11 | |
psch | moritz: irclog.perlgeek.de/perl6/2015-06-16#i_10756235 | 15:12 | |
15:13
domidumont left,
rindolf left
|
|||
moritz not convinced that is workable | 15:14 | ||
if we optimize based on the type, we can't allow exceptions | |||
timotimo | we are good at deopting | ||
at least for dynamic optimizations | |||
15:15
sjn_phone joined
|
|||
psch | well, i've patched it as written in the clog, as the last check in p6typecheckrv | 15:16 | |
e.g. after the "is it maybe unboxable" | 15:17 | ||
smls | timotimo: What do you mean by "just allocates an appropriately sized list and throws the values into it from the source array"? | ||
psch | so dynopts should've already happened before we end up there anyway, or not? | ||
timotimo | do the Z yourself | ||
psch: i'm not sure we do any optimizations based on the defined return value of a sub at the moment | 15:18 | ||
smls | ah, like the Perl 5 version? | ||
timotimo | oh | ||
i didn't know the perl 5 version did it like that | |||
smls | "map { @_[$_, $_ + $mid] } 0..($mid - 1);" | ||
nebuchadnezzar | [ptc]: thanks, FROGGS made some patches too, maybe the same? | 15:19 | |
yoleaux | 14:03Z <[ptc]> nebuchadnezzar: I've patched the files in the moarvm package so that debuild builds correctly, and pushed the changes to alioth. Just wanted to let you know :-) | ||
psch | timotimo: we have "optimize_p6typecheckrv" in Optimizer.nqp, but that seems to not do particularly much | ||
timotimo | also, i wonder what happens if you @deck := perfect-shuffle @deck | ||
psch | lines 1183ff | ||
15:19
diana_olhovik_ left
|
|||
timotimo | psch: i'd guess that just possibly throws out the type check if the thing we're returning is already proven to be of the right type | 15:19 | |
[ptc] | nebuchadnezzar: I only made patches to the debian package. | 15:20 | |
nebuchadnezzar: I'm guessing FROGGS made patches to MoarVM itself? | |||
psch | timotimo: yeah, that interpretation makes sense... | ||
TimToady | I did a few stats on the dynvar caching last night, and discovered what I expected, that we're kinda overwhelming the 1-per-frame cache, according to gist.github.com/TimToady/fe858b303f9d033365d9 | 15:22 | |
when I last worked on that cache, I got it tuned to about 5 frames average, but most of the symbols average quite a bit more than that now | 15:23 | ||
and we're traversing 11 million frames to look up $*ACTIONS | |||
so we really need that better cache we discussed a few weeks ago | 15:24 | ||
smls | timotimo: Interestingly, .map({ @deck[$_, $_ + $mid] }) seems to be significantly slower than map({ @deck[$_], @deck[$_ + $mid] }) | 15:25 | |
TimToady | $*MAST_FRAME is averaging 34 frames per lookup | ||
nebuchadnezzar | [ptc]: yes, and provide gists to add debian patches if I understand correctly | 15:26 | |
timotimo | smls: doesn't surprise me terribly much, to be honest :( | ||
smls | timotimo: := instead of = seems to help a little, too. | ||
timotimo | smls: i wonder how well we're doing with regards to lazyness when we use := there | ||
hm. well, we'll pretty much always grab the very first element and the first one after the middle | 15:27 | ||
because we start comparing the first and second element every time | |||
so lazyness doesn't help us terribly much there | |||
anyway, gotta be afk for a bit | |||
TimToady | oh, those dynvar stats were from compiling the setting | 15:32 | |
FROGGS | [ptc]: I patched MoarVM for GNU/kFreeBSD and provided a patch for libuv | ||
dalek | line-Perl5: 0064616 | (Stefan Seifert)++ | README.md: Add some hints on where to obtain a libperl.so on Debian and Fedora Some Linux distributions seem to split perl into multiple packages. Thanks to Benjamin Tietze for the suggestion. |
15:33 | |
RabidGravy | psch, I sent a quick PR for Audio::PortAudio - but it seems it also tickles something related to #125408 | 15:34 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...?id=125408 | ||
15:36
rurban left,
Ven joined
15:37
rurban joined
15:40
[Sno] left
15:44
zakharyas left
15:45
FROGGS[mobile] joined,
abraxxa left,
abraxxa joined
15:46
JimmyZ_ joined
15:47
captain-adequate joined
|
|||
japhb | .tell [ptc] Oh, I wasn't complaining about the general set of is-approx patches (dealing with very large or small numbers well is important to the use case), I was specifically saying that that particular commit seemed to have a couple bugs in it. | 15:47 | |
yoleaux | japhb: I'll pass your message to [ptc]. | ||
japhb | .tell smls La la la la, please make that a github.com/japhb/perl6-bench minibenchmark ... # re: irclog.perlgeek.de/perl6/2015-06-16#i_10757135 | 15:50 | |
yoleaux | japhb: I'll pass your message to smls. | ||
15:50
FROGGS left
|
|||
japhb | .oO( Might as well sing it, it feels like the chorus of my #perl6 song at this point ) |
15:51 | |
psch | RabidGravy: line 68 in which file tickles the bug? | ||
RabidGravy | in the test.pl | ||
psch | ah | ||
hm, native nums :/ | 15:52 | ||
smls | japhb: I'll look into that :P | ||
RabidGravy | it's something to do with assigning to an item in a NumTypedCArray under some circumstance | ||
psch | the underrun is most likely performance in generating data or iteration or something | ||
i.e. should get better eventually | |||
i think i prefill the data, so it should be just iteration | |||
15:53
Gardner joined
|
|||
psch | consider with 44100hz we have that many values per second to deliver to the audio device | 15:53 | |
RabidGravy | oh for sure | 15:54 | |
psch | but idk, i do know that i had plenty of underruns too, pretty much constantly | ||
the thing with jvminterop that i started used an osc written in java... | 15:55 | ||
and even that dropped frames occassionally | |||
15:56
telex left
15:57
Gardner left,
spider-mario joined
16:00
diana_olhovik_ joined,
Ven left
16:01
telex joined
|
|||
psch | RabidGravy: i've added you as a collaborator | 16:03 | |
to that repo | |||
'cause that's probably the way forward if it's supposed to go into the ecosystem, as i'm kinda at capacity with the jvm things i want to do | |||
with the underrun issue i'm reminded that i wanted to try offline rendering, though | 16:04 | ||
hm, the Failure patch from above gives me a TODO passed in S02-types/native.t..? o.O | 16:06 | ||
and 10 failures across a few files, 3 of those in S17 | 16:07 | ||
RabidGravy | sounds like a plan, I might test it out with some input from a file | ||
16:08
sjn_phone left
|
|||
psch | heh | 16:09 | |
a failure in S02-types/deprecations.t | |||
expected version, name | |||
got name, version" | |||
...paraphrased | |||
m: my num32 $x; say $x | 16:11 | ||
camelia | rakudo-moar d6430c: OUTPUT«0» | ||
psch | m: my num64 $x; say $x | ||
camelia | rakudo-moar d6430c: OUTPUT«NaN» | ||
psch | j: my num32 $x; say $x | ||
camelia | ( no output ) | ||
psch | j: my num64 $x; say $x | 16:12 | |
camelia | rakudo-jvm d6430c: OUTPUT«NaN» | ||
psch | num32 works with my patch for RT #64990... | ||
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...l?id=64990 | ||
psch | but further FAILs look like they need more attention than i have right now | 16:13 | |
bbl o/ | |||
16:16
sjn_phone joined,
uncleyea1 joined
16:19
uncleyear left,
diana_olhovik_ left
16:28
molaf joined,
StavroMueller joined
16:31
JimmyZ_ left
16:32
gfldex joined,
itz left
16:35
abraxxa left
|
|||
RabidGravy | if one has a Signature object in hand, what can you do with it? | 16:38 | |
16:38
[Sno] joined
16:40
smls left
|
|||
[ptc] | japhb: do you think the implementation as it currently stands is sound? | 16:42 | |
yoleaux | 15:47Z <japhb> [ptc]: Oh, I wasn't complaining about the general set of is-approx patches (dealing with very large or small numbers well is important to the use case), I was specifically saying that that particular commit seemed to have a couple bugs in it. | ||
16:45
diana_olhovik_ joined
|
|||
skids | m: Signature.^methods.say; say Signature.^attributes.map: *.name # RabidGravy | 16:50 | |
camelia | rakudo-moar d6430c: OUTPUT«<anon> <anon> <anon> <anon> arity count params returns ACCEPTS perl gist$!params $!returns $!arity $!count $!code» | ||
[ptc] | nebuchadnezzar: sorry if I trampled on anyone's work. I basically assumed that since there were no new commits to the Alioth repos that I could go ahead and update the MoarVM and nqp projects | 16:51 | |
skids | psch: Some of the num32 behavior is irclog.perlgeek.de/perl6/2015-06-13#i_10746333 and RT#124084 | 16:58 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...?id=124084 | ||
17:02
rurban left
17:06
sjn_phone left
17:10
[particle]1 joined,
uncleyea1 is now known as uncleyear,
uncleyear left,
uncleyear joined
17:11
[particle] left
|
|||
masak | getting RT tickets from Zefram is like being knocked unconscious by a bottle of really fine champagne. | 17:12 | |
(hi #perl6) | |||
17:13
_mg_ joined
|
|||
psch | skids: the clog bit doesn't seem particularly related, but the ticket is exactly what seems fixed by my change | 17:14 | |
skids: i just have no clue *why* my change would fix it... :) | |||
skids | Which change? | ||
psch | a fix for RT #64990 | 17:15 | |
synbot6 | Link: rt.perl.org/rt3/Public/Bug/Display...l?id=64990 | ||
psch | i.e. let Failure always match return type constraints of subs | ||
so it doesn't blow up with TypeCheck::Return | |||
skids | Right, but is the patch anywhere viewable yet? | ||
japhb | .tell [ptc] Your calculation for the implementation which takes a $tol parameter (the second one) will always fail if $expected == 0 and $tol < 1, because then $abs-diff == $abs-max == $got and $rel-diff == 1. | 17:16 | |
yoleaux | japhb: I'll pass your message to [ptc]. | ||
psch | the change does seem to break something with passing the Junction type into subs, which i'll look at next... | ||
17:16
[particle] joined
|
|||
skids | And does it fix my num32 = 3e0 for example? | 17:16 | |
17:17
[particle]1 left
|
|||
psch | $ ./perl6 -e'my num32 $x; my num32 $y = 3e0; say $x ~ " " ~ $y' | 17:17 | |
NaN 3 | |||
that's -j, btw | |||
dunno if the bug exists on moar | |||
jnthn | Sized integer types in lexicals are barely implemented in Moar | 17:18 | |
skids | m: my num32 $x = 3e0; $x.say | ||
camelia | rakudo-moar d6430c: OUTPUT«0» | ||
jnthn | In fact, we generated invalid code for them that the verifier should probably be rejected. | ||
*rejecting | |||
psch | j: my num32 $x = 3e0; $x.say | ||
camelia | rakudo-jvm d6430c: OUTPUT«3» | ||
psch | the NaN bit is broken on camelia iirc | ||
j: my num32 $x; say $x | |||
camelia | rakudo-jvm d6430c: OUTPUT«NaN» | ||
psch | eh | ||
nevermind then :P | |||
must've been seeing things :) | 17:19 | ||
japhb | .tell [ptc] The implementation which takes a :$rel_tol and :$abs_tol (the third one) allows *either* tolerance to succeed, and there doesn't seem to be a way to require both; that may or may not matter. Also, using Numeric for the tolerances leaves me wondering about the exact behavior if the tolerances are Complex instead of Real. | ||
yoleaux | japhb: I'll pass your message to [ptc]. | ||
psch | jnthn: Moar verifier? | ||
jnthn | psch: MoarVM's bytecode verifier | ||
I suspect it's too lax somewhere | 17:20 | ||
psch | ah, okay | ||
japhb | psch: Moar has a bytecode verifier that makes sure the bytecode is sane enough to even try executing. | ||
jnthn | "num32...num64...what's that between friends" :) | ||
It does the same with the sized int types, but you get away with it on LE :P | |||
psch | well, that explains the TODO passed i get in S02-types/native.t — it's not fudged for only moar even though it should be, 'cause jvm seems to do it right | 17:21 | |
skids | Yes that was added very recently. | 17:22 | |
psch | aside from that i get 3 FAILs that could be said to be wrong tests, because they expect TypeCheck::Return instead of DivideByZero | ||
on FAIL that's expecting order where there isn't any to be expected | |||
and flappers and java-version-dependent TODO passed | 17:23 | ||
and one test that definitely isn't working right anymore so i'd have to look at that | |||
cognominal | flappers? | ||
psch | S17 FAIL that go away when the file is ran standalone | ||
unicode being dependent on jvm version is kind of iffy i feel sometimes | 17:24 | ||
jnthn | I really dislike the whole "Failure sneaks through" thing | 17:25 | |
psch | jnthn: it was a ticket, i just tried to make it work as expected from the ticket... :s | ||
jnthn | I suspect the optimizer will need a look over. | ||
psch: I wasn't saying "Failure sneaks through" isn't the Perl 6 design, just that I think it's bad design. :) | 17:26 | ||
I feel the same about Nil, though. | |||
17:27
rindolf joined
|
|||
jnthn | (which needs special handling on assignment) | 17:27 | |
skids | The alternative is the user has to catch thrown exceptions and turn them soft, if that's the desired behavior. | ||
jnthn | If we are going to not be able to rely on return types, though, then we may want to consider dropping our compile-time signature analysis just to consider natively typed things. | 17:28 | |
skids | I see the design as sort of "NaN for OO" | ||
17:29
lolisa left
|
|||
psch | i'll admit i don't see all the implications | 17:29 | |
for me it's mostly confusing to see TypeCheck::Return when fail()ing from a sub | 17:30 | ||
17:30
prammer joined,
lolisa joined
|
|||
jnthn | sub foo(Int $x) { ... }; sub bar() returns Int { ... }; foo(bar()) # can't compile-time dispatch foo | 17:30 | |
But I think we may well have code that tries to do so today in the optimizer; if so, that may be the source of some failures. | 17:32 | ||
17:32
espadrine left
|
|||
psch | the FAIL i have that looks most related is in S03-junctions/misc.t | 17:32 | |
'sub foo($) { }; foo(Junction)' | 17:33 | ||
throws AdHoc instead of TypeCheck::Binding | |||
with null for varName in the Binder | |||
line 364 in Binder.java | |||
skids | An argument could be made for "compile-time-dispatch anyway and let the Failure blow up inside foo() at runtime" | 17:34 | |
jnthn | skids: It may actually *not* blow up | 17:35 | |
skids | (For implicitly |Failures on the constraint, but not for returns Failure) | ||
jnthn | Because when we compile-time inline we lose the constraints. :) | ||
That's part of the point of doing it. | 17:36 | ||
17:37
domidumont joined
|
|||
skids | When inlined the part of bar that returns the failure would count as a use of the failure (for the multidipatch) and should then explode, no? | 17:37 | |
jnthn | skids: We'd not inline something that calls fail(...) anyway at the moment; it's the inlining of foo that is at issue | 17:38 | |
(we toss any signature checks when inlining because we "proved" they aren't needed) | 17:39 | ||
The issue is that we simply can't rely on the "returns" to provide useful type information for the optimizer for the non-native case when a Failure may also be returned. | 17:40 | ||
skids | So you'd have inlined foo with a call to bar which could return a Failure where you think you have an Int. | ||
jnthn | Right | ||
17:42
sjn_phone joined
|
|||
skids | My immediate reaction is that bar() should have beenrewritten into sepearate entry points one of which returns failures, the other of which where any return fail raises exceptions. | 17:42 | |
jnthn | That's too much work to be bothered with in the static optimizer. | 17:43 | |
It has no stats on if it's work is even worthwhile. | |||
skids | sorta like us humans? :-) | 17:44 | |
jnthn | Indeed :P | ||
Anyway, we mostly want to stick to simple trnasforms there | |||
(Like unpicking simple Junctions) | |||
Along with inlining natives | |||
And tbh, now we know how spesh and indy look, I think maybe we can just leave compile-time inlining explicitly for natives. | 17:45 | ||
So maybe I should stop worrying, simplify Perl6::Optimizer, and be happy. :) | 17:46 | ||
(At the time I wrote the analyses in question, we were targeting Parrot, which has nothing like spesh/indy.) | 17:48 | ||
17:48
cognominal left,
sjn_phone left
17:49
araujo left
17:51
araujo joined,
araujo left,
araujo joined
|
|||
jnthn | psch: src/Perl6/Optimizer.nqp:1865 and :1952 are the lines that'd need guarding for native types only, fwiw | 17:52 | |
psch | jnthn: alright, i'll take a note of that | ||
first gotta figure out that test failure and port my changes to moar too | 17:53 | ||
jnthn | psch: To port to Moar you probably want to look in src/moar/Perl6/Ops.nqp or src/moar/ops/perl6_ops.c | ||
psch | yeah, i think the former | 17:54 | |
i think i saw p6typecheckrv there | |||
jnthn | *nod* | ||
dinner & | 17:58 | ||
dalek | rl6-roast-data: b96151f | coke++ | / (9 files): today (automated commit) |
18:08 | |
18:11
sjn_phone joined
|
|||
ab5tract | hmm.. searching doc.perl6.org for '>>' returns only a link to regex | 18:12 | |
are we missing docs for hyper ops? | |||
I also couldn't find docs on [&infix] | |||
colomon | ab5tract: did you try looking for » ? | ||
ab5tract | colomon: that one returns docs for Quote as well ;) | 18:13 | |
(I also couldn't remember/unpack what the [&infix] form of [] would be called. 'circumfix:<[ ]>' makes the most sense. is it implemented as a multi, with one for &infix behavior and one for creating Arrays? | 18:14 | ||
psch | [&infix] is META_REDUCE in Grammar.nqp iirc | 18:16 | |
i.e. [+] @ints | |||
ab5tract | psch: right, that's the one. | 18:17 | |
psch | so the "Reduction Meta-Operator" i suppose | ||
eh, maybe not | |||
Z and X are listed as reduction operators in the design | |||
ab5tract | psch: thanks for digging : | 18:18 | |
psch | hm, no, i misinterpreted skimming of the google summary of S03 :P | ||
ab5tract | :) | 18:19 | |
heh | |||
psch | S03:Reduction_operators | ||
synbot6 | Link: design.perl6.org/S03.html#Reduction_operators | ||
ab5tract is writing a proposal YAPC::EU | |||
*for YAPC::EU | 18:20 | ||
tentative title: 'Whatever, or How I Stopped Fearing and Fell in Love with this Op' | 18:26 | ||
[Coke] | I'm pretty happy that we have a p5er dealing with the stuff on the language list. :) | 18:29 | |
colomon | [Coke]: you mean the uninformed trolling on the language list? ;) | 18:30 | |
[Coke] | aristotle++ | ||
Everyone who wants to respond to those, take a deep breath. :) | |||
ab5tract | [Coke]: is there a list archive available? | ||
colomon | aristotle++ indeed | 18:31 | |
ab5tract: trust me, it is not worth reading. | |||
ab5tract | well, the language list might be | ||
colomon | ab5tract: actually, the language list in general has very rarely been worth reading in the last 7 years. | 18:32 | |
ab5tract | ok | ||
18:35
bbkr joined
18:36
smls joined
|
|||
smls | timotimo: gist.github.com/smls/a1f6033c142202bddc4d <-- full report on the 'Perfect Shuffle' thing :P | 18:36 | |
turns out the line zipping the half-lists is indeed responsible for most of the run time | 18:38 | ||
colomon | ab5tract: the archive is www.nntp.perl.org/group/perl.perl6.language/ but seriously, the list basically functions as a honeypot for people who have Very Important Ideas about language design, but can’t be bothered to figure out real discussion occurs on #perl6 | 18:40 | |
18:41
_mg_ left
|
|||
ab5tract | colomon: gotcha | 18:43 | |
18:46
silug left
|
|||
skids | smls: I had noticed that "for @a Z @b" was a major slowdown in Sum as well. | 18:49 | |
18:50
molaf_ joined
|
|||
dagurval | any way to represent an array in struct with NativeCall? For example struct a { int b[256]; int i; } | 18:51 | |
18:51
uncleyear left
18:52
uncleyear joined
18:53
molaf left
|
|||
ugexe | maybe something like this untested class Foo is repr('CStruct') { has CArray[OpaquePointer] $.b; has int $.i; } | 18:59 | |
RabidGravy | CArray[int32] even | ||
if its expect to be a particular size then you need to assign a new one to it | 19:02 | ||
then $foo.b[255] = 0; | |||
timotimo | smls: it's missing one variant i'm missing | 19:04 | |
smls | ? | ||
19:04
Gardner joined
|
|||
timotimo | something like my @result = 0 xx +@deck; loop (...) { @result[$foo] = @deck[$bar]; @result[$foo + 1] = @deck[$baz] } | 19:04 | |
smls | ah, ok | 19:05 | |
hoelzro | ab5tract: I, for one, would like to see the language list be a more interesting and better place | ||
then again, I myself barely post there =/ | |||
RabidGravy | I think I subscribed to it for afew months in 2001-2 | 19:06 | |
19:06
andreoss left
|
|||
timotimo | smls: and also using div instead of / for division | 19:06 | |
hoelzro | should --ll-exception be enabled for building lib/*.pm in rakudo? | ||
smls | ok | ||
hoelzro | that way, if it fails, it's one fewer step to finding out why | 19:07 | |
timotimo | hoelzro: may be a good idea | ||
smls | timotimo: funny though that binding instead of asisgning to @deck actually made it slower on a full run, right? | ||
when i tried it out on small inputs, it seemed to help | |||
dagurval | RabidGravy: thanks, I'll try that. It's the particular size issue I'm having problem figuring out | 19:08 | |
skids | Not sure CArray members are supported yet. | 19:13 | |
dagurval | if so, any other way to tell 'CStruct' that "here are 256 ints" (a[256]) - so I can access the data below? | 19:16 | |
pmichaud | j/lastlog pmichaud 5 | 19:18 | |
good afternoon, #perl6 | |||
colomon | o/ | 19:19 | |
19:19
uncleyear left,
uncleyear joined
19:20
bin_005 joined
|
|||
RabidGravy | yeah, that may not work actually | 19:22 | |
m: use NativeCall; class Foo is repr("CStruct") { has CArray[int32] $.b is rw }; my $b = Foo.new; $b.b = CArray[int32].new; | |||
camelia | rakudo-moar d6430c: OUTPUT«Cannot modify an immutable IntTypedCArray[int32] in block <unit> at /tmp/ZKlPu4ia2V:1» | ||
skids | dagurval: maybe point an OpaquePointer and use nativecast? | 19:24 | |
You'll have to do your own memory mgmt on the data separate from the CStruct. | |||
[Coke] | I would love to see attributes have an "is required" that throws a typed exception. (instead of handrolling your own required die closure) | 19:27 | |
... heh. ovid has it on a slide. Yes, that thing. | 19:30 | ||
19:34
sjn_phone_ joined,
sjn_phone left
|
|||
dagurval | skids: I don't see how, but I'll look into it. | 19:35 | |
19:38
Gardner left
|
|||
timotimo | dagurval: we want to have that at some point, but we don't have it yet :( | 19:41 | |
dagurval | timotimo: ok - I'll work with what we have :-). | 19:43 | |
19:43
domidumont left
|
|||
timotimo | sorry about that :( | 19:44 | |
19:44
smls left,
smls_ joined
|
|||
smls_ | timotimo: gist updated. | 19:48 | |
timotimo | yeah, i expected it to be a whole lot faster | 19:50 | |
19:50
rindolf left
|
|||
timotimo | it's quite surprising to me that the difference between intmath and rats is so big | 19:51 | |
but i suppose we keep the rat around and then turn it into an int over and over and over again | 19:52 | ||
smls_ | well, it does do one addition on that value per iteration of the innermost loop | ||
19:54
_mg_ joined
19:56
brrt joined
|
|||
timotimo | right | 19:59 | |
addition on a rat has a multiplication inside it | |||
masak | that's because rats as a concept have a multiplication in them :) | 20:02 | |
brrt | btw, are FatRats already implemented | 20:04 | |
colomon | yes | 20:05 | |
masak | m: FatRat; say "yes" | ||
camelia | rakudo-moar d6430c: OUTPUT«yes» | ||
20:06
_mg_ left
|
|||
colomon | m: say 1/3.FatRat ** 1000000 | 20:06 | |
camelia | rakudo-moar d6430c: OUTPUT«(timeout)» | ||
colomon | m: say (1/3.FatRat ** 1000000).perl | ||
camelia | rakudo-moar d6430c: OUTPUT«(timeout)» | 20:07 | |
colomon | oh | ||
RabidGravy | not ideal | ||
brrt | why... does that break | 20:08 | |
oh | |||
there's a ** | |||
no wonder | |||
colomon | may have gotten carried away wit hthe size of the ** | ||
brrt | m: say (1/3.FatRat ** 10); | ||
camelia | rakudo-moar d6430c: OUTPUT«0.000017» | ||
colomon | m: say 1 / (3 ** 500).FatRat | 20:09 | |
camelia | rakudo-moar d6430c: OUTPUT«0.000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000028» | ||
colomon | m: say (1 / (3 ** 500).FatRat).perl | ||
camelia | rakudo-moar d6430c: OUTPUT«FatRat.new(1, 36360291795869936842385267079543319118023385026001623040346035832580600191583895484198508262979388783308179702534403855752855931517013066142992430916562025780021771247847643450125342836565813209972590371590152578728008385990139795377610001)» | ||
20:12
FROGGS joined
20:13
brrt left
20:14
brrt joined
|
|||
smls_ | timotimo: updated again. Turning the per-iteration addition from int+Int to int+int helped quite a bit more, and binding is suddenly beneficial again :) | 20:16 | |
RabidGravy | I'm looking at a native API that has twenty+ pairs of get_/set_ functions is it sane to fake up 20 "attributes" with Proxy? like "method foo() is rw returns Str { Proxy.new( FETCH => sub ($) { get_foo(self) }, STORE => sub ($, $foo ) { set_foo(self, $foo) }} ..." ? | 20:18 | |
smls_ | Do you think Rakudo will ever become smart enough to run the naive implementation (810 sec) as fast as the optimized one (19 sec)? | ||
RabidGravy: Why not? | 20:19 | ||
GTK::Simple does it | 20:20 | ||
psch | i'm planning to do something similar for jvminterop, fwiw | ||
20:20
brrt left
|
|||
psch | although the problem of the get_/set_ methods come from the jvm in that case | 20:20 | |
or maybe from how we generate the interop classes | |||
so that's another "why not?" | 20:21 | ||
20:22
dolmen joined
|
|||
RabidGravy | works nicely, just feels like I should be able to factor it more tidily | 20:22 | |
PerlJam | RabidGravy: or just have perl generate the 20 attrs directly | ||
smls_ | PerlJam: but how would you hook them up to the native library's getters/setters? | ||
vendethiel | mmh, what's the report channel on freenode? | 20:23 | |
RabidGravy | I may get bored typing it and work out a way of generating them magically | ||
smls_ | :P | ||
psch | yeah, i'm hoping to get that into the JavaHOW for jvminterop | 20:24 | |
like, RakudoJavaInterop.java generates those get_/set_ methods | |||
and the JavaHOW builds attributes for every one of those | |||
but i have no solid idea how that'll work and it's a bit further down on my list too... :) | 20:25 | ||
the most noteable problem there seems to be that i have to pull the JavaHOW into Perl 6 land, instead of having it in NQP land | |||
but there it should be easy enough, i think | 20:26 | ||
and NativeCall is already Perl 6 land so you should be fine :P | |||
i have a feeling that a trait_mod could do it somewhat cleanly, but it's a bit knee-jerky, that feeling | 20:27 | ||
20:29
darutoko left
|
|||
RabidGravy | yeah, apply a role to the Method the makes a CALL-ME with the boilerplate, passing the subs as the trait args | 20:30 | |
20:30
Gardner joined
|
|||
skids | .oO("is required" ... "has $.foo!" maybe?) |
20:31 | |
20:35
Akagi201_ joined
20:38
kurahaupo1 joined,
Akagi201 left
20:40
[Sno] left
20:43
kurahaupo1 left
20:50
uncleyear left
20:51
uncleyear joined
20:53
nys joined
20:55
kurahaupo1 joined
|
|||
smls_ | m: y @x := [\*] 1..*; say @x[^10] | 20:59 | |
camelia | rakudo-moar d6430c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/E56AlQLdXYUnsupported use of y///; in Perl 6 please use tr///at /tmp/E56AlQLdXY:1------> 3y7⏏5 @x := [\*] 1..*; say @x[^10]» | ||
smls_ | m: @x := [\*] 1..*; say @x[^10] | 21:00 | |
camelia | rakudo-moar d6430c: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Ghl4_aGxp3Variable '@x' is not declaredat /tmp/Ghl4_aGxp3:1------> 3<BOL>7⏏5@x := [\*] 1..*; say @x[^10]» | ||
smls_ | m: my @x := [\*] 1..*; say @x[^10] | ||
camelia | rakudo-moar d6430c: OUTPUT«1 2 6 24 120 720 5040 40320 362880 3628800» | ||
smls_ | m: my @x := 1, [\*] 1..*; say @x[^10] | ||
camelia | rakudo-moar d6430c: OUTPUT«Memory allocation failed; could not allocate 16384 bytes» | ||
smls_ | ^^ so the comma operator forces eagerness? | ||
then how can I concatenate a lazy list to the end of a literal list? | 21:01 | ||
21:02
molaf_ left,
kurahaupo1 left,
rurban joined
21:03
rurban left
21:04
kurahaupo1 joined,
rurban joined
|
|||
[Coke] | the yapc::na videos audio & video are not in sync, it seems. | 21:04 | |
21:04
bin_005 left,
bin_005_i joined
|
|||
[Coke] | had problems with both ovid++'s and util++'s . :( | 21:05 | |
vendethiel | [Coke]: really? util++'s was good for me when I watched it | ||
21:09
cognominal joined,
skids left
21:12
[Sno] joined
21:17
uncleyear left,
uncleyear joined
|
|||
smls_ | Strange... after moar was killed by the kernel for running out of memory, I can no longer run perl6 | 21:18 | |
"error while loading shared libraries: .../lib/libmoar.so: unexpected PLT reloc type 0xa0331a29" | |||
timotimo | smls_: there's a method called "plan" that's used to append a lazy list to another | 21:19 | |
or elements to a lazy list | |||
without eagerifying the list | |||
smls_ | ok | 21:20 | |
21:23
kurahaupo1 left
|
|||
smls_ | I wonder if TimToady's/pmichaud's hypothetical list concatenation operation will be able to handle this as well... | 21:24 | |
21:28
FROGGS left
|
|||
timotimo | quite possible | 21:30 | |
21:32
diana_olhovik_ left
21:36
espadrine joined
|
|||
masak | I read an unusually nice autopun the other day. | 21:39 | |
21:39
rurban left
|
|||
masak | so, there's this planet full of individuals who strongly believe in anti-induction. | 21:39 | |
the sun has risen every morning in living memory, so (they believe) it's *not* at all likely to rise tomorrow. | 21:40 | ||
understandably, everyone on this planet is very bad at dealing with reality. they are all quite miserable. | 21:41 | ||
a visiting xenoanthropologist asks "but... why? why do you keep believing in anti-induction? it's obviously the source of all your trouble, so why?" | |||
they say "well, it's never worked before..." | |||
smls_ | ;) | 21:42 | |
masak | paraphrased from www.scottaaronson.com/democritus/lec15.html -- which read, by the way. | 21:43 | |
21:44
uncleyear left
21:45
uncleyear joined
|
|||
masak | 'night, #perl6 | 21:48 | |
21:50
espadrine left
21:53
dolmen left
21:55
diana_olhovik_ joined
|
|||
RabidGravy | nighty night | 21:58 | |
nebuchadnezzar | [ptc]: I just include FROGGS[mobile] patches in MoarVM, maybe you could present yourself on the pkg-rakudo mailing list? | 22:00 | |
I'm testing a build before pushing | 22:01 | ||
22:05
diana_olhovik_ left,
RabidGravy left
22:06
dolmen joined
22:10
uncleyear left,
uncleyear joined
22:19
Gardner left
22:35
bin_005_i left
22:36
skids joined
22:37
uncleyear left
22:38
uncleyear joined,
LLamaRider joined
22:39
LLamaRider left
|
|||
nebuchadnezzar | .tell [ptc] Ok, now I figure out you are Paul Cochrane, I revert your patch on Configure.pl since it's forbidden to modify upstream directly and you arleady provided a patch for this | 22:39 | |
yoleaux | nebuchadnezzar: I'll pass your message to [ptc]. | ||
22:46
kaare_ left,
dolmen left
22:47
bjz left
22:49
vendethiel left
22:50
vendethiel joined
23:06
lolisa left
23:09
Sqirrel left
23:13
Sqirrel joined
23:14
thezip joined
23:17
thezip left
23:21
Akagi201_ left
23:27
[particle] left
23:28
[particle] joined
23:29
kurahaupo1 joined
23:30
telex left
23:31
uncleyear left,
uncleyear joined
23:32
telex joined
23:34
nys is now known as nyssa,
nyssa is now known as nys
23:51
coffee` is now known as luc3
23:52
uncleyear left,
uncleyear joined
23:56
laouji joined
|