Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Possible GC bug in Rakudo (parrot r27449, r27451)
There appears to be a possible GC-related bug introduced to Parrot
prior to r27449 which is showing up in Rakudo.  Using the following
script (courtesy of Jonathan W):

--------------------------------
class Foo {
has $.x;
method boo { say $.x }
}

class Bar is Foo {
method set($v) { $.x = $v }
}

my Foo $u .= new(x => 5);
$u.boo;                    # 5

$u= Bar.new(Foo{ x => 12 });
$u.boo;                    # 12
$u.set(9);
$u.boo;                    # 9
--------------------------------

'perl6 obj_init.p6' results :

5
Segmentation fault

--------------------------------

'parrot ~/src/parrot/languages/perl6/perl6.pbc obj_init.p6' results:

cjfields:tests cjfields$ parrot ~/src/parrot/languages/perl6/perl6.pbc
obj_init.p6
5
get_pmc_keyed() not implemented in class 'Undef'
current instr.: '_block10' pc 137 (EVAL_13:46)
called from Sub 'parrot;PCT::HLLCompiler;eval' pc 785 (src/PCT/
HLLCompiler.pir:458)
called from Sub 'parrot;PCT::HLLCompiler;evalfiles' pc 1067 (src/PCT/
HLLCompiler.pir:587)
called from Sub 'parrot;PCT::HLLCompiler;command_line' pc 1246 (src/
PCT/HLLCompiler.pir:676)
called from Sub 'parrot;Perl6::Compiler;main' pc 9647 (perl6.pir:187)

--------------------------------

'parrot -G ~/src/parrot/languages/perl6/perl6.pbc obj_init.p6' results:

5
get_pmc_keyed() not implemented in class 'Any'
current instr.: '_block10' pc 137 (EVAL_13:46)
called from Sub 'parrot;PCT::HLLCompiler;eval' pc 785 (src/PCT/
HLLCompiler.pir:458)
called from Sub 'parrot;PCT::HLLCompiler;evalfiles' pc 1067 (src/PCT/
HLLCompiler.pir:587)
called from Sub 'parrot;PCT::HLLCompiler;command_line' pc 1246 (src/
PCT/HLLCompiler.pir:676)
called from Sub 'parrot;Perl6::Compiler;main' pc 9647 (perl6.pir:187)

--------------------------------

Note difference with Any (-G) vs Undef (no -G).  Not sure if it means
anything.

-chris


Report this thread to moderator Post Follow-up to this message
Old Post
Chris Fields
05-12-08 10:16 AM


Re: Possible GC bug in Rakudo (parrot r27449, r27451)
Chris Fields wrote:
> There appears to be a possible GC-related bug introduced to Parrot
> prior to r27449 which is showing up in Rakudo.  Using the following
> script (courtesy of Jonathan W):
> <snip>
After investigating a little, the breakage occurred in:
http://www.parrotvm.org/svn/parrot/revision?rev=27447

Basically, protoobjects didn't handle the switch-over to using the new
copy opcode for :pasttype('copy') nodes properly. Fixed in r27539, so
this example runs again.

Thanks,

Jonathan



Report this thread to moderator Post Follow-up to this message
Old Post
Jonathan Worthington
05-16-08 01:35 PM


Re: Possible GC bug in Rakudo (parrot r27449, r27451)
That also fixes the bus error I reported in rt:

http://rt.perl.org/rt3/Public/Bug/Display.html?id=54004

I went ahead and closed that ticket out.  jonathan++

Thanks!

chris

On May 16, 2008, at 7:01 AM, Jonathan Worthington wrote:

> Chris Fields wrote: 
> After investigating a little, the breakage occurred in:
> http://www.parrotvm.org/svn/parrot/revision?rev=27447
>
> Basically, protoobjects didn't handle the switch-over to using the
> new copy opcode for :pasttype('copy') nodes properly. Fixed in
> r27539, so this example runs again.
>
> Thanks,
>
> Jonathan
>

Christopher Fields
Postdoctoral Researcher
Lab of Dr. Marie-Claude Hofmann
College of Veterinary Medicine
University of Illinois Urbana-Champaign


Report this thread to moderator Post Follow-up to this message
Old Post
Chris Fields
05-17-08 12:33 AM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

Perl 6 Compiler archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 09:26 AM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.