Parrot 4.6.0 "Wild Parrots of Telegraph Hill" | parrot.org/ | Log: irclog.perlgeek.de/parrot | #parrotsketch meeting Tuesday 19:30 UTC
Set by moderator on 18 July 2012.
00:41 wagle joined 00:56 preflex_ joined 01:43 benabik joined 01:45 whiteknight joined 02:25 benabik joined 02:26 eternaleye joined, wendar joined 02:28 nine joined 02:29 jsut joined, cosimo joined, Timbus joined 02:30 Hunger joined 02:31 pmichaud joined, ttbot joined 02:32 drift_ joined 02:33 Maddingu1 joined 02:35 allison joined 02:36 PacoAir_ joined, plobsing joined 02:44 eternaleye_ joined, aloha joined 02:45 dngor joined, awwaiid joined, Patterner joined, woolfy joined, Timbus joined, sivoais joined, ingy joined, szbalint joined, cxreg joined, rblackwe_ joined, Hunger joined, cosimo joined, nine joined, contingencyplan joined, mtk joined, slavorg joined, Util joined, tokuhirom joined, rurban joined, cotto joined, Coke joined, knewt joined, sorear joined, atrodo joined 02:46 LizM joined 02:47 Tene joined, pmichaud joined, ttbot joined 02:48 benabik joined 02:56 slavorg joined 02:58 woolfy_ joined 02:59 LizM joined 03:08 Tene joined 03:11 benabik_ joined 03:12 eternaleye joined 03:13 Timbus joined, rblackwe joined 03:14 contingencyplan joined, atrodo joined, sivoais joined 03:15 cotto joined, dukeleto joined 03:16 Patterner joined, ingy joined, szbalint joined, cxreg joined 03:17 TonyC joined 03:18 awwaiid joined 03:19 slavorg joined 04:30 tadzik joined 05:02 wagle joined 06:08 JimmyZ joined 06:46 muixirt joined
muixirt good morning! 06:46
Tene Hi! 06:47
muixirt Hi Tene how are things going in the parrot world? 06:48
Tene Haven't done anything with Parrot in ages, sorry to say.
Maybe someday I'll start again.
muixirt it's a bit awkward to see that most language implementation based on parrot are stalled, and ... 06:50
rakudo devs seem to want to get away from parrot vm 06:51
Tene Yeah, I'm sad to see that too. I'm still pretty hopeful that the current work on Parrot goes well, which might make parrot a more attractive platform.
I haven't seen much indication that rakudo folks want to abandon parrot, mostly just that they also want to run on other VMs as well. 06:52
although, that probably depends on who specifically you ask. :) 06:53
JimmyZ muixirt: rakudo doesn't want to get away from parrot vm :) 06:54
muixirt parrot -h mentions the -O option but it's gone
JimmyZ: yeah it would be a major rewrite of rakudo to do so, which isn't very popular these days :-) 06:56
JimmyZ muixirt: multi-implementation or multi-backend is a goal of Perl 6 :), rakudo inherits it 06:57
Tene no, it mostly just involves changes to NQP
JimmyZ Tene: speaking of parrot, you may want to be another white knight who wants to porting 6model to parrot? 06:58
muixirt the other day i stumble across a blog post which discussed computed gotos for VMs and i wondered what parrot uses nowadays
Tene JimmyZ: I'd love to work on that; whiteknight and I have talked about that work a few times before. 06:59
JimmyZ Tene: Great, I'd like to help it too. but it is beyond my ability range 07:01
Tene It's in my technical ability range, but I haven't had sufficient motivation to work on any recreational programming for the past few years. 07:02
07:05 fperrad joined
JimmyZ I'm not optimistic until parrot get 6model. and I'll be very optimistic until m0/m1 lands 07:06
*after m0/m1 lands 07:07
Tene: Porting 6model to parrot may be not recreational :) 07:08
Tene Eh? Someone's got a grant to work on it? 07:10
JimmyZ I'm +1 on it. but need a sponsor 07:12
Tene I'm barely able to keep up with my normal job these days; I'm not reliable enough to accept grant money right now. 07:14
It would be a lot of fun, though.
JimmyZ well, the real problem is no sponsor :)
I thinnk 07:17
muixirt are the parrot src macros ARGMOD, ARGIN etc. still useful?
JimmyZ yep
muixirt JimmyZ: what tools/compilers utilize them? 07:20
JimmyZ splint
muixirt JimmyZ: but parrot is not (sp)lint clean, or is it? 07:22
and splint really provides these macros? 07:23
JimmyZ nope
07:28 brrt left
muixirt is splint regularly used by the parrot devs? 07:36
sorry for the noob questions 07:44
can someone tell me where does PARROT_HAS_HEADER_SAL come from? (was looking at include/parrot/compiler.h) 07:45
muixirt shivers ... alone again 07:56
muixirt still wonders where PARROT_HAS_HEADER_SAL is defined and under what circumstances 08:05
08:49 JimmyZ joined
JimmyZ muixirt: you can grep -r 'PARROT_HAS_HEADER_SAL' * 09:03
moritz muixirt: a grep shows that it's never defined, and only used twice in compiler.h
muixirt JimmyZ: moritz I did and so I wondered 09:04
so macros like ARGIN, ARGMOD and so on do nothing except adding splint comments? 09:06
JimmyZ muixirt: yep 09:08
muixirt and there was (and won't be) no efforts to make parrot source code splint clean (?) 09:14
JimmyZ doesn't know 09:19
10:26 whiteknight joined 10:27 zby_home joined
muixirt hi whiteknight 10:30
whiteknight hello muixirt
muixirt should '-O' mentioned in the usage messages go away? what happened to it? 10:31
whiteknight I think it should go away. I don't think it's connected to anything anymore 10:40
muixirt it was connected to the imcc optimizer? 10:44
whiteknight at one point, yes. But most of that logic got ripped out at one point 10:56
if you're thinking about doing this, definitely double-check the code to make sure -O is not used
and it should probably be done in a branch. I think NQP or Rakudo might still be relying on -O in their makefiles 11:03
muixirt $ parrot -O test.pir #--> Option -O not known 11:12
11:23 JimmyZ joined
whiteknight ha! My readline implementation doesn't have a bug after all! 11:23
JimmyZ whiteknight++ 11:24
whiteknight my stupid editor was silently saving the file as UTF-16, but my test program was reading it in as UTF-8
wait, it might still have a bug, but a different one 11:26
dalek p/toqast: f6a5c44 | jnthn++ | src/QAST/Compiler.nqp:
Fix a couple of small code-gen bugs.
11:29
p/toqast: 9133c44 | jnthn++ | src/QAST/Compiler.nqp:
Fix to unicode string handling.
11:31 lucian joined 11:36 PacoAir joined
benabik ~~ 11:39
whiteknight good morning, benabik 11:41
benabik o/ whiteknight
dalek rrot/whiteknight/io_cleanup1: 7bfbee2 | Whiteknight++ | src/io/api.c:
Fix so the build works again.
rrot/whiteknight/io_cleanup1: bc28672 | Whiteknight++ | src/pmc/handle.pmc:
Update the Handle.readline method to take an optional STRING parameter for a custom record separator, like what Socket.readline does in master (but now all Handle-derived types have it).
rrot/whiteknight/io_cleanup1: 6cc0855 | Whiteknight++ | src/io/buffer.c:
Add a check for a non-full buffer, which might indicate no more data to be read.

This fixes the case of multiple-character readline delimiters for every ad hoc test I've been able to throw at it.
whiteknight damnit! It's still cutting off a byte somewhere 11:47
readline is the worst thing ever 11:51
JimmyZ that's hard to debug 11:53
dalek rrot/whiteknight/io_cleanup1: cf8250e | Whiteknight++ | src/io/buffer.c:
Don't prematurely determine there's not enough data to read.

If we don't have enough data to contain a full delimiter, we probably still have something to return (data after the last delimiter). This fixes one more small issue I've found in ad hoc testing.
whiteknight okay, so now everything is looking good
finally
benabik whiteknight++ 11:54
JimmyZ whiteknight++ indeed
whiteknight I'm sure that this can all be optimized, but I want to make sure I get the semantics correct before starting any of that 11:55
now the fun part: writing up all this stuff as tests 11:56
dalek rrot/whiteknight/io_cleanup1: ff2dba3 | Whiteknight++ | t/pmc/io.t:
Add a test for FileHandle.readline(s) with multi-character delimiter.
12:10
whiteknight msg moritz: I think io_cleanup1 is ready for more wide-scale testing now. Let me know if you see any problems. 12:12
aloha OK. I'll deliver the message.
benabik whiteknight: Did you get my message about the IMCC segfault?
whiteknight benabik: maybe. What was the issue again? 12:13
benabik whiteknight: It's segfaulting in add_namespace, but seemingly only when I run the test through Rosella.
whiteknight: gist.github.com/3153298
whiteknight on master or the io_cleanup1 branch? 12:14
benabik master
whiteknight I'll have a look at it. I assume this is blocking you?
benabik Yeah. I was planning on having a set of tests that compiled PIR and disassembled into PACT. 12:15
I suppose I could do the compilation outside of the tests for now... :-/
dalek p/toqast: e106957 | jnthn++ | src/QAST/Compiler.nqp:
Restore capture_lex on block entry.
12:23
kudo/toqast: b2e068f | jnthn++ | src/core/Regex.pm:
Fix a pirop sig that led to invalid code gen.
kudo/toqast: cb9e7de | jnthn++ | src/QPerl6/Actions.pm:
Fix rather over-eager whatever currying (it was currying stuff like $a ?? * !! $b).
whiteknight benabik: blah! I'll try to track down the problem in a little bit
benabik whiteknight: thanks 12:24
dalek rrot/whiteknight/io_cleanup1: 1ed2945 | Whiteknight++ | / (3 files):
Verify that the record_separator is the right encoding, even if it is set after the encoding is.

Factor out some re-encoding logic into a new helper function. fix the .record_separator() method to accept strings of sizes other than 1 character
12:40
whiteknight benabik: that's in your pact repo? 12:45
benabik whiteknight: It's a cut down version of t/00-sanity.t
Oh. Which I haven't pushed.
dalek CT: ef4303b | benabik++ | t/00-sanity.t:
Basic sanity tests
whiteknight okay, I have to re-build parrot master first. Give me a few minutes
benabik NP
whiteknight And I may take this opportunity to go grab some breakfast 12:47
benabik I'm in that process myself 12:48
12:50 lucian joined 13:18 JimmyZ_ joined
moritz tests rakudo on top of io_cleanup1 13:18
whiteknight moritz++ 13:19
moritz whiteknight: uhm, now all the socket tests fail :( 13:30
in rakudo, that is
whiteknight damnit!
moritz it always receives the empty string
whiteknight okay, Let me stare it it
moritz whiteknight: I think the previous test I ran was with commit ff2dba3a5da0f2bc767cef648d2ebeb7a3132ea4 "Add a test for FileHandle.readline(s) with multi-character delimiter." and it was much better 13:32
whiteknight okay, let me figure out what I broke 13:34
benabik moritz: ff2dba3 is also from this morning
moritz benabik: I know
benabik moritz: Lots of testing, then. :-) 13:35
No bad thing.
dalek kudo/toqast: e242a9a | jnthn++ | src/QPerl6/Actions.pm:
Re-implement handling of exceptions thrown inside exception handlers.
13:41
13:48 JimmyZ_ joined
whiteknight benabik: I get that segfault just running the test from the commandline 13:51
benabik whiteknight: right. If I just call (new SanityTest).test_imcc() instead of the Rosella setup, it seems to work for me. 13:52
whiteknight oh, I see what you're saying
When I try that, I get exceptions about the assert attribute not being found 13:53
benabik Oh, right. My copy of the test is trimmed down to just the compile call. 13:54
whiteknight yeah, I did that. You're right 13:55
dalek CT/segfault: 64f1f0e | benabik++ | t/00-sanity.t:
Golfed sanity test to segfaulting bit
whiteknight weird 13:56
Adding a .namespace directive into the compiled PIR snippet makes it work 13:57
benabik Uh.
whiteknight ...which isn't really a solution
benabik Does Rosella compile anything in there? Perhaps some variable isn't getting cleared. 13:58
whiteknight I don't think it does any compiling. I have to check it 13:59
hmmm
benabik Hm, indeed...
whiteknight jam a .namespace directive in there so you don't have to wait for me to debug this bad boy 14:00
14:00 JimmyZ joined
dalek CT/segfault: 072a3e5 | benabik++ | t/00-sanity.t:
load_bytecode is all that's need to break it?
14:01
benabik whiteknight: ^^
whiteknight hmm... 14:02
the plot thickens
benabik Two of your favorite chunks of code working together: Packfile loading and IMCC.
whiteknight I KNOW, I'M IN LOVE 14:03
dalek kudo/toqast: feda23a | jnthn++ | / (17 files):
Fold QPerl6::* back into Perl6::*, thus eliminating qperl6. This means that the perl6 that is now built is using QAST, as is the setting, test run, etc.
whiteknight I've got to get up for a minute. Do whatever you can to avoid this issue for now 14:05
dalek Heuristic branch merge: pushed 87 commits to rakudo/toqast by jnthn 14:28
kudo/toqast: db138e7 | jnthn++ | src/core/Mu.pm:
Fix a proto's signature.
14:59
p/toqast: ca9306c | jnthn++ | src/QAST/Operations.nqp:
Fix 2-arg rindex, thus fixing the rindex test failures in Rakudo.
15:00
p/toqast: bfbf20a | jnthn++ | src/QRegex/NFA.nqp:
Get NFA builder to recognize/handler qastnode.
15:28
15:30 benabik joined
dalek kudo/nom: d0dc2d3 | moritz++ | src/core/IO/Socket/INET.pm:
explicitly set encoding on sockets
16:01
kudo/nom: e09fbe6 | moritz++ | src/core/IO/Socket/INET.pm:
Merge remote branch 'remotes/origin/parrot-iocleanup1' into nom
kudo/nom: cd31947 | moritz++ | src/core/List.pm:
fix List.tree

it got broken by the last API change of MapIter.new
kudo/nom: 6db12d6 | moritz++ | src/core/IO/Socket/INET.pm:
Revert "Merge remote branch 'remotes/origin/parrot-iocleanup1' into nom"

This reverts commit e09fbe68707707004d1111dba7b0b6fb9e100541, reversing changes made to 5b56cfcf9286e70b9a77a73369b80ad98ad10786.
16:02
16:36 lucian joined 16:41 whiteknight joined 16:57 jashwanth joined
whiteknight good afternoon, #parrot 16:59
dalek kudo/nom: 3ac8c77 | moritz++ | src/core/List.pm:
fix another misuse of MapIter.new, felher++
17:03
17:20 benabik_ joined
benabik_ ~~ 17:21
17:21 wagle_ joined 17:22 PacoAir joined, cosimo joined, TonyC joined 17:23 nine joined, Util joined, cxreg joined, Timbus|Away joined, ttbot joined 17:24 eternaleye joined, sivoais joined 17:25 cotto joined 17:26 muixirt joined, sorear joined, Coke joined, lucian joined, tadzik joined, ingy joined, szbalint joined, tokuhirom joined, jashwanth joined, Hunger joined, knewt joined 17:27 rurban joined 17:28 rblackwe joined 17:30 mtk joined 17:32 fperrad joined 17:33 pmichaud joined, ttbot joined 17:35 Psyche^ joined 17:36 slavorg joined
dalek CT: 8fc5583 | benabik++ | t/dummy.t:
Remove dummy test
17:42
CT: de2e4fe | benabik++ | t/00-sanity.t:
t/sanity: add message for a test
CT: aa9e5b3 | benabik++ | t/00-sanity.t:
t/sanity: helps to get the assert object first

assert != self.assert
CT: 5624eff | benabik++ | t/00-sanity.t:
t/sanity: Kludge for strange IMCC segfault
17:46 Patterner joined, mtk joined, muixirt joined, sorear joined, Coke joined, tadzik joined, ingy joined, szbalint joined
dalek kudo/toqast: bec9a8e | jnthn++ | tools/build/Makefile.in:
Install the new Perl6::Ops PBC.
17:49
benabik whiteknight: Do you manually generate the headers for Rosella? Would you recommend hooking winxed_mk_header into distutils or just committing the output?
benabik discovers the rosella headers. 17:50
whiteknight I manually run winxed_mk_header
17:56 eternaleye_ joined 17:57 Hunger- joined 17:58 atrodo joined 18:00 Psyche^ joined 18:05 tokuhirom joined
benabik Hm. Both load_bytecode and .include search the current directory. So the headers and source need to have different names... 18:06
18:07 Hunger joined 18:08 ttbot joined
benabik I could just move the source back into src/ 18:08
18:11 lucian joined 18:12 muixirt joined, sorear joined, Coke joined, tadzik joined, ingy joined, szbalint joined 18:15 knewt joined 18:16 ttbot joined 18:18 Psyche^ joined
muixirt ping whiteknight 18:48
whiteknight pong
muixirt whiteknight: I#M looking at the embedding docs 18:49
if a language dev chooses not to generate pir and instead uses Parrot_api_load_bytecode_bytes 18:50
are the opcode numbers "public"?
18:50 lucian joined
muixirt whiteknight: or is that a stupid idea? 18:57
whiteknight what do you mean? 18:58
muixirt how do I generate bytecode without pir? 18:59
what is the user of Parrot_api_load_bytecode_bytes supposed to put in memory that holds the bytecode? 19:01
dalek p/toqast: 4f9fa15 | jnthn++ | src/QAST/ (2 files):
Fix if/unless with pointy blocks taking the condition as an argument.
19:02
p/toqast: 69b0f82 | jnthn++ | src/QAST/Operations.nqp:
while and until with pointy.
kudo/toqast: 709b09f | jnthn++ | src/core/Numeric.pm:
Correct another wrong proto.
muixirt probably i'm missing something essential 19:07
btw the code example in pdd10_embedding.pod in line 200 it should be probably GET_INIT_STRUCT instead of GET_INIT_ARGS 19:12
whiteknight: so is generating bytecode on the fly discouraged, impossible or what? sorry for bothering you :-) 19:23
moritz support for that isn't good, afaict 19:24
I think benabik is owkring on improving it 19:25
muixirt moritz: ok, so language devs have to stick with pir (or pir generating cimpiler like nqp or winxed)? 19:27
moritz for now, yes 19:28
benabik You can generate bytecode by hand, but you have to know a lot about how bytecode works. Hopefully by Sept, PACT will make that simpler. 19:47
benabik re-lurks.
muixirt ok, thanks benabik and moritz 19:48
20:17 perlite_ joined
whiteknight muixirt: sorry I'm not replying! Yes, generating bytecode without PIR is, at the moment, very difficult 20:53
muixirt: your best bet is to set up some kind of black box where you put your code in and get bytecode out. Inside it does the PIR->PBC translation
later, when we get our act together, you'll be able to replace that system with something much simpler
muixirt whiteknight: thanks 20:54
whiteknight no problem. Sorry I can't be more helpful 21:03
23:35 TonyC joined