develooper Front page | perl.perl6.internals | Postings from October 2001

Re: Fetching the PC?

Thread Previous | Thread Next
From:
Dan Sugalski
Date:
October 12, 2001 07:37
Subject:
Re: Fetching the PC?
Message ID:
5.1.0.14.2.20011012103504.01c80058@pop.sidhe.org
At 03:04 PM 10/12/2001 +0200, Ritz Daniel wrote:
> > I think the confusion's because the jump opcode's broken. When you say
> >
> >    jump 12
> >
> > It should jump to absolute address 12, not 12 bytes/words/opcodes from the
> > current position.
>
>i fixed that. but ther's only a jump_i, no jump_ic...
>
>"jump Ix" now jumps to the absolute address held in a register Ix. 
>Absolute means
>start of the bytecode + Ix.

It can't mean that. This:

   set I0, 0
   jump I0

should coredump.

>the following code will result in a simple program restart,
>no core dump:
>     set I1, 0
>     jump I1
>
>the fixed jump breaks the tests: basic5, call.pasm, jump.pasm
>but i wonder why nobody realized that jump's broken, the doc says it jumps 
>_to_
>the address, not forward or backward........

That was brought up a while ago, but I don't think anyone's had time to put 
a patch in. I'm working on stack and jsr support, so I'll fix it then.

					Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
dan@sidhe.org                         have teddy bears and even
                                      teddy bears get drunk


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About