[A83] Re: Conditional bcall()ing
[Prev][Next][Index][Thread]
[A83] Re: Conditional bcall()ing
At 08:25 2001-10-29, you wrote:
>I understand what you try to say... But... It does matters, since the
>hexadecimal 'relativeness' in a JR is a two's complement of the number of
>bytes to jump from the start of the JR instruction. At least that's what
>I've understood, never figured why they called it a 'complement' (since it
>doesn't do things like 'XOR and such', it only substracts 2).
Yes, you are completly right. The argument to jr is relative the next
instruction.
BUT $ has nothing to do with this. And the construct "$+0" was what we was
talking about and the whole point of the discussion was that "jr $+0" is
NOT the same thing as "jr 0", since $ is calculated from the _current_
instruction and not the next.
I hope everybody has this clear now :)
(In the code we was discussing, you could write "jr 3" instead of "jr $+5",
but not "jr $+3")
///Olle
References: