本文整理匯總了C++中Breakpoint::IsEnabled方法的典型用法代碼示例。如果您正苦於以下問題:C++ Breakpoint::IsEnabled方法的具體用法?C++ Breakpoint::IsEnabled怎麽用?C++ Breakpoint::IsEnabled使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Breakpoint
的用法示例。
在下文中一共展示了Breakpoint::IsEnabled方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。
示例1: if
bool Core65c02::Execute (unsigned int count)
{
bool hit_breakpoint = false;
Breakpoint * bp = 0;
unbuild_P(P);
while (count && !hit_breakpoint)
{
--count;
/* check for interrupts */
if (interrupt_flags)
{
if ((I == 0) && (interrupt_flags & F_IRQ))
interrupt(IRQ_VECTOR, F_IRQ);
else if (interrupt_flags & F_NMI)
interrupt(NMI_VECTOR, F_NMI);
else if (interrupt_flags & F_RESET)
interrupt(RES_VECTOR, F_RESET);
else if ((I==0) && (interrupt_flags & F_PAD_A_IRQ))
{
printf("got keyboard interrupt\n");
interrupt(PAD_A_IRQ_VECTOR, F_PAD_A_IRQ);
}
}
/* fetch, decode, and execute and instruction */
opcode = READ(emPC); ++emPC;
EXECUTE(opcode);
++num_instructions;
/* tick the clock for interested parties */
if (num_clockusers != 0)
{
unsigned long long time = 1000000000;
time = (time * cycle_clock) / frequency;
for (int idx = 0; idx < num_clockusers; ++idx)
clockuser[idx]->TellTime(time);
}
/* check for encountered breakpoints */
int nbkpts = bpm->NumBreakpoints();
if (nbkpts != 0)
{
/* must count down (not up) because of automatic breakpoint deletion */
while (nbkpts--)
{
bp = bpm->GetBreakpointAtIndex(nbkpts);
if (bp->IsEnabled() == false)
continue;
if (bp->GetOperandFlags() == bp_PC)
{
if (bp->GetConditionFlags() == bp_equal)
if (bp->GetAddress() == emPC)
{
hit_breakpoint = true;
if (bp->IsAutomatic())
bpm->DeleteBreakpoint(bp);
}
}
else if (bp->GetOperandFlags() == bp_S)
{
if (bp->GetConditionFlags() == bp_equal)
if (bp->GetValue() == S)
{
hit_breakpoint = true;
if (bp->IsAutomatic())
bpm->DeleteBreakpoint(bp);
}
}
}
}
}
P = build_P();
return hit_breakpoint;
}