Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match_all(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 700

Warning: Invalid argument supplied for foreach() in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 701

Warning: preg_replace(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 705

Warning: preg_match_all(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 700

Warning: Invalid argument supplied for foreach() in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 701

Warning: preg_replace(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 705

Warning: preg_match_all(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 700

Warning: Invalid argument supplied for foreach() in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 701

Warning: preg_replace(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 705

Warning: preg_match_all(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 700

Warning: Invalid argument supplied for foreach() in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 701

Warning: preg_replace(): Compilation failed: group name must start with a non-digit at offset 4 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 705

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722

Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722
Introducing the Instruction Set Part 3 - Intellivision Wiki

Introducing the Instruction Set Part 3


Warning: preg_match(): Compilation failed: group name must start with a non-digit at offset 8 in /home/content/30/6867330/html/intellivision/wiki/includes/MagicWord.php on line 722
From Intellivision Wiki

Jump to: navigation, search
(Adding to the Program Counter)
(Unconditional Branches and Jumps)
Line 70: Line 70:
</TABLE>
</TABLE>
<br/>
<br/>
-
As you can see, the primary difference between branches and jumps is that branches are smaller and faster.  Branches encode their "target address," the address being jumped to, as a [[relative displacement]] to the current address.  Jumps, on the other hand, store the actual address of the target.  In most cases, especially in a 16-bit ROM, there are few reasons to use a [[J]] instruction, although the combination instructions, [[JD]] and [[JE]] can be useful.
+
As you can see, the primary difference between branches and jumps is that branches are smaller and faster.  Branches encode their "target address," the address being jumped to, as a relative offset from the current address.  Jumps, on the other hand, store the actual address of the target.  In most cases, especially in a 16-bit ROM, there are few reasons to use a [[J]] instruction, although the combination instructions, [[JD]] and [[JE]] can be useful.
<br/><br/>
<br/><br/>
There is also a pseudo-instruction, [[JR]], that allows "jumping to a location held in a register."  It is really a pseudonym for "[[MOVR]] Rx, R7".  Because it is a MOVR instruction, it will modify the [[Sign Flag]] and [[Zero Flag]], which may be confusing if you're not expecting it.  Otherwise, it is an efficient method for jumping to an address held in an register, such as when returning from a CALL.
There is also a pseudo-instruction, [[JR]], that allows "jumping to a location held in a register."  It is really a pseudonym for "[[MOVR]] Rx, R7".  Because it is a MOVR instruction, it will modify the [[Sign Flag]] and [[Zero Flag]], which may be confusing if you're not expecting it.  Otherwise, it is an efficient method for jumping to an address held in an register, such as when returning from a CALL.

Revision as of 08:37, 5 November 2007

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox