Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
mg_notes:65816_notes:addressing_modes [2019/06/24 15:24]
M.G. native address modes
mg_notes:65816_notes:addressing_modes [2019/06/24 16:04]
M.G.
Line 19: Line 19:
 | Accumulator | 0 | | | Accumulator | 0 | |
  
 +^ Simple Branches and Jumps ^^^^
 +^ Mode ^ Operand Size ^ Base Address ^ Effective Address \\ wrap to KKxxxx ^
 +| Absolute {JMP, JSR} | 2 | KK0000 | base+operand |
 +| Relative {8}        | 1 | {PC}  | PC+signed operand |
 +| Relative {16(BRL)} ​ | 2 | {PC} | PC+signed operand |
  
 ^ Simple and Basic Indexed Memory Access ^^^^ ^ Simple and Basic Indexed Memory Access ^^^^
 ^ Mode ^ Operand Size ^ Base Address ^ Effective Address ^ ^ Mode ^ Operand Size ^ Base Address ^ Effective Address ^
-| Absolute {JMPJSR} | 2 | KK0000 | base+operand | +| Absolute {not JMP/JSR} | 2 | BB0000 | base+operand |
-| Absolute {others} ​  | 2 | BB0000 | base+operand |+
 | Absolute,X or ,Y    | 2 | BB0000 | base+operand+X or Y | | Absolute,X or ,Y    | 2 | BB0000 | base+operand+X or Y |
 | Direct ​             | 1 | 00DDDD | base+operand,​ wrap to 00xxxx | | Direct ​             | 1 | 00DDDD | base+operand,​ wrap to 00xxxx |
 | Direct,X or ,Y      | 1 | 00DDDD | base+operand+X or Y, wrap to 00xxxx | | Direct,X or ,Y      | 1 | 00DDDD | base+operand+X or Y, wrap to 00xxxx |
-| Long                | 3 | 000000 ​base+operand | +| Long                | 3 |  | operand | 
-| Long,​X ​             | 3 | 000000 ​base+operand+x | +| Long,​X ​             | 3 |  | operand+|
-| Relative {8}        | 1 | KK0000 | base+signed operand, wrap to KKxxxx | +
-| Relative {16(BRL)} ​ | 2 | KK0000 | base+signed operand, wrap to KKxxxx ​|+
  
 ^ Basic Stack Access ^^^^ ^ Basic Stack Access ^^^^
-^ Mode ^ Operand Size ^ Base Address ^ Effective Address ^ +^ Mode ^ Operand Size ^ Base Address ^ Effective Address ​\\ wrap to 00xxxx ​
-| Stack {push, pull}  | 0 | 00SSSS ​| base+0, wrap to 00xxxx ​+| Stack {push, pull}  | 0 | 00SSSS ​(before decrement/​after increment) ​
-| Stack,​S ​            | 1 | 00SSSS | base+operand, wrap to 00xxxx ​|+| Stack,​S ​            | 1 | 00SSSS | base+operand |
  
 ^ Stack Indirect Access ^^^^^^^ ^ Stack Indirect Access ^^^^^^^
-^ Mode ^ Operand Size ^ Pointer Base Address ^ Pointer EA  ^ Pointer Size ^ Target Base ^ Target EA ^ +^ Mode ^ Operand Size ^ Pointer Base Address ^ Pointer EA \\ wrap to 00xxxx ​^ Pointer Size ^ Target Base ^ Target EA ^ 
-| (Stack,S) | 1 | 00SSSS | base+operand ​(wrap to 00xxxx) ​| 2 | BB0000 | base+pointer | +| (Stack,S) | 1 | 00SSSS | base+operand | 2 | BB0000 | base+pointer | 
  
 ^ Indirect Jumps ^^^^^^^ ^ Indirect Jumps ^^^^^^^
-^ Mode ^ Operand Size ^ Pointer Base Address ^ Pointer EA  ^ Pointer Size ^ Target Base ^ Target EA (wrap to KKxxxx) ​+^ Mode ^ Operand Size ^ Pointer Base Address ^ Pointer EA  ^ Pointer Size ^ Target Base ^ Target EA ^ 
-| (Absolute) {JMP}    | 2 | KK0000 | base+operand | 2 | KK0000 | base+pointer | +| (Absolute) {JMP}    | 2 | KK0000 | base+operand | 2 | KK0000 | base+pointer, wrap to KKxxxx ​
-| (Absolute,​X) {JMP}  | 2 | KK0000 | base+operand+X | 2 | KK0000 | base+pointer | +| (Absolute,​X) {JMP}  | 2 | KK0000 | base+operand+X | 2 | KK0000 | base+pointer, wrap to KKxxxx ​
-| [Absolute] {JML}    | 2 | KK0000 | base+operand | 3 | 000000 ​base+pointer |+| [Absolute] {JML}    | 2 | KK0000 | base+operand | 3 | | pointer |
  
  
 ^ Direct Page Indirect ^^^^^^^ ^ Direct Page Indirect ^^^^^^^
-^ Mode ^ Operand Size ^ Pointer Base Address ​(Wrap to 00xxxx) ​^ Pointer EA  ^ Pointer Size ^ Target Base ^ Target EA ^+^ Mode ^ Operand Size ^ Pointer Base Address ^ Pointer EA \\ wrap to 00xxxx ​ ^ Pointer Size ^ Target Base ^ Target EA ^
 | (Direct) ​           | 1 | 00DDDD | base+operand | 2 | BB0000 | base+pointer | | (Direct) ​           | 1 | 00DDDD | base+operand | 2 | BB0000 | base+pointer |
-| [Direct] ​           | 1 | 00DDDD | base+operand | 3 | 000000 | base+pointer ​ | 
 | (Direct,​X) ​         | 1 | 00DDDD | base+operand+X | 2 | BB0000 | base+pointer ​ | | (Direct,​X) ​         | 1 | 00DDDD | base+operand+X | 2 | BB0000 | base+pointer ​ |
 | (Direct),​Y ​         | 1 | 00DDDD | base+operand | 2 | BB0000 | base+pointer+Y | | (Direct),​Y ​         | 1 | 00DDDD | base+operand | 2 | BB0000 | base+pointer+Y |
-| [Direct],​Y ​         | 1 | 00DDDD | base+operand | 3 | 000000 ​base+pointer+Y | +| [Direct] ​           | 1 | 00DDDD | base+operand | 3 | | pointer ​ | 
 +| [Direct],​Y ​         | 1 | 00DDDD | base+operand | 3 | | pointer+Y |
  
 +^ Memory Move {MVN, MVP} ^^^
 +^ Mode ^ Operand Size ^ Notes ^
 +| Src {II}, Dest {JJ} | 2 * 1 | Effective addresses for the move are II0000+X and JJ0000+Y, \\ wrapped at the bank boundary. |