#parrot Parrot 0.5.2 Released | parrotcode.org/ | see www.parrotcode.org/misc/parrotsketch-logs/ for logs
Set by moderator on 11 February 2008.
mncharity Following www.perlmonks.net/?node_id=659584 on a fedora8 x86_64, ./pbc_to_exe languages/perl6/perl6.pbc fails because gcc 4.1.2 doesn't like -Folanguages/perl6/perl6.o , and drops perl6.o in the cwd. One can work around this by then copying perl6.o down to languages/perl6, and rerunning ./pbc_to_exe. parrot r25997. fyi. 00:05
./languages/perl6/perl6 languages/perl6/t/01-sanity/07-defined.t segfaults. so I'll mention the build time warning src/gc/gc_ims.c: In function ‘parrot_gc_ims_collect’: src/gc/gc_ims.c:853: warning: cast to pointer from integer of different size, which may be an x86_64-ism. 00:12
s/segfaults/segfaulted/. non-replicable. :/ 00:13
oops. tested wrong file. segfault on defined.t *is* consistent. 00:17
pmichaud mncharity: I wonder where the -Folanguages/perl6.perl6.o switch is coming from, then? 00:32
00:32 Andy joined
pmichaud mncharity: do you get the segfault if running 07-defined.t using "parrot perl6.pbc"? 00:36
00:39 kj joined
kj Andy: (scrollback) I know a bit of flex and bison, ifyou still need help 00:42
although I am planning to get some sleep really soon now
Andy I'm here
I just don't know what the code is supposed to do.
kj mmm. lines? I'll take a quick look
maybe i read it before
Andy look at line 544 of compilers/imcc/imcc.l 00:43
kj guess I'll first svn up
oh i should mention, my focus on imcc is not really correctness wrt memory 00:45
i read something about a function falling through, no return; is that your concern? 00:46
if flex doesn't return it'll just continue scanning, but i guess you knew that already
so it doesn't have to be wrong
Andy no I didn't know tht
I just see a function that doesn't ahve a return. 00:47
kj so, on a side note, the if type>0 stuff, should be removed long-term, as this involves the type-ids
well, it's not really a function ;-)
so after the lexer finds out the it cannot find .Foo (if Foo is not a type), it will try to expand the macro Foo 00:48
that's the part with if(!expand_macro ,.. stuff
if it CANNOT expand
it will return a dot 00:49
the other case, it will continue, apparently
(not expanding, returning a dot, makes sense, no?)
Andy hld
kj not sure, but i think a lexer is just one big switch/case thingie
it's not seperate functions for each rule
actually, currently (but it's 01:51 am here) i cannot think of any other case than .Integer and .my_macro(42) (type ids and expansion, resp.) 00:51
but it's my guess, that the lexer will happily scan more, and return something at a later point to the parser 00:52
who will probably complain
(as i said: cannot think of any other case)
but in all 3 cases, the memory is freed, if i see thsi correctly 00:53
Andy back
mncharity pmichaud: re 'do you get the segfault if running 07-defined.t using "parrot perl6.pbc"?', no. ../../parrot perl6.pbc t/01-sanity/07-defined.t works. 00:54
Andy ah, ok
I see in the compiled code
kj (i also saw something with valp in the scrollback, I don't have a clue there) 00:55
pmichaud mncharity: okay, that helps a bit. It might be in the x86_64 core then, or it might be something specific to pbc_to_exe on x86_64, or who knows
kj andy: note line 623; there's no return there either
Andy looking at the copmiled code, it makes sense 00:56
kj that's fine, a new state is entered, and the scanner will continue
Andy ok, yup makes sense. 00:57
kj line 462, same thing; handling the .include directive; this case should be more clear 00:58
as it opens a new file and scanning continues in the included file.
just as you'd expect
oh, one more thing very very very important in flex files: the { should be on the same line as the pattern that is matched 00:59
but you might have figured that out yourself
andy: do you think the pct implementation of C is helpful for cage tasks? 01:01
Coke I'd be amused to rewrite some of the t/codingstd tests using the PCT version. 01:02
kj coke: i did a bit of thinking about a full implementation.It might get tricky with pointers
mncharity pmichaud: re 'I wonder where the -Folanguages/perl6.perl6.o switch is coming from, then?', I see in ./config/init/hints/mswin32.pm c_o_out => '-Fo', and note that gcc was invoked via "cc". Perhaps it's confusing fedora with mswin? perl 5.10. -V looks normal. 01:03
pmichaud mncharity: yes, it sounds like a configuration issue. iirc, pbc_to_exe just uses whatever compiler flags are stored in the parrot config 01:05
Andy II don't know 01:08
mncharity sial.org/pbot/30323 re 'pbc_to_exe fails with -Folanguage/perl6/perl6.o', here's the myconfig and parrot_config.pasm 01:16
kj well. i'm off for some sleep.
andy: if you need more help with flex/bison stuff, ping me 01:17
Andy kthx
kj if im here
Andy We still have a problem we were tracking down
that led me to find that.
kj what was the orig. probl
Andy ummm.
I don't remmeber.
hold on.
svnbotl r25998 | petdance++ | trunk: 01:18
: removed an unnecessary malloc/free pairing
diff: parrotvm.org/svn/parrot/revision/?rev=25998
kj the whole macro layer in imcc.l is.... scary. to say the least.
Andy rt.perl.org/rt3/Ticket/Display.html?id=51104 01:19
kj mm. right. 01:20
you know what that loop does, right? 01:21
it reads in a macro definition (the macro parser is implemented in c code, in this piece of the lexer)
wait a minute. valp is then passed to yylex again 01:26
01:26 jasonmay left
kj in the last line of the loop 01:26
yylex is the lexer function, which will activate the patterns again, where valp->s can be allocated again 01:27
i think that's where valp->s is realloced again
01:27 Oniichan left
kj andy: that's the answer on your reply on that ticket. 01:28
Andy ok hold on
kj so, just to make sure; you know what yylex is, right?
that's the entry point of the lexer, as called by the parser.
but this code implements the macro parser, which will just ask for the next token through yylex 01:29
which will then happily match patterns just as any other invocation
fyi; it seems read_params does something similar, but a bit different. not quite sure. it defines a YYSTYPE object (valp is also a YYSTYPE thing i think) 01:31
Andy I really just need a crash course in the parser stuff.
kj we really should move to pirc :-P (advertising my own stuff here ;-) 01:32
so, for instance, line 308 allocates memory and assigns it to valp->s 01:33
this line may well be activated when yylex is invoked, from that little macro-parser you're trying to debug 01:34
that's why it's ok to free it later on, and then after invoking yylex, referencing it again
Andy the key is that valp is all null at the poit of the crash
kj as long as valp->s is reallocated of course.
i'm interested whcih macro it chokes on 01:35
Andy first, reupdate
kj the preamble is full of macros
(that file is included, it's in c99/src)
andy: you know what valp is? 01:38
i mean, you know it refers to an object defined by %union in imcc.y 01:39
mm.i don't trust line 517 in imcc.l: valp->s=yytext. and later on valp->s might be freed... That's a bad thing,as yytext is global in the lexer/parser 01:45
not sure, but I'd bet a few dollars on that line.
good luck; off to bed 01:47
Andy no idea 01:48
(vim lex mode coloring)++ 01:51
02:07 Limbic_Region joined 02:23 particle joined 02:31 particl1 joined
svnbotl r25999 | jkeenan++ | trunk: 02:54
: Applying patch contributed by mkraai in rt.perl.org/rt3/Ticket/Display.html?id=51106 correcting number of tests to be SKIPped.
diff: parrotvm.org/svn/parrot/revision/?rev=25999
03:12 e joined 03:20 rafl joined
svnbotl r26000 | jkeenan++ | trunk: 03:31
: Remove two directories from repository structure. Their contents were
: deleted yesterday as they are Perl 5.8+ core modules.
diff: parrotvm.org/svn/parrot/revision/?rev=26000
Andy chromatic; You around? 04:03
04:05 cotto_ joined 04:07 AndyA joined
svnbotl r26001 | petdance++ | trunk: 04:27
: use PARROT_INTERP macro
diff: parrotvm.org/svn/parrot/revision/?rev=26001
05:00 x joined 05:14 Theory joined
svnbotl r26002 | petdance++ | trunk: 05:23
: parenthesizing macros
r26003 | petdance++ | trunk:
: unreverted the macro_name str_dup patch. See rt.perl.org/rt3/Ticket/Display.html?id=50920
diff: parrotvm.org/svn/parrot/revision/?rev=26003
05:24 mire joined 05:28 bgeron joined 05:32 Theory joined 05:45 teknomunk joined
svnbotl r26004 | petdance++ | trunk: 06:07
: consting, and removed unused arg from expand_macro
diff: parrotvm.org/svn/parrot/revision/?rev=26004
06:08 teknomunk joined 06:17 teknomunk joined 06:37 SCalimlim joined 06:41 Coke joined
svnbotl r26005 | chromatic++ | pdd17pmc: 07:03
: [PMC] Ported Object PMC to PDD 17 attribute declaration.
: The Class PMC now refers to the generated pmc_object.h file.
diff: parrotvm.org/svn/parrot/revision/?rev=26005
r26006 | chromatic++ | pdd17pmc: 07:10
: [PMC] Ported Role PMC to PDD 17 attribute declarations.
diff: parrotvm.org/svn/parrot/revision/?rev=26006
r26007 | chromatic++ | pdd17pmc: 07:17
: [PMC] Ported SchedulerMessage PMC to PDD 17 attribute declarations.
diff: parrotvm.org/svn/parrot/revision/?rev=26007
07:50 Alias joined 07:51 HG` joined
Tene Hmm... I'm trying to remember if I broke assignment in cardinal, or if I just hadn't fixed it yet... 08:24
I'm pretty sure it's the latter, and 'svn diff' doesn't show anything related to assignment, and 'make test' passes...
svnbotl r26008 | tene++ | trunk: 08:38
: Very very basic function support for cardinal.
: Allow defining functions that accept parameters.
: Allow calling functions with ()s.
: A few minor grammar fixes.
Tene reads up on MANIFEST 08:47
pmichaud MANIFEST is truly riveting. :-) 08:49
Alias :)
Although banal in comparison to the level of excitement in MANIFEST.SKIP
Tene ponders building a graph of rakudo's grammar. 08:51
pmichaud a graph? 08:52
purl somebody said a graph was a hint at something useful. It is an illustration.
Tene which rules call which other rules
pmichaud ahhh 08:53
Alias It would be helpful 08:57
svnbotl r26009 | tene++ | trunk:
: Add the functions test for cardinal to MANIFEST.
diff: parrotvm.org/svn/parrot/revision/?rev=26009
pmichaud perhaps it would be equally useful to produce such a graph for STD.pm
Tene solicits feedback on r26009 08:58
That was appropriate, right?
pmichaud looks right to me. Did you use mk_manifest_and_skip to add it?
and is languages/cardinal/t/02-functions.t actually committed to the repo? 08:59
Tene It is committed to the repo. I did not use mk_manifest_and_skip.
Should I have?
Would such a graph actually be useful, or just fun? 09:00
pmichaud mk_manifest_and_skip is the canonical mechanism for (re)generating MANIFEST 09:01
Tene If it's a generated file, why is it tracked in the repository?
pmichaud it exists for the tarball versions of Parrot (i.e., the releases) 09:02
Tene But I should be rebuilding it every time I add a file, right? 09:03
pmichaud yes
Tene Okay. Thanks.
Alias: helpful how? 09:12
Alias Tene: Anything that helps people get a bird's eye view of an entire subject is helpful 09:13
It would make it easier to learn the grammar 09:14
pmichaud I always did well in grammar school. :-)
"Plays well with others."
"Doesn't run with scissors." 09:15
Alias I always got "Could pay more attention"
Some say I'm a dreamer 09:16
pmichaud but you're not the only one?
(sorry, started channelling lennon for a second there.) 09:17
Alias That was my intent :)
pmichaud The clock here says 10:17am, but my body has no clue what time it is.
Tene lessee what I can hack together real quick.
Alias BTW, if you can make it work, I know an awesome tricky for search.cpan 09:18
I can make an image of the grammar appear in the POD docs on search.cpan :)
Tene I'm just doing a quick hand-built translation of rakudo's grammar.pg for now 09:23
pmichaud works
Tene can't think of anything interesting to do with literal text in a rule. 09:25
would it be relevant for me to include 'panic' or 'fail' nodes? 09:26
Hmm. -> #perl6 09:40
svnbotl r26010 | pmichaud++ | trunk:
: [pct]:
: * Fix '-e' option so that it also honors --target= and other options.
: * Patch from chromatic++ , with minor refactors.
: * Resolves RT#51116.
diff: parrotvm.org/svn/parrot/revision/?rev=26010
09:54 ptc joined 09:55 kj joined
Tene pleasedieinafire.net/~tene/grammar.png -- quick graph of rakudo's grammar.pm 10:07
svnbotl r26011 | kjs++ | trunk: 10:17
: [cardinal] add svn properties to new file.
diff: parrotvm.org/svn/parrot/revision/?rev=26011
pmichaud interesting. now I just need a big printer for it. 10:19
Tene Heh. 10:20
Now I'm considering the possibility of a --target=graph 10:21
kj tene: i saw you removed a default scope attribute for PAST::Var in method identifier in cardinal 10:24
10:26 c9s joined
Tene kj: I did. As I recall, it was emitting find_global when it should have been emitting find_lex 10:29
kj mm. ok. the :scope attribute must be set at some point
if it's not set, it will result in an error
pmichaud it can be inherited from an outer Block's symtable 10:30
kj pmichaud: what do you mean?
pmichaud each Block is allowed to keep a list of the symbols it defines and their scopes 10:31
kj right, using .symbol()
pmichaud right 10:32
if a PAST::Var node doesn't have a :scope attribute set, then PAST searches outwards through nested Blocks to find a block with a corresponding symbol
and uses the 'scope' attribute from there
kj oh. so PAST automatically looks in outer scopes if a symbol used in an inner scope was not found in that inner scope's symbol table? 10:33
pmichaud yes
kj ah i see. no need to write a loop to do it yourself then
pmichaud right
each scope only needs to keep track of the symbols it defines 10:34
it doesn't hurt for it to keep track of its outer scope's symbols, but it's not necessary
kj but when entering a symbol, you'd need to add a :scope() argument
pmichaud when defining a symbol? no, it doesn't need a :scope() argument -- it just needs an entry in the block's .symbol() table
for example 10:35
kj is it automatically set to 'lexical' then?
pmichaud my $x; does two things
1. It adds an entry to .scope for '$x' with a 'scope' of 'lexical'
2. It creates a PAST::Var node for $x (and the PAST::Var node doesn't need its own :scope attribute)
kj s/.scope/symbol table/ ? 10:36
ah i see
pmichaud yes
so, any standard variable can simply create a PAST::Var node, and rely on the nested blocks to provide the appropriate scope 10:37
kj i see.good to know. i'll update that in the pct docs
pmichaud btw, were you aware that the pct docs are one of the nlnet grant milestones? 10:38
kj ehm. no? 10:39
i just wrote down what i knew so i don't forget :-)
pmichaud given that I'm supposed to have done that milestone (for $2k), I'm thinking we should split it (assuming that I get around to updating it and adding things as well) 10:40
(and assumingyou're not ineligible for some reason) 10:41
kj well, then I really feel I should update them more thorougly; they're not that great yet imo 10:42
pmichaud we'll work on it together and figure out what to do with the money :-)
kj sure 10:43
pmichaud chromatic may also want to help -- he was interested in doing so last Dec (although not connected with the grant)
Tene pleasedieinafire.net/~tene/nqp.png -- I did nqp too, apparently.
pmichaud Tene++ 10:46
kj pmichaud: btw, did you have a chance to look at the patch i sent for PAST::Var :scope('attribute') ?
pmichaud kj: briefly
I decided not to apply it pre-Feb release
and since the release I've been (1) traveling, (2) catching up on sleep, (3) preparing for FOSDEM presentation 10:47
however,it's on my list of things to do very soon
kj ok. maybe the patch is not optimal, but it implements what I was thinking. Maybe there shouldn't be a default of "self" like you suggested.
ok good.
(otherwise I should change the docs, as they describe what i proposed) 10:48
pmichaud I'm still trying to decide how to represent 'self' in PAST
also 'outer' and 'caller'
kj and "super" maybe?
pmichaud well, does Parrot yet have a good way to handle 'super'? ;-) 10:49
kj ehm. not on PIR level
i think...
istr there was something for super, but i forgot
pmichaud there was, but it's never quite worked right iirc 10:50
kj and it gets tricky with multiple inheritance, not sure..
maybe it's also subject to the MRO stuff
pmichaud anyway, I can't decide if self/outer/caller are scopes, names, or something else altogether
kj aren't these often referred to as Pseudo variables?
or something like that/
'self','super'
pmichaud so, maybe :scope('pseudo') ? 10:52
kj my mind was thinking of PAST::Pseudo or PseudoVar, with :name('self') {super, outer, caller}
i guess it's just syntax there :-) 10:53
members.aol.com/m206ou/m206/M206_Sm...oVariables 10:54
shorten kj's url is at xrl.us/bgnwc
kj <<== smalltalk calls them pseudo vars
pmichaud they could almost be PAST::Op nodes, then, with :pasttype self/super/outer/caller 10:55
10:55 cotto joined
kj wrt self-documenting code: they're not really operations, are they? 10:56
Tene glances between STD.pm and bed.
pmichaud well, almost anything can be considered an operation :-)
Tene I was inspired by blog.nicksieger.com/articles/2006/1...ys-grammar fwiw 10:57
shorten Tene's url is at xrl.us/bgnwe
pmichaud ::Var makes sense if these are values that can be changed or assigned to
kj :-) yes, it doesn't really matter. They all have in common that they're referring to a certain object that is context-dependent
well, actually, "self" can be assigned to I think 10:58
in some languages
if it shouldn't be done, the language should throw an exception
maybe in the semantic analysis phase of the compiler 10:59
s/language/compiler/
pmichaud anyway, it's still percolating in my brain :-) 11:01
kj I'm sure it will result in something nice :-) 11:02
pmichaud I'm shutting down for a bit to preserve battery on my laptop
bbl
Tene can PGE currently parse STD.pm?
TimToady no 11:03
well, depends on what you mean by parse... 11:04
Tene Maybe I can write some dumb regexes to get the information I want... 11:05
TimToady glances between STD.pm and bed, and bed wins...
gah, 3am here...
thunk &
Tene Oh, right, rakudo can't do IO yet. 11:08
pmichaud STD.pm also has a number of interesting constructs that PGE doesn't understand yet 11:13
11:34 cognominal_ joined
svnbotl r26012 | kjs++ | trunk: 11:38
: [docs] update a bit on pct docs w.r.t. symbol handling and scopes. It could use a review at some point (hint, hint)
diff: parrotvm.org/svn/parrot/revision/?rev=26012
r26013 | paultcochrane++ | trunk: 11:45
: [core] For some reason svk hasn't picked up the svn properties properly, so
: setting them here. This in some sense is a test commit (for that I
: apologise in advance) so that I can make sure I haven't killed anything on
: the svn side. If this works, all the other files in my svk working copy
: with the appropriately updated svn properties will be committed.
diff: parrotvm.org/svn/parrot/revision/?rev=26013
r26014 | paultcochrane++ | trunk: 11:51
: [t] Updating svn properties appropriately so the file_metadata test runs
: correctly for svk working copies.
diff: parrotvm.org/svn/parrot/revision/?rev=26014
r26015 | paultcochrane++ | trunk: 11:58
: [lib] Updating svn properties appropriately so the file_metadata test runs
: correctly for svk working copies.
r26016 | paultcochrane++ | trunk:
: [rakudo] Updating svn properties appropriately so the file_metadata test runs
: correctly for svk working copies.
r26017 | paultcochrane++ | trunk:
: [abc] Updating svn properties appropriately so the file_metadata test runs
: correctly for svk working copies.
r26018 | paultcochrane++ | trunk:
: [core, config] Updating svn properties appropriately so the file_metadata
: test runs correctly for svk working copies.
diff: parrotvm.org/svn/parrot/revision/?rev=26018
cognominal_ good luck to pmichaud for his talk in a few minutes at fosdem 12:18
12:48 Coke joined
svnbotl r26019 | kjs++ | trunk: 13:01
: [c99]
: - add is pirop traits to basic operators
: - add postfix inc/dec operators
: - add several other actions, refactoring the grammar a bit
r26020 | kjs++ | trunk: 13:07
: [c99] add ternary operator + test.
diff: parrotvm.org/svn/parrot/revision/?rev=26020
13:08 PacoLinux joined
svnbotl r26021 | kjs++ | trunk: 13:32
: [c99]
: add prefix inc/dec operators
: and some other stuff.
r26022 | jkeenan++ | trunk:
: Inside file, correct references to file's own name in one comment and twice in POD.
diff: parrotvm.org/svn/parrot/revision/?rev=26022
13:36 kid51 joined 13:38 HG` joined 13:41 ptc joined
svnbotl r26023 | jkeenan++ | trunk: 14:28
: In two locations, eliminate excess wordspace before parens, thereby enabling this file to get past t/codingstd/c_parens.t.
diff: parrotvm.org/svn/parrot/revision/?rev=26023
14:29 davidfetter joined
svnbotl r26024 | kjs++ | trunk: 15:12
: [languages] update LANGUAGES_STATUS.pod on several points
diff: parrotvm.org/svn/parrot/revision/?rev=26024
15:26 rdice joined 15:31 Ron joined 15:33 Andy joined 15:54 iblechbot joined
svnbotl r26025 | petergibbs++ | trunk: 16:01
: More complete fix for the constant string problems in hll_info causing
: segfaults, refer also r25990 and RT#51122.
: This now enforces that constant String PMCs embed constant parrot strings.
r26026 | petdance++ | trunk:
16:30 DarkWolf84 joined 16:55 parrot-poke joined 17:25 Limbic_Region joined 17:37 svnbotl joined, Psyche^ joined 18:12 HG` left, HG` joined 18:38 barney joined
barney back with new notebook 18:39
19:10 slightlyoff joined 19:19 marmic joined 19:29 amoore joined
svnbotl r26027 | bernhard++ | trunk: 19:41
: [plumhead]
: verified with parrot 0.5.3
diff: parrotvm.org/svn/parrot/revision/?rev=26027
r26028 | bernhard++ | trunk: 19:59
: [Eclectus]
: verified with Parrot 0.5.3
diff: parrotvm.org/svn/parrot/revision/?rev=26028
20:05 pack|eet joined
barney ping cotto 20:26
purl I can't find cotto in the DNS.
svnbotl r26029 | bernhard++ | trunk: 20:50
: #51062: [NEW] PHPArray PMC
: Add an implementation of PHPArray.
: Courtesy of Christoph Otto.
diff: parrotvm.org/svn/parrot/revision/?rev=26029
r26030 | bernhard++ | trunk: 20:56
: [Plumhead]
: Update location of Wiki page
diff: parrotvm.org/svn/parrot/revision/?rev=26030
21:00 schmalbe joined
svnbotl r26031 | bernhard++ | trunk: 21:03
: [Plumhead]
: Update copyright dates for PHPArray files.
diff: parrotvm.org/svn/parrot/revision/?rev=26031
21:10 Andy joined 21:11 chromatic joined 21:13 barney joined 21:21 chromatic joined
svnbotl r26032 | bernhard++ | trunk: 21:28
: [Plumhead]
: Satisfy coding standard tests.
diff: parrotvm.org/svn/parrot/revision/?rev=26032
21:39 grim_fandango joined 21:44 Andy joined 21:46 IllvilJa joined 21:49 ruoso joined 21:54 kid51 joined 21:55 Theory joined 22:58 Psyche^ joined 23:33 kid51 joined 23:56 slightlyoff joined