Parrot 3.8.0 "Magrathea" | parrot.org | Log: irclog.perlgeek.de/parrot | #parrotsketch meeting Tuesday 19:30 UTC
Set by moderator on 21 September 2011.
00:53 ilbot2 joined
moderator Parrot 3.8.0 "Magrathea" | parrot.org | Log: irclog.perlgeek.de/parrot | #parrotsketch meeting Tuesday 19:30 UTC
slavorgn joined 00:56 Psyche^ joined, tewk_ joined
dalek kudo/optimizer: 74e8d35 | jnthn++ | src/Perl6/Actions.pm:
Handle natively typed variables in inlinability analysis.
00:57
kudo/optimizer: b4ecf53 | jnthn++ | src/binder/multidispatch.c:
Couple of fixes to native types in multi-dispatch; one in narrowness compuation, another in compile time analysis.
kudo/optimizer: 7d26339 | jnthn++ | src/core/Int.pm:
Stub in first couple of native operators.
kudo/optimizer: 074021d | jnthn++ | src/Perl6/Optimizer.pm:
A crack at enabling inlining in the simple case of chaining operators, though something seems slightly adrift here. At this point, we can now inline the couple of native operators that have been added to the setting. There's various issues, various test regressions, but not crazily many.
00:59 autark joined 01:00 slavorg joined 01:11 particle joined 01:18 benabik joined 01:30 alester joined 01:34 particle joined
cotto ~~ 01:55
02:01 particle joined 02:02 jsut_ joined 02:13 AzureStone joined 02:21 woosley joined 02:58 dalek joined 03:07 dalek joined 03:21 rfw joined 04:18 particle joined 04:23 contingencyplan joined 04:50 preflex joined 05:08 preflex_ joined
nine Good morning #parrot 06:39
cotto hi nine 06:46
nine After DLL hell and dependecy hell, parrot now brings: bootstrap hell 07:20
07:42 mj41 joined
nine Funny: it seems like kill_threads is actually the smallest problem for green_threads. Things like the new embedding interface or splitting arguments into sysargs and progargs make my life much more difficult 07:46
08:19 lucian joined 08:30 jsut_ joined 08:40 mj41 joined 09:19 mj41 joined 09:38 mj41 joined 09:41 woosley left
nine Ok, how am I supposed to create a FixedPMCArray with the new embedding API? 09:53
09:55 schmooster joined
tadzik nine: you may want to read through the PL/Perl6 project, it's about embedding Parrot in PostgreSQL 09:58
nine tadzik: plparrot seems to use the old and supposedly deprecated embedding API. At least that's what I see in raw.github.com/leto/plparrot/master/plparrot.c 10:02
tadzik oh, ok 10:03
well, I'd look for tests then. dukeleto had a grant some time ago to improve test coverage of the embedding api, so I suppose those tests are up to date
10:05 redicaps joined
nine Four lines of code and four variables. That's crazy. 10:14
And it doesn't even work :) 10:15
tadzik :P 10:17
10:18 mj41 joined
nine but thanks for the hint 10:21
It's actually much easier to create a PMC for a string array than it is to create one for a single string or even a simple int 10:29
Extra trap: FixedPMCArray init function takes a size int. But it fails if you actually give it a size. Instead, you have to use set_integer_native which's docs explicitely state that it cannot be used to resize the array. 10:39
tadzik ah, been there, done that :/ 10:44
11:04 SHODAN joined
dalek p: 422048a | jnthn++ | src/PAST/NQP.pir:
Fix handling of WHAT in nqp::op mapping.
11:09
11:12 benabik left
nine waaaaaaaaaaaaaaaaaaaah 11:26
11:35 jsut joined
dalek kudo/optimizer: 1a2a145 | jnthn++ | tools/build/NQP_REVISION:
Bump NQP_REVISION to get map_node fixes.
11:35
kudo/optimizer: 7b09735 | jnthn++ | src/Perl6/ (2 files):
Add supprot for nqp::want, and make various bits of analysis smarter about PAST::Want.
kudo/optimizer: f70067c | jnthn++ | src/core/Int.pm:
Native operators should use nqp::want; get infix:<+>(int, int) to do so.
11:36
kudo/optimizer: e14527f | jnthn++ | src/Perl6/Optimizer.pm:
Correct the chain analysis so it only handles the very constrained (but very common) case I'd intended it to. Fixes various of the spectest regressions.
11:36 Psyche^ joined 11:53 benabik joined 12:01 whiteknight joined 12:11 SHODAN joined
whiteknight good morning, #parrot 12:22
nine good morning whiteknight 12:23
benabik o/ whiteknight, #parrot
nine parrot's build system is the horror 12:28
atrodo =~ 12:29
benabik It could be worse, but it is pretty bad 12:30
dalek kudo/optimizer: a3f69b6 | jnthn++ | src/ (2 files):
Don't lie about what types we can provide.
12:31
kudo/optimizer: 1f0a570 | jnthn++ | src/Perl6/Optimizer.pm:
Don't lose :named during inlining a call. Fixes majority of inliner-induced failures.
whiteknight hello nine. What don't you like about the build system? What do you need to change about it? 12:32
good morning also, benabik
12:32 Kulag joined
benabik My major objection to the build system is the total failure of make after a version number change. This can probably be fixed either by having more things depend on the version number or by making the PBC format more stable. 12:33
nine whiteknight: fighting with boostrapping. Had to change frontend/parrot2/prt0.winxed but to bootstrap, I need a working ./miniparrot. So I cannot do the corresponding changes in frontend/parrot2/main.c at the same time 12:34
whiteknight oh, what changes do you need to make to the frontend? Also, miniparrot is made from frontend/parrot/main.c, not parrot2/main.c 12:35
nine Now there's pbc_to_exe.pir which seems to need the same change. Only that other times, it seems to be called different, so it doesn't need the change.
whiteknight what change needs to be made?
Coke I am interested in conversations about the build system, having forced the makefile to DTRT in some cases. 12:36
12:36 mj41 joined
nine whiteknight: the source of these changes is that to move the call of :main to a scheduled task, it can only have a single argument 12:36
12:38 bluescreen joined 12:44 jsut_ joined
whiteknight nine: damnit, allowing :main to take more than one was a change I added recently. Is there a way we can update scheduled tasks to be more flexible? 12:48
benabik … What's expected to be passed to a :main sub?
whiteknight benabik: in the frontend I updated it so it can take two sets of arguments, those for the VM and those for the program
it's much easier to separate out the two at the C level than at the PIR level 12:49
benabik: most programs written in PIR or higher only expect a single argument, which is the array of args passed to that program, but the frontend is a little different because it needs to take options for controlling the VM as well 12:50
nine whiteknight: I know. Like I mentioned this morning: actually kill_threads was very simple to merge. Other changes are unexpectedly much more of a problem for me.
whiteknight nine: you can bootstrap prt0.winxed.pir with a separate parrot install
nine: feel free to break out tasks and assign them out to me 12:53
if you run into problems like that, especially if I caused them, I'll gladly fix them
nine whiteknight: thanks for the offer. For now I can still use the learning experience, so I'll try to handle it myself. But of course I appreciate all hints :) 12:56
12:56 particle joined
whiteknight frontend/parrot/main.c is the old frontend which is used to build miniparrot, so that should only take a single argument to :main and you should be able to build that at least 12:58
Instead of using two separate arguments to main like I have been doing, You can append the two lists together at the C level. Just do a rudimentary sort to put the system arguments first and the program arguments second, maybe separated by a flag or something 12:59
benabik Or pass it an array with two arrays.
whiteknight yeah, I thought about that too 13:00
nine I'm passing a FixedPMCArray containing the two arrays now
whiteknight okay, that works fine too
benabik Do we have a basic list/pair structure? (Cons cell, linked list, tuple, whatever)
whiteknight benabik: no 13:01
benabik sadface
whiteknight there's no reason why not, other than nobody having written them
we have RPA and Key
benabik I like immutable data structures.
Key is fairly close, albeit hard to manipulate.
whiteknight yeah, that's exactly it. Key isn't used much, so it doesn't have a nice interface for usability
nine Converting the task PMC to allow an arbitrary amount of parameters seems rather difficult. I have no idea how I would construct the signature for Parrot_ext_call
benabik It could use a Capture to pass things around and expand it inside the task.. 13:02
whiteknight nine: we could do such a thing through judicious use of the :flat and :slurpy modifiers, but that does seem like a waste
benabik (if that makes sense. I'm not sure I'm awake)
nine As long as you're not a parrot beginner trying to change the VM entry, packing your task parameters into some data structure should be very simple. So I don't see much of a gain by allowing more than one parameter 13:04
whiteknight nine: yeah, that's exactly true. There is no real reason to keep a special exception if it's only used by the one frontend 13:05
nine so I'll just keep fighting with pbc_to_exe :) parrot and miniparrot seem to work 13:06
I did the argument packing in Parrot_pf_execute_bytecode_program 13:07
whiteknight pbc_to_exe wasn't updated when I added the new frontend, it should be functionally similar to miniparrot 13:11
it's not as easy to play with, because of all the PIR 13:12
I had wanted to rewrite it in Winxed, but I never got around to it 13:13
nine since both frontends ended up using Parrot_pf_execute_bytecode_program all mains should no be called with a single parameter. 13:14
That's funny: paste.scsys.co.uk/145648 13:15
whiteknight ...lolfail? 13:16
nine The first case seems to be a pbc_to_exe expecting a single argument getting called with two and the second case expects two arguments but gets called with a single one 13:17
whiteknight weird 13:18
nine that's bootstrap hell :)
whiteknight for the first project, we like to drive new developers crazy
nine it's good that I did not pick something really difficult ;) 13:19
Just today I've been bitten by: 13:20
* building parrot requires a working parrot 13:21
* old embedding api / new api
* old frontend / new frontend
* having to not use the obvious parameter but use a function where the doc says "don't use me!"
* code that works in a frontend file absolutely blows when moved to an internal function 13:22
whiteknight what function says "don't use me?" 13:33
nine That's what I meant: Extra trap: FixedPMCArray init function takes a size int. But it fails if you actually give it a size. Instead, you have to use set_integer_native which's docs explicitely state that it cannot be used to resize the array.
whiteknight FixedPMCArray is a huge fail, you're right 13:34
nine I don't understand why ./parrot pbc_to_exe.pbc pbc_to_exe.pbc would fail. ./parrot got rebuilt and so has to use my changed Parrot_pf_execute_bytecode_program. So where's the FixedPMCArray? 13:38
whiteknight is there a parrot_old binary around you can use instead? 13:39
nine whiteknight: there is and it works. But make still wants to redo the call 13:40
ah no, it just needs to compile some more files 13:41
whiteknight ok 13:46
nine similiar problem later with nqp-rx.pbc 13:54
dalek kudo/optimizer: 1cb3f8d | jnthn++ | src/core/Int.pm:
A few more native int operators. If anybody fancies doing the num ones, dive in!
13:55
whiteknight nine: weird 13:59
oh wait, I think I know what the problem is
nine yeah?
whiteknight when you call ./parrot pbc_to_exe.pbc, it packs the two arrays into a single array and passes it to the frontend
nine Actually I think miniparrot works, but parrot still calls using two params 14:00
whiteknight when you call ./pbc_to_exe, it only has one array that doesn't get packed
that same program, in two different forms, gets two different input arguments
remember, frontend/parrot2/main.c is different from frontend/parrot/main.c and pbc_to_exe 14:01
I think you're going to have to undo that solution, and instead of making an array of arrays in frontend/parrot2/main.c, you need to just have one normal ResizableStringArray 14:02
nine whiteknight: I did not change frontend/parrot2/main.c. I implemented the packing in Parrot_pf_execute_bytecode_program in src/packfile/api.c which is used by both frontend/parrot/main.c and frontend/parrot2/main.c 14:05
At least that's what I think
whiteknight oh, so it always packs?
nine it should
whiteknight okay
then how are you doing Parrot_ext_call? 14:06
nine I'm not using Parrot_ext_call yet. I'm trying to implement the argument packing in a clean master since the change is completely tangential to green_threads. I'm not trying to do two fundamentally changing things at the same time :) 14:08
whiteknight ok
if you commit what you have, I can take a look at it in a little while 14:09
nine pushed to git@github.com:niner/parrot.git pack_main_args branch 14:11
have to leave now anyway 14:12
whiteknight okay, I'll take a look. Thanks
nine thank you :)
14:18 nbrown joined 14:26 contingencyplan joined 14:40 dmalcolm joined 14:57 particle1 joined
dalek kudo/nom: 38f1a2c | jnthn++ | src/ (2 files):
Implement 'is required' on parameters.
15:02
kudo/nom: 9da03d2 | jnthn++ | t/spectest.data:
Run S06-signature/slurpy-params.t.
kudo/nom: 8ba6979 | jnthn++ | src/core/Range.pm:
Tiny optimization to range iteration.
kudo/nom: 1eeac15 | jnthn++ | src/core/Mu.pm:
Fix error reporting for non-existent private methods.
15:23
kudo/nom: 1e95c0a | jnthn++ | src/Perl6/Actions.pm:
Catch illegally unqualified private method calls at compile time.
rrot/whiteknight/main_args: d6a0c0f | Whiteknight++ | / (9 files):
Simplify argument passing to :main. Always pass exactly one PMC arg to :main. The new frontend combines it's two arrays into a single array argument, and parses that out.
15:38
whiteknight msg nine Check out the whiteknight/main_args branch in parrot/parrot. I redid arguments to :main so it always takes exactly one argument. I changed prt0.winxed to parse a single arg list instead of parsing two lists. Let me know if this works for you 15:39
aloha OK. I'll deliver the message.
dalek kudo/nom: d104b94 | jnthn++ | src/core/Numeric.pm:
Fix infinite recursion with lcm/gcd. Resolves the [lcm] 1..3 issue.
15:51
15:58 bubaflub joined 16:08 darbelo joined
dalek kudo/nom: def94fa | jnthn++ | src/Perl6/Grammar.pm:
Add error from STD for using $0 in a prameter list.
16:16
16:26 dodathome joined
dalek kudo/nom: 71d1557 | jnthn++ | src/Perl6/Actions.pm:
Fix .+$foo() style dispatches (many candidates plus indirect name in combination).
17:02
benabik How do you get inf into a $N register in PIR? 17:04
Coke $S1="Inf"; $N1= $S1 # works, but probably a shorter way
17:04 fperrad joined
benabik Hm. t/op/inf_nan.t appears to spell the special nuns 'Inf', '-Inf', and 'NaN' 17:05
Fun.
Coke er, $N1 = "Inf" # shorter. ;)
dalek kudo/nom: 9e7a62e | jnthn++ | src/core/Enum.pm:
Add Enum.at_key.
17:10
kudo/nom: db05a44 | jnthn++ | t/spectest.data:
Run S12-methods/parallel-dispatch.t.
17:20 mj41 joined
tadzik nom: say so IO::Socket::INET ~~ IO 17:34
p6eval nom def94f: OUTPUT«Could not find symbol 'IO::Socket::&INET'␤ in sub die at src/gen/CORE.setting:416␤ in block <anon> at /tmp/7O4mTYMyJM:1␤ in <anon> at /tmp/7O4mTYMyJM:1␤␤»
tadzik goddamnit, SAFE
b: say so IO::Socket::INET ~~ IO
p6eval b 1b7dd1: OUTPUT«Bool::False␤»
tadzik huh 17:35
oh, ww, pardon
dalek kudo/optimizer: ebf115c | moritz++ | src/core/Num.pm:
prefix:<->(num). Wracks havoc of tests becase -Inf now generates invalid PIR (set $N100, Inf)
17:39
nine whiteknight++ # making my life much easier :) 17:50
cotto_work ~~ 17:52
whiteknight nine: it's better to just do it the right way, then to work around doing it the wrong way 18:20
I haven't even run tests on that branch. I got it to build and I sent it to you for review. If you like it, I can finish the work 18:21
nine true, true
whiteknight: like it? absolutely 18:27
whiteknight awesome. I'll fix it up tonight and merge it to master
18:49 mj41 joined, Kulag joined
dalek kudo/optimizer: b95d441 | moritz++ | src/core/Num.pm:
more num ops; correct return value of cmp
18:57
kudo/optimizer: 0b30152 | moritz++ | src/core/Num.pm:
more num ops
18:57 jsut joined 19:10 alvis joined 19:17 alester joined 19:57 ingy joined 20:00 athomason joined 20:09 ingy joined 20:13 sjn_ joined 20:42 d1-1 joined
d1-1 hello, can anybody point me towards the LALR stuff written by tcurtis for GSoC please? 20:43
bubaflub d1-1: github.com/ekiru/lalrskate 20:45
d1-1 awesome, thank you bubaflub 20:47
dalek kudo/optimizer: 7bc5ce7 | jnthn++ | src/Perl6/SymbolTable.pm:
Fix Inf/NaN in native num contexts.
21:16
21:41 perlite joined 21:47 jsut_ joined
dalek kudo/optimizer: 2cf8944 | jnthn++ | src/core/Int.pm:
Start to add some returns traits to various ops. Also a couple more native int ops.
22:18
kudo/optimizer: c085ef9 | jnthn++ | src/Perl6/ (3 files):
If we know what we're going to call, add its return type into the tree, so things a level up can use that type in their analysis. This means that given ($a, $b, $c) are all int, $a + $b * $c will be able to inline both operations; before it would not inline the +.
23:08 bluescreen joined
dalek kudo/optimizer: f7344b1 | jnthn++ | src/Perl6/Optimizer.pm:
Little refactor in preparation for analyzing only calls further.
23:14
kudo/optimizer: ea3e344 | jnthn++ | src/ (3 files):
Some initial infrastructure for trial-binding calls to only subs.
kudo/optimizer: 8c0c759 | jnthn++ | src/Perl6/Optimizer.pm:
Update optimizer so that it can start making some use of the only-sub trial bind analysis, once it's implemented (at the moment, it always gets 'not sure' though, and does no transformation).
23:20 whiteknight joined
cotto_work g'day wagle_ 23:20
er, whiteknight
whiteknight wigglewaggle, cotto_work 23:21
wagle_ zzz
wagle 5 year old came up with that one
WAY gul 23:22
23:47 soh_cah_toa joined 23:51 benabik joined