Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Dynamic PMC Classes

Newsgroups: perl.perl6.internals
Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!nntp.perl.org
Return-Path: <mbar...@dsi.unive.it>
Mailing-List: contact perl6-internals-h...@perl.org; run by ezmlm
Delivered-To: mailing list perl6-intern...@perl.org
Delivered-To: perl6-intern...@perl.org
Received-SPF: unknown
Date: Tue, 5 Aug 2003 21:59:28 +0200 (ora legale Europa occidentale)
Subject: Re[2]: [RFC] Dynamic PMC Classes
To: perl6-intern...@perl.org, l...@toetsch.at
Message-ID: <Mahogany-0.64.2-1176-20030805-215928.00@rbnet.it>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
Content-Disposition: INLINE
References: <3F27A15C.3060301@nextra.at> <a05210619bb4d98a1d514@[63.120.19.221]> <200307310910.h6V9AI222337@thu8.leo.home> <a0521061ebb4eaaf5358c@[63.120.19.221]> <200308051559.h75Fxao03410@thu8.leo.home>
In-Reply-To: <200308051559.h75Fxao03410@thu8.leo.home>
X-Mailer: Mahogany 0.64.2 'Sparc', running under Windows NT 5.0 (build 2195, Service Pack 3)
X-SMTPD: qpsmtpd/0.27-dev, http://develooper.com/code/qpsmtpd/
X-Spam-Check-By: one.develooper.com
X-Spam-Status: No, hits=-1.3 required=7.0 tests=CARRIAGE_RETURNS,IN_REP_TO,QUOTED_EMAIL_TEXT,REFERENCES,SPAM_PHRASE_01_02 version=2.44
X-SMTPD: qpsmtpd/0.26, http://develooper.com/code/qpsmtpd/
Approved: n...@nntp.perl.org
From: mbar...@dsi.unive.it (Mattia Barbon)
Lines: 32

On Tue, 5 Aug 2003 17:59:36 +0200 Leopold Toetsch <l...@toetsch.at> wrote:

> Dan Sugalski <d...@sidhe.org> wrote:
> > At 11:10 +0200 7/31/03, Leopold Toetsch wrote:
> >>  > *) Determine the init and setup routine names
> >>
> >>- Parrot_<classname>_class_setup
> >>- Parrot_<classname>_class_init
> >>
> >>The class_setup also sets the class_enum i.e vtable->base_type.
> 
> > Well... there are versioning issues there. We ought to be able to
> > have multiple versions of a class loaded, in which case this may not
> > work. I'm pretty sure that there are some platforms that require
> > unique names in libraries across the entire process.
> 
> What about the following (also considering, that we might not like one
> handle/mmap... per PMC, as stated in one f'up):
> 
> A dynamic PMC library has one init function returning a dyn_pmc_info
> structure:
  Why not do it (more or less) the way Perl5 does it? Have a
"load_and_init" operation which loads a dynamic library and calls some
predefined function in it (just pick a name). That function can then
register new PMCs, opcodes, events, whatever you like using normal Parrot_*
API functions. This can be made to be exactly as efficient as your
proposal, and I think it is more flexible.

Regards
Mattia