You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
286 B

3 years ago
class insn_mem:
3 years ago
memory = [8 * '0'] * 4 * 1024 * 16
3 years ago
def __init__(self) -> None:
pass
def fetch(self, address):
3 years ago
insn = self.memory[address + 3] + self.memory[address + 2] + \
self.memory[address + 1] + self.memory[address]
3 years ago
return insn