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 Compile op with return values
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Leopold Toetsch  
View profile  
 More options Sep 1 2004, 3:33 am
Newsgroups: perl.perl6.internals
From: l...@toetsch.at (Leopold Toetsch)
Date: Wed, 1 Sep 2004 09:33:50 +0200
Local: Wed, Sep 1 2004 3:33 am
Subject: Re: Compile op with return values

Steve Fink <st...@fink.com> wrote:
> ... Leo's @ANON implementation of
> your scheme works great for me (I have no problem wrapping that around
> my code.) All this does raise the question of garbage collection for
> packfile objects; is there any?

Not yet. We basically have two kinds of dynamically compiled code:

1) loaded modules - persistent code used until end of program
2) evaled "statements" - volatile code, maybe used once only

But the current implementation doesn't know about that difference. The
compiled code is always appended to the list of code segments. There is
no interface yet to manipulate packfile segments.

We finally need a packfile PMC that is the owner of packfile segments.
If that PMC goes out of scope the compiled code structures can be freed.
This packfile PMC would also vastly eliminate the difference between 1)
and 2), the more when there is some interface to be able to append the
newly compiled code to existing code segments, so that you can e.g. dump
the combined code to disc.

But it would still be useful to differentiate between 1) and 2). For 1)
we could do global constant folding (if a constant already exists in the
main contant table just use it, or, if not, append to the main constant
table).

For 2) a distinct constant table is needed.

leo


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.