yaze 0.2.0
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::app::emu::Cpu Class Reference

#include <cpu.h>

Inheritance diagram for yaze::app::emu::Cpu:
Collaboration diagram for yaze::app::emu::Cpu:

Public Types

enum class  AccessType { Control , Data }
 

Public Member Functions

 Cpu (memory::Memory &mem, Clock &vclock, memory::CpuCallbacks &callbacks)
 
void Reset (bool hard=false)
 
void RunOpcode ()
 
void ExecuteInstruction (uint8_t opcode)
 
void LogInstructions (uint16_t PC, uint8_t opcode, uint16_t operand, bool immediate, bool accumulator_mode)
 
void UpdatePC (uint8_t instruction_length)
 
void UpdateClock (int delta_time)
 
void SetIrq (bool state)
 
void Nmi ()
 
uint8_t GetInstructionLength (uint8_t opcode)
 
void DoInterrupt ()
 
void SetFlags (uint8_t val)
 
void SetZN (uint16_t value, bool byte)
 
bool m ()
 
bool xf ()
 
int GetAccumulatorSize () const
 
int GetIndexSize () const
 
void SetAccumulatorSize (bool set)
 
void SetIndexSize (bool set)
 
void SetNegativeFlag (bool set)
 
void SetOverflowFlag (bool set)
 
void SetBreakFlag (bool set)
 
void SetDecimalFlag (bool set)
 
void SetInterruptFlag (bool set)
 
void SetZeroFlag (bool set)
 
void SetCarryFlag (bool set)
 
bool GetNegativeFlag () const
 
bool GetOverflowFlag () const
 
bool GetBreakFlag () const
 
bool GetDecimalFlag () const
 
bool GetInterruptFlag () const
 
bool GetZeroFlag () const
 
bool GetCarryFlag () const
 
uint8_t ReadOpcode ()
 
uint16_t ReadOpcodeWord (bool int_check=false)
 
uint8_t ReadByte (uint32_t address)
 
uint16_t ReadWord (uint32_t address, uint32_t address_high, bool int_check=false)
 
uint32_t ReadWordLong (uint32_t address)
 
void WriteByte (uint32_t address, uint8_t value)
 
void WriteWord (uint32_t address, uint32_t address_high, uint16_t value, bool reversed=false, bool int_check=false)
 
void WriteLong (uint32_t address, uint32_t value)
 
void PushByte (uint8_t value)
 
void PushWord (uint16_t value, bool int_check=false)
 
void PushLong (uint32_t value)
 
uint8_t PopByte ()
 
uint16_t PopWord (bool int_check=false)
 
uint32_t PopLong ()
 
void DoBranch (bool check)
 
void set_int_delay (bool delay)
 
uint32_t Absolute (uint32_t *low)
 
uint32_t AbsoluteIndexedX ()
 
uint32_t AdrAbx (uint32_t *low, bool write)
 
uint32_t AbsoluteIndexedY ()
 
uint32_t AdrAby (uint32_t *low, bool write)
 
void AdrImp ()
 
uint32_t AdrIdx (uint32_t *low)
 
uint32_t AdrIdp (uint32_t *low)
 
uint32_t AdrIdy (uint32_t *low, bool write)
 
uint32_t AdrIdl (uint32_t *low)
 
uint32_t AdrIly (uint32_t *low)
 
uint32_t AdrIsy (uint32_t *low)
 
uint32_t Immediate (uint32_t *low, bool xFlag)
 
uint16_t AbsoluteIndexedIndirect ()
 
uint16_t AbsoluteIndirect ()
 
uint32_t AbsoluteIndirectLong ()
 
uint32_t AbsoluteLong ()
 
uint32_t AdrAbl (uint32_t *low)
 
uint32_t AbsoluteLongIndexedX ()
 
uint32_t AdrAlx (uint32_t *low)
 
void BlockMove (uint16_t source, uint16_t dest, uint16_t length)
 
uint16_t DirectPage ()
 
uint32_t AdrDp (uint32_t *low)
 
uint16_t DirectPageIndexedX ()
 
uint32_t AdrDpx (uint32_t *low)
 
uint16_t DirectPageIndexedY ()
 
uint32_t AdrDpy (uint32_t *low)
 
uint16_t DirectPageIndexedIndirectX ()
 
uint16_t DirectPageIndirect ()
 
uint32_t DirectPageIndirectLong ()
 
uint16_t DirectPageIndirectIndexedY ()
 
uint32_t DirectPageIndirectLongIndexedY ()
 
uint16_t Immediate (bool index_size=false)
 
uint16_t StackRelative ()
 
uint32_t AdrSr (uint32_t *low)
 
uint32_t StackRelativeIndirectIndexedY ()
 
void ADC (uint16_t operand)
 
void AND (uint32_t address, bool immediate=false)
 
void ANDAbsoluteLong (uint32_t address)
 
void ASL (uint16_t address)
 
void BCC (int8_t offset)
 
void BCS (int8_t offset)
 
void BEQ (int8_t offset)
 
void BIT (uint16_t address)
 
void BMI (int8_t offset)
 
void BNE (int8_t offset)
 
void BPL (int8_t offset)
 
void BRA (int8_t offset)
 
void BRK ()
 
void BRL (int16_t offset)
 
void BVC (int8_t offset)
 
void BVS (int8_t offset)
 
void CLC ()
 
void CLD ()
 
void CLI ()
 
void CLV ()
 
void CMP (uint32_t address, bool immediate=false)
 
void COP ()
 
void CPX (uint32_t address, bool immediate=false)
 
void CPY (uint32_t address, bool immediate=false)
 
void DEC (uint32_t address, bool accumulator=false)
 
void DEX ()
 
void DEY ()
 
void EOR (uint32_t address, bool immediate=false)
 
void INC (uint32_t address, bool accumulator=false)
 
void INX ()
 
void INY ()
 
void JMP (uint16_t address)
 
void JML (uint16_t address)
 
void JSR (uint16_t address)
 
void JSL (uint16_t address)
 
void LDA (uint16_t address, bool immediate=false, bool direct_page=false, bool data_bank=false)
 
void LDX (uint16_t address, bool immediate=false)
 
void LDY (uint16_t address, bool immediate=false)
 
void LSR (uint16_t address, bool accumulator=false)
 
void MVN ()
 
void MVP ()
 
void NOP ()
 
void ORA (uint32_t low, uint32_t high)
 
void PEA ()
 
void PEI ()
 
void PER ()
 
void PHA ()
 
void PHB ()
 
void PHD ()
 
void PHK ()
 
void PHP ()
 
void PHX ()
 
void PHY ()
 
void PLA ()
 
void PLB ()
 
void PLD ()
 
void PLP ()
 
void PLX ()
 
void PLY ()
 
void REP ()
 
void ROL (uint32_t address, bool accumulator=false)
 
void ROR (uint32_t address, bool accumulator=false)
 
void RTI ()
 
void RTL ()
 
void RTS ()
 
void SBC (uint32_t operand, bool immediate=false)
 
void SEC ()
 
void SED ()
 
void SEI ()
 
void SEP ()
 
void STA (uint32_t address)
 
void STP ()
 
void STX (uint16_t address)
 
void STY (uint16_t address)
 
void STZ (uint16_t address)
 
void TAX ()
 
void TAY ()
 
void TCD ()
 
void TCS ()
 
void TDC ()
 
void TRB (uint16_t address)
 
void TSB (uint16_t address)
 
void TSC ()
 
void TSX ()
 
void TXA ()
 
void TXS ()
 
void TXY ()
 
void TYA ()
 
void TYX ()
 
void WAI ()
 
void WDM ()
 
void XBA ()
 
void XCE ()
 
void And (uint32_t low, uint32_t high)
 
void Eor (uint32_t low, uint32_t high)
 
void Adc (uint32_t low, uint32_t high)
 
void Sbc (uint32_t low, uint32_t high)
 
void Cmp (uint32_t low, uint32_t high)
 
void Cpx (uint32_t low, uint32_t high)
 
void Cpy (uint32_t low, uint32_t high)
 
void Bit (uint32_t low, uint32_t high)
 
void Lda (uint32_t low, uint32_t high)
 
void Ldx (uint32_t low, uint32_t high)
 
void Ldy (uint32_t low, uint32_t high)
 
void Sta (uint32_t low, uint32_t high)
 
void Stx (uint32_t low, uint32_t high)
 
void Sty (uint32_t low, uint32_t high)
 
void Stz (uint32_t low, uint32_t high)
 
void Ror (uint32_t low, uint32_t high)
 
void Rol (uint32_t low, uint32_t high)
 
void Lsr (uint32_t low, uint32_t high)
 
void Asl (uint32_t low, uint32_t high)
 
void Inc (uint32_t low, uint32_t high)
 
void Dec (uint32_t low, uint32_t high)
 
void Tsb (uint32_t low, uint32_t high)
 
void Trb (uint32_t low, uint32_t high)
 
uint16_t SP () const
 
void SetSP (uint16_t value)
 
bool IsBreakpoint (uint32_t address)
 
void SetBreakpoint (uint32_t address)
 
void ClearBreakpoint (uint32_t address)
 
void ClearBreakpoints ()
 
auto GetBreakpoints ()
 
void CheckInt ()
 
auto mutable_log_instructions () -> bool *
 
- Public Member Functions inherited from yaze::app::core::ExperimentFlags
 ExperimentFlags ()=default
 
virtual ~ExperimentFlags ()=default
 
auto flags () const
 
Flagsmutable_flags ()
 
std::string Serialize () const
 

Public Attributes

std::vector< uint32_t > breakpoints_
 
std::vector< InstructionEntryinstruction_log_
 
uint16_t A = 0
 
uint16_t X = 0
 
uint16_t Y = 0
 
uint16_t D = 0
 
uint8_t DB = 0
 
uint8_t PB = 0
 
uint16_t PC = 0
 
uint8_t E = 1
 
uint8_t status = 0b00110000
 

Private Member Functions

void compare (uint16_t register_value, uint16_t memory_value)
 
void SetFlag (uint8_t mask, bool set)
 
bool GetFlag (uint8_t mask) const
 

Private Attributes

bool log_instructions_ = false
 
bool waiting_ = false
 
bool stopped_ = false
 
bool irq_wanted_ = false
 
bool nmi_wanted_ = false
 
bool reset_wanted_ = false
 
bool int_wanted_ = false
 
bool int_delay_ = false
 
memory::CpuCallbacks callbacks_
 
memory::Memorymemory
 
Clockclock
 

Detailed Description

Definition at line 38 of file cpu.h.

Member Enumeration Documentation

◆ AccessType

Enumerator
Control 
Data 

Definition at line 148 of file cpu.h.

Constructor & Destructor Documentation

◆ Cpu()

yaze::app::emu::Cpu::Cpu ( memory::Memory & mem,
Clock & vclock,
memory::CpuCallbacks & callbacks )
inlineexplicit

Definition at line 40 of file cpu.h.

Member Function Documentation

◆ Reset()

void yaze::app::emu::Cpu::Reset ( bool hard = false)

Definition at line 15 of file cpu.cc.

References A, D, DB, E, int_delay_, int_wanted_, irq_wanted_, nmi_wanted_, PB, PC, reset_wanted_, status, stopped_, waiting_, X, and Y.

Referenced by yaze::app::emu::SNES::Reset().

◆ RunOpcode()

◆ ExecuteInstruction()

◆ LogInstructions()

void yaze::app::emu::Cpu::LogInstructions ( uint16_t PC,
uint8_t opcode,
uint16_t operand,
bool immediate,
bool accumulator_mode )

Definition at line 1805 of file cpu.cc.

References A, D, DB, yaze::app::core::ExperimentFlags::flags(), instruction_log_, opcode_to_mnemonic, PB, PC, SP(), status, X, and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ UpdatePC()

void yaze::app::emu::Cpu::UpdatePC ( uint8_t instruction_length)
inline

Definition at line 51 of file cpu.h.

References PC.

◆ UpdateClock()

void yaze::app::emu::Cpu::UpdateClock ( int delta_time)
inline

Definition at line 52 of file cpu.h.

References clock, and yaze::app::emu::Clock::UpdateClock().

Here is the call graph for this function:

◆ SetIrq()

void yaze::app::emu::Cpu::SetIrq ( bool state)
inline

◆ Nmi()

void yaze::app::emu::Cpu::Nmi ( )
inline

Definition at line 55 of file cpu.h.

References nmi_wanted_.

Referenced by yaze::app::emu::SNES::RunCycle(), and yaze::app::emu::SNES::WriteReg().

◆ GetInstructionLength()

uint8_t yaze::app::emu::Cpu::GetInstructionLength ( uint8_t opcode)

◆ DoInterrupt()

void yaze::app::emu::Cpu::DoInterrupt ( )

Definition at line 87 of file cpu.cc.

References callbacks_, yaze::app::emu::memory::CpuCallbacks::idle, int_wanted_, nmi_wanted_, PB, PC, PushByte(), PushWord(), ReadWord(), SetDecimalFlag(), SetInterruptFlag(), and status.

Referenced by RunOpcode().

Here is the call graph for this function:

◆ SetFlags()

void yaze::app::emu::Cpu::SetFlags ( uint8_t val)
inline

Definition at line 99 of file cpu.h.

References E, GetIndexSize(), SetAccumulatorSize(), SetIndexSize(), SetSP(), SP(), status, X, and Y.

Referenced by ExecuteInstruction(), and RunOpcode().

Here is the call graph for this function:

◆ SetZN()

void yaze::app::emu::Cpu::SetZN ( uint16_t value,
bool byte )
inline

Definition at line 112 of file cpu.h.

References SetNegativeFlag(), and SetZeroFlag().

Referenced by Adc(), And(), Asl(), Cmp(), Cpx(), Cpy(), Dec(), Eor(), ExecuteInstruction(), Inc(), Lda(), Ldx(), Ldy(), Lsr(), Rol(), Ror(), and Sbc().

Here is the call graph for this function:

◆ m()

bool yaze::app::emu::Cpu::m ( )
inline

Definition at line 123 of file cpu.h.

References GetAccumulatorSize().

Here is the call graph for this function:

◆ xf()

bool yaze::app::emu::Cpu::xf ( )
inline

Definition at line 124 of file cpu.h.

References GetIndexSize().

Here is the call graph for this function:

◆ GetAccumulatorSize()

int yaze::app::emu::Cpu::GetAccumulatorSize ( ) const
inline

◆ GetIndexSize()

int yaze::app::emu::Cpu::GetIndexSize ( ) const
inline

Definition at line 126 of file cpu.h.

References status.

Referenced by AdrAbx(), AdrAby(), AdrIdy(), compare(), Cpx(), Cpy(), ExecuteInstruction(), Immediate(), Ldx(), Ldy(), SetFlags(), Stx(), Sty(), and xf().

◆ SetAccumulatorSize()

void yaze::app::emu::Cpu::SetAccumulatorSize ( bool set)
inline

Definition at line 127 of file cpu.h.

References SetFlag().

Referenced by yaze::app::zelda3::dungeon::DungeonObjectRenderer::ConfigureObject(), and SetFlags().

Here is the call graph for this function:

◆ SetIndexSize()

void yaze::app::emu::Cpu::SetIndexSize ( bool set)
inline

Definition at line 128 of file cpu.h.

References SetFlag().

Referenced by yaze::app::zelda3::dungeon::DungeonObjectRenderer::ConfigureObject(), and SetFlags().

Here is the call graph for this function:

◆ SetNegativeFlag()

void yaze::app::emu::Cpu::SetNegativeFlag ( bool set)
inline

Definition at line 131 of file cpu.h.

References SetFlag().

Referenced by Bit(), compare(), ORA(), and SetZN().

Here is the call graph for this function:

◆ SetOverflowFlag()

void yaze::app::emu::Cpu::SetOverflowFlag ( bool set)
inline

Definition at line 132 of file cpu.h.

References SetFlag().

Referenced by Adc(), Bit(), ExecuteInstruction(), and Sbc().

Here is the call graph for this function:

◆ SetBreakFlag()

void yaze::app::emu::Cpu::SetBreakFlag ( bool set)
inline

Definition at line 133 of file cpu.h.

References SetFlag().

Here is the call graph for this function:

◆ SetDecimalFlag()

void yaze::app::emu::Cpu::SetDecimalFlag ( bool set)
inline

Definition at line 134 of file cpu.h.

References SetFlag().

Referenced by DoInterrupt(), ExecuteInstruction(), and RunOpcode().

Here is the call graph for this function:

◆ SetInterruptFlag()

void yaze::app::emu::Cpu::SetInterruptFlag ( bool set)
inline

Definition at line 135 of file cpu.h.

References SetFlag().

Referenced by DoInterrupt(), ExecuteInstruction(), and RunOpcode().

Here is the call graph for this function:

◆ SetZeroFlag()

void yaze::app::emu::Cpu::SetZeroFlag ( bool set)
inline

Definition at line 136 of file cpu.h.

References SetFlag().

Referenced by Bit(), compare(), ExecuteInstruction(), ORA(), SetZN(), Trb(), and Tsb().

Here is the call graph for this function:

◆ SetCarryFlag()

void yaze::app::emu::Cpu::SetCarryFlag ( bool set)
inline

Definition at line 137 of file cpu.h.

References SetFlag().

Referenced by Adc(), Asl(), Cmp(), compare(), Cpx(), Cpy(), ExecuteInstruction(), Lsr(), Rol(), Ror(), and Sbc().

Here is the call graph for this function:

◆ GetNegativeFlag()

bool yaze::app::emu::Cpu::GetNegativeFlag ( ) const
inline

Definition at line 140 of file cpu.h.

References GetFlag().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ GetOverflowFlag()

bool yaze::app::emu::Cpu::GetOverflowFlag ( ) const
inline

Definition at line 141 of file cpu.h.

References GetFlag().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ GetBreakFlag()

bool yaze::app::emu::Cpu::GetBreakFlag ( ) const
inline

Definition at line 142 of file cpu.h.

References GetFlag().

Here is the call graph for this function:

◆ GetDecimalFlag()

bool yaze::app::emu::Cpu::GetDecimalFlag ( ) const
inline

Definition at line 143 of file cpu.h.

References GetFlag().

Referenced by Adc(), and Sbc().

Here is the call graph for this function:

◆ GetInterruptFlag()

bool yaze::app::emu::Cpu::GetInterruptFlag ( ) const
inline

Definition at line 144 of file cpu.h.

References GetFlag().

Referenced by CheckInt().

Here is the call graph for this function:

◆ GetZeroFlag()

bool yaze::app::emu::Cpu::GetZeroFlag ( ) const
inline

Definition at line 145 of file cpu.h.

References GetFlag().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ GetCarryFlag()

bool yaze::app::emu::Cpu::GetCarryFlag ( ) const
inline

Definition at line 146 of file cpu.h.

References GetFlag().

Referenced by Adc(), ExecuteInstruction(), Rol(), Ror(), and Sbc().

Here is the call graph for this function:

◆ ReadOpcode()

uint8_t yaze::app::emu::Cpu::ReadOpcode ( )
inline

◆ ReadOpcodeWord()

uint16_t yaze::app::emu::Cpu::ReadOpcodeWord ( bool int_check = false)
inline

Definition at line 152 of file cpu.h.

References CheckInt(), and ReadOpcode().

Referenced by Absolute(), AdrAbl(), AdrAbx(), AdrAby(), AdrAlx(), and ExecuteInstruction().

Here is the call graph for this function:

◆ ReadByte()

◆ ReadWord()

uint16_t yaze::app::emu::Cpu::ReadWord ( uint32_t address,
uint32_t address_high,
bool int_check = false )
inline

Definition at line 160 of file cpu.h.

References CheckInt(), and ReadByte().

Referenced by Adc(), AdrIdl(), AdrIdp(), AdrIdx(), AdrIdy(), AdrIly(), AdrIsy(), And(), Asl(), Bit(), Cmp(), Cpx(), Cpy(), Dec(), DoInterrupt(), Eor(), ExecuteInstruction(), Inc(), Lda(), Ldx(), Ldy(), Lsr(), ORA(), Rol(), Ror(), RunOpcode(), Sbc(), Trb(), and Tsb().

Here is the call graph for this function:

◆ ReadWordLong()

uint32_t yaze::app::emu::Cpu::ReadWordLong ( uint32_t address)
inline

Definition at line 167 of file cpu.h.

References ReadByte().

Referenced by DirectPageIndirectLong(), and DirectPageIndirectLongIndexedY().

Here is the call graph for this function:

◆ WriteByte()

void yaze::app::emu::Cpu::WriteByte ( uint32_t address,
uint8_t value )
inline

◆ WriteWord()

void yaze::app::emu::Cpu::WriteWord ( uint32_t address,
uint32_t address_high,
uint16_t value,
bool reversed = false,
bool int_check = false )
inline

Definition at line 178 of file cpu.h.

References callbacks_, CheckInt(), and yaze::app::emu::memory::CpuCallbacks::write_byte.

Referenced by Asl(), Dec(), Inc(), Lsr(), Rol(), Ror(), Sta(), Stx(), Sty(), Stz(), Trb(), and Tsb().

Here is the call graph for this function:

◆ WriteLong()

void yaze::app::emu::Cpu::WriteLong ( uint32_t address,
uint32_t value )
inline

◆ PushByte()

void yaze::app::emu::Cpu::PushByte ( uint8_t value)
inline

Definition at line 196 of file cpu.h.

References callbacks_, E, SetSP(), SP(), and yaze::app::emu::memory::CpuCallbacks::write_byte.

Referenced by DoInterrupt(), ExecuteInstruction(), PushLong(), and PushWord().

Here is the call graph for this function:

◆ PushWord()

void yaze::app::emu::Cpu::PushWord ( uint16_t value,
bool int_check = false )
inline

Definition at line 201 of file cpu.h.

References CheckInt(), and PushByte().

Referenced by DoInterrupt(), ExecuteInstruction(), and PushLong().

Here is the call graph for this function:

◆ PushLong()

void yaze::app::emu::Cpu::PushLong ( uint32_t value)
inline

Definition at line 206 of file cpu.h.

References PushByte(), and PushWord().

Referenced by yaze::app::zelda3::dungeon::DungeonObjectRenderer::RenderObject().

Here is the call graph for this function:

◆ PopByte()

uint8_t yaze::app::emu::Cpu::PopByte ( )
inline

Definition at line 211 of file cpu.h.

References E, ReadByte(), SetSP(), and SP().

Referenced by ExecuteInstruction(), PopLong(), and PopWord().

Here is the call graph for this function:

◆ PopWord()

uint16_t yaze::app::emu::Cpu::PopWord ( bool int_check = false)
inline

Definition at line 216 of file cpu.h.

References CheckInt(), and PopByte().

Referenced by ExecuteInstruction(), and PopLong().

Here is the call graph for this function:

◆ PopLong()

uint32_t yaze::app::emu::Cpu::PopLong ( )
inline

Definition at line 221 of file cpu.h.

References PopByte(), and PopWord().

Here is the call graph for this function:

◆ DoBranch()

void yaze::app::emu::Cpu::DoBranch ( bool check)
inline

Definition at line 227 of file cpu.h.

References callbacks_, CheckInt(), yaze::app::emu::memory::CpuCallbacks::idle, PC, and ReadOpcode().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ set_int_delay()

void yaze::app::emu::Cpu::set_int_delay ( bool delay)
inline

◆ Absolute()

uint32_t yaze::app::emu::Cpu::Absolute ( uint32_t * low)

Definition at line 98 of file addressing.cc.

References DB, and ReadOpcodeWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AbsoluteIndexedX()

uint32_t yaze::app::emu::Cpu::AbsoluteIndexedX ( )

◆ AdrAbx()

uint32_t yaze::app::emu::Cpu::AdrAbx ( uint32_t * low,
bool write )

Definition at line 104 of file addressing.cc.

References callbacks_, DB, GetIndexSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcodeWord(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AbsoluteIndexedY()

uint32_t yaze::app::emu::Cpu::AbsoluteIndexedY ( )

◆ AdrAby()

uint32_t yaze::app::emu::Cpu::AdrAby ( uint32_t * low,
bool write )

Definition at line 113 of file addressing.cc.

References callbacks_, DB, GetIndexSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcodeWord(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrImp()

void yaze::app::emu::Cpu::AdrImp ( )

Definition at line 7 of file addressing.cc.

References callbacks_, CheckInt(), yaze::app::emu::memory::CpuCallbacks::idle, int_wanted_, PB, PC, and ReadByte().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIdx()

uint32_t yaze::app::emu::Cpu::AdrIdx ( uint32_t * low)

Definition at line 159 of file addressing.cc.

References callbacks_, D, DB, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), ReadWord(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIdp()

uint32_t yaze::app::emu::Cpu::AdrIdp ( uint32_t * low)

Definition at line 45 of file addressing.cc.

References callbacks_, D, DB, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), and ReadWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIdy()

uint32_t yaze::app::emu::Cpu::AdrIdy ( uint32_t * low,
bool write )

Definition at line 53 of file addressing.cc.

References callbacks_, D, DB, GetIndexSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), ReadWord(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIdl()

uint32_t yaze::app::emu::Cpu::AdrIdl ( uint32_t * low)

Definition at line 64 of file addressing.cc.

References callbacks_, D, yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadOpcode(), and ReadWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIly()

uint32_t yaze::app::emu::Cpu::AdrIly ( uint32_t * low)

Definition at line 73 of file addressing.cc.

References callbacks_, D, yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadOpcode(), ReadWord(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AdrIsy()

uint32_t yaze::app::emu::Cpu::AdrIsy ( uint32_t * low)

Definition at line 89 of file addressing.cc.

References callbacks_, DB, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), ReadWord(), SP(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Immediate() [1/2]

uint32_t yaze::app::emu::Cpu::Immediate ( uint32_t * low,
bool xFlag )

Definition at line 19 of file addressing.cc.

References GetAccumulatorSize(), GetIndexSize(), PB, and PC.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AbsoluteIndexedIndirect()

uint16_t yaze::app::emu::Cpu::AbsoluteIndexedIndirect ( )

◆ AbsoluteIndirect()

uint16_t yaze::app::emu::Cpu::AbsoluteIndirect ( )

◆ AbsoluteIndirectLong()

uint32_t yaze::app::emu::Cpu::AbsoluteIndirectLong ( )

◆ AbsoluteLong()

uint32_t yaze::app::emu::Cpu::AbsoluteLong ( )

◆ AdrAbl()

uint32_t yaze::app::emu::Cpu::AdrAbl ( uint32_t * low)

Definition at line 122 of file addressing.cc.

References ReadOpcode(), and ReadOpcodeWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ AbsoluteLongIndexedX()

uint32_t yaze::app::emu::Cpu::AbsoluteLongIndexedX ( )

◆ AdrAlx()

uint32_t yaze::app::emu::Cpu::AdrAlx ( uint32_t * low)

Definition at line 129 of file addressing.cc.

References ReadOpcode(), ReadOpcodeWord(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ BlockMove()

void yaze::app::emu::Cpu::BlockMove ( uint16_t source,
uint16_t dest,
uint16_t length )

◆ DirectPage()

uint16_t yaze::app::emu::Cpu::DirectPage ( )

Definition at line 143 of file addressing.cc.

References D, and ReadOpcode().

Here is the call graph for this function:

◆ AdrDp()

uint32_t yaze::app::emu::Cpu::AdrDp ( uint32_t * low)

Definition at line 136 of file addressing.cc.

References callbacks_, D, yaze::app::emu::memory::CpuCallbacks::idle, and ReadOpcode().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ DirectPageIndexedX()

uint16_t yaze::app::emu::Cpu::DirectPageIndexedX ( )

Definition at line 148 of file addressing.cc.

References D, GetAccumulatorSize(), ReadOpcode(), and X.

Here is the call graph for this function:

◆ AdrDpx()

uint32_t yaze::app::emu::Cpu::AdrDpx ( uint32_t * low)

Definition at line 29 of file addressing.cc.

References callbacks_, D, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ DirectPageIndexedY()

uint16_t yaze::app::emu::Cpu::DirectPageIndexedY ( )

Definition at line 154 of file addressing.cc.

References ReadOpcode(), and Y.

Here is the call graph for this function:

◆ AdrDpy()

uint32_t yaze::app::emu::Cpu::AdrDpy ( uint32_t * low)

Definition at line 37 of file addressing.cc.

References callbacks_, D, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ DirectPageIndexedIndirectX()

uint16_t yaze::app::emu::Cpu::DirectPageIndexedIndirectX ( )

◆ DirectPageIndirect()

uint16_t yaze::app::emu::Cpu::DirectPageIndirect ( )

◆ DirectPageIndirectLong()

uint32_t yaze::app::emu::Cpu::DirectPageIndirectLong ( )

Definition at line 168 of file addressing.cc.

References D, ReadOpcode(), and ReadWordLong().

Here is the call graph for this function:

◆ DirectPageIndirectIndexedY()

uint16_t yaze::app::emu::Cpu::DirectPageIndirectIndexedY ( )

◆ DirectPageIndirectLongIndexedY()

uint32_t yaze::app::emu::Cpu::DirectPageIndirectLongIndexedY ( )

Definition at line 174 of file addressing.cc.

References D, GetAccumulatorSize(), ReadOpcode(), ReadWordLong(), and Y.

Here is the call graph for this function:

◆ Immediate() [2/2]

uint16_t yaze::app::emu::Cpu::Immediate ( bool index_size = false)

◆ StackRelative()

uint16_t yaze::app::emu::Cpu::StackRelative ( )

Definition at line 182 of file addressing.cc.

References ReadOpcode(), and SP().

Here is the call graph for this function:

◆ AdrSr()

uint32_t yaze::app::emu::Cpu::AdrSr ( uint32_t * low)

Definition at line 82 of file addressing.cc.

References callbacks_, yaze::app::emu::memory::CpuCallbacks::idle, ReadOpcode(), and SP().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ StackRelativeIndirectIndexedY()

uint32_t yaze::app::emu::Cpu::StackRelativeIndirectIndexedY ( )

◆ ADC()

void yaze::app::emu::Cpu::ADC ( uint16_t operand)

◆ AND()

void yaze::app::emu::Cpu::AND ( uint32_t address,
bool immediate = false )

◆ ANDAbsoluteLong()

void yaze::app::emu::Cpu::ANDAbsoluteLong ( uint32_t address)

◆ ASL()

void yaze::app::emu::Cpu::ASL ( uint16_t address)

◆ BCC()

void yaze::app::emu::Cpu::BCC ( int8_t offset)

◆ BCS()

void yaze::app::emu::Cpu::BCS ( int8_t offset)

◆ BEQ()

void yaze::app::emu::Cpu::BEQ ( int8_t offset)

◆ BIT()

void yaze::app::emu::Cpu::BIT ( uint16_t address)

◆ BMI()

void yaze::app::emu::Cpu::BMI ( int8_t offset)

◆ BNE()

void yaze::app::emu::Cpu::BNE ( int8_t offset)

◆ BPL()

void yaze::app::emu::Cpu::BPL ( int8_t offset)

◆ BRA()

void yaze::app::emu::Cpu::BRA ( int8_t offset)

◆ BRK()

void yaze::app::emu::Cpu::BRK ( )

◆ BRL()

void yaze::app::emu::Cpu::BRL ( int16_t offset)

◆ BVC()

void yaze::app::emu::Cpu::BVC ( int8_t offset)

◆ BVS()

void yaze::app::emu::Cpu::BVS ( int8_t offset)

◆ CLC()

void yaze::app::emu::Cpu::CLC ( )

◆ CLD()

void yaze::app::emu::Cpu::CLD ( )

◆ CLI()

void yaze::app::emu::Cpu::CLI ( )

◆ CLV()

void yaze::app::emu::Cpu::CLV ( )

◆ CMP()

void yaze::app::emu::Cpu::CMP ( uint32_t address,
bool immediate = false )

◆ COP()

void yaze::app::emu::Cpu::COP ( )

◆ CPX()

void yaze::app::emu::Cpu::CPX ( uint32_t address,
bool immediate = false )

◆ CPY()

void yaze::app::emu::Cpu::CPY ( uint32_t address,
bool immediate = false )

◆ DEC()

void yaze::app::emu::Cpu::DEC ( uint32_t address,
bool accumulator = false )

◆ DEX()

void yaze::app::emu::Cpu::DEX ( )

◆ DEY()

void yaze::app::emu::Cpu::DEY ( )

◆ EOR()

void yaze::app::emu::Cpu::EOR ( uint32_t address,
bool immediate = false )

◆ INC()

void yaze::app::emu::Cpu::INC ( uint32_t address,
bool accumulator = false )

◆ INX()

void yaze::app::emu::Cpu::INX ( )

◆ INY()

void yaze::app::emu::Cpu::INY ( )

◆ JMP()

void yaze::app::emu::Cpu::JMP ( uint16_t address)

◆ JML()

void yaze::app::emu::Cpu::JML ( uint16_t address)

◆ JSR()

void yaze::app::emu::Cpu::JSR ( uint16_t address)

◆ JSL()

void yaze::app::emu::Cpu::JSL ( uint16_t address)

◆ LDA()

void yaze::app::emu::Cpu::LDA ( uint16_t address,
bool immediate = false,
bool direct_page = false,
bool data_bank = false )

◆ LDX()

void yaze::app::emu::Cpu::LDX ( uint16_t address,
bool immediate = false )

◆ LDY()

void yaze::app::emu::Cpu::LDY ( uint16_t address,
bool immediate = false )

◆ LSR()

void yaze::app::emu::Cpu::LSR ( uint16_t address,
bool accumulator = false )

◆ MVN()

void yaze::app::emu::Cpu::MVN ( )

◆ MVP()

void yaze::app::emu::Cpu::MVP ( )

◆ NOP()

void yaze::app::emu::Cpu::NOP ( )

◆ ORA()

void yaze::app::emu::Cpu::ORA ( uint32_t low,
uint32_t high )

Definition at line 385 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), SetNegativeFlag(), and SetZeroFlag().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ PEA()

void yaze::app::emu::Cpu::PEA ( )

◆ PEI()

void yaze::app::emu::Cpu::PEI ( )

◆ PER()

void yaze::app::emu::Cpu::PER ( )

◆ PHA()

void yaze::app::emu::Cpu::PHA ( )

◆ PHB()

void yaze::app::emu::Cpu::PHB ( )

◆ PHD()

void yaze::app::emu::Cpu::PHD ( )

◆ PHK()

void yaze::app::emu::Cpu::PHK ( )

◆ PHP()

void yaze::app::emu::Cpu::PHP ( )

◆ PHX()

void yaze::app::emu::Cpu::PHX ( )

◆ PHY()

void yaze::app::emu::Cpu::PHY ( )

◆ PLA()

void yaze::app::emu::Cpu::PLA ( )

◆ PLB()

void yaze::app::emu::Cpu::PLB ( )

◆ PLD()

void yaze::app::emu::Cpu::PLD ( )

◆ PLP()

void yaze::app::emu::Cpu::PLP ( )

◆ PLX()

void yaze::app::emu::Cpu::PLX ( )

◆ PLY()

void yaze::app::emu::Cpu::PLY ( )

◆ REP()

void yaze::app::emu::Cpu::REP ( )

◆ ROL()

void yaze::app::emu::Cpu::ROL ( uint32_t address,
bool accumulator = false )

◆ ROR()

void yaze::app::emu::Cpu::ROR ( uint32_t address,
bool accumulator = false )

◆ RTI()

void yaze::app::emu::Cpu::RTI ( )

◆ RTL()

void yaze::app::emu::Cpu::RTL ( )

◆ RTS()

void yaze::app::emu::Cpu::RTS ( )

◆ SBC()

void yaze::app::emu::Cpu::SBC ( uint32_t operand,
bool immediate = false )

◆ SEC()

void yaze::app::emu::Cpu::SEC ( )

◆ SED()

void yaze::app::emu::Cpu::SED ( )

◆ SEI()

void yaze::app::emu::Cpu::SEI ( )

◆ SEP()

void yaze::app::emu::Cpu::SEP ( )

◆ STA()

void yaze::app::emu::Cpu::STA ( uint32_t address)

◆ STP()

void yaze::app::emu::Cpu::STP ( )

◆ STX()

void yaze::app::emu::Cpu::STX ( uint16_t address)

◆ STY()

void yaze::app::emu::Cpu::STY ( uint16_t address)

◆ STZ()

void yaze::app::emu::Cpu::STZ ( uint16_t address)

◆ TAX()

void yaze::app::emu::Cpu::TAX ( )

◆ TAY()

void yaze::app::emu::Cpu::TAY ( )

◆ TCD()

void yaze::app::emu::Cpu::TCD ( )

◆ TCS()

void yaze::app::emu::Cpu::TCS ( )

◆ TDC()

void yaze::app::emu::Cpu::TDC ( )

◆ TRB()

void yaze::app::emu::Cpu::TRB ( uint16_t address)

◆ TSB()

void yaze::app::emu::Cpu::TSB ( uint16_t address)

◆ TSC()

void yaze::app::emu::Cpu::TSC ( )

◆ TSX()

void yaze::app::emu::Cpu::TSX ( )

◆ TXA()

void yaze::app::emu::Cpu::TXA ( )

◆ TXS()

void yaze::app::emu::Cpu::TXS ( )

◆ TXY()

void yaze::app::emu::Cpu::TXY ( )

◆ TYA()

void yaze::app::emu::Cpu::TYA ( )

◆ TYX()

void yaze::app::emu::Cpu::TYX ( )

◆ WAI()

void yaze::app::emu::Cpu::WAI ( )

◆ WDM()

void yaze::app::emu::Cpu::WDM ( )

◆ XBA()

void yaze::app::emu::Cpu::XBA ( )

◆ XCE()

void yaze::app::emu::Cpu::XCE ( )

◆ And()

void yaze::app::emu::Cpu::And ( uint32_t low,
uint32_t high )

65816 Instruction Set

Definition at line 15 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Eor()

void yaze::app::emu::Cpu::Eor ( uint32_t low,
uint32_t high )

Definition at line 27 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Adc()

void yaze::app::emu::Cpu::Adc ( uint32_t low,
uint32_t high )

Definition at line 39 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), GetCarryFlag(), GetDecimalFlag(), ReadByte(), ReadWord(), SetCarryFlag(), SetOverflowFlag(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Sbc()

void yaze::app::emu::Cpu::Sbc ( uint32_t low,
uint32_t high )

Definition at line 79 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), GetCarryFlag(), GetDecimalFlag(), ReadByte(), ReadWord(), SetCarryFlag(), SetOverflowFlag(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Cmp()

void yaze::app::emu::Cpu::Cmp ( uint32_t low,
uint32_t high )

Definition at line 123 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), SetCarryFlag(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Cpx()

void yaze::app::emu::Cpu::Cpx ( uint32_t low,
uint32_t high )

Definition at line 138 of file instructions.cc.

References CheckInt(), GetIndexSize(), ReadByte(), ReadWord(), SetCarryFlag(), SetZN(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Cpy()

void yaze::app::emu::Cpu::Cpy ( uint32_t low,
uint32_t high )

Definition at line 153 of file instructions.cc.

References CheckInt(), GetIndexSize(), ReadByte(), ReadWord(), SetCarryFlag(), SetZN(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Bit()

void yaze::app::emu::Cpu::Bit ( uint32_t low,
uint32_t high )

Definition at line 168 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), SetNegativeFlag(), SetOverflowFlag(), and SetZeroFlag().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Lda()

void yaze::app::emu::Cpu::Lda ( uint32_t low,
uint32_t high )

Definition at line 185 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), ReadByte(), ReadWord(), and SetZN().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Ldx()

void yaze::app::emu::Cpu::Ldx ( uint32_t low,
uint32_t high )

Definition at line 195 of file instructions.cc.

References CheckInt(), GetIndexSize(), ReadByte(), ReadWord(), SetZN(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Ldy()

void yaze::app::emu::Cpu::Ldy ( uint32_t low,
uint32_t high )

Definition at line 205 of file instructions.cc.

References CheckInt(), GetIndexSize(), ReadByte(), ReadWord(), SetZN(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Sta()

void yaze::app::emu::Cpu::Sta ( uint32_t low,
uint32_t high )

Definition at line 215 of file instructions.cc.

References A, CheckInt(), GetAccumulatorSize(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Stx()

void yaze::app::emu::Cpu::Stx ( uint32_t low,
uint32_t high )

Definition at line 224 of file instructions.cc.

References CheckInt(), GetIndexSize(), WriteByte(), WriteWord(), and X.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Sty()

void yaze::app::emu::Cpu::Sty ( uint32_t low,
uint32_t high )

Definition at line 233 of file instructions.cc.

References CheckInt(), GetIndexSize(), WriteByte(), WriteWord(), and Y.

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Stz()

void yaze::app::emu::Cpu::Stz ( uint32_t low,
uint32_t high )

Definition at line 242 of file instructions.cc.

References CheckInt(), GetAccumulatorSize(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Ror()

void yaze::app::emu::Cpu::Ror ( uint32_t low,
uint32_t high )

◆ Rol()

void yaze::app::emu::Cpu::Rol ( uint32_t low,
uint32_t high )

◆ Lsr()

void yaze::app::emu::Cpu::Lsr ( uint32_t low,
uint32_t high )

Definition at line 289 of file instructions.cc.

References callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetCarryFlag(), SetZN(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Asl()

void yaze::app::emu::Cpu::Asl ( uint32_t low,
uint32_t high )

Definition at line 308 of file instructions.cc.

References callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetCarryFlag(), SetZN(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Inc()

void yaze::app::emu::Cpu::Inc ( uint32_t low,
uint32_t high )

Definition at line 325 of file instructions.cc.

References callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetZN(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Dec()

void yaze::app::emu::Cpu::Dec ( uint32_t low,
uint32_t high )

Definition at line 340 of file instructions.cc.

References callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetZN(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Tsb()

void yaze::app::emu::Cpu::Tsb ( uint32_t low,
uint32_t high )

Definition at line 355 of file instructions.cc.

References A, callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetZeroFlag(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ Trb()

void yaze::app::emu::Cpu::Trb ( uint32_t low,
uint32_t high )

Definition at line 370 of file instructions.cc.

References A, callbacks_, CheckInt(), GetAccumulatorSize(), yaze::app::emu::memory::CpuCallbacks::idle, ReadByte(), ReadWord(), SetZeroFlag(), WriteByte(), and WriteWord().

Referenced by ExecuteInstruction().

Here is the call graph for this function:

◆ SP()

uint16_t yaze::app::emu::Cpu::SP ( ) const
inline

Definition at line 730 of file cpu.h.

References memory, and yaze::app::emu::memory::Memory::SP().

Referenced by AdrIsy(), AdrSr(), ExecuteInstruction(), LogInstructions(), PopByte(), PushByte(), RunOpcode(), SetFlags(), and StackRelative().

Here is the call graph for this function:

◆ SetSP()

void yaze::app::emu::Cpu::SetSP ( uint16_t value)
inline

Definition at line 731 of file cpu.h.

References memory, and yaze::app::emu::memory::Memory::SetSP().

Referenced by ExecuteInstruction(), PopByte(), PushByte(), RunOpcode(), and SetFlags().

Here is the call graph for this function:

◆ IsBreakpoint()

bool yaze::app::emu::Cpu::IsBreakpoint ( uint32_t address)
inline

Definition at line 733 of file cpu.h.

References breakpoints_.

◆ SetBreakpoint()

void yaze::app::emu::Cpu::SetBreakpoint ( uint32_t address)
inline

Definition at line 737 of file cpu.h.

References breakpoints_.

◆ ClearBreakpoint()

void yaze::app::emu::Cpu::ClearBreakpoint ( uint32_t address)
inline

Definition at line 738 of file cpu.h.

References breakpoints_.

◆ ClearBreakpoints()

void yaze::app::emu::Cpu::ClearBreakpoints ( )
inline

Definition at line 743 of file cpu.h.

References breakpoints_.

◆ GetBreakpoints()

auto yaze::app::emu::Cpu::GetBreakpoints ( )
inline

Definition at line 747 of file cpu.h.

References breakpoints_.

◆ CheckInt()

void yaze::app::emu::Cpu::CheckInt ( )
inline

◆ mutable_log_instructions()

auto yaze::app::emu::Cpu::mutable_log_instructions ( ) -> bool*
inline

Definition at line 755 of file cpu.h.

References log_instructions_.

◆ compare()

void yaze::app::emu::Cpu::compare ( uint16_t register_value,
uint16_t memory_value )
inlineprivate

Definition at line 758 of file cpu.h.

References GetIndexSize(), SetCarryFlag(), SetNegativeFlag(), and SetZeroFlag().

Here is the call graph for this function:

◆ SetFlag()

void yaze::app::emu::Cpu::SetFlag ( uint8_t mask,
bool set )
inlineprivate

◆ GetFlag()

bool yaze::app::emu::Cpu::GetFlag ( uint8_t mask) const
inlineprivate

Member Data Documentation

◆ breakpoints_

std::vector<uint32_t> yaze::app::emu::Cpu::breakpoints_

Definition at line 59 of file cpu.h.

Referenced by ClearBreakpoint(), ClearBreakpoints(), GetBreakpoints(), IsBreakpoint(), and SetBreakpoint().

◆ instruction_log_

std::vector<InstructionEntry> yaze::app::emu::Cpu::instruction_log_

Definition at line 60 of file cpu.h.

Referenced by LogInstructions().

◆ A

◆ X

◆ Y

uint16_t yaze::app::emu::Cpu::Y = 0

◆ D

◆ DB

◆ PB

◆ PC

◆ E

uint8_t yaze::app::emu::Cpu::E = 1

Definition at line 84 of file cpu.h.

Referenced by ExecuteInstruction(), PopByte(), PushByte(), Reset(), RunOpcode(), and SetFlags().

◆ status

uint8_t yaze::app::emu::Cpu::status = 0b00110000

◆ log_instructions_

bool yaze::app::emu::Cpu::log_instructions_ = false
private

Definition at line 785 of file cpu.h.

Referenced by ExecuteInstruction(), and mutable_log_instructions().

◆ waiting_

bool yaze::app::emu::Cpu::waiting_ = false
private

Definition at line 787 of file cpu.h.

Referenced by ExecuteInstruction(), Reset(), and RunOpcode().

◆ stopped_

bool yaze::app::emu::Cpu::stopped_ = false
private

Definition at line 788 of file cpu.h.

Referenced by ExecuteInstruction(), Reset(), and RunOpcode().

◆ irq_wanted_

bool yaze::app::emu::Cpu::irq_wanted_ = false
private

Definition at line 790 of file cpu.h.

Referenced by CheckInt(), Reset(), RunOpcode(), and SetIrq().

◆ nmi_wanted_

bool yaze::app::emu::Cpu::nmi_wanted_ = false
private

Definition at line 791 of file cpu.h.

Referenced by CheckInt(), DoInterrupt(), Nmi(), Reset(), and RunOpcode().

◆ reset_wanted_

bool yaze::app::emu::Cpu::reset_wanted_ = false
private

Definition at line 792 of file cpu.h.

Referenced by Reset(), and RunOpcode().

◆ int_wanted_

bool yaze::app::emu::Cpu::int_wanted_ = false
private

Definition at line 793 of file cpu.h.

Referenced by AdrImp(), CheckInt(), DoInterrupt(), Reset(), and RunOpcode().

◆ int_delay_

bool yaze::app::emu::Cpu::int_delay_ = false
private

Definition at line 794 of file cpu.h.

Referenced by CheckInt(), Reset(), and set_int_delay().

◆ callbacks_

◆ memory

memory::Memory& yaze::app::emu::Cpu::memory
private

Definition at line 797 of file cpu.h.

Referenced by SetSP(), and SP().

◆ clock

Clock& yaze::app::emu::Cpu::clock
private

Definition at line 798 of file cpu.h.

Referenced by UpdateClock().


The documentation for this class was generated from the following files: