Camelia, the Perl 6 bug

IRC log for #parrot, 2011-07-28

Parrot | source cross referenced

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

All times shown according to UTC.

Time Nick Message
00:05 kid51 left #parrot
00:07 dmalcolm left #parrot
00:25 theory joined #parrot
00:35 jsut_ joined #parrot
00:40 jsut left #parrot
00:49 theory left #parrot
00:53 kid51 joined #parrot
00:57 soh_cah_toa joined #parrot
01:14 bacek_at_work left #parrot
01:16 aloha left #parrot
01:23 soh_cah_toa is there a way i can preserve a numbers base in pir? say i have $I0 = 0o755. when i print $I0 i get 493 instead, it's decimal representation. pretty much, i want to print an octal number
01:25 bacek_at_work joined #parrot
01:26 aloha joined #parrot
01:43 RobertLJ joined #parrot
01:44 Kulag left #parrot
01:44 Kulag joined #parrot
01:46 whiteknight sprintf("%o") ?
01:47 * soh_cah_toa looks
01:49 whiteknight left #parrot
02:01 Kulag left #parrot
02:02 Kulag joined #parrot
02:13 soh_cah_toa left #parrot
02:15 Drossel joined #parrot
02:17 Kulag left #parrot
02:20 dalek parrot: 358549e | jkeenan++ | Configure.pl:
02:20 dalek parrot: Remove import of Data::Dumper.
02:20 dalek parrot: review: https://github.com/parrot/parrot/commit/358549ee57
02:26 kid51 left #parrot
02:42 woosley joined #parrot
02:42 RobertLJ1 joined #parrot
02:47 RobertLJ left #parrot
02:47 preflex joined #parrot
02:51 preflex_ left #parrot
02:52 dalek rakudo/nom: 5bfd327 | Coke++ | t/spectest.data:
02:52 dalek rakudo/nom: track more test error status, reclaim some files.
02:52 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5bfd327510
02:59 soh_cah_toa joined #parrot
03:05 woosley1 joined #parrot
03:07 woosley left #parrot
03:08 RobertLJ1 left #parrot
03:11 woosley1 left #parrot
03:16 woosley joined #parrot
04:02 dalek left #parrot
04:03 dalek joined #parrot
04:14 cotto ~~
04:17 davidfetter joined #parrot
04:18 dalek parrot: 62e830a | soh_cah_toa++ | runtime/parrot/library/osutils.pir:
04:18 dalek parrot: Added :named('verbose') argument to chmod() in osutils.pir.
04:18 dalek parrot: review: https://github.com/parrot/parrot/commit/62e830aeef
04:18 dalek parrot: 171eb16 | soh_cah_toa++ | runtime/parrot/library/osutils.pir:
04:18 dalek parrot: Added perldoc for the install() function in osutils.pir.
04:18 dalek parrot: review: https://github.com/parrot/parrot/commit/171eb16380
04:46 plobsing ~~
05:25 plobsing msg whiteknight great work on the :tag business so far. I think we can do better than a linear scan of string equality test over all tag-sub pairs.
05:25 aloha OK. I'll deliver the message.
05:26 soh_cah_toa left #parrot
05:27 plobsing msg whiteknight we could reduce the number of entries to be scanned by either mandating a single entry per tag (internal, not necessarily as exposed by PIR) or by using a 2-level index
05:27 aloha OK. I'll deliver the message.
05:28 plobsing msg whiteknight we could improve O(n) performance to O(log(n)) by sorting (at compile time) and using a binary search
05:28 aloha OK. I'll deliver the message.
05:31 woosley1 joined #parrot
05:33 woosley left #parrot
06:07 Drossel left #parrot
06:07 Kulag joined #parrot
06:14 Drossel joined #parrot
06:14 Kulag left #parrot
06:30 Drossel left #parrot
06:30 Kulag joined #parrot
06:31 fperrad joined #parrot
06:35 dalek rakudo/nom: 6383a6d | jonathan++ | src/core/IO.pm:
06:35 dalek rakudo/nom: Implement &prompt.
06:35 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6383a6d1ad
06:36 daniel-s joined #parrot
06:39 TiMBuS left #parrot
06:59 AzureSto_ joined #parrot
07:01 AzureStone left #parrot
07:13 mj41 joined #parrot
07:16 TiMBuS joined #parrot
07:46 davidfetter left #parrot
08:59 dalek parrot/m0-prototype: 7b03c58 | cotto++ | / (2 files):
08:59 dalek parrot/m0-prototype: add a basic metadata test + assembler support (test fails)
08:59 dalek parrot/m0-prototype: review: https://github.com/parrot/parrot/commit/7b03c58588
08:59 dalek parrot/m0-prototype: 1eb0f8c | cotto++ | src/m0/perl5/m0_assembler.pl:
08:59 dalek parrot/m0-prototype: fix metadata segment generation, all tests pass again
08:59 dalek parrot/m0-prototype: review: https://github.com/parrot/parrot/commit/1eb0f8c24e
09:24 dalek rakudo/nom: 09c8fab | moritz++ | src/core/ (3 files):
09:24 dalek rakudo/nom: add :D constraints to invocants of Str/Int/Num methods
09:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/09c8fab094
09:51 woosley1 left #parrot
09:55 dalek nqp: f68aa56 | moritz++ | src/6model/reprs/P6opaque.c:
09:55 dalek nqp: [P6opaque] guard against unboxing type object, a common-ish cause for segfaults in rakudo/nom
09:55 dalek nqp: review: https://github.com/perl6/nqp/commit/f68aa566a3
10:39 daniel-s left #parrot
10:46 preflex_ joined #parrot
10:50 preflex left #parrot
10:52 ambs joined #parrot
11:09 contingencyplan left #parrot
11:44 daniel-s joined #parrot
11:51 atrodo =~
11:59 particle1 joined #parrot
12:03 whiteknight joined #parrot
12:03 particle left #parrot
12:05 whiteknight good morning, #parrot
12:09 whiteknight msg plobsing the :tag search only does linear string comparions until we find the index of the target string. It's unique since IMCC de-dups at compile time. After we find the index, it's an integer comparison. A compile-time sort and binary search would be a big improvement, yes
12:09 aloha OK. I'll deliver the message.
12:12 mikehh left #parrot
12:27 dalek rakudo/nom: c2307d4 | moritz++ | / (8 files):
12:27 dalek rakudo/nom: routines that unbox to native types or access attributes need :D in their signature.
12:27 dalek rakudo/nom:
12:27 dalek rakudo/nom: Also bump NQP_REVISION to get error checking when unboxing type objects
12:28 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c2307d4616
12:28 fperrad left #parrot
12:35 preflex joined #parrot
12:40 preflex_ left #parrot
12:45 dalek rakudo/nom: c087c52 | moritz++ | src/core/ (4 files):
12:45 dalek rakudo/nom: fix syntax error in previous commit, moritz--
12:45 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c087c529be
12:55 dalek rakudo/nom: f3d1b8f | kboga++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Implemented @*INC.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/f3d1b8f9f2
12:55 dalek rakudo/nom: 496ec52 | kboga++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Implement $*PID.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/496ec525ca
12:55 dalek rakudo/nom: 2708593 | kboga++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Implement $*VM and clean up @*INC.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2708593681
12:55 dalek rakudo/nom: eba4254 | kboga++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Implement $*OS and $*OSVER.
12:55 dalek rakudo/nom:
12:55 dalek rakudo/nom: Note: they get their info from $*VM<config> instead of the sysinfo dynop like master.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/eba4254587
12:55 dalek rakudo/nom: fde5bfd | kboga++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Implement $*EXECUTABLE_NAME.
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/fde5bfdac3
12:55 dalek rakudo/nom: 241faa2 | moritz++ | src/core/terms.pm:
12:55 dalek rakudo/nom: Merge pull request #30 from kboga/special-vars
12:55 dalek rakudo/nom:
12:55 dalek rakudo/nom: Special vars
12:55 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/241faa2d4b
13:00 bluescreen joined #parrot
13:18 bubaflub joined #parrot
13:19 dalek NQR: 336feda | (Jay Emerson)++ | README.pod:
13:19 dalek NQR: Updated requirements
13:19 dalek NQR: review: https://github.com/NQRCore/NQR/commit/336fedaba9
13:21 dalek NQR: 41fc921 | (Jay Emerson)++ | benchmark3.nqr:
13:21 dalek NQR: Oops... not for the repository
13:21 dalek NQR: review: https://github.com/NQRCore/NQR/commit/41fc9214ff
13:30 bubaflub ~
13:37 benabik joined #parrot
13:41 benabik ~~
13:41 whiteknight hello benabik, bubaflub
13:41 benabik o/ whiteknight!  How's things?
13:41 bubaflub morning whiteknight.
13:44 fperrad joined #parrot
13:54 whiteknight benabik: Good enough. You?
13:55 benabik whiteknight: Pretty good, although I really need a new power cord for my laptop…  The insulation is dissolving.
13:56 whiteknight benabik: I ran into that same exact problem last weekend. The insulation wore out at one point, and the wires inside started to fray
13:56 whiteknight I pulled out my soldering iron, some patch wire, electrical tape and some cable ties, and fixed it
13:56 whiteknight it's extremely ghetto, but it works
13:56 benabik whiteknight: I coated the break in electrical tape and it's now splitting open further down.
13:56 whiteknight ouch
13:57 whiteknight I'd say go to radioshack and get some shrink tube, but it's hard to find a radioshack anymore
13:57 whiteknight much less one that carries more than phones and a small assortment of stereo equipment
13:57 benabik There are several around here.  I'm poking Apple with a stick.  I may still be in warrantee.
13:59 benabik Actually, not only do I know of a RadioShack around here that still carries electronics parts, but there's an entire store dedicated to them downtown.
14:01 atrodo I was surprised the other week when I actually went into a shack at the mall.  They had actual electronic parts
14:04 whiteknight It's like the mythical atlantis!
14:04 whiteknight minus the men of greatness and superior intelligence
14:04 atrodo I know!  I thought they got rid of those YEARS ago
14:47 benabik left #parrot
14:48 pjcj left #parrot
14:49 pjcj joined #parrot
14:50 JimmyZ joined #parrot
15:07 dalek rakudo/nom: 7cc1567 | moritz++ | t/spectest.data:
15:07 dalek rakudo/nom: 3 more passing test files
15:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/7cc1567225
15:07 dalek rakudo/nom: c22bfbd | moritz++ | src/core/Enumeration.pm:
15:07 dalek rakudo/nom: make $enumValue.Int less awkward
15:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c22bfbdbdb
15:19 daniel-s left #parrot
15:41 soh_cah_toa joined #parrot
15:42 soh_cah_toa ~~
15:42 AzureStone joined #parrot
15:45 Kulag left #parrot
15:45 AzureSto_ left #parrot
15:45 RobertLJ joined #parrot
15:48 mj41 left #parrot
15:49 soh_cah_toa left #parrot
15:54 JimmyZ left #parrot
15:55 soh_cah_toa joined #parrot
15:58 dalek parrot: f7f182e | soh_cah_toa++ | t/library/osutils.t:
15:58 dalek parrot: Added tests for file_exists() to t/library/osutils.t.
15:58 dalek parrot: review: https://github.com/parrot/parrot/commit/f7f182e3ef
16:00 soh_cah_toa does t/library/osutils.t fail for anybody else b/c of 2 tests in test_newer()?
16:03 whiteknight Let me fire up my VM and try it
16:13 dalek rakudo/nom: 00ad1de | moritz++ | src/core/Hash.pm:
16:13 dalek rakudo/nom: implement basic Hash.delete
16:13 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/00ad1deeaa
16:13 dalek rakudo/nom: 6eabc3a | moritz++ | src/core/Str.pm:
16:13 dalek rakudo/nom: remove workaround, now that we have Hash.delete
16:13 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6eabc3ab4f
16:13 NotFound joined #parrot
16:17 whiteknight soh_cah_toa: t/library/osutils.t passes on my system
16:17 whiteknight I jsut did a git pull and rebuild
16:17 soh_cah_toa hmm...
16:17 dalek parrot: 5ae62b7 | soh_cah_toa++ | t/library/osutils.t:
16:17 dalek parrot: Added test for slurp() to t/library/osutils.t.
16:17 dalek parrot: review: https://github.com/parrot/parrot/commit/5ae62b7bc3
16:18 soh_cah_toa oh yeah, i think rebuilding would fix that b/c it compares the pbc file against the pir file and i just edited it w/o rebuilding
16:20 mj41 joined #parrot
16:22 bluescreen left #parrot
16:22 dmalcolm joined #parrot
16:24 Kulag joined #parrot
16:26 soh_cah_toa whiteknight: what do you think i should do for testing system()? it's a super simple test except there can't be any output (b/c it's interpreted as a TAP token) and that's fine
16:26 soh_cah_toa whiteknight: i was using `test -e t/library/osutils.t` since there's no output but i don't want it to fail on win32 platforms. should i do something like "if Env['MSWin32'] do one test else do another"?
16:30 whiteknight that's a very good question. I don't know what to do about system()
16:32 soh_cah_toa left #parrot
16:32 dodathome joined #parrot
16:34 jay joined #parrot
16:42 dalek NQR: 1e4897e | (Jay Emerson)++ | VERSION:
16:42 dalek NQR: Updated version for today's work
16:42 dalek NQR: review: https://github.com/NQRCore/NQR/commit/1e4897e53d
16:43 soh_cah_toa joined #parrot
16:47 rdesfo joined #parrot
16:49 dukeleto NotFound: winxed.org is still empty.
16:49 cotto ~~
16:57 rdesfo left #parrot
17:00 soh_cah_toa left #parrot
17:00 whiteknight hello dukeleto, cotto
17:00 NotFound dukeleto: I know
17:09 jay On http://docs.parrot.org/parrot/latest/​html/docs/book/pct/ch04_pge.pod.html  there are references to "CHP-7-TABLE-3Table 7-3 shows the escape sequences for rules."
17:10 jay I don't see the tables, though.
17:10 jay Are they basically PERL metacharacters and escape sequences?  E.g. try perlish code and hope for the best?
17:11 soh_cah_toa joined #parrot
17:11 dukeleto NotFound: i have been telling people about winxed and pointing them there. That sucks.
17:11 dukeleto NotFound: do you want to just moved winxed.org to be a github repo, so we can use github pages and all parrot devs can update the site?
17:13 dukeleto jay: they are perlish, yes
17:16 jay [a-zA-Z][\w\.]*    is then   "start with an alpha character, followed by as many word (alphanumeric plus _) or dot characters as you want?"
17:17 dukeleto jay: looks to be that way
17:17 jay I love Perl.  Or used to... I've been distracted.
17:18 dukeleto jay: indeed. I do Perl for my $dayjob :)
17:19 jay Hmmm... I'm trying to customize by identifier:
17:19 jay token identifier {
17:19 jay <!keyword> [a-zA-Z][\w\.]*
17:19 jay }
17:20 jay It says,   "Confused at line 187, near "token iden"
17:20 jay I'm confused, too.  !-)  No biggie, but if it were something obvious I'd like to permit . in identifiers rather than use the stock <ident>
17:21 soh_cah_toa jay: p6 character classes need <> around the brackets i.e. <[a-z]>
17:21 jay Ah... perl5 vs perl6 then... I'll try that.
17:22 jay and .. instead of - for character ranges?
17:22 soh_cah_toa yes
17:22 soh_cah_toa <[a..z]>
17:22 jay compiled.  Thanks, I'll test it.
17:23 * soh_cah_toa does not like that new syntax at all
17:26 NotFound dukeleto: I've located the guy, I hope the site be alive again in few hours.
17:26 dalek parrot: 7b9fa19 | soh_cah_toa++ | t/library/osutils.t:
17:26 dalek parrot: Added tests for mkpath() and rmtree() to t/library/osutils.t.
17:26 dalek parrot: review: https://github.com/parrot/parrot/commit/7b9fa1943a
17:28 bluescreen joined #parrot
17:29 jay soh_cah_toa: I'm not quite there.... the trailing * doesn't seem to be quite right for "as many of [\w\.] that I want.  Hint?    I have:     <[a..zA..Z]><[\w\.]>*
17:29 dukeleto jay: you may want that * inside the <>'s
17:30 jay Tried that and it didn't compile.
17:31 jay I found a perl6 example (googled) that indicates my usage might be right:    <[A-Z]><[a-z]>+  for something like a name, for example.
17:31 dukeleto NotFound++
17:34 jay Ok, <[a..zA..Z]><[a..zA..Z.]>*   seems to work.... the \w may not be what it claims, or else something else subtle is going on.
17:34 PerlJam jay: I'm not sure if <[ ]> supports the character class shortcuts.  The trailing * should be fine (it still means "zero or more of the previous atom")
17:35 jay PerlJam: yes, I think I agree based on this little test.
17:35 soh_cah_toa jay: i'm guessing this is for identifier names, right?
17:35 jay Yup.
17:36 soh_cah_toa well, wouldn't you want a limit on the length of identifiers? using * won't do that
17:36 soh_cah_toa unless r doesn't have a limit, i don't know
17:36 jay If there is a limit, I've never hit it.  I'm too lazy to actually use long names.  However, the point is taken.
17:40 jay Ah, now I need to change the method....    what does the ~ mean here:        my $name  := ~$<ident>;
17:40 particle1 left #parrot
17:40 soh_cah_toa forces string context
17:41 theory joined #parrot
17:42 jay Would    <!keyword> $<myident>=<[a..zA..Z]><[a..zA..Z_.]>*   then give the name "myident" for use in the corresponding action?
17:43 soh_cah_toa hmm...
17:43 jay Er, no.  Sorry, let me struggle with this for a bit.
17:44 theory_ joined #parrot
17:46 cotto_work ~~
17:47 PerlJam jay: it would, but it might not contain what you think it should :)
17:48 theory left #parrot
17:48 theory_ is now known as theory
17:49 PerlJam jay: might you want $<myident>=[<[a..zA..Z]>[\w|'.']*]   ?
17:50 jay Hmm.... I might have found a way, just a sec.
17:50 contingencyplan joined #parrot
17:50 jay Ok, Here we go:
17:50 jay token identifier {
17:50 jay <!keyword> <myident>
17:50 jay }
17:50 jay token myident {
17:50 jay PerlJam... unlss you think your suggestion might have a performance benefit?
17:51 particle joined #parrot
17:51 PerlJam maybe slightly, but I wouldn't worry about it.
17:52 jay I'm happy enough to have the blasted thing working, I'm not worried about it at all.  Thanks PerlJam++ soh_cah_toa++ DukeLeto++
17:53 soh_cah_toa jay: have you seen the spec where it says that identifiers can't begin w/ a digit nor underscore nor a period followed by a digit?
17:53 soh_cah_toa http://cran.r-project.org/doc/m​anuals/R-lang.html#Identifiers
17:53 jay Haven't seen the spec, but I'm trying to be consistent with that, yes.
17:54 jay I think my rule is ok on that front.  In fact, a leading . is allowed in R, and it creates a "hidden" variable of some sort.  not recommended, but I just tested it.
17:55 jay Ah, I see, can't be .9ab but could be .ab, yes.
17:55 soh_cah_toa b/c i'm trying to make a regex for you for that but i seem to forget negation in p6
17:55 jay Right -- and I forgot the digits.  So I have a little more work to do.
17:56 PerlJam jay: and you're definitely correct to use a subrule when the rules for identifiers are so complicated.
17:56 jay Back to Parrot: I'd like to create a function named which.max().  This is a legal R function name, but apparently not in PIR/NQP/Winxed.  Any advice?
17:56 jay PerlJam, Thanks, I agree, easier to read.
17:57 soh_cah_toa oh, that's just a function, not a method call?
17:57 * soh_cah_toa doesn't know if r is object-oriented
17:58 moritz token identifier { \. <alpha> \w* }
17:58 jay Erm... I think of it as a function... I have a working runtime function (written in winxed) whichmax that works fine, I just want it to be which.max instead.
17:58 moritz something like that?
17:58 PerlJam jay: Where does your R implementation live?
17:58 jay https://github.com/NQRCore/NQR
17:59 jay moritz: not an identifier issue I think.  This is a Winxed/NQR/PIR naming issue... I just want to expose a Runtime function to the R user and need to get around the function name limition (apparently) of Winxed, in this case.
18:00 dalek NQR: 3a2270f | (Jay Emerson)++ | src/nqr (4 files):
18:00 dalek NQR: New identifier, working on more runtimes
18:00 dalek NQR: review: https://github.com/NQRCore/NQR/commit/3a2270f89f
18:00 jay Glance at   https://github.com/NQRCore/NQR/bl​ob/master/src/nqr/Runtime.winxed    and you'll see the function which.max that is the issue... if I get rid of the . it works fine.
18:02 jay This may be a non-trivial issue... perhaps I need to maintain a list of exposed user-functions that map to internal functions, or something like that.
18:02 * dukeleto just found a way to coredump parrot with 2 lines of PASM
18:02 PerlJam dukeleto: That's an aweseome achievement to unlock!  :)
18:03 moritz jay: in PIR, function names are arbitrary (always quoted in '')
18:04 jay Ok... so I could move these to PIR.  Anybody know a clever fix in Winxed?
18:05 RobertLJ left #parrot
18:05 soh_cah_toa left #parrot
18:05 PerlJam jay: I don't know about "clever" but you could add a dispatch table as you suggested to only be used when it can't find the function via normal means
18:06 PerlJam (I assume winxed has exception mechanisms)
18:06 jay Ok.  So I have good instincts and I'll leave it on the back burner for now.  !_)  Bigger fish to fry, thanks PerlJam.
18:06 soh_cah_toa joined #parrot
18:08 benabik joined #parrot
18:09 PerlJam jay: you could also make a PIR layer that dispatches only the dotted names to winxed with some regular name-mangling  (the down side would be that the mangled names would also be available in your runtime)
18:10 PerlJam (but if winxed has some sort of namespace support, you can mitigate the damage)
18:11 jay How about this: a modification of the trick used to get around array:
18:11 jay $P0 = find_lex 'array'
18:11 jay set_global '!array', $P0
18:11 whiteknight dukeleto: I really wish people weren't using PASM. I'm starting to think we should disallow it from use completely
18:12 benabik whiteknight: People are still using PASM?
18:12 jay Uh oh.  Am I causing trouble?
18:12 whiteknight jay: no, you're fine
18:13 whiteknight dukeleto just reported a ticket where we can segfault in two lines of pasm
18:13 theory left #parrot
18:13 whiteknight the reason is because PASM is T3H SUX
18:13 dukeleto http://trac.parrot.org/parrot/ticket/2165
18:13 dukeleto our TT bot is slow
18:13 mj41 left #parrot
18:14 atrodo well that's an embarrassing bug
18:14 whiteknight it's not a bug really
18:14 whiteknight PASM is too low level for humans to be writing things in
18:15 atrodo One could argue the same thing about memory management.
18:15 whiteknight if you make poorly formatted input at such a low level, and use the fast core which turns off bounds checking, you get poorly formed output
18:15 atrodo Aye, but we should never segfault.
18:15 whiteknight I don't see why not
18:16 whiteknight I mean, at the PIR level we shouldn't. No
18:16 whiteknight at the PASM level, all bets are off. If you're going to play with fire, we won't pretend we can prevent the burns
18:16 dalek TT #2165 created by dukeleto++: Coredumping Parrot with only 2 lines of PASM for fun and profit
18:16 dalek TT #2165: http://trac.parrot.org/parrot/ticket/2165
18:16 whiteknight The solution here is to either use the slow core, or to disallow pasm as a valid input format
18:17 atrodo Which won't work, because you can always hand craft a pbc to do the exact same thing
18:17 whiteknight atrodo: And I can always hand-craft a machine code binary to segfault or worse without parrot
18:18 atrodo But the container of that program, the OS, doesn't crash because of it
18:20 whiteknight I don't see any reasonable way to guarantee at the Parrot level that this cannot happen
18:20 dukeleto whiteknight: what does the slow core do on that input?
18:20 whiteknight dukeleto: the slow core is the fast core, but it performs bounds-checking. I think it would throw an exception if we tried to go out of bounds
18:22 whiteknight I don't think there is any possible way to prevent this in all cases
18:23 whiteknight atrodo: with NCI functionality, any user can force a segfault at any time
18:23 whiteknight get handle to some function, pass a NULL pointer to that function. Repeat
18:23 atrodo Another way to think about it.  Can you cause a segfault with a malformed class in JVM or .Net?
18:23 whiteknight atrodo: I would be extremely surprised if you could not
18:24 jsut joined #parrot
18:24 jnthn__ You can segfault the CLR by doing NCI-ish stuff. :)
18:24 * jnthn__ did it :)
18:24 atrodo Ya, once you leave the sandbox, I assume you can do anything to it.  I'm talking about while you're inside the sandbox
18:26 whiteknight atrodo: If you are at the level of a malformed assembly file, I'm sure you could segfault it
18:26 atrodo I would be surprised
18:26 atrodo That's a huge security issue
18:27 jnthn__ Doubt a malfomred assmebly will segfault it.
18:27 jnthn__ Since it does bytecode verification
18:27 benabik I think JVM and CLR do verification on the bytecode...
18:27 jnthn__ It can statically know what would be out of bounds.
18:27 whiteknight That's the only way around it that I can see: lots of bytecode verification on load
18:28 plobsing atrodo: how does being able to segfault the process with arbitrary code equate to a security problem?
18:28 whiteknight I just can't think of any ways which would be full-proof
18:28 * dukeleto just sent github a pull request to detect Parrot-ish stuff : https://github.com/github/linguist/pull/58
18:28 plobsing you already have arbitrary code execution. you've won already.
18:28 dalek NQR: f3f755d | (Jay Emerson)++ | src/nqr (3 files):
18:28 dalek NQR: Solved the dot (.) problem with which.max
18:28 dalek NQR: review: https://github.com/NQRCore/NQR/commit/f3f755dfff
18:29 jsut_ left #parrot
18:32 whiteknight The immediate problem is that users can type in bad pasm by accident. The solution I see to that problem is to disallow pasm
18:33 whiteknight We could make a lot of ugliness in IMCC go away pretty quick with that policy
18:33 whiteknight and if M0 is coming around the mountain quickly enough, nobody would mourn the loss
18:34 benabik I see value in PASM.  I'd really like a textual format for PBC that we can assemble from and disassemble to.  That said, I don't think the current PASM is that.
18:34 whiteknight it's not, it never has been, and it never will be.
18:34 whiteknight clearly, nobody here is going to put in the necessary energy. PASM hasn't been touched in years
18:35 benabik whiteknight: It's one of the things on my Parrot wishlist...
18:35 whiteknight And eventually, PBCs won't even be in that format, so PASM will become just another compatibility nightmare during the M0 transition
18:36 whiteknight benabik: PIR is almost the same thing, except PIR actually lets you do most things you need. If you can disassemble to PASM, you can disassemble to PIR
18:36 benabik whiteknight: Really?  Can you write a 1:1 map of opcodes to PIR without IMCC trying to mangle it into something subtly different?
18:37 whiteknight it may do some optimizations, and translations of some ops, but I think that's the same for both PIR and PASM modes
18:37 whiteknight so in short, if you write out the low-level ops by hand, I don't think the PIR would be any more mangled than the PASM would be
18:38 whiteknight what kills you isn't the op mangling, it's the things like compile-time directives which aren't ops at all and are very hard to trace
18:39 benabik I'd like a 0% mangling assembly language.
18:39 whiteknight that isn't PASM
18:39 benabik No, it's what I'd like PASM to be.  :-D
18:39 benabik I can call it something else.
18:39 plobsing that language needs a good way to represent object graphs (that's what PBC in the end). neither PIR nor PASM have that.
18:40 whiteknight plobsing: what do you mean?
18:41 plobsing right now, both PIR and PASM assume we want only specify a collection of subs. that's not really what we want
18:41 dalek rakudo/nom: 56e2229 | jonathan++ | src/core/traits.pm:
18:41 dalek rakudo/nom: Make $x is readonly work on parameters.
18:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/56e2229935
18:41 dalek rakudo/nom: 49ede3c | jonathan++ | src/binder/multidispatch.c:
18:41 dalek rakudo/nom: Missing decontainerize in junctional argument check in the multi-dispatcher. Gets us further with the junction tests.
18:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/49ede3c3f5
18:41 dalek rakudo/nom: 1aa1163 | jonathan++ | src/core/Numeric.pm:
18:41 dalek rakudo/nom: Remove an optimization that busts +SomeEnumValue.
18:41 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1aa1163608
18:42 whiteknight plobsing: ah, you're talking about constant tables
18:42 plobsing we want to specify collections of objects - classes, namespaces, methods, subs, keys, etc...
18:42 benabik plobsing++
18:42 whiteknight I've always looked at the constants table as what should be the central item in a pbc
18:43 Kulag left #parrot
18:43 Kulag joined #parrot
18:43 plobsing I think the constant table is a big part of what PBC is, or should be.
18:44 plobsing but our textual representations are sorely lacking when it comes to providing access to it
18:44 whiteknight yes, very much so
18:44 plobsing :anon :immediate? not nearly enough.
18:45 whiteknight it's not a bad start though, and it is sorely underused and underapprciated
18:45 plobsing it doesn't round-trip
18:45 dodathome left #parrot
18:45 whiteknight and the performance is lousy, and the safety and reentrancy of the implementation is lousy
18:47 whiteknight so what would the alternative look like? We've kicked around ideas to add object literals to PIR for a long time, and nobody ever jumped on it
18:47 whiteknight not that we ever had a compelling design to jump on
18:47 dalek rakudo/nom: b420e0d | moritz++ | src/core/Hash.pm:
18:47 dalek rakudo/nom: fix typo in Hash.pm, mls++
18:47 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b420e0ddf1
18:48 whiteknight With vtable overrides and other garbage like that, I can't think of any real way for any syntax to be round-trip arbitrarily anyway
18:49 whiteknight unless the result after a disassemble was allowed to be human-unreadable gibberish
18:50 plobsing I created a branch a while ago with a textual serialization format. Not entirely human-readable, but 100% equivalent to the binary
18:50 whiteknight is that branch still around?
18:51 plobsing yes. it is called pasm-serializer IIRC
18:51 whiteknight I'll have to stare vacantly at it
18:54 whiteknight hmm.. this is actually very interesting
18:55 plobsing also, TT #1644 is tracking it
18:56 bubaflub_ joined #parrot
18:56 plobsing has some example outputs
18:56 bubaflub left #parrot
18:56 bubaflub_ is now known as bubaflub
18:56 whiteknight so what would we need next, an assembler to put it back into .pbc format?
18:56 whiteknight and how does it handle opcodes? I don't see any special-purpose code for that
18:56 moritz why do we need object literals for that? can't we just have a .sub that is executed at the time when the .pbc is created, and serialize its result?
18:57 plobsing it doesn't. it only handles objects.
18:57 plobsing so we'd need other parts
18:57 plobsing a top-level that split sections appart, and other tools to handle the other sections
18:57 whiteknight moritz:can't disassemble it, no round-trip fidelity
18:58 dukeleto whiteknight: "Round-Trip Fidelity" sounds like the name of bad movie...
18:58 whiteknight :)
18:58 whiteknight plobsing: so something like an LEX file, with delimited regions for constants, subs, etc?
18:59 plobsing whiteknight: yes, something like that could work
18:59 plobsing well, subs don't get a delimited region, code does
19:00 plobsing subs live in the object section
19:02 simcop2387_ joined #parrot
19:04 simcop2387 left #parrot
19:04 simcop2387_ is now known as simcop2387
19:10 preflex_ joined #parrot
19:10 whiteknight how do you have a sub object without specifying it's bytecode contents?
19:10 whiteknight just a "to be continued" marker somewhere?
19:11 plobsing the way sub objects exist in-memory and in-bytecode: they simply have integer indices which are taken to mean into the associated bytecode segment
19:12 preflex left #parrot
19:14 plobsing like I said, it isn't exactly human-readable. it may be parrot-core-dev-readable though. half of us are robots anyways.
19:14 dodathome joined #parrot
19:19 lucian joined #parrot
19:27 whiteknight so pasm-serializer is not intended to replace something like IMCC, or pbc_dump?
19:28 whiteknight moritz: again, it's not round-trip safe
19:28 whiteknight oh shoot, sorry.
19:29 whiteknight my scrollbar was in the wrong place
19:29 moritz no problem
19:29 plobsing whiteknight: not on its own
19:30 moritz I'm not convinced by that argument, but disassembling is a good reason
19:30 plobsing but it can be part of a larger solution that acts as a replacement
19:31 whiteknight If we commit ourselves that PIR/PASM are not the ultimate, best possible textual pbc format, we need to start seriously considering some alternatives
19:32 whiteknight and I can't imagine anybody making the argument that PIR is the best possible language for it's particular place in the stack
19:32 plobsing moritz: round-tripping is important if for no other reason that being able to prove that the disassembly is capable of fully representing the binary
19:33 dalek rakudo/nom: 19c000b | moritz++ | t/spectest.data:
19:33 dalek rakudo/nom: run two more test files
19:33 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/19c000b3a7
19:36 whiteknight if that pasm serializer PMC were a dynpmc, we could move it into master more quickly
19:37 dalek NQR: 66c2ae5 | (Jay Emerson)++ | src/nqr/Grammar.pm:
19:37 dalek NQR: Updated notes on grammar changes
19:37 dalek NQR: review: https://github.com/NQRCore/NQR/commit/66c2ae560b
19:40 plobsing whiteknight: do you have any tests for the :tag functionality yet?
19:41 NotFound http://winxed.org/ is back!
19:42 bluescreen left #parrot
19:48 whiteknight plobsing: no .t files, no. Just a long series of "test1.pir" files in my working directory
19:48 whiteknight I'll turn them into tests soonish
19:48 whiteknight plobsing: thanks for the feedback on that, by the way. A sort/bsearch would be a nice addition to id
19:50 whiteknight I was thinking today that we could replace :main as well with the same kind of mechanism. PackfileView.main_sub() could get the list of all subs flagged :tag("main") and pop the last one off the list
19:50 whiteknight or the first, whatever semantic we want
19:52 RobertLJ1 joined #parrot
19:52 plobsing whiteknight: I'm halfway through coding up the sort/bsearch. I'd really like to know that I'm not screwing anything up.
19:54 whiteknight I'll commit some tests tonight. It's pretty straight-forward
19:54 whiteknight get a packfileview, pfv.'subs_by_flag'("my flag") to get an array of Subs, execute the subs to see that all the ones you want trigger as you expect
19:57 bluescreen joined #parrot
19:59 whiteknight do a bsearch on the array. When you find an index matching the Sub you want, look to the left and to the right to get all the entries with the same string index
19:59 theory joined #parrot
19:59 whiteknight if we really want to replace :load and :init, we need to make sure we get the ordering the same, but that's a detail
20:00 whiteknight actually, I don't know. Do we make ordering guarantees about those flags?
20:01 plobsing they are ordered now, but I'm fairly sure that isn't documented
20:01 whiteknight When we do the deprecation for those things, we'll make explicit note that ordering, if any, won't be preserved
20:02 * lucian is an idiot
20:02 dalek rakudo/nom: 118befb | pmichaud++ | src/core/Hash.pm:
20:02 dalek rakudo/nom: Make sure that Hash.STORE doesn't consume the thing it's storing.
20:02 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/118befba26
20:02 whiteknight lucian: having troubles?
20:04 NotFound msg dukeleto winxed.org is back and the most recent version restored
20:04 aloha OK. I'll deliver the message.
20:04 lucian whiteknight: i managed to lose data
20:05 lucian that is, a couple of commits. i forgot to push before wiping my laptop and selling it
20:05 whiteknight ouch
20:05 lucian i did use osx's time machine to backup the entire hard drive, which is likely to be the reason i forgot to push
20:06 whiteknight oh, so you have that backup somewhere?
20:06 lucian but i can't follow directory hard links on anything other than osx
20:06 lucian so until i find an osx machine, those bits are unreachable
20:08 whiteknight is it anything you can reproduce from memory?
20:11 NotFound left #parrot
20:15 NotFound joined #parrot
20:16 theory left #parrot
20:16 theory joined #parrot
20:17 theory left #parrot
20:18 lucian whiteknight: possibly, it was monday's work mostly
20:21 whiteknight I can't be too much help because I don't have a mac
20:26 whiteknight left #parrot
20:40 dodathome left #parrot
20:41 theory joined #parrot
21:09 dalek rakudo/nom: 29058a9 | jonathan++ | src/Perl6/Actions.pm:
21:09 dalek rakudo/nom: &?ROUTINE
21:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/29058a9b0e
21:09 dalek rakudo/nom: 1c335ac | jonathan++ | src/core/Routine.pm:
21:09 dalek rakudo/nom: Support Routine.assuming as well as master did (some day we may want to do some magic with generating an updated signature and some such, but that's teh tricky).
21:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/1c335ac7f5
21:09 dalek rakudo/nom: 5161c8b | jonathan++ | t/spectest.data:
21:09 dalek rakudo/nom: Two more passing test files.
21:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5161c8be35
21:19 dalek parrot/whiteknight/imcc_tag: 440f18f | plobsing++ | compilers/imcc/pbc.c:
21:19 dalek parrot/whiteknight/imcc_tag: [codingstd] c_arg_assert
21:19 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/440f18f533
21:19 dalek parrot/whiteknight/imcc_tag: cb07909 | plobsing++ | compilers/imcc/pbc.c:
21:19 dalek parrot/whiteknight/imcc_tag: [codingstd] linelength
21:19 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/cb07909d66
21:19 dalek parrot/whiteknight/imcc_tag: 28b69a4 | plobsing++ | compilers/imcc/ (2 files):
21:19 dalek parrot/whiteknight/imcc_tag: [codingstd] c_function_docs
21:19 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/28b69a4265
21:19 dalek parrot/whiteknight/imcc_tag: 7835cd1 | plobsing++ | / (6 files):
21:19 dalek parrot/whiteknight/imcc_tag: use a proper struct to manage the format of the tag_map
21:19 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/7835cd1e2b
21:19 dalek parrot/whiteknight/imcc_tag: 4cf23c5 | plobsing++ | / (3 files):
21:20 dalek parrot/whiteknight/imcc_tag: store tags as a sorted pairs list
21:20 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/4cf23c5f55
21:20 dalek parrot/whiteknight/imcc_tag: ffe846f | plobsing++ | src/packfile/api.c:
21:20 dalek parrot/whiteknight/imcc_tag: use binary search to determine range of tag map containing querried tag entries
21:20 dalek parrot/whiteknight/imcc_tag: review: https://github.com/parrot/parrot/commit/ffe846f5be
21:20 bluescreen left #parrot
21:21 RobertLJ1 left #parrot
21:25 ambs left #parrot
21:44 Psyche^ joined #parrot
21:48 dalek rakudo/nom: b0a7bcd | jonathan++ | t/spectest.data:
21:48 dalek rakudo/nom: One more passing test file.
21:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b0a7bcdd7a
21:48 dalek rakudo/nom: d9d0d00 | pmichaud++ | src/core/IO.pm:
21:48 dalek rakudo/nom: Fix filetest operators for non-existent files.
21:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/d9d0d00a11
21:49 Patterner left #parrot
21:49 Psyche^ is now known as Patterner
21:50 bubaflub left #parrot
21:54 lucian left #parrot
21:59 jay left #parrot
22:00 dalek lalrskate: 39438d0 | tcurtis++ | src/LALR/Generator/ (3 files):
22:00 dalek lalrskate: Add several things I've been working on but forgot to commit.
22:00 dalek lalrskate: review: https://github.com/ekiru/l​alrskate/commit/39438d007e
22:00 dalek lalrskate: e262efb | tcurtis++ | src/LALR/Generator.winxed:
22:00 dalek lalrskate: Add another.
22:00 dalek lalrskate: review: https://github.com/ekiru/l​alrskate/commit/e262efbe35
22:00 dalek lalrskate: a1e93a6 | tcurtis++ | setup.winxed:
22:00 dalek lalrskate: Update setup.winxed.
22:00 dalek lalrskate: review: https://github.com/ekiru/l​alrskate/commit/a1e93a6d1f
22:05 dalek rakudo/nom: c2794a4 | jonathan++ | src/core/Routine.pm:
22:05 dalek rakudo/nom: Routine.candidates
22:05 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c2794a44d9
22:05 dalek rakudo/nom: 333a91f | jonathan++ | t/spectest.data:
22:05 dalek rakudo/nom: Run S06-multi/syntax.t.
22:05 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/333a91ff19
22:14 theory left #parrot
22:40 dalek rakudo/nom: 764d2f9 | jonathan++ | src/core/traits.pm:
22:40 dalek rakudo/nom: A couple more trait handlers (though nothing yet answers them).
22:40 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/764d2f948d
22:40 dalek rakudo/nom: 075104d | jonathan++ | t/spectest.data:
22:40 dalek rakudo/nom: Two more passing test files.
22:40 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/075104d015
22:45 theory joined #parrot
22:50 dalek rakudo/nom: 9246ce6 | jonathan++ | src/Perl6/Metamodel/BOOTSTRAP.pm:
22:50 dalek rakudo/nom: Add logic to attribute meta-object so it may be explicitly marked readonly, and able to default itself to rw if it wasn't marked readonly.
22:50 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/9246ce6de0
22:50 dalek rakudo/nom: 0ca6dad | jonathan++ | src/Perl6/Metamodel/ (2 files):
22:50 dalek rakudo/nom: Implement rw handling for types in AttributeContainer role; also factor attribute composition into that role to take a little more bulk out of ClassHOW.
22:50 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/0ca6dad381
22:50 dalek rakudo/nom: caf5d1a | jonathan++ | t/spectest.data:
22:50 dalek rakudo/nom: Run S12-class/rw.t.
22:50 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/caf5d1aa5c
23:00 bubaflub joined #parrot
23:02 bubaflub ~
23:02 jay joined #parrot
23:08 davidfetter joined #parrot
23:08 theory left #parrot
23:10 kid51 joined #parrot
23:25 dukeleto aloha, clock?
23:25 aloha dukeleto: LAX: Thu, 16:25 PDT / CHI: Thu, 18:25 CDT / NYC: Thu, 19:25 EDT / UTC: Thu, 23:25 UTC / LON: Fri, 00:25 BST / BER: Fri, 01:25 CEST / TOK: Fri, 08:25 JST / SYD: Fri, 09:25 EST
23:26 NotFound left #parrot
23:26 NotFound joined #parrot
23:27 GodFather joined #parrot
23:38 dalek website: soh_cah_toa++ | HBDB Closed for Construction, Please Use Detour
23:38 dalek website: http://www.parrot.org/content/hbdb-c​losed-construction-please-use-detour
23:48 dalek rakudo/nom: b05b391 | jonathan++ | LHF.markdown:
23:48 dalek rakudo/nom: Update LHF; remove a dupe entry...nice as minmax op would be, it only needs to be listed once. :-)
23:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b05b391310
23:48 dalek rakudo/nom: 5d31774 | jonathan++ | src/ (3 files):
23:48 dalek rakudo/nom: Allow state declarator and pass along a flag to the lexpad when something is state scoped.
23:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5d31774cc1
23:48 dalek rakudo/nom: 24c07b6 | jonathan++ | src/Perl6/Grammar.pm:
23:48 dalek rakudo/nom: Re-enable state scope declarator, in preparation for restoring state var functionality.
23:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/24c07b6466
23:48 dalek rakudo/nom: 2d89f4a | jonathan++ | src/Perl6/Actions.pm:
23:48 dalek rakudo/nom: Need action method for state scope declarator also.
23:48 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2d89f4ac56
23:51 whiteknight joined #parrot
23:51 cotto_work hio whiteknight
23:52 whiteknight hey cotto_work
23:56 whiteknight pg parrot
23:56 whiteknight damnit
23:58 dmalcolm left #parrot

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

Parrot | source cross referenced