Camelia, the Perl 6 bug

IRC log for #parrot, 2009-05-26

Parrot | source cross referenced

| Channels | #parrot index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:02 bacek_ joined #parrot
00:03 darbelo Just checked. Same here.
00:04 darbelo wayland, both the installed binary and the one generated on the parrot build-dir give me the correct answer.
00:05 wayland Ok, thanks.  It must be something to do with me making it into an RPM then
00:07 Whiteknight joined #parrot
00:08 wayland rpm -qf /usr/bin/svn
00:08 wayland subversion-1.5.4-3.i386
00:08 wayland (svn software used)
00:21 tetragon_ joined #parrot
00:26 dalek decnum-dynpmcs: r62 | darbelo++ | trunk/src/pmc/decnum.pmc:
00:26 dalek decnum-dynpmcs: MULTI is no more! It has ceased to be! It's expired and gone to meet it's maker!
00:26 dalek decnum-dynpmcs: review: http://code.google.com/p/decn​um-dynpmcs/source/detail?r=62
00:34 Whiteknight darbelo++
00:36 darbelo Heh. I (re)watched 'And now for something completely different' today. I just couldn't help myself.
00:46 Whiteknight haha, that's a great one
00:46 Whiteknight Not as good as Grail or Life of Brian, but fun nonetheless
00:53 tetragon joined #parrot
00:55 tetragon_ joined #parrot
01:01 tetragon joined #parrot
01:08 patspam joined #parrot
01:36 kid51 joined #parrot
01:46 kid51 wayland ping
01:47 cotto joined #parrot
01:59 wayland Present :)
01:59 wayland (or should I say, kid51 pong :) )
01:59 Maddingue joined #parrot
01:59 mj41_ joined #parrot
01:59 dalek joined #parrot
01:59 amoc joined #parrot
01:59 kid51 wayland Read your queries about revision number on scrollback.
01:59 kid51 Feature, not bug.
01:59 wayland oh, ok
01:59 kid51 If you look at lib/Parrot/Revision.pm, you'll see that the SVN revision requires running 'svn' code.
01:59 kid51 Implies you're in your sandbox, not building from a tarball or package.
02:00 wayland ok, great
02:00 wayland Rakudo needs modification then :)
02:00 kid51 If the file DEVELOPING exists in your top-level directory, you're considered to be working directly from source, are a Parrot developer, etc.  Hence, svn rev number is of prime importance.
02:01 kid51 but if you're building from a tarball, we presume you're doing something with the Parrot executable, not trying to hack on Parrot itself.
02:01 kid51 Over past few years, we've had a tremendous amount of back-and-forth on this.  (Too much, IMHO.)
02:02 wayland No, it's all good.  It just means that Rakudo is bad :)
02:02 kid51 At one time, we had code in lib/Parrot/Revision.pm to enable SVK users to determine the revision number.
02:02 kid51 But none of our SVK users were willing to help maintain that code.
02:02 kid51 So we yanked it.
02:03 kid51 Then Linus proclaimed that everyone who didn't use git was an asshole.
02:03 kid51 So people clamored for some git code there.
02:03 kid51 And eventually some crept in.  Though, once again, it's not verified by any tests.
02:04 kid51 Net result:  The only thing we guarantee once you're building from a tarball, RPM, etc., is the Parrot version number, not the svn revision number.
02:05 kid51 If our Smolder server were working, you'd be able to observe this.
02:05 kid51 Smolder reports that come from testing tarballs display SVN rev 0.
02:05 kid51 IIRC
02:06 kid51 cf:  http://thenceforward.net/parrot/coverage/c​onfigure-build/lib-Parrot-Revision-pm.html
02:10 kid51 Also, note how tests 017 018 and 061 in t/configure/*.t are designed to work differently depending on whether you're DEVELOPING or not.
02:10 kid51 But, better still, don't worry too much about this.
02:11 wayland Exactly what I was hoping to do :o)
02:11 Andy joined #parrot
02:12 wayland Anyway, I'm being called for lunch.  Thanks for your help :)
02:27 tetragon_ joined #parrot
02:42 janus joined #parrot
02:48 Austin_Hastings joined #parrot
03:05 Infinoid kid51: I recently re-added the git code, when rakudo started refusing to build without it
03:06 Infinoid I'm not sure what the best way to test that is.  If we could somehow fake the output of "git log" and verify the number it returns, that should be sufficient
03:06 Andy hey infinvoid
03:07 Infinoid hey Andy
03:07 Andy hey Infinoid have you tried the splint lately?
03:07 Infinoid I have been unable to get spint installed on my machine, and been too busy with moving and applying for work
03:07 Infinoid it is on my list for this week, though.
03:07 Andy what is yr machine?
03:07 Infinoid gentoo/amd64
03:08 Andy and yu can't get a package installed?
03:08 Infinoid The problem is that gentoo wants to install from the source tarball, but the tarball it downloads doesn't match the MD5sum it has stored, so it thinks it's been hacked and refuses to build it.
03:08 Andy huh
03:09 Infinoid (gentoo tends to be one of the first to detect hacked tarballs on sourceforge and the like, because of this feature.  But it also has some false positives, and I don't think splint is high enough profile to be a target for malware)
03:12 Andy Did you try the tarball yrself?
03:13 Andy Infinoid: Here's what the output is looking like these days http://pastebin.com/m4404e416
03:20 Andy How do I set a default value for a variable?
03:20 Andy in a makefile?
03:20 Austin_Hastings A_default = foo
03:21 Austin_Hastings A = $(A_default$(A))$(A)
03:27 dalek decnum-dynpmcs: r63 | darbelo++ | trunk/src/pmc/decnum.pmc:
03:27 dalek decnum-dynpmcs: Add floor_divide VTABLEs.
03:27 dalek decnum-dynpmcs: review: http://code.google.com/p/decn​um-dynpmcs/source/detail?r=63
03:30 Austin_Hastings Andy: Alternatively, you could use the 'ifeq' test to set the value if it was not set. This is probably clearer, and Parrot seems to be using gnumake exclusively.
03:31 Andy Austin_Hastings: Not true.  I have to be very careful not to break the Windows make
03:31 Andy I don't get the A_default thing
03:31 Austin_Hastings Okay, consider this:
03:31 Austin_Hastings A_default=foo
03:31 Andy What I want is
03:31 Austin_Hastings That's just a setting for the default.
03:32 Andy SPLINT_TARGETS="blah blah blah" unless defined $SPLINT_TARGETS
03:32 Austin_Hastings Now $(A_default) is going to expand to "foo" always.
03:32 Andy ok
03:32 Austin_Hastings But $(A_defaultXXX) has no value.
03:32 Andy one hopes
03:32 Austin_Hastings So if I set B = XXX, I can use A_default$(B) to get A_defaultXXX
03:33 Austin_Hastings But if I set B =  (nothing), I get A_default$(B) = A_default
03:34 Austin_Hastings So when I expand A_default$(B) I either get A_defaultXXX or I get A_default
03:35 Austin_Hastings By setting A = $(A_default$(B)) I either get A = $(A_defaultXXX) (= nothing) or I get A = $(A_default) (= foo)
03:35 Austin_Hastings Actually, if you're using an unspecified make I should make that C =
03:35 Austin_Hastings C = $(A_default$(B))
03:36 Austin_Hastings So now C = (nothing) or C = foo
03:36 Austin_Hastings But I don't want C = (nothing) if the user provides a value for C. I want C = uservalue
03:37 Austin_Hastings The user value in this case is B, which is either (nothing) or XXX.
03:37 Austin_Hastings So I set C = $(B)
03:37 Austin_Hastings And I get C = XXX
03:37 Austin_Hastings But when $(B) is nothing, I want "foo"
03:37 Austin_Hastings So I set C = $(B)$(A_default$(B))
03:37 darbelo Andy, is the definition (or lack thereof) known to Configure.pl? In that case you can use #IF(condition) on the Makefile.in template. Less likely to break brain-dead makes :)
03:38 Andy darbelo: Dunno.  It's not really a big deal.
03:38 Austin_Hastings Which gets me (nothing) + foo when B = nothing, or XXX+ (nothing) when B = XXX
03:39 Andy Austin_Hastings: So it basically is just relying on the default variable not existing as expanded
03:39 Austin_Hastings The only problem is that with older makes, you can't redefine a variable in terms of itself.
03:39 Austin_Hastings Andy: Yes.
03:39 Austin_Hastings So you can't say A = $(A), etc. That's a gnu-ism.
03:40 Austin_Hastings So try something like _A = $(A) instead.
03:40 Austin_Hastings _A = $(A)$(A_default($A))
03:40 Austin_Hastings Then use _A elsewhere.
03:41 Austin_Hastings _SPLINT_TARGETS = $(SPLINT_TARGETS)$(SPLINT_TARG​ETS_default$(SPLINT_TARGETS))
03:42 darbelo I used the #IF() thing for the decnum-dynpmcs Makefile to determine the endianess of the platform.
03:42 darbelo line 16 of http://code.google.com/p/decnum-dynpmcs/source​/browse/trunk/build/src/decNumber/Makefile.in
03:43 Austin_Hastings But won't you do okay with just assigning the value in the file, and letting the user override it on the command line? Or are you looking at including another makefile?
03:43 Andy Will it get overridden if I specify on the command line?
03:44 Andy I didn't think it would
03:44 Austin_Hastings Yeah.
03:46 Austin_Hastings http://nopaste.com/p/awlxSMQtfb
03:47 Austin_Hastings That's what you're looking for, no?
03:54 Austin_Hastings ...?
03:54 purl Yada yada yada hasn't been implemented yet! (unless you run bleadperl)
04:07 Andy so no need for default! :-)
04:08 Austin_Hastings No need to put in code, if all you want to do is provide the user with a default.
04:08 Austin_Hastings If you want to provide a default to another piece of code, see above.
04:08 Austin_Hastings But the user "wins" whenever a command-line value is specified.
04:11 Andy how is the default determined?
04:11 Andy What "make" makes?
04:11 Andy with no args?
04:11 Austin_Hastings First target
04:11 purl i heard First target was probably Unicode::Collate
04:11 tetragon joined #parrot
04:12 Andy how can i tell what that is
04:13 Austin_Hastings sed?
04:13 purl sed is not a programming language its an editor. or perl jr
04:13 Andy no, I mean looking at the fil
04:13 Andy It looks like it's "all"
04:14 Andy Will my enviornment variables override what's in the makefile, too?
04:14 Andy I want to provide a $TMP if the user's env doesn't have one.
04:14 Austin_Hastings It's all.
04:14 Austin_Hastings sed -ne '/^[a-z_A-Z0-9]*[ ]*:[^=]/{p;q}' ~/parrot/Makefile
04:15 Austin_Hastings You can specify -e to force environment variables to override makefile vars.
04:15 Austin_Hastings But check to see if the current behavior isn't what you want already.
04:18 Austin_Hastings In most makes, setting TMP=/tmp will override whatever setting comes from the environment.
04:18 Austin_Hastings This is one of those cases where you might have to use the default-value hack.
04:20 darbelo cotto, ping
04:29 cotto darbelo, pong
04:31 darbelo I'm looking at the cmp VTABLE, and I was wondering if I should implement a total ordering or not. Any thoughts?
04:33 cotto Why wouldn't you?  Does the library not support that directly?
04:34 darbelo It supports both "IEEE total ordering" and "Comparing NaNs is silly"  behaviors.
04:35 darbelo Total ordering is "�NaN < �sNaN < �Infinity < �finites < �0 < +0 < +finites < +Infinity < +sNaN < +NaN"
04:36 cotto Hmm.
04:36 darbelo The other is "WTF? NaN? Bugger all, I dunno." Which I can turn into an exception easily enough.
04:37 cotto My instinct says that if NaNs are popping up, you've got bigger issues than ordering.
04:37 cotto so fail noisily
04:39 cotto but feel free to go the other way if you can imagine the more common use cases where that happens benefiting from an ordering that includes the NaNs.
04:39 * cotto wonders if that last statement could have been better phrased
04:41 * Infinoid overflows his stack and segfaults
04:41 darbelo I'll make the VTABLE throw an exception and provide a METHOD for people who want full IEEE 754 ordering.
04:42 cotto sounds like a good way to go
04:43 * cotto makes careful notes on Infinoid's vulnerability
04:44 darbelo I think "NaN? WTF?" is the default response we'll get from people. Might as well make it the software's. :)
04:45 darbelo cotto: Think the overflow is exploitable?
04:45 cotto I'll have to run some more tests
04:47 cotto Infinoid, A hundred prisoners are each locked in a room with three pirates, one of whom will walk the plank in the morning. Each prisoner has 10 bottles of wine, one of which has been poisoned; and each pirate has 12 coins, one of which is counterfeit and weighs either more or less than a genuine coin. In the room is a single switch, which the prisoner may either leave as it is, or flip. Before being led into the rooms, the prisoners are
04:47 cotto all made to wear either a red hat or a blue hat; they can see all the other prisoners' hats, but not their own. Meanwhile, a six-digit prime number of monkeys multiply until their digits reverse, then all have to get across a river using a canoe that can hold at most two monkeys at a time. But half the monkeys always lie and the other half always tell the truth. Given that the Nth prisoner knows that one of the monkeys doesn't know that
04:47 cotto a pirate doesn't know the product of two numbers between 1 and 100 without knowing that the N+1th prisoner has flipped the switch in his room or not after having determined which bottle of wine was poisoned and what colour his hat is, what is the solution to this puzzle? send cotto a check for one million dollars
04:47 * cotto waits expectantly
04:48 davidfetter cotto, 42
04:51 * cotto is not entirely disappointed
05:09 davidfetter joined #parrot
05:30 flh joined #parrot
05:49 jisom joined #parrot
05:49 dalek parrot: r39172 | petdance++ | trunk/src/call/pcc.c:
05:49 dalek parrot: consting
05:49 purl consting is a nightmare :)
05:49 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39172/
05:53 dalek parrot: r39173 | petdance++ | trunk (2 files):
05:53 dalek parrot: shimmed an interp and reran the headerizer
05:53 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39173/
05:56 dalek parrot: r39174 | petdance++ | trunk/config/gen/makefiles/root.in:
05:56 dalek parrot: The splint-andy target is now just 'splint', vs. 'splint-all' which works on the entire tree
05:56 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39174/
05:58 cotto no, consting is <reply>
05:58 purl okay, cotto.
06:02 skids joined #parrot
06:11 iblechbot joined #parrot
06:19 patspam1 joined #parrot
06:21 he__ joined #parrot
06:23 dalek parrot: r39175 | petdance++ | trunk/lib/Parrot/Pmc2c/PMCEmitter.pm:
06:23 dalek parrot: adding splint macros to the generated C code from PMCs
06:23 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39175/
06:28 flh joined #parrot
06:43 skids joined #parrot
06:56 dalek parrot: r39176 | Util++ | trunk/tools/dev/pbc_to_exe.pir:
06:56 dalek parrot: [pbc_to_exe] TT #688 - performance fixed for GCC.
06:56 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39176/
07:04 moritz Util++ # very good improvement
08:10 Ademan joined #parrot
08:15 cotto joined #parrot
08:16 cotto joined #parrot
08:17 cotto joined #parrot
08:21 Debolaz joined #parrot
08:29 Maghnus_ joined #parrot
08:34 dalek rakudo: 870bf3b | moritz++ | t/spectest.data:
08:34 dalek rakudo: fix typo in t/spectest.data, moritz--
08:34 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/8​70bf3b65392684f12ea8b42bd3cb0fd99d8e773
08:39 cotto joined #parrot
08:43 rg joined #parrot
08:44 amoc joined #parrot
08:46 cotto joined #parrot
08:51 iblechbot joined #parrot
09:01 donaldh joined #parrot
09:05 skids joined #parrot
09:37 gaz joined #parrot
09:52 moritz parrot r39132 broke rakudo's t/spec/S12-methods/indirect_notation.t
09:56 rdice joined #parrot
09:58 bacek moritz: I know...
09:58 bacek But it 30% faster with this caching.
10:02 wayland I know the fastest VM.
10:02 wayland exit(0)
10:02 wayland :)
10:04 HG` joined #parrot
10:13 jonathan bacek: Mighta been good if you'd posted to the list first saying it broke something and getting analysis on why...one test fail can point to something important but rarely exercised.
10:14 bacek jonathan: I did post. But I'm failing to understand why it's failing.
10:27 mikehh joined #parrot
10:33 HG` joined #parrot
10:45 wayland Where does socket.pasm come from?
10:45 bacek wayland: generated by Configure.pl from C enum
10:45 wayland ok
10:45 wayland Because it's not in the MANIFEST anywhere
10:45 wayland should it be?
10:46 wayland (or at least, not the manifest in SVN)
10:47 bacek no, it shouldn't (iiuc)
10:47 wayland Oh, wait, it's in MANIFEST.configure.generated or something
10:47 bacek indeed
10:49 wayland (I'm trying to make a Rakudo RPM build on a Parrot RPM, and the Parrot RPM doesn't package that file, so I'm trying to fix that)
10:50 wayland Should make install-dev be putting socket.pasm somewhere?
10:51 bacek wayland: no idea. Ask kid51 and allison
10:51 wayland ok, will do
10:52 wayland However, I've got this feeling that maybe kid51 doesn't know :).  Well, we'll see :)
11:03 riffraff joined #parrot
11:07 bacek jonathan: around?
11:10 bacek msg jonathan Looks like sometimes Object.increment and Int.succ can  fall in infinite love^W^W mutual recursive calls
11:10 purl Message for jonathan stored.
11:12 masak joined #parrot
11:13 jonathan bacek: Is that related to the method dispatch bug?
11:14 bacek jonathan: no. I just found it during investigations...
11:14 jonathan Ah, OK.
11:15 bacek Object.increment calls self.succ. Int.succ calls "inc $P0", which is VTABLE_increment and calls Object.increment
11:17 he__ joined #parrot
11:17 bacek jonathan: where is hll_global Callable defined? (in rakudo)
11:18 jonathan src/classes/Callable.pir I expect
11:20 bacek it's "Callable[::T]"
11:21 bacek and there is no "set_hll_global" in it
11:21 jonathan bacek: Oh
11:21 donaldh joined #parrot
11:21 jonathan Yes, it just sets up one factory and installs it as one of the parametric role variants.
11:22 jonathan There's various bits of code relating to that, I think see guts.pir's !create_parametric_role
11:23 bacek I'm digging guts.pir ATM trying to fix dispatch bug..
11:24 jonathan There Be Dragons. :-)
11:24 moritz There Be Spectests
11:24 jonathan Indeed.
11:24 moritz aka anti-dragons
11:24 jonathan I've had them happily catching my accidental breakage of parametric roles a couple of times.
11:25 bacek Hooray.
11:25 moritz maybe we should call them "regression tests which coincide with the specs" ;-)
11:25 bacek P6Invocation cache conflicting with my cache
11:26 jonathan P6Invocation doesn't have a cache as such.
11:26 bacek jonathan: it is.
11:26 bacek check VTABLE_invoke
11:27 jonathan bacek: It wraps the invocation, and acts iterator-ish.
11:27 bacek ouch...
11:27 jonathan That isn't going to change.
11:27 bacek no cookies for me
11:27 jonathan (As in, the need to do that.)
11:27 jonathan We can probably re-work the specifics somehow.
11:27 jonathan I'm curious how your PMCProxy caching causes issues though.
11:28 bacek I'm curious either :/
11:28 jonathan They sound fairly orthogonal to me.
11:28 jonathan Is it something in the way the P6Invocation is instantiated?
11:30 bacek It's just call "root_new [...]
11:31 jonathan OK, but the notable part is that it passes something along to init with too.
11:31 jonathan You sure there's no issues there?
11:31 jonathan (that is, we'll be calling init_pmc not just init
11:31 jonathan )
11:31 bacek of cause no... I suspect every single line of code
11:31 jonathan everything is suspect!
11:32 burmas joined #parrot
11:32 * moritz blames the whitespaces
11:33 jonathan moritz: It's not written in Python. :-P
11:33 bacek more like "brainfuck"...
11:33 jonathan (Though it amuses me that if it were, that would be a valid thing to blame. :-))
11:34 moritz actually in Perl 6 ws carries some semantics too
11:34 moritz say(1, 2), 3   vs   say (1, 2), 3
11:35 pfig joined #parrot
11:35 jonathan moritz: Yes, true. :-)
11:36 jonathan Of course, the Whitespace language wins. :-)
11:43 wayland are socket.pasm and sockets.pasm different?
11:46 contingencyplan joined #parrot
11:49 bacek jonathan: fine... Parrot's Undef clashed with Rakudo's Undef...
11:50 jonathan bacek: Oh, ouch.
11:50 jonathan bacek: And that was the only test it showed up in? D'oh.
11:50 bacek indeed...
11:50 purl indubitably
11:50 jonathan bacek++ # well found
11:50 jonathan I'm relieved it wasn't an issue with wrapping invocation.
11:51 bacek Looks like "new "Undef"; <register rakudo's Undef>; root_new "Undef"" produces wrong results..
11:52 bacek P6Invcations is fine.
11:53 bacek hmm... But may be I was wrong (as usual)
11:58 szbalint joined #parrot
12:09 wayland bacek: Do you know if socket.pasm and sockets.pasm are supposed to be the same file?
12:10 bacek wayland: lemme check
12:12 Whiteknight joined #parrot
12:16 bacek wayland: socketS.pasm is outdated and should be removed.
12:17 wayland Well, it still exists in my build from SVN :)
12:17 wayland Whereas socket.pasm doesn't get packaged
12:17 wayland anyway, thanks for the info
12:17 bacek socket.pasm is autogenerated from includes.
12:17 bacek May be there is a problem.
12:21 bacek wayland++ # For TT#705
12:22 dalek TT #705 created by bacek++: [cage] runtime/parrot/include/sockets.pasm is outdated and shoud be ...
12:22 wayland I'll work on the packaging
12:27 wayland (well, maybe I shouldn't volunteer.  I'll work on it, but I may not solve it :) )
12:35 dalek TT #706 created by mj41++: Out of mem (PASM, compreg, invokecc)
12:40 rg1 joined #parrot
12:42 Whiteknight urg, #706 looks like a doozie
12:42 bacek Whiteknight: special gift for you :)
12:45 dalek TT #705 closed by bacek++: [cage] runtime/parrot/include/sockets.pasm is outdated and shoud be ...
12:47 dalek parrot: r39177 | bacek++ | trunk (5 files):
12:47 dalek parrot: [cage] Remove obsoleted files. Closes TT#705
12:47 dalek parrot: - runtime/parrot/include/sockets.pasm
12:47 dalek parrot: - runtime/parrot/library/tcpstream.pir
12:47 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39177/
12:57 gryphon joined #parrot
12:57 wayland bacek: Just quickly, do you know which script generates socket.pasm?
12:58 bacek wayland: Configure.pl
12:58 purl i guess Configure.pl is not a spammy domain name. it's not even registered.
13:03 Whiteknight purl forget Configure.pl
13:03 purl Whiteknight: I forgot configure.pl
13:04 wayland Hmm.  I'm really trying to find where the runtime/* lines get written to MANIFEST.configure.generated
13:04 wayland Because I want to add a [library] to the end of them
13:05 wayland (it'll be one of the calls to append_configure_log, I think)
13:13 bkuhn joined #parrot
13:15 wayland Found it, don't worry :)
13:30 azawawi joined #parrot
13:37 azawawi hi
13:38 skids joined #parrot
13:44 Whiteknight hello
13:46 rakudohudson joined #parrot
13:54 patspam joined #parrot
14:06 azawawi left #parrot
14:08 Maghnus joined #parrot
14:28 dalek TT #476 reopened by doughera++: Binaries should not contain rpath
14:36 wayland Thanks for your help bacek.  'night all
15:03 Andy joined #parrot
15:18 dalek parrot: r39178 | NotFound++ | trunk/t/pmc/io.t:
15:18 dalek parrot: [tests] delete todo'ed stringhandle test in io.t, there is already a stringhandle.t file
15:18 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39178/
15:20 donaldh joined #parrot
15:27 Austin_Hastings joined #parrot
15:31 dalek TT #707 created by NotFound++: [RFC] StringHandle interface
15:33 Austin_Hastings moo
15:33 Austin_Hastings Why does dispatch hang on multi-subs ok(_,_) and ok(_,_,_)?
15:34 Austin_Hastings (dynamically loaded, in the [] namespace)
15:34 Infinoid Got a test case?
15:35 moritz that sounds like a bug to me
15:37 Austin_Hastings I'm sure it's my problem, because I modeled it on t/pmc/multispatch_44.pir
15:38 Austin_Hastings But it's irritating because I have no idea what's going on internally. :(
15:43 Austin_Hastings Here's a question: how does multi-dispatch interact with :optional params?
15:45 Austin_Hastings If I have a multi(_,_) sub, can I safely label the second param as optional? Is there some way to tell mmd that it can be 1-ary or 2-ary?
15:46 rhr joined #parrot
15:47 NotFound Austin_Hastings: Will not be cleaner to add a (_) multi?
15:48 Austin_Hastings I don't know. I'm coming at this from (_,?)
15:49 Austin_Hastings Of course, right now the optional param works and the multi doesn't, so that's a problem.
15:50 NotFound As Infinoid said: got a test case?
15:54 Austin_Hastings Nope.
16:04 Util join #parrotsketch
16:04 * Util sighs
16:05 NotFound Thanks, I copy&paste it
16:06 * moritz too
16:06 moritz though I don't know if I'll be around
16:06 moritz and if, I won't have a report
16:09 * Infinoid finds himself asking, once again, "did I do anything for parrot this week?"
16:10 NotFound Ask Uncle Sam
16:10 Austin_Hastings #$P55 = iseq $P53, $P54
16:11 Austin_Hastings That's my test case - uncommenting it causes load_bytecode to (apparently) hang when loading a pir file.
16:11 Infinoid Running it with "parrot -t" will tell you what the classes of P53 and P54 were, which may help
16:12 Austin_Hastings Umm, since it's loading, not executing, do they even have classes?
16:12 Infinoid Are you saying it fails at parse-time rather than run-time?
16:12 NotFound load_bytecode can execute things
16:13 Infinoid ah, yes
16:13 Austin_Hastings Nope. I'm saying it appears to hang when I load_bytecode a .pir file.
16:13 NotFound Lots of things, in fact
16:13 NotFound Even more things if is a pir file X-)
16:17 Austin_Hastings Aha
16:17 Austin_Hastings Thanks, NotFound.
16:17 Infinoid so anyway, iseq calls VTABLE_is_equal, so knowing which class it is calling is crucial to figure out how that vtable is implemented for that data type
16:17 Austin_Hastings Trying to compile produces the culprit: The opcode 'iseq_p_p_p' (iseq<3>) was not found.
16:18 Infinoid Okay.  Try assigning the result to an integer register, rather than a PMC register
16:18 NotFound Uh, that's another problem. Parsing problems when load_bytecode a pir are not catched.
16:18 Austin_Hastings Already there.
16:18 purl that was quick.
16:19 NotFound Well, almost any problem, in fact.
16:20 Austin_Hastings Plus, pir parsing problems produce poor performance.
16:20 Infinoid "failing to run" makes "poor performance" a bit of an understatement :)
16:20 flh joined #parrot
16:20 NotFound Hanging forever is very poor performance, certainly X-)
16:20 moritz writing a different PIR compiler would be a nice contribution ;-)
16:20 Austin_Hastings I wouldn't mind "failing to run"
16:20 Austin_Hastings It's "going to sleep for a long time and not responding" that gets me perplexed.
16:20 NotFound moritz: another one?
16:21 moritz NotFound: one that actually replaces IMCC
16:21 NotFound moritz: pirc is supposed to be that.
16:21 moritz NotFound: yes. And it does not.
16:22 moritz NotFound: at least not right now, and I didn't see any work on it for quite some time
16:22 NotFound moritz: starting write another one that also deoesn't is not a goo solution.
16:22 Infinoid Austin_Hastings: It might just be that your pir's init code is doing something in a loop, and your commenting out the check just means the condition is never met and the loop keeps looping.  I think parrot -t should help to determine that
16:22 moritz NotFound: I don't mind how its done, as long as it gets done, and the result is more maintainable than imcc.
16:23 NotFound We can write one in pir
16:23 NotFound Surely will be more maintainable than imcc and pirc
16:23 Austin_Hastings Infinoid: Nope. That *was* the check. I'm trying to implement ok(...)
16:23 NotFound pir/nqp/pct/whatever
16:24 Infinoid Austin_Hastings: Can you nopaste the full pir file?  (Sorry if you've already done so, I must have missed it.)
16:24 Infinoid purl, nopaste?
16:24 purl rumour has it nopaste is at http://nopaste.snit.ch/ (ask TonyC for new channels) or http://rafb.net/paste or http://poundperl.pastebin.com/ or http://paste.scsys.co.uk/ or App::Nopaste or tools/dev/nopaste.pl or at http://www.extpaste.com/ or http://paste.scsys.co.uk (for #catalyst, #dbix-class, #moose  and others)
16:26 NotFound rafb.net/paste has been discontinued
16:29 Austin_Hastings http://nopaste.com/p/afPE8SM7Z
16:29 Austin_Hastings (Sorry, had to break it and fix it again.)
16:31 pmichaud good morning/afternoon #parrot
16:31 Austin_Hastings morning, pm
16:31 NotFound Can we tell purl to forget only a part?
16:31 moritz I think it supports s/// somehow
16:32 NotFound purl: do what I mean
16:32 purl wish i knew, notfound
16:32 moritz purl: nopaste =~ s/http:..rafb.net.paste//
16:32 purl That doesn't contain 'http:..rafb.net.paste'
16:32 moritz purl: nopaste =~ s{http://rafb.net/paste}{}
16:32 purl OK, moritz
16:32 moritz nopaste?
16:32 clunker3 http://pasta.test-smoke.org/ or http://paste.husk.org/ or http://nopaste.snit.ch:8001/ or http://rafb.net/paste or http://poundperl.pastebin.com/ or http://paste.scsys.co.uk/
16:32 purl nopaste is probably at http://nopaste.snit.ch/ (ask TonyC for new channels) or  or http://poundperl.pastebin.com/ or http://paste.scsys.co.uk/ or App::Nopaste or tools/dev/nopaste.pl or at http://www.extpaste.com/ or http://paste.scsys.co.uk (for #catalyst, #dbix-class, #moose  and others)
16:33 moritz purl: nopaste =~ s{or  or}{or}
16:33 purl OK, moritz
16:33 moritz nopaste?
16:33 clunker3 http://pasta.test-smoke.org/ or http://paste.husk.org/ or http://nopaste.snit.ch:8001/ or http://rafb.net/paste or http://poundperl.pastebin.com/ or http://paste.scsys.co.uk/
16:33 purl it has been said that nopaste is at http://nopaste.snit.ch/ (ask TonyC for new channels) or http://poundperl.pastebin.com/ or http://paste.scsys.co.uk/ or App::Nopaste or tools/dev/nopaste.pl or at http://www.extpaste.com/ or http://paste.scsys.co.uk (for #catalyst, #dbix-class, #moose  and others)
16:33 moritz afk
16:33 NotFound Now tell to clunker3, for extra bonus ;)
16:33 nopaste "mj41" at 147.229.5.176 pasted "Segmentatio fault on PGE compiling on new TapTinder client (i386-redhat-linux on vmware). http://ttcopy.ro.vutbr.cz:4000/​buildstatus/pr-Parrot/rp-trunk" (43 lines) at http://nopaste.snit.ch/16667
16:39 davidfetter joined #parrot
16:39 dalek rakudo: 6953001 | pmichaud++ | docs/spectest-progress.csv:
16:39 dalek rakudo: spectest-progress.csv update: 394 files, 11343 passing, 0 failing
16:39 dalek rakudo: review: http://github.com/rakudo/rakudo/commit/6​95300177166915cba179726673c6d24abaed0f7
16:44 Infinoid Austin_Hastings: Your code seems to work fine here
16:45 nopaste "Infinoid" at 75.31.91.80 pasted "A pir file which loads Austin_Hastings's pir file and uses it (successfully)" (9 lines) at http://nopaste.snit.ch/16668
16:47 nopaste "Infinoid" at 75.31.91.80 pasted "The output I get when I run the previous nopaste" (8 lines) at http://nopaste.snit.ch/16669
16:50 Austin_Hastings Works fine here, too. It was the assignment into a $P instead of $I that messed everything up.
16:50 Austin_Hastings Thank you for checking it.
16:53 Austin_Hastings Flush with that success, I believe I'll go eat lunch. Later, #parrot.
16:54 Austin_Hastings left #parrot
16:55 rdice left #parrot
17:07 Theory joined #parrot
17:08 acajou joined #parrot
17:09 acajou left #parrot
17:21 dalek TT #561 reopened by coke++: What are valid characteristics for 'inspect_str' vtable?
17:27 darbelo joined #parrot
17:30 rob joined #parrot
17:32 ruoso joined #parrot
17:48 dalek TT #708 created by Util++: Trac ticket report {8} (Active Tickets, Mine first) does not work as ...
18:05 dalek TT #708 closed by Util++: Trac ticket report {8} (Active Tickets, Mine first) does not work as ...
18:10 whoppix joined #parrot
18:12 Whiteknight bacek: ping
18:13 Whiteknight purl msg bacek can you take a look at TT #68? I think one of your commits earlier today may have resolved it.
18:13 purl Message for bacek stored.
18:13 Infinoid I've gotta go now; I pre-posted my #ps report
18:13 Whiteknight Infinoid++
18:14 Util jonathan, and other Win32 testers: is there an known issue with PASM using `print` or `say` to output huge strings to the console?
18:15 Util I have a simple test case that prints a huge string and then prints a short string. Only the short string appears in the CMD session. Redirecting to a file causes all the output to show up correctly. Running the test on non-Win32 also causes all the output to show up correctly.
18:15 Whiteknight Util: How large is the "huge" string?
18:16 Util 1MB certainly. In playing with it, I got it to trigger at around 54000 bytes, but that might vary per revision.
18:16 Whiteknight hmm, that's weird
18:16 Util If this does not ring a bell for anyone, I will create a ticket.
18:17 Whiteknight I've certainly never heard about anything like that
18:17 Whiteknight I wonder if it's a Parrot problem or a Windows problem? Can you output huge strings like that from other programs?
18:18 NotFound Util: can you nopaste the test case?
18:19 chromatic joined #parrot
18:20 barney joined #parrot
18:21 Util NotFound: yes, working...
18:21 purl i guess working is a good approximation.
18:22 Util Whiteknight: Perl 5 works as expected printing 1MB to console: perl -e "$_ = 'abcdefgh' x (1024*1024/8); print;"
18:25 nopaste "Util" at 68.191.99.24 pasted "Win32 huge string PASM test case" (9 lines) at http://nopaste.snit.ch/16670
18:27 pmichaud #parrotsketch in 3
18:28 pmichaud Util: does it fail just in printing the string or is the length also incorrect?
18:29 Whiteknight I can imagine that a huge string printed all at once would overflow the DOS text buffer
18:29 Whiteknight I wonder if the Perl executable breaks huge strings like that up into smaller chunks
18:30 Util pmichaud: length is correct
18:30 NotFound DOS? We are in 2009, aren't we?
18:31 Whiteknight the Win32 command prompt
18:31 Util My OS is Win2000, so... not completely, NotFound!
18:31 Whiteknight I call it DOS, because it's about as modern a tool, and just as robust
18:33 NotFound But the buffer lives in the Win32 console subsystem, not in cmd, command.com, or whateer
18:33 Whiteknight #ps
18:34 NotFound Util: he's still learning to sing 'Daisy, Daisy'?
18:37 Whiteknight What's the status of the other GSOC project? I haven't heard anything about it in a while
18:37 darbelo There was another GSoC project?
18:37 Whiteknight yeah, I thought there was
18:38 Whiteknight the LLVM one
18:38 moritz seen tewk
18:38 purl tewk was last seen on #parrot 6 days, 16 hours, 49 minutes and 47 seconds ago, saying: Infinoid: great, thanks, I don't want to butt in,  you can run with it.  If you need me to do anything let me know.  [May 20 01:45:02 2009]
18:38 Util NotFound: heh. Win2K does all I need. All the newer OSes add is singing "Slowly, Slowly, Upgrade and give Me your Cash..."
18:39 NotFound Util: hey, I have win xp home ;)
18:45 NotFound WriteFile fails with the huge string
18:51 particle joined #parrot
18:56 Util NotFound: Aha! In src/io/win32.c, sub Parrot_io_write_win32 calls WriteFile(), and fails silently on error. It is marked with FIXME.
18:56 NotFound I still don't find what is the error.
18:57 chromatic Windows hates you and has a plan for your data.
18:58 dalek TT #709 created by whiteknight++: Pmc2c should generate mark and destroy VTABLES
19:00 NotFound Soemone has in memory what is error 8 in win32?
19:03 NotFound ERROR_NOT_ENOUGH_MEMORY
19:04 Whiteknight ah, so it is a buffer problem
19:05 dalek parrot: r39179 | whiteknight++ | trunk/DEPRECATED.pod:
19:05 dalek parrot: [DEPRECATED] Add branch_cs opcode to the list, per TT #470
19:05 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39179/
19:08 Util NotFound, Whiteknight: from MSDN: "The WriteFile function may fail with ERROR_INVALID_USER_BUFFER or ERROR_NOT_ENOUGH_MEMORY whenever there are too many outstanding asynchronous I/O requests."
19:09 Whiteknight Util, but you're only making one request, just a very large request
19:09 Util Whiteknight: Oh, right.
19:10 iblechbot joined #parrot
19:10 rdice joined #parrot
19:14 ZuLuuuuuu joined #parrot
19:20 donaldh joined #parrot
19:24 barney joined #parrot
19:26 Whiteknight Infinoid: I'm planning lots of work in PDD22-world too, we should collaborate
19:26 Infinoid Sounds good, please keep me in the loop and I'll do the same
19:27 Whiteknight I've definitely got a Select PMC in the works, although I was probably going to name it something like "Listener" or something
19:30 dalek parrot: r39180 | chromatic++ | trunk/src/pmc (2 files):
19:30 dalek parrot: [PMC] Replaced some unnecessary calloc() calls with regular malloc() calls.
19:30 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39180/
19:33 Theory joined #parrot
19:33 Infinoid pmichaud: PVMW?  Parrot Very Much Works?
19:33 Whiteknight PVM Workshop
19:33 Infinoid ah, cool
19:33 Whiteknight it's the weekend before YAPC::NA
19:33 pmichaud PVWM is the Parrot Virtual Machine Workshop at YAPC::NA 2009
19:34 Theory joined #parrot
19:35 Topic for #parrotis now Parrot 1.2.0 released | http://parrot.org/ | 304 RTs left | Weekly Priority: Profiling
19:38 whoppix joined #parrot
19:40 particle- no, PVMW is the Parrot Virtual Machine Workshop at YAPC::NA 2009
19:40 szbalint damn I really need a diffscript on topics
19:40 szbalint I never know what changed :Ö
19:40 szbalint :)
19:40 * particle- guesses weekly priority
19:40 szbalint yeah
19:46 fperrad joined #parrot
19:52 Util szbalint: See http://irclog.perlgeek.de/p​arrot/2009-05-24#i_1170927 ; it was the previous topic update
19:53 Util szbalint: Oops! I mean http://irclog.perlgeek.de/p​arrot/2009-05-25#i_1171767
19:54 dalek lua: 5b5682d | fperrad++ | t/io.t:
19:54 dalek lua: add a test of io.popen (mode write)
19:54 dalek lua: review: http://github.com/fperrad/lua/commit/5b​5682d04ff75e4dcbf33e81c46ec886c7187992
19:54 szbalint Util: yeah, I just scrolled back in my scrollback buffer of this screened irssi, but that's already too much effort for a simple problem like this :)
19:55 eternaleye joined #parrot
19:55 Util grep the auto-log that irssi saves (if you have it turned on)
19:55 NotFound Util: docs also suggest ERROR_NOT_ENOUGH_QUOTA, buy I don't think that may happan on console, or that can be solved by retrying.
19:57 szbalint /lastlog topic is faster
20:01 NotFound Util: have you opened a ticket?
20:01 Util szbalint: cool!
20:02 Util NotFound: Not yet. About 10 minutes, or have you found an existing ticket?
20:02 NotFound Util: No. I just want one to mention in my attempt of fox.
20:02 NotFound fix
20:03 Util Ticketing...
20:03 purl it has been said that ticketing is such a subjective application though.
20:04 Whiteknight purl forget ticketing
20:04 purl Whiteknight: I forgot ticketing
20:06 HG` joined #parrot
20:12 Austin_Hastings joined #parrot
20:13 jonathan Util: Don't remember a bug along those lines, or at least don't rmemeber seeing one.
20:13 Tene pmichaud: ping
20:14 NotFound I don't think there is a lot of people wishing to write hundred of thousands of charecter to console in one shot ;)
20:15 particle- $ yes 'parrot rocks!'
20:15 Util NotFound: ticket accomplished :)
20:16 Austin_Hastings Question for anyone more knowledgeable than me:   Is it meaningful to say ":multi" with no args? If so, what does it mean?
20:17 dalek TT #710 created by Util++: IO - On Win32, huge strings printed by Parrot do not appear in the console ...
20:17 Util NotFound: Actually, this bug tripped me up badly while trying to write the MSVC part of the pbc_to_exe bugfix.
20:17 Util jonathan: thanks!
20:22 jonathan Austin_Hastings: You can legitimately have a multi-variant of arity 0.
20:23 jonathan Austin_Hastings: Taking Perl 6 syntax: multi foo() { }; multi foo($a) { }; # arity 0 vs arity 1
20:23 Austin_Hastings jonathan: So that would be :multi and not :multi(), or is either form okay?
20:23 jonathan I think :multi()
20:23 jonathan I've never seen/used :multi
20:23 Austin_Hastings Okay. Thanks!
20:23 Austin_Hastings I used it for the first time earlier today, with predictable results. :(
20:24 jonathan BTW, don't follow what Rakudo emits in terms of multis.
20:24 Austin_Hastings Okay. Why not?
20:24 jonathan Because it doesn't use :multi(T1,T2,T3) style syntax to declare the variants, but instead works off Perl 6 signature objects.
20:25 Austin_Hastings Hmm. So it works by just taking a single parameter, or is there some other hackery being done?
20:25 jonathan Other hackery.
20:25 japhb joined #parrot
20:26 jonathan We emit :multi() to get Parrot aware they are multis, but instead bless them into Perl6MultiSub, which is a subclass of Parrot's MultiSub.
20:26 dalek parrot: r39181 | NotFound++ | trunk/src/io/win32.c:
20:26 dalek parrot: [IO] On Win32, retry failed write of big size in smallest chunks on some conditions, TT #710
20:26 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39181/
20:26 Austin_Hastings Gotcha. I'll be sure and not do that. :)
20:26 jonathan And it calls .signature on the candidates etc.
20:26 jonathan Sure, just wanted to flag it up so you don't go look at Rakudo and come away thinking, "huh, wtf" :-)
20:27 Austin_Hastings Oh. Well, that happens a couple of times a day.
20:27 pmichaud Tene: pong
20:27 jonathan Couple is better than a few ;-)
20:27 Austin_Hastings :-/
20:28 japhb_ joined #parrot
20:33 Tene pmichaud: looks like the right place for a 'parrot' compiler would be runtime/parrot/languages/parrot/parrot.pir, do you agree?
20:33 Tene That's where "load_lang 'parrot'" looks, at least.
20:35 pmichaud Tene: Sure.  Although I somewhat expect the 'parrot' compiler to be loaded "for free" when loading PCT.
20:36 Tene OK.
21:12 particle1 joined #parrot
21:13 dalek parrot: r39182 | chromatic++ | trunk/config/gen/makefiles/root.in:
21:13 dalek parrot: [config] Added Makefile dependencies on config.h for STRING encoding system;
21:13 dalek parrot: this helps pick up ICU configuration changes in the #defines there.
21:13 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39182/
21:13 dalek parrot: r39183 | chromatic++ | trunk/src/pmc/retcontinuation.pmc:
21:13 dalek parrot: [PMC] Replaced an unnecessary calloc() with a regular malloc().
21:13 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39183/
21:13 dalek parrot: r39184 | chromatic++ | trunk/src/pmc/sub.pmc:
21:13 dalek parrot: [PMC] Removed vestigial and bit-rotted code.
21:13 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39184/
21:13 dalek parrot: r39185 | chromatic++ | trunk/src/pmc/object.pmc:
21:13 dalek parrot: [OO] Reduced the amount of work required to get an attribute's index in the
21:13 dalek parrot: Object PMC.  This is a modest optimization (measurable, but not huge).
21:13 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39185/
21:31 bacek joined #parrot
21:43 Whiteknight joined #parrot
22:03 dalek decnum-dynpmcs: r64 | darbelo++ | trunk/src/pmc/decnum.pmc:
22:03 dalek decnum-dynpmcs: Implement cmp VTABLE.
22:04 dalek decnum-dynpmcs: review: http://code.google.com/p/decn​um-dynpmcs/source/detail?r=64
22:09 dolmen joined #parrot
22:09 janus may i request a system install mode? having either /parrot in the prefix or adding it everywhere below prefix makes me patch like a monkey :/
22:09 janus or i did miss a new button
22:10 darbelo janus: system install? what do you mean?
22:10 janus i want parrot installed like everything else
22:11 janus i don't want a versioned install path
22:12 janus maybe there is a switch or option i havent found yet...
22:12 janus but on my patch way through the configure scripts i didn't see any
22:12 janus (yet?)
22:12 NotFound janus: if you want parrot, parrot_config et al to be available in PATH, just change your PATH, or use --prefix=/usr for example
22:13 darbelo The default configuration puts parrot on /usr/local/. and the binaries are in /usr/local/bin/ like everything else.
22:13 dalek parrot: r39186 | chromatic++ | trunk/src/list.c:
22:13 dalek parrot: [src] Tidied code; no functional changes.
22:13 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39186/
22:14 NotFound darbelo: not everything else in this world, just gnu/autotools convention
22:14 janus hmmm, let me recheck.  when i regenerated the packaging list i got massive of /parrot-1.2.0 showing up
22:15 janus *ouch*
22:15 janus --prefix is missing, i wonder that didn't hit me before
22:15 janus sorry for the (premature) noise and thanks for the fish ;)
22:17 darbelo You might have seen the  shared libraries and headers. Those *do* go to versioned dirs.
22:18 darbelo And parrot is not the only one doing this:
22:19 darbelo $ ls -l `which python`
22:19 darbelo lrwxr-xr-x  1 root  wheel  24 May 12 15:07 /usr/local/bin/python -> /usr/local/bin/python2.5
22:19 janus hmm
22:19 janus +lib/pkgconfig/parrot/1.2.0/parrot.pc
22:19 janus what?!
22:20 cotto chromatic++ for making Parrot nicer to look at
22:22 janus i wonder how that will work... pkg-config parrot/1.2.0/parrot.pc --libs?
22:23 janus previously in lib/pkgconfig/parrot.pc, which is the location everything else uses
22:24 darbelo NotFound: Actually OpenBSD convention: /usr/bin is reserved to utilities shipped with the base system. Packages/ports get thrown to /usr/local/bin
22:25 janus darbelo: who cares if he can tweak/change it? ;)
22:27 janus here's the complete packaging list diff: http://pastebin.com/m9d13fe0
22:28 janus (from 0.9.0.1 to 1.2.0)
22:30 skids joined #parrot
22:32 NotFound darbelo: well, there are more systems with the same conventions. The point is that is not universal posix or unix.
22:38 darbelo Oh. Sorry. When I said that parrot went into /usr/local "Same as everything else" I meant "Same as everything else on my system" which is what I thought janus was asking.
22:39 darbelo I'm pretty sure Windows doesn't install stuff into /usr/local :)
22:41 jonathan Huh? What's /usr/local? ;-)
22:42 Whiteknight Infinoid: ping
22:49 janus NotFound: it wasn't the missing --prefix
22:52 janus a mix of overriding VERSION_DIR via make flags and patched tools/dev/install_files.pl should get me back to the previous location; diff when it DWIM
22:54 janus http://pastebin.com/m3bc03d22 + VERSION_DIR="/parrot"
22:58 janus sigh, yes... i could have checked current svn first
22:59 janus seems my issue is already obsolete
23:20 donaldh joined #parrot
23:24 eternaleye joined #parrot
23:26 chromatic c'mon dalek....
23:27 dalek parrot: r39187 | chromatic++ | trunk/docs/book/ch03_pir.pod:
23:27 dalek parrot: [book] Edited second third of this chapter.  I added some editorial comments
23:27 dalek parrot: and concerns.
23:27 dalek parrot: review: https://trac.parrot.org/parrot/changeset/39187/
23:36 Infinoid Whiteknight: faint-pong
23:37 Whiteknight Infinoid: I want to get a branch going to start refactoring IO PMCs
23:38 Whiteknight Maybe we should put together a little task list first, so we don't step on each other's toes?
23:38 Infinoid Okay
23:39 Infinoid I was meaning to put together a proposal tonight, but I can see about throwing a quick version of it up on the wiki
23:39 Whiteknight The big things on the agenda are (1) to refactor the PMCs to inherit common stuff, and (2) to change the IO API to not use PCCINVOKE method calls
23:39 Whiteknight and I think we can get those changes made by the end of the week
23:40 Infinoid Does that mean all API functions will be vtables?
23:40 Whiteknight well, either that or GET_ATTR/SET_ATTR kinds of calls
23:40 * Infinoid is thinking about connect(), listen(), bind() for Socket, and reader() and writer() for Pipe
23:40 Whiteknight er, PARROT_IOHANDLE()
23:41 Whiteknight we break a little encapsulation for big performance gains
23:41 Infinoid Can you declare vtable functions in pir subclasses?
23:42 * Infinoid doesn't care about MULTI, but he does want subclasses (eventually)
23:42 Whiteknight yeah, with the :vtable flag
23:42 Infinoid great, that will be fine then
23:42 Whiteknight the way to get PIR subclasses working is to have all ATTRs be inheritable, so STRING*, PMC*, INTVAL, and FLOATVAL only
23:43 Whiteknight if we can make that happen, inheritance will flow from it
23:43 Infinoid Sockaddr will be a bit weird in that regard, but it's not an IO subclass (just some data used by some of the Socket API)
23:43 Whiteknight Right, sockaddr probably won't be subclassable
23:43 Infinoid one subclass of Sockaddr for each socket address family, and set_string_native to parse the address from strings, will work fine
23:44 Whiteknight Right, but those subclasses can be defined in C, not PIR
23:44 Infinoid well, SockaddrInet, SockaddrInet6, SockaddrTipc, SockaddrIPX, SockaddrUnix, etc
23:44 Infinoid yeah
23:44 Whiteknight https://trac.parrot.org/parrot/wiki/IOTasklist  <--- The page we can use for planning
23:44 Infinoid ah, great.  I was already halfway to creating a similar page with a capital L :)
23:45 Infinoid so what's this you were saying about select() being part of the AIO work?
23:46 Infinoid On win32, select() only works with sockets, not with files or terminals.  That's been bugging me a lot
23:47 Whiteknight Infinoid: On Win32 I was thinking about using IO Completion Ports, which do similar stuff but work with all IO handle types
23:47 Infinoid Which is awesome.  I wouldn't mind abstracting select() on top of that kind of system
23:48 Infinoid though I suppose poll()'s API is a little closer
23:48 Whiteknight I've been planning an "IOScheduler" or "IOListener" type of PMC that would integrate with the scheduler
23:48 Whiteknight so we add handles to it that we want to monitor, and poll them every time the scheduler runs
23:49 Infinoid hmm, ok.  the Select interface I was thinking of is basically identical to perl5's IO::Select, if you're familiar with that
23:49 Whiteknight Yeah, I am
23:49 Infinoid but as long as the functionality is there, I don't care what it looks like
23:49 Infinoid Your implementation sounds like it would meet my needs very well
23:49 Whiteknight I've been sort of trying to avoid syntax that is so closely tied to Perl, but if there is a lot of pressure to not do that, I won't bother
23:50 Infinoid well, I guess the important part is to make it easy to use from PIR
23:50 Whiteknight right
23:51 Whiteknight How did Pipes get implemented, as a FileHandle or something separate?
23:51 Infinoid it's currently a FileHandle, which I intend to fix
23:51 Whiteknight okay, awesome
23:52 Infinoid There are two things we want to call Pipes, though.  NotFound++'s nice work is to open shell commands as pipes, which is the implicit way
23:52 Whiteknight I've been thinking that it was an awkward fit to force them into the FileHandle PMC
23:52 Infinoid I also want the explicit IO::Pipe style, where you create a pair of Handles and then call methods to get the reader Handle and writer Handle
23:52 Infinoid I want to convert the implicit stuff to use the Pipe object internally.
23:53 Infinoid so it would create a Pipe, fork off and dup2() the writer to stdout and execute the command, and return the reader Handle
23:53 Infinoid or whatever.
23:53 Infinoid I've been moving all day, so I haven't had a chance to write any of this down yet
23:54 Infinoid (let alone *do* any of it :))
23:55 tetragon joined #parrot
23:57 Infinoid is it worth trying to mark the various Handle subclasses so they can does(seek) or does(connected) or whatever?  (is it "does" or "has" or what?  I'm not familiar with the notation.)
23:58 Infinoid Other than some special cases like http client classes that support resumes and chunked encoding, FileHandles are pretty much the only thing that can seek().  But I'm not sure how hard it is to tell the rest of parrot about that (or whether it's worth it)
23:59 Whiteknight Using roles for that kind of stuff is an interesting idea
23:59 Whiteknight I don't really know what the current state of the code is in respect to roles

| Channels | #parrot index | Today | | Search | Google Search | Plain-Text | summary

Parrot | source cross referenced