On Thu, Aug 7, 2008 at 10:04 AM, jerry gay <[EMAIL PROTECTED]> wrote:
> On Thu, Aug 7, 2008 at 5:44 AM, Jonathan Worthington <[EMAIL PROTECTED]> 
> wrote:
>> Klaas-Jan Stol wrote:
>>>
>>> I think basically the question remans; is there any way we could do
>>> without the :unique_reg?
>>>
>> Yes:
>>
>> 1) Add the reference-taking op and register reference PMC to the Parrot
>> core.
>>
>> 2) Make IMCC specially aware of this op so that it never re-uses this
>> register.
>>
> also, if i understand satisfy patrick's use case in pge,
>
> 3) add the ability to select the register allocator used, or disable
> it, within a sub.
>
> a programmer who knows what he's doing should have the ability to
> disable the register allocator and manage registers himself. the scope
> of the action must be limited to make the intent clear and to ease
> maintenance programming; it must occur at the sub level rather than at
> the file level.

As noted earlier, you cannot really do this with the currently
documented version of PIR in PDD19. There is no way to say "use this
register". If someone wants this level of control and to ignore the
register allocator, I would expect them to write PASM instead of PIR,
based on my understanding of the recent revisions to PDD19.

Now, if the problem is that the register allocator is broken, then
let's fix the register allocator. If :unique_reg is just a workaround
because fixing it is hard, let's document it as deprecated with the
expectation that it will be removed when the allocator is no longer
broken.

(This is ignoring Jonathan's use case for the moment)

> ~jerry
>



-- 
Will "Coke" Coleda

Reply via email to