// // Disassembler6502.hpp // Clock Signal // // Created by Thomas Harte on 10/11/2016. // Copyright © 2016 Thomas Harte. All rights reserved. // #ifndef Disassembler6502_hpp #define Disassembler6502_hpp #include #include #include #include namespace StaticAnalyser { namespace MOS6502 { struct Instruction { uint16_t address; enum { BRK, ORA, KIL, SLO, NOP, ASL, PHP, ANC, BPL } operation; enum { Absolute, AbsoluteIndirect, Accumulator, Immediate, Implied, IndexAbsolute, IndexedZeroPage, IndexedIndirectX, IndirectIndexedY, Relative, ZeroPage } addressing_mode; uint16_t operand; }; struct Disassembly { std::vector instructions; std::set outward_calls; }; std::unique_ptr Disassemble(std::vector memory, uint16_t start_address, std::vector entry_points); } } #endif /* Disassembler6502_hpp */