Parrot 5.0.0 "Johnny Five Alive" | parrot.org/ | Log: irclog.perlgeek.de/parrot | #parrotsketch meeting Tuesday 19:30 UTC
Set by moderator on 23 January 2013.
00:12 Reini joined 00:42 Reini joined 00:59 kid51_ joined
Coke r: my $a = /a/; say $a.perl; 01:04
p6eval rakudo 932bc5: OUTPUT«regex(Mu : Mu *%_) { ... }␤»
Coke r: my $a = /a/; say ~$a;
p6eval rakudo 932bc5: OUTPUT«␤»
Coke r: my $a = /a/; say $agist; 01:05
p6eval rakudo 932bc5: OUTPUT«[31m===[0mSORRY![31m===[0m�Variable '$agist' is not declared�at /tmp/9aOZ8tvtjf:1�------> [32mmy $a = /a/; say $agist[33m�[31m;[0m� expecting any of:� postfix�»
Coke r: my $a = /a/; say $a.gist;
p6eval rakudo 932bc5: OUTPUT«␤»
Coke r: my $a = /a/; say ~$a;
p6eval rakudo 932bc5: OUTPUT«␤»
Coke is there a way to get something like "a" out of that?
benabik r: /a/.^methods 01:06
p6eval rakudo 932bc5: ( no output )
benabik r: /a/.^methods.say
p6eval rakudo 932bc5: OUTPUT«No such method 'gist' for invocant of type 'Sub'␤ in method gist at src/gen/CORE.setting:5131␤ in sub say at src/gen/CORE.setting:7601␤ in method say at src/gen/CORE.setting:898␤ in block at /tmp/IsHfXY9fuT:1␤␤»
benabik r: /a/.^methods.map(*.name).say
p6eval rakudo 932bc5: OUTPUT«Unmarshallable foreign language value passed for parameter '$x0'␤ in block at /tmp/XeUXtZ6ntf:1␤␤»
benabik Blah.
Coke: No idea, but #perl6 might know. 01:08
Coke benabik: oh. I thought this WAS perl6. Thanks. ;) 01:14
benabik Coke: Thought I'd see if I could answer your question anyway. :-D 01:28
01:43 Reini joined 01:46 MikeFair joined 02:28 Reini joined 03:53 Reini joined
dalek rrot/sixparrot: bbb5d1b | allison++ | src/pmc/parrotinterpreter.pmc:
Remove multidispatch from ParrotInterpreter equality vtable.
04:14
kid51 allison: If you're looking at sixparrot, you might want to look at these test failures I reported two days ago: 04:17
irclog.perlgeek.de/parrot/2013-02-15#i_6455738
allison kid51: curious, I haven't seen any test failures 04:18
kid51 in make fulltest
Coke kid51: early days yet.
kid51 not in make test
Coke: understood
I was able to fix one of three myself
Would actually have expected much more breakage 04:19
Coke there will be more of that too, no doubt. ;) 04:23
cotto no doubt
04:26 Reini joined
allison yah, breakage likely 04:29
the shootout example seem worth keeping, to watch the alioth benchmarks
not a fantastic measure (they're pretty obscure), but a measure anyway 04:30
dalek rrot/sixparrot: 8b5e0b7 | coke++ | sixparrot-TODO.md:
Track more removals
04:47
04:48 preflex_ joined
allison and here comes cutting decision time: removing MULTI from scalar.pmc causes failing tests in Parrot, but Rakudo all still passes 04:55
and, the failing tests in Parrot are specifically related to multidispatch 04:56
so, it's actually removing functionality 04:57
it's functionality I *intend* to remove, so I'm inclined to remove the tests 04:58
but, will leave it here in IRC until tomorrow to give other time to comment
others, that is
05:01 awwaiid joined
kid51 allison: That might be worth a parrot-dev post, just so that everyone is fully aware of how it reflects a (desirable) change of course 05:04
allison kid51: at the moment, it's purely experimental, it's a 20 line change that has no observable impact on performance 05:05
kid51: but, it's one change in a much larger direction 05:06
kid51 And a direction I support
allison so, if people are uncomfortable removing functionality, then I can branch it
kid51 Are you doing this in master or in a branch?
allison and wait to see if the full change really does bring real performance improvements 05:07
sixparrot branch
kid51 Fine
cotto allison: +2 to remove the tests and functionality 05:14
allison cotto: okey-dokey 05:15
Coke moritz: something weird with "make src/pmc/addrregistry.o" in sixparrot branch. 05:32
looks like you removed it and readded, so I'm deferring to you for now.
dalek rrot/sixparrot: 6e635d5 | allison++ | / (2 files):
Remove multidispatch from scalar PMC.
05:50
05:57 Reini joined
dalek p/target-pbc: 97fd401 | moritz++ | src/QAST/ (3 files):
[QAST dumper] include a bit more info
06:17
p/target-pbc: b1258d7 | jnthn++ | tools/ (2 files):
Revert "Merge remote-tracking branch 'origin/spacey'"

This reverts commit 1db6167740f7306a0e3acf04ccb15dfcc27c3dcb, reversing changes made to c9bc4a25ba2ca57e3642dbe870da31fd1b661322.
p/target-pbc: 0514fec | jnthn++ | src/NQP/ (2 files):
Remove a now-unused option.
p/target-pbc: 1e0a374 | jnthn++ | src/NQP/Actions.pm:
Remove a redundant load.
p/target-pbc: c6832d5 | jnthn++ | src/NQP/Actions.pm:
Add a way to specify a custom regex lib.

Useful for nqp-jvm while it only has the runtime part of it.
p/target-pbc: b19dbc1 | (Gerhard R)++ | / (7 files):
Merge branch 'master' into target-pbc
rrot/ops2c-necromancy: 7b8889c | cotto++ | / (12 files):
resurrect ops2c.pl, ops2pm.pl and dependencies
06:36
rrot/ops2c-necromancy: c66f40d | cotto++ | src/ops/ops.num:
update ops.num for the current set of ops
rrot/ops2c-necromancy: cd1fc9d | cotto++ | lib/Parrot/Ops2pm.pm:
minimize differences between old and new generated include/parrot/oplib/ops.h
rrot/ops2c-necromancy: d15fd44 | cotto++ | lib/Parrot/OpsRenumber.pm:
minimize differences in generated include/parrot/opsenum.h
rrot/ops2c-necromancy: f3de8ab | cotto++ | config/auto/ops.pm:
put experimental ops at the end of the list
rrot/ops2c-necromancy: b19020d | cotto++ | src/ops/ops.num:
add the experimental ops to ops.num
rrot/ops2c-necromancy: 0858c01 | cotto++ | include/parrot/op (2 files):
check in the generated ops headers
rrot/ops2c-necromancy: fbe0a4f | cotto++ | / (3 files):
[ops2c] bring back the old ops2c.pl and a couple dependencies
rrot/ops2c-necromancy: 57e3690 | cotto++ | config/gen/makefiles/root.in:
[ops2c] use ops2pm to build some generated files
rrot/ops2c-necromancy: ec5e249 | cotto++ | lib/Parrot/Op (2 files):
[ops2c] update/clean up ops2c
cotto The generated headers work just fine. The generated C code still needs some work. 06:37
(just in case any ambitious soul wants to jump in)
'night 06:41
07:08 Mike-PerlRecruiter_ joined 07:12 Khisanth joined 07:17 PacoAir joined 07:28 Reini joined
dalek kudo/optimizer-void-context: a5a3718 | moritz++ | src/Perl6/Optimizer.pm:
steal match widening from rakudo-debugger

now "23 + 4" in sink context reports the whole expression, not just the operator
08:02
10:02 Khisanth joined 10:28 muixirt joined
dalek p/target-pbc: 7cd9056 | (Gerhard R)++ | src/HLL/Compiler.pm:
integrate PBC generation more naturally into HLL::Compiler
10:34
10:51 woolfy joined 10:52 Liz joined 11:30 dngor joined 12:18 dngor_ joined 12:27 PacoAir joined 12:40 PacoAir joined
dalek p/target-pbc: 6fc76a3 | (Gerhard R)++ | src/stage0/ (9 files):
rebootstrap so we can build on parrot branch eval_pmc
12:49
13:21 PacoAir joined 13:33 bouncy joined 14:21 Psyche^ joined 14:24 brrt joined, brrt left 14:49 kid51 joined
dalek kudo/nom: a10db62 | moritz++ | src/Perl6/Optimizer.pm:
try to track void context in the optimizer

does not work yet, it seems to consider all string literals in void context. No idea why :(
14:55
kudo/nom: f41f314 | moritz++ | src/Perl6/Optimizer.pm:
be a bit less wrong about void context detection

still does not work at all :(
kudo/nom: 15219f7 | moritz++ | src/Perl6/Optimizer.pm:
fix logic error in void context detection

still has quite a fe false positives
kudo/nom: d501814 | moritz++ | src/Perl6/Optimizer.pm:
track declaration bits in the QAST
14:56
kudo/nom: 9244510 | moritz++ | src/Perl6/Optimizer.pm:
use %!worrying mechanism for string constants in void context
kudo/nom: 7636b79 | moritz++ | src/Perl6/Actions.pm:
give string literal QAST nodes a Match object
kudo/nom: c24440a | moritz++ | src/Perl6/Optimizer.pm:
detect Int and Num literals in void context

Does not trigger yet, probably because they have no .node info. Also replace the constant QAST node with a null op
kudo/nom: 89c7e57 | moritz++ | src/Perl6/ (2 files):
give numeric constant QAST nodes a .node

now Int and Num literals warn in void context
kudo/nom: f6a731c | moritz++ | src/Perl6/Optimizer.pm:
warn when inlining constant expressions in void context
kudo/nom: a5a3718 | moritz++ | src/Perl6/Optimizer.pm:
steal match widening from rakudo-debugger

now "23 + 4" in sink context reports the whole expression, not just the operator
kudo/nom: df3a732 | moritz++ | src/Perl6/ (3 files):
Merge remote-tracking branch 'origin/optimizer-void-context' into nom
14:57 Reini joined
dalek kudo/nom: d2795bb | moritz++ | docs/ChangeLog:
update ChangeLog with new warnings
14:58
14:58 mtk joined 15:01 dngor joined 15:03 mtk joined 15:07 mtk joined 15:14 xcombelle joined 15:24 woolfy joined, mtk joined 15:25 Liz joined 15:56 kid51 joined
dalek p/target-pbc: de66164 | (Gerhard R)++ | src/ (3 files):
untangle code
15:58
p/target-pbc: 4068cef | (Gerhard R)++ | t/ (4 files):
adjust tests
p/target-pbc: 7fef0cc | (Gerhard R)++ | src/stage0/ (9 files):
rebootstrap
16:25 zby_home joined 17:02 kid51 joined
moritz can I simply #include <sys/resource.h> in src/platform/sysmem.c, or does that need some kind of configure probe first? 17:45
17:45 Eddward joined
allison moritz: not windows-safe 17:47
moritz so, how do I add the configure probe? 17:48
or do I have to add an src/platform/linux/sysmem.c ? 17:49
kid51 moritz: You might want to first look at other files in src/platform/*/*.c 17:50
moritz kid51: and look for what? 17:51
kid51 These files are infrequently added, so I don't know the answer off the top of my head..
Look for what includes those files have.
My hunch is that a configure probe will be needed, but I haven't thought about anything like this in > 1 yr
What is your objective? 17:52
moritz kid51: include ulimits in the calculation of available system memory
kid51 hmm, I have a vague recollection that we did something like that about two years ago, say, when we were dealing with garbage collection 17:53
benabik kid51: I think this is one of those "discussed to no solution thing", much like estimating memory on 64b OS X.
kid51 sysmem.c is mentioned in config/auto/platform.pm 17:54
pmichaud some discussion about this issue at irclog.perlgeek.de/parrot/2012-07-01#i_5775352
good morning, #parrot
kid51 We have OS-specific versions of probes: e.g., src/platform/generic/sysmem.c 17:55
src/platform/darwin/sysmem.c
src/platform/win32/sysmem.c
pmichaud more directly: irclog.perlgeek.de/parrot/2012-07-02#i_5776957 17:56
moritz kid51: if I add a platform/linux/sysmem.c, does that need to start as a copy of the generic one? 17:57
I still think that a configure probe would be better 17:58
but I have no clue how to add one
and git grep doesn't give me a clue either
kid51 Have you looked at config/auto/platform.pm? 17:59
moritz I've looked just now; but it doesn't enlighten me 18:00
config/gen/config_h.pm looks like the better place
kid51 config_h.pm is one of the last configuration steps 18:01
18:01 contingencyplan joined
kid51 the 'gen' steps are intended to spew out Makefiles and header files based on data assembled earlier 18:01
moritz the problem is, I have no idea how the data flows in the configure system 18:02
for example there's a $conf->data->keys()
where does that data come from? 18:03
kid51 IIRC -- and, again, I haven't had to think about this in some time -- we first examine the local Perl5 %Config, then override values with config/init/hints/*.pm, then conduct probes in the config/auto stage
Roughly speaking , there are 4 configuration stages 18:04
init: Populate with default values from P5 %Config, hints, etc.
moritz oh, found it 18:05
kid51 inter: Additional population of values where interactive configuration is sometimes appropriate (that sometimes being: when done by Andy Dougherty :-) )
auto: probe the system, usually with little C programs
moritz config/auto/headers.pm has a list of @extra_headers
18:06 Reini joined
kid51 finally, gen: spew out files based on data in the Parrot::Configure object -- $conf in your example above. 18:06
perldoc Parrot::Configure 18:08
or Parrot::Configure::Data
or Parrot::Configure::Compiler
Also: perldoc pod/configuration.pod 18:09
moritz woah, compiled at first attempt 18:12
and it's been weeks since I last wrote any C code :-)
kid51 Other things being equal, I'd say adding that header to config/auto/headers.pm would be the way to go. 18:13
moritz erm no, it just compiled it later than I expected 18:15
kid51 At the risk of exposing how long it's been since *I* wrote C code ... 18:16
... where would headers like sys/resources be stored? 18:17
rurban I'm adding a getrlimit check now: rurban/rlimit-gh935
moritz rurban: I think I'm done now
rurban: we can compare patches :-)
kid51: in /usr/include/
it's a system header 18:18
rurban You need to check PARROT_HAS_HEADER_SYSRESOURCE
moritz rurban: right, but first you need to tell configure to generate that macro
rurban then compare getrlimit to the returened memsize, and return the min
sure, easy
moritz after 20 minuts of grepping around, it's easy, yes :-)
rurban and I'm not sure if we need to check RLIMIT_DATA and RLIMIT_AS or only one
moritz I'm checking RLIMIT_AS for now 18:19
rurban I wrote it in 5min :)
moritz because I usually set ulimit -v
rurban: moritz.faui2k3.org/tmp/respect-ulimit.patch that's my patch so far
rurban I think per process data maybe limited also
dalek rrot/rurban/rlimit-gh935: baefa33 | rurban++ | / (2 files):
[GH #935] honor user-rlimits for returned sysmem_amount (untested)
18:23
rurban oops 18:25
benabik Now if we can write a nice probe for HW_MEMSIZE on OS X... 18:26
kid51 benabik: I *definitely* remember discussions about that one!
rurban I think HW_PHYSMEM supported > 4GB 18:27
and HW_MEMSIZE only < 2GB, or smthng like this
benabik HW_PHYSMEM returns 32s. HW_MEMSIZE returns 64b. 18:28
*32b
rurban oh! I think I already patched that somewhere
18:29 kid51_ joined
moritz rurban: seems our patches are nearly identical, except that you test more limits than me 18:30
dalek rrot/rurban/rlimit-gh935: aa3c2dd | rurban++ | / (2 files):
[GH #935] honor user-rlimits for returned sysmem_amount (untested)

We need to check for RLIMIT_DATA and then RLIMIT_AS, first hard, then soft limits.
18:31
rurban We also need to add a testcase
benabik: there's a branch rurban/darwin-memsize-gh268 18:33
All tests pass, so I merge it before the rlimit check
benabik rurban: You changed it in platform/generic, but there's a platform/darwin 18:35
dalek rrot: 7b86dcd | rurban++ | src/platform/generic/sysmem.c:
[GH #268] sysctl: check for HW_MEMSIZE

HW_PHYSMEM returns max 2G as its a signed int only. Use HW_MEMSIZE if available. This helps rakudo building core.pir doing less gc, which is triggered when 10% of total memory is allocated
18:36
rrot: f856f62 | rurban++ | src/platform/generic/sysmem.c:
Merge remote-tracking branch 'origin/rurban/darwin-memsize-gh268'
rurban Oh, I have to do it both? I'll do 18:37
kid51 There is also src/platform/win32/sysmem.c 18:40
dalek rrot/rurban/darwin-memsize-gh268: 1103c31 | rurban++ | src/platform/darwin/sysmem.c:
[GH #268] provide >2GB RAM HW_MEMSIZE check also for darwin, not only generic
18:41
rurban win32 last
benabik I'd be slightly surprised if win32 uses sysctl for memory size.
rurban I guess win32 has a proper API for this
our t/stress/gc.t sucks 18:43
I'll wait with the new rurban/darwin-memsize-gh268 until I get reports, and until I tested it on ppc 18:44
18:47 travis-ci joined
travis-ci [travis-ci] parrot/parrot#813 (master - f856f62 : Reini Urban): The build was fixed. 18:47
[travis-ci] Change view : github.com/parrot/parrot/compare/b...56f62ae774
[travis-ci] Build details : travis-ci.org/parrot/parrot/builds/4858806
18:47 travis-ci left
moritz rurban: seems you just merged darwin-memsize-gh26 into master 18:49
rurban yes, the old version. This was tested ok. 18:50
moritz ok
rurban I just forgot to merge it a month ago.
This helps on 4GB linux and BSD systems
without sysconf(_SC_PHYS_PAGES)
There was a reported problem on a darwin system with the new patch, which I want to get tested 18:51
benabik rurban++
rurban But first I need to add to the t/stress/gc.t 18:52
and add rlimit's
moritz tests rurban/rlimit-gh935 18:54
rurban moritz: we need to test against RLIM_INFINITY as result value I guess 18:55
moritz yes, that's what moritz.faui2k3.org/tmp/respect-ulimit.patch does 18:56
/home/moritz/p6/rakudo/install/bin/parrot -o blib/Perl6/ModuleLoader.pbc src/gen/perl6-moduleloader.pir 19:00
error:imcc:loadlib directive could not find library `nqp_group' in file 'src/gen/perl6-moduleloader.pir' line 1
rurban oop, my patch is wrong. ~0 not 0
moritz make: *** [blib/Perl6/ModuleLoader.pbc] Error 1
moritz has no idea what's going on there 19:01
rurban use -L . -X . 19:02
moritz ah no, I know what's going on
rurban new loadpath order
moritz the nqp is compiled for an older parrot 19:03
rurban oh
moritz so now it looks in the wrong places
19:08 Mike-PerlRecruiter_ joined
dalek rrot/rurban/rlimit-gh935: 2c4e32b | rurban++ | / (2 files):
[GH #935] honor user-rlimits for returned sysmem_amount (untested)

We need to check for RLIMIT_DATA and then RLIMIT_AS, first hard, then soft limits.
19:12
rrot/ops2c-necromancy: ca95550 | cotto++ | lib/Parrot/Ops2c/Utils.pm:
[ops2c] remove x_numops, which nothing uses
rrot/ops2c-necromancy: a55f89c | cotto++ | lib/Parrot/OpsFile.pm:
[ops2c] fix branch detection in the ops processor
rurban This guy says stackoverflow.com/questions/7382554...c-in-linux 19:14
if (lim.rlim_cur >= 0xC000000000000000ull) // most systems cannot address more than 48 bits
But he doesn't check for RLIM_INFINITY (~0UL) 19:15
dalek p: 54985c7 | jnthn++ | src/ (6 files):
Eliminate a bunch of pir::.
19:23
p: 3c896f1 | jnthn++ | t/nqp/62-subst.t:
Update test to not pass due to a PCC fail.

Something that takes no parameters will not check that it got none. Fixing the test, rather than porting the bug.
p: d47185c | jnthn++ | src/core/Regex.pm:
Further portability tweak.
rrot/rurban/rlimit-gh935: 1b0620f | rurban++ | t/stress/gc.t:
[GH #935] add t/stress/gc.t

use from cmd-line as ./parrot t/stress/gc_2.pir 1000000 ulimit -Sv 64000
  ./parrot t/stress/gc_3.pir 1000000
ulimit -Sv unlimited
20:01
rrot/ops2c-necromancy: 5779631 | cotto++ | lib/Parrot/Op (2 files):
[ops2c] remove the op body prelude, which is no longer needed
20:04
rrot/ops2c-necromancy: 27d50f5 | cotto++ | lib/Parrot/Op (3 files):
[ops2c] various cosmetic changes to generated ops code
20:12 perlite_ joined
dalek p: 4500780 | jnthn++ | src/HLL/Compiler.pm:
Remove one seemingly unrequired loadbytecode.
20:26
p: 26b0b8e | jnthn++ | src/QAST/Operations.nqp:
Map some more SC related ops.
p: 90f5160 | jnthn++ | src/ (4 files):
More pir:: => nqp::.
p: 8740c50 | moritz++ | / (2 files):
remove pir::escape call
21:33
21:47 donaldh joined
dalek p: 5265cf6 | jnthn++ | src/HLL/Compiler.pm:
Seems PGE/Dumper.pbc is not used.
21:52
p: 9c9d7bc | jnthn++ | src/QAST/Operations.nqp:
Another missing SC op mapping.
p: 77bd4eb | jnthn++ | src/NQP/World.pm:
Replace a couple of QAST::VM with QAST::Op.
p: c484723 | jnthn++ | src/QAST/Operations.nqp:
A couple more coderef op mappings.
p: afbe2be | jnthn++ | src/NQP/World.pm:
Get rid of another QAST::VM.

Seems this is one of, if not the last QAST::VM node in code-gen that should be portable. Of course, still a bunch of pir:: and Q:PIR uses to go.
22:10 donaldh joined 22:33 bluescreen joined
dalek p: 32a218b | jnthn++ | src/HLL/Grammar.pm:
Eliminate Q:PIR in starter/stopper.

Took a simpler approach than the kboga++ patches for these two.
22:42
p: 98a623e | jnthn++ | src/HLL/Grammar.pm:
Port HLL::Grammar.O to NQP.

Mostly from kboga++'s pull request, with a few tweaks and some use of native types.
rrot/sixparrot: 3c8de68 | allison++ | / (4 files):
Remove multidispatch from Integer PMC.
23:00
cotto allison++ 23:06
allison I've gained a pretty consistent 30 seconds on the parrot test suite, but no significant change on Rakudo 23:07
(not slower, anyway)
cotto All dynop tests pass. I still need to implement write barriers, but this is progressing nicely. 23:31
and github is down 23:35
I guess that's why dalek didn't pick up a previous push 23:36
dalek kudo/nom: 10dac76 | jnthn++ | src/Perl6/ (2 files):
Support for nqp::const.
23:43
kudo/nom: b9ee89a | jnthn++ | / (9 files):
Some pir:: => nqp:: for the setting.
rurban github up again 23:45