本文整理汇总了C++中PUSHWORD函数的典型用法代码示例。如果您正苦于以下问题:C++ PUSHWORD函数的具体用法?C++ PUSHWORD怎么用?C++ PUSHWORD使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了PUSHWORD函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: swi
/* $3f SWI absolute indirect ----- */
INLINE void swi( void )
{
PUSHWORD(pPC);
PUSHWORD(pX);
PUSHBYTE(A);
PUSHBYTE(B);
PUSHBYTE(CC);
SEI;
PCD = RM16(0xfffa);
CHANGE_PC();
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:12,代码来源:6800ops.c
示例2: check_irq_lines
static void check_irq_lines(m68_state_t *m68_state)
{
if( m68_state->irq_state[M6809_IRQ_LINE] != CLEAR_LINE ||
m68_state->irq_state[M6809_FIRQ_LINE] != CLEAR_LINE )
m68_state->int_state &= ~M6809_SYNC; /* clear SYNC flag */
if( m68_state->irq_state[M6809_FIRQ_LINE]!=CLEAR_LINE && !(CC & CC_IF) )
{
/* fast IRQ */
/* HJB 990225: state already saved by CWAI? */
if( m68_state->int_state & M6809_CWAI )
{
m68_state->int_state &= ~M6809_CWAI; /* clear CWAI */
m68_state->extra_cycles += 7; /* subtract +7 cycles */
}
else
{
CC &= ~CC_E; /* save 'short' state */
PUSHWORD(pPC);
PUSHBYTE(CC);
m68_state->extra_cycles += 10; /* subtract +10 cycles */
}
CC |= CC_IF | CC_II; /* inhibit FIRQ and IRQ */
PCD=RM16(m68_state, 0xfff6);
(void)(*m68_state->irq_callback)(m68_state->device, M6809_FIRQ_LINE);
}
else
if( m68_state->irq_state[M6809_IRQ_LINE]!=CLEAR_LINE && !(CC & CC_II) )
{
/* standard IRQ */
/* HJB 990225: state already saved by CWAI? */
if( m68_state->int_state & M6809_CWAI )
{
m68_state->int_state &= ~M6809_CWAI; /* clear CWAI flag */
m68_state->extra_cycles += 7; /* subtract +7 cycles */
}
else
{
CC |= CC_E; /* save entire state */
PUSHWORD(pPC);
PUSHWORD(pU);
PUSHWORD(pY);
PUSHWORD(pX);
PUSHBYTE(DP);
PUSHBYTE(B);
PUSHBYTE(A);
PUSHBYTE(CC);
m68_state->extra_cycles += 19; /* subtract +19 cycles */
}
CC |= CC_II; /* inhibit IRQ */
PCD=RM16(m68_state, 0xfff8);
(void)(*m68_state->irq_callback)(m68_state->device, M6809_IRQ_LINE);
}
}
开发者ID:NastyNoah,项目名称:groovyarcade.groovymame,代码行数:53,代码来源:m6809.c
示例3: set_irq_line
/****************************************************************************
* Set IRQ line state
****************************************************************************/
static void set_irq_line(int irqline, int state)
{
if (irqline == INPUT_LINE_NMI)
{
if (hd6309.nmi_state == state) return;
hd6309.nmi_state = state;
LOG(("HD6309#%d set_irq_line (NMI) %d (PC=%4.4X)\n", cpu_getactivecpu(), state, pPC));
if( state == CLEAR_LINE ) return;
/* if the stack was not yet initialized */
if( !(hd6309.int_state & HD6309_LDS) ) return;
hd6309.int_state &= ~HD6309_SYNC;
/* HJB 990225: state already saved by CWAI? */
if( hd6309.int_state & HD6309_CWAI )
{
hd6309.int_state &= ~HD6309_CWAI;
hd6309.extra_cycles += 7; /* subtract +7 cycles next time */
}
else
{
CC |= CC_E; /* save entire state */
PUSHWORD(pPC);
PUSHWORD(pU);
PUSHWORD(pY);
PUSHWORD(pX);
PUSHBYTE(DP);
if ( MD & MD_EM )
{
PUSHBYTE(F);
PUSHBYTE(E);
hd6309.extra_cycles += 2; /* subtract +2 cycles */
}
PUSHBYTE(B);
PUSHBYTE(A);
PUSHBYTE(CC);
hd6309.extra_cycles += 19; /* subtract +19 cycles next time */
}
CC |= CC_IF | CC_II; /* inhibit FIRQ and IRQ */
PCD = RM16(0xfffc);
CHANGE_PC;
}
else if (irqline < 2)
{
LOG(("HD6309#%d set_irq_line %d, %d (PC=%4.4X)\n", cpu_getactivecpu(), irqline, state, pPC));
hd6309.irq_state[irqline] = state;
if (state == CLEAR_LINE) return;
CHECK_IRQ_LINES();
}
}
开发者ID:broftkd,项目名称:historic-mame,代码行数:54,代码来源:hd6309.c
示例4: wai
/* $3e WAI inherent ----- */
INLINE void wai( void )
{
/*
* WAI stacks the entire machine state on the
* hardware stack, then waits for an interrupt.
*/
m6808.wai_state |= M6808_WAI;
PUSHWORD(pPC);
PUSHWORD(pX);
PUSHBYTE(A);
PUSHBYTE(B);
PUSHBYTE(CC);
CHECK_IRQ_LINES();
if (m6808.wai_state & M6808_WAI) EAT_CYCLES;
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:16,代码来源:6800ops.c
示例5: konami_set_irq_line
/****************************************************************************
* Set IRQ line state
****************************************************************************/
void konami_set_irq_line(int irqline, int state)
{
#if defined FBA_DEBUG
if (!DebugCPU_KonamiInitted) bprintf(PRINT_ERROR, _T("konami_set_irq_line called without init\n"));
#endif
if (irqline == KONAMI_INPUT_LINE_NMI)
{
if (konami.nmi_state == state) return;
konami.nmi_state = state;
// LOG(("KONAMI#%d set_nmi_line %d\n", cpu_getactivecpu(), state));
if( state == CPU_IRQSTATUS_NONE ) return;
/* if the stack was not yet initialized */
if( !(konami.int_state & KONAMI_LDS) ) return;
konami.int_state &= ~KONAMI_SYNC;
/* state already saved by CWAI? */
if( konami.int_state & KONAMI_CWAI )
{
konami.int_state &= ~KONAMI_CWAI;
konami.extra_cycles += 7; /* subtract +7 cycles next time */
}
else
{
CC |= CC_E; /* save entire state */
PUSHWORD(pPC);
PUSHWORD(pU);
PUSHWORD(pY);
PUSHWORD(pX);
PUSHBYTE(DP);
PUSHBYTE(B);
PUSHBYTE(A);
PUSHBYTE(CC);
konami.extra_cycles += 19; /* subtract +19 cycles next time */
}
CC |= CC_IF | CC_II; /* inhibit FIRQ and IRQ */
PCD = RM16(0xfffc);
change_pc(PC); /* TS 971002 */
}
else if (irqline < 2)
{
// LOG(("KONAMI#%d set_irq_line %d, %d\n", cpu_getactivecpu(), irqline, state));
konami.irq_state[irqline] = state;
if (state == CPU_IRQSTATUS_NONE) return;
CHECK_IRQ_LINES;
}
}
开发者ID:Cpasjuste,项目名称:libarcade,代码行数:51,代码来源:konami.cpp
示例6: trap_23
static void trap_23( void )
{
PUSHWORD( PC );
pPC = RM16(0xffd0);
CHANGE_PC;
tms7000_icount -= 14;
}
开发者ID:broftkd,项目名称:historic-mame,代码行数:7,代码来源:tms70op.c
示例7: PUSHWORD
/* Generate interrupt - m68705 version */
void m68705_device::interrupt()
{
if ((m_pending_interrupts & ((1 << M6805_IRQ_LINE) | M68705_INT_MASK)) != 0 )
{
if ((CC & IFLAG) == 0)
{
PUSHWORD(m_pc);
PUSHBYTE(m_x);
PUSHBYTE(m_a);
PUSHBYTE(m_cc);
SEI;
standard_irq_callback(0);
if ((m_pending_interrupts & (1 << M68705_IRQ_LINE)) != 0 )
{
m_pending_interrupts &= ~(1 << M68705_IRQ_LINE);
RM16(0xfffa, &m_pc);
}
else if ((m_pending_interrupts & (1 << M68705_INT_TIMER)) != 0)
{
m_pending_interrupts &= ~(1 << M68705_INT_TIMER);
RM16(0xfff8, &m_pc);
}
}
m_icount -= 11;
}
}
开发者ID:dinkc64,项目名称:mame,代码行数:28,代码来源:m6805.c
示例8: jsr_ex
/* $bd JSR extended ----- */
INLINE void jsr_ex( void )
{
EXTENDED;
PUSHWORD(pPC);
PC = EA;
CHANGE_PC();
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:8,代码来源:6800ops.c
示例9: m68705_Interrupt
/* Generate interrupt - m68705 version */
static void m68705_Interrupt( m6805_Regs *cpustate )
{
if( (cpustate->pending_interrupts & ((1<<M6805_IRQ_LINE)|M68705_INT_MASK)) != 0 )
{
if ( (CC & IFLAG) == 0 )
{
PUSHWORD(cpustate->pc);
PUSHBYTE(cpustate->x);
PUSHBYTE(cpustate->a);
PUSHBYTE(cpustate->cc);
SEI;
if (cpustate->irq_callback)
(*cpustate->irq_callback)(cpustate->device, 0);
if ((cpustate->pending_interrupts & (1<<M68705_IRQ_LINE)) != 0 )
{
cpustate->pending_interrupts &= ~(1<<M68705_IRQ_LINE);
RM16( cpustate, 0xfffa, &pPC);
}
else if((cpustate->pending_interrupts&(1<<M68705_INT_TIMER))!=0)
{
cpustate->pending_interrupts &= ~(1<<M68705_INT_TIMER);
RM16( cpustate, 0xfff8, &pPC);
}
}
cpustate->iCount -= 11;
}
}
开发者ID:lidibupa,项目名称:ClientServerMAME,代码行数:29,代码来源:m6805.c
示例10: jsr_di
/* $9d JSR direct ----- */
INLINE void jsr_di( void )
{
DIRECT;
PUSHWORD(pPC);
PC = EA;
CHANGE_PC();
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:8,代码来源:6800ops.c
示例11: jsr_ix
/* $ad JSR indexed ----- */
INLINE void jsr_ix( void )
{
INDEXED;
PUSHWORD(pPC);
PC = EA;
CHANGE_PC();
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:8,代码来源:6800ops.c
示例12: m68705_Interrupt
/* Generate interrupt - m68705 version */
static void m68705_Interrupt(void)
{
if( (m6805.pending_interrupts & ((1<<M6805_IRQ_LINE)|M68705_INT_MASK)) != 0 )
{
if ( (CC & IFLAG) == 0 )
{
PUSHWORD(m6805.pc);
PUSHBYTE(m6805.x);
PUSHBYTE(m6805.a);
PUSHBYTE(m6805.cc);
SEI;
if (m6805.irq_callback)
(*m6805.irq_callback)(0);
if ((m6805.pending_interrupts & (1<<M68705_IRQ_LINE)) != 0 )
{
m6805.pending_interrupts &= ~(1<<M68705_IRQ_LINE);
RM16( 0xfffa, &pPC);
change_pc(PC);
}
else if((m6805.pending_interrupts&(1<<M68705_INT_TIMER))!=0)
{
m6805.pending_interrupts &= ~(1<<M68705_INT_TIMER);
RM16( 0xfff8, &pPC);
change_pc(PC);
}
}
m6805_ICount -= 11;
}
}
开发者ID:tigerking,项目名称:FB-Alpha,代码行数:31,代码来源:m6805.cpp
示例13: bsr
/* $8d BSR ----- */
INLINE void bsr( void )
{
UINT8 t;
IMMBYTE(t);
PUSHWORD(pPC);
PC += SIGNED(t);
CHANGE_PC(); /* TS 971002 */
}
开发者ID:cdrr,项目名称:MAME_hack,代码行数:9,代码来源:6800ops.c
示例14: DERIVED_OP_HANDLER
DERIVED_OP_HANDLER( hd63705, swi )
{
PUSHWORD(m_pc);
PUSHBYTE(m_x);
PUSHBYTE(m_a);
PUSHBYTE(m_cc);
SEI;
RM16(0x1ffa, &m_pc);
}
开发者ID:Ilgrim,项目名称:MAMEHub,代码行数:9,代码来源:6805ops.c
示例15: set_irq_line
/****************************************************************************
* Set IRQ line state
****************************************************************************/
static void set_irq_line(int irqline, int state)
{
if (irqline == INPUT_LINE_NMI)
{
if (konami.nmi_state == state) return;
konami.nmi_state = state;
LOG(("KONAMI#%d set_nmi_line %d\n", cpu_getactivecpu(), state));
if( state == CLEAR_LINE ) return;
/* if the stack was not yet initialized */
if( !(konami.int_state & KONAMI_LDS) ) return;
konami.int_state &= ~KONAMI_SYNC;
/* state already saved by CWAI? */
if( konami.int_state & KONAMI_CWAI )
{
konami.int_state &= ~KONAMI_CWAI;
konami.extra_cycles += 7; /* subtract +7 cycles next time */
}
else
{
CC |= CC_E; /* save entire state */
PUSHWORD(pPC);
PUSHWORD(pU);
PUSHWORD(pY);
PUSHWORD(pX);
PUSHBYTE(DP);
PUSHBYTE(B);
PUSHBYTE(A);
PUSHBYTE(CC);
konami.extra_cycles += 19; /* subtract +19 cycles next time */
}
CC |= CC_IF | CC_II; /* inhibit FIRQ and IRQ */
PCD = RM16(0xfffc);
change_pc(PC); /* TS 971002 */
}
else if (irqline < 2)
{
LOG(("KONAMI#%d set_irq_line %d, %d\n", cpu_getactivecpu(), irqline, state));
konami.irq_state[irqline] = state;
if (state == CLEAR_LINE) return;
CHECK_IRQ_LINES;
}
}
开发者ID:RobinDX,项目名称:xmame,代码行数:47,代码来源:konami.c
示例16: set_irq_line
/****************************************************************************
* Set IRQ line state
****************************************************************************/
static void set_irq_line(m68_state_t *m68_state, int irqline, int state)
{
if (irqline == INPUT_LINE_NMI)
{
if (m68_state->nmi_state == state) return;
m68_state->nmi_state = state;
LOG(("M6809 '%s' set_irq_line (NMI) %d\n", m68_state->device->tag(), state));
if( state == CLEAR_LINE ) return;
/* if the stack was not yet initialized */
if( !(m68_state->int_state & M6809_LDS) ) return;
m68_state->int_state &= ~M6809_SYNC;
/* HJB 990225: state already saved by CWAI? */
if( m68_state->int_state & M6809_CWAI )
{
m68_state->int_state &= ~M6809_CWAI;
m68_state->extra_cycles += 7; /* subtract +7 cycles next time */
}
else
{
CC |= CC_E; /* save entire state */
PUSHWORD(pPC);
PUSHWORD(pU);
PUSHWORD(pY);
PUSHWORD(pX);
PUSHBYTE(DP);
PUSHBYTE(B);
PUSHBYTE(A);
PUSHBYTE(CC);
m68_state->extra_cycles += 19; /* subtract +19 cycles next time */
}
CC |= CC_IF | CC_II; /* inhibit FIRQ and IRQ */
PCD = RM16(m68_state, 0xfffc);
}
else if (irqline < 2)
{
LOG(("M6809 '%s' set_irq_line %d, %d\n", m68_state->device->tag(), irqline, state));
m68_state->irq_state[irqline] = state;
if (state == CLEAR_LINE) return;
check_irq_lines(m68_state);
}
}
开发者ID:NastyNoah,项目名称:groovyarcade.groovymame,代码行数:46,代码来源:m6809.c
示例17: call_ind
static void call_ind( void )
{
UINT8 v;
IMMBYTE( v );
PUSHWORD( PC );
PC.w.l = RRF16(v);
tms7000_icount -= 13;
}
开发者ID:broftkd,项目名称:historic-mame,代码行数:10,代码来源:tms70op.c
示例18: call_inx
static void call_inx( void )
{
PAIR tPC;
IMMWORD( tPC );
PUSHWORD( PC );
pPC = tPC.w.l + RDB;
CHANGE_PC;
tms7000_icount -= 16;
}
开发者ID:broftkd,项目名称:historic-mame,代码行数:10,代码来源:tms70op.c
示例19: call_dir
static void call_dir( void )
{
PAIR tPC;
IMMWORD( tPC );
PUSHWORD( PC );
pPC = tPC.d;
CHANGE_PC;
tms7000_icount -= 14;
}
开发者ID:broftkd,项目名称:historic-mame,代码行数:11,代码来源:tms70op.c
示例20: LOG
/* IRQ enter */
void m6800_cpu_device::enter_interrupt(const char *message,UINT16 irq_vector)
{
LOG((message, tag()));
if( m_wai_state & (M6800_WAI|M6800_SLP) )
{
if( m_wai_state & M6800_WAI )
m_icount -= 4;
m_wai_state &= ~(M6800_WAI|M6800_SLP);
}
else
{
PUSHWORD(pPC);
PUSHWORD(pX);
PUSHBYTE(A);
PUSHBYTE(B);
PUSHBYTE(CC);
m_icount -= 12;
}
SEI;
PCD = RM16( irq_vector );
}
开发者ID:GiuseppeGorgoglione,项目名称:mame,代码行数:22,代码来源:m6800.cpp
注:本文中的PUSHWORD函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论