As far as I understand LEA, if a memory access happen depends on the addressing mode.
It depends on how the description or information 'read_from_memory' is meant or used for ...
Code: Select all
LEA: {'HNZVC': '-----',
[..]
'instr_desc': 'Load effective address into stack pointer',
'mnemonic': {'LEAS': {'desc': 'S = EA',
'operand': REG_S,
'ops': {0x32: {'addr_mode': INDEXED,
'bytes': 2,
'cycles': 4}},
'read_from_memory': None,
'write_to_memory': None},
'LEAU': {'desc': 'U = EA',
'operand': REG_U,
'ops': {0x33: {'addr_mode': INDEXED,
'bytes': 2,
'cycles': 4}},
'read_from_memory': None,
'write_to_memory': None},
'LEAX': {'desc': 'X = EA',
'operand': REG_X,
'ops': {0x30: {'addr_mode': INDEXED,
'bytes': 2,
'cycles': 4}},
'read_from_memory': None,
'write_to_memory': None},
'LEAY': {'desc': 'Y = EA',
'operand': REG_Y,
'ops': {0x31: {'addr_mode': INDEXED,
'bytes': 2,
'cycles': 4}},
'read_from_memory': None,
'write_to_memory': None}},
'operation': "R' = EA",
'source form': 'LEAX, LEAY, LEAS, LEAU'},
...
Just in case of a strict definition any indirect addressing modes implies actual a read:
[disp,R]
[,--R]
[,R++]
[A,R]
[B,R]
[D,R]
[disp,PC]
[address]
They all read a word because each has to fetch the effective address from memory ...
In not LEA-cases, multiple reads or read followed by writes may occur.
To take this thought further, JSR produces reads for indexed indirect addressing modes too, beside the fact that the saving of the PC to the stack could be regarded as writes too. So,
Code: Select all
'read_from_memory': None,
'write_to_memory': None}},
might no hold in this or similar cases ...