8085 Reference: Difference between revisions
(Removing all content from page) |
(Add missing undocumented instructions to the Z80 Equivalent Mnemonics table) |
||
(98 intermediate revisions by 7 users not shown) | |||
Line 1: | Line 1: | ||
<H1>8085 Instruction Mnemonic Meanings</H1> | |||
<H2 >Data Transfer Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>MOV</P> | |||
| | <P>dreg, sreg</P> | |||
| | <P>MOVe</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MVI</P> | |||
| | <P>reg, byte</P> | |||
| | <P>MoVe Immediate</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MVX</P> | |||
| | <P>drp, srp</P> | |||
| | <P>MoVe eXtended-register (pseudo for high & | |||
low MOVs)</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LXI</P> | |||
| | <P>rp, word</P> | |||
| | <P>Load eXtended-register Immediate</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>XCHG</P> | |||
| | <P><BR></P> | |||
| | <P>eXCHanGe hl with de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDA</P> | |||
| | <P>addr</P> | |||
| | <P>LoaD Accumulator direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STA</P> | |||
| | <P>addr</P> | |||
| | <P>STore Accumulator direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>B</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
Bc</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>B</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register Bc</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>D</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
De</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>D</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register De</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Load HL Direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Store HL Direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Load HL Indirect via extended register de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>SHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Store HL Indirect via extended register de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Arithmetic Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>ADD</P> | |||
| | <P>reg</P> | |||
| | <P>ADD</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADI</P> | |||
| | <P>byte</P> | |||
| | <P>ADd Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADC</P> | |||
| | <P>reg</P> | |||
| | <P>ADd with Carry</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ACI</P> | |||
| | <P>byte</P> | |||
| | <P>Add with Carry Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SUB</P> | |||
| | <P>reg</P> | |||
| | <P>SUBtract</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SUI</P> | |||
| | <P>byte</P> | |||
| | <P>SUbtract Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SBB</P> | |||
| | <P>reg</P> | |||
| | <P>SuBtract with Borrow</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SBI</P> | |||
| | <P>byte</P> | |||
| | <P>Subtract with Borrow Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DAA</P> | |||
| | <P><BR></P> | |||
| | <P>Decimal Adjust Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>INR</P> | |||
| | <P>reg</P> | |||
| | <P>INcrement Register</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>INX</P> | |||
| | <P>rp</P> | |||
| | <P>INcrement eXtended-register</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DCR</P> | |||
| | <P>reg</P> | |||
| | <P>DeCrement Register</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DCX</P> | |||
| | <P>rp</P> | |||
| | <P>DeCrement eXtended-register</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DAD</P> | |||
| | <P>rp</P> | |||
| | <P>Dual-register ADd to hl</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>HLMBC</P> | |||
| | <P><BR></P> | |||
| | <P>HL Minus BC</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>h</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DEHL</P> | |||
| | <P>byte</P> | |||
| | <P>DE from HL plus byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>DESP</P> | |||
| | <P>byte</P> | |||
| | <P>DE from SP plus byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Logical Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>CMP</P> | |||
| | <P>reg</P> | |||
| | <P>CoMPare</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CPI</P> | |||
| | <P>byte</P> | |||
| | <P>ComPare Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CMA</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Accumulator</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CMC</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STC</P> | |||
| | <P><BR></P> | |||
| | <P>SeT Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLR</P> | |||
| | <P><BR></P> | |||
| | <P>Shift HL Right</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>ANA</P> | |||
| | <P>reg</P> | |||
| | <P>ANd Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ANI</P> | |||
| | <P>byte</P> | |||
| | <P>ANd Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ORA</P> | |||
| | <P>reg</P> | |||
| | <P>OR Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ORI</P> | |||
| | <P>byte</P> | |||
| | <P>OR Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XRA</P> | |||
| | <P>reg</P> | |||
| | <P>eXclusive oR Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XRI</P> | |||
| | <P>byte</P> | |||
| | <P>eXclusive oR Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>RAL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Left through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RAR</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Right through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RLC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Left Circular</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RRC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Right Circular</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>RDEL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate DE Left through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Stack, Input/Output, & Machine Control Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>PUSH</P> | |||
| | <P>rp</P> | |||
| | <P>PUSH on stack</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>POP</P> | |||
| | <P>rp</P> | |||
| | <P>POP off stack</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SPHL</P> | |||
| | <P><BR></P> | |||
| | <P>Stack Pointer from HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>XTHL</P> | |||
| | <P><BR></P> | |||
| | <P>eXchange Top of stack with HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>IN</P> | |||
| | <P>port</P> | |||
| | <P>INput from port</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>OUT</P> | |||
| | <P>port</P> | |||
| | <P>OUTput to port</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DI</P> | |||
| | <P><BR></P> | |||
| | <P>Disable Interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>EI</P> | |||
| | <P><BR></P> | |||
| | <P>Enable Interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>[[8085 RIM Instruction|RIM]]</P> | |||
| | <P><BR></P> | |||
| | <P>Read Interrupt Mask</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SIM</P> | |||
| | <P><BR></P> | |||
| | <P>Set Interrupt Mask</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>NOP</P> | |||
| | <P><BR></P> | |||
| | <P>No OPeration</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>HLT</P> | |||
| | <P><BR></P> | |||
| | <P>HaLT</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Branch Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>JMP</P> | |||
| | <P>label</P> | |||
| | <P>JuMP unconditional</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPE</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPO</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CALL</P> | |||
| | <P>label</P> | |||
| | <P>CALL unconditioanl</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CNZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CP</P> | |||
| | <P>label</P> | |||
| | <P>Call if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CM</P> | |||
| | <P>label</P> | |||
| | <P>Call if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CC</P> | |||
| | <P>label</P> | |||
| | <P>Call if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CNC</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPE</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPO</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RET</P> | |||
| | <P><BR></P> | |||
| | <P>RETurn unconditional</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RP</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RM</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPE</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPO</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>PCHL</P> | |||
| | <P><BR></P> | |||
| | <P>Program Counter from HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RST</P> | |||
| | <P>n</P> | |||
| | <P>ReSTart</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>RSTV</P> | |||
| | <P><BR></P> | |||
| | <P>ReSTart if oVerflow</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H1 >8085 Instruction Actions by Functional Group</H1> | |||
<H2 >Data Transfer Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 % | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 % | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 % | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>MOV</P> | |||
| | <P>dreg, sreg</P> | |||
| | <P>dreg<=sreg</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MVI</P> | |||
| | <P>reg, byte</P> | |||
| | <P>reg<=byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MVX</P> | |||
| | <P>drp, srp</P> | |||
| | <P>drp<=srp (pseudo for high & low MOVs)</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LXI</P> | |||
| | <P>rp, word</P> | |||
| | <P>rp<=word</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>XCHG</P> | |||
| | <P><BR></P> | |||
| | <P>HL<=DE while DE<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDA</P> | |||
| | <P>addr</P> | |||
| | <P>A<=b[addr]</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STA</P> | |||
| | <P>addr</P> | |||
| | <P>b[addr]<=A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>B</P> | |||
| | <P>A<=b[BC]</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>B</P> | |||
| | <P>b[BC]<=A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>D</P> | |||
| | <P>A<=b[DE]</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>D</P> | |||
| | <P>b[DE]<=A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLD</P> | |||
| | <P>addr</P> | |||
| | <P>HL<=w[addr]</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLD</P> | |||
| | <P>addr</P> | |||
| | <P>w[addr]<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLI</P> | |||
| | <P><BR></P> | |||
| | <P>HL<=w[DE]</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>SHLI</P> | |||
| | <P><BR></P> | |||
| | <P>w[DE]<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Arithmetic Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>ADD</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A+reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A+byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADC</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A+reg+Cf</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ACI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A+byte+Cf</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SUB</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A-reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SUI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A-byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SBB</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A-reg-Cf</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SBI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A-byte-Cf</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DAA</P> | |||
| | <P><BR></P> | |||
| | <P>in A3..A0 and A7..A4: if >9 then +6, carry | |||
to next</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>INR</P> | |||
| | <P>reg</P> | |||
| | <P>reg<=reg+1</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>INX</P> | |||
| | <P>rp</P> | |||
| | <P>rp<=rp+1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DCR</P> | |||
| | <P>reg</P> | |||
| | <P>reg<=reg-1</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DCX</P> | |||
| | <P>rp</P> | |||
| | <P>rp<=rp-1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DAD</P> | |||
| | <P>rp</P> | |||
| | <P>HL<=HL+rp</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>HLMBC</P> | |||
| | <P><BR></P> | |||
| | <P>HL<=HL-BC</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>h</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DEHL</P> | |||
| | <P>byte</P> | |||
| | <P>DE<=HL+byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- VALIGN=TOP | |||
| | <P>DESP</P> | |||
| | <P>byte</P> | |||
| | <P>DE<=SP+byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2 >Branch Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>JMP</P> | |||
| | <P>label</P> | |||
| | <P>PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JZ</P> | |||
| | <P>label</P> | |||
| | <P>if Zf=1 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNZ</P> | |||
| | <P>label</P> | |||
| | <P>if Zf=0 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JP</P> | |||
| | <P>label</P> | |||
| | <P>if Sf=0 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JM</P> | |||
| | <P>label</P> | |||
| | <P>if Sf=1 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JC</P> | |||
| | <P>label</P> | |||
| | <P>if Cf=1 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNC</P> | |||
| | <P>label</P> | |||
| | <P>if Cf=0 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTM</P> | |||
| | <P>label</P> | |||
| | <P>if TSf=1 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTP</P> | |||
| | <P>label</P> | |||
| | <P>if TSf=0 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPE</P> | |||
| | <P>label</P> | |||
| | <P>if Pf=1 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPO</P> | |||
| | <P>label</P> | |||
| | <P>if Pf=0 then PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CALL</P> | |||
| | <P>label</P> | |||
| | <P>SP<=SP-2, w[SP]<=PC+3, PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CZ</P> | |||
| | <P>label</P> | |||
| | <P>if Zf=1 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CNZ</P> | |||
| | <P>label</P> | |||
| | <P>if Zf=0 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CP</P> | |||
| | <P>label</P> | |||
| | <P>if Sf=0 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CM</P> | |||
| | <P>label</P> | |||
| | <P>if Sf=1 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CC</P> | |||
| | <P>label</P> | |||
| | <P>if Cf=1 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CNC</P> | |||
| | <P>label</P> | |||
| | <P>if Cf=0 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPE</P> | |||
| | <P>label</P> | |||
| | <P>if Pf=1 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPO</P> | |||
| | <P>label</P> | |||
| | <P>if Pf=0 then SP<=SP-2, w[SP]<=PC+3, | |||
PC<=label</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RET</P> | |||
| | <P><BR></P> | |||
| | <P>PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RZ</P> | |||
| | <P><BR></P> | |||
| | <P>if Zf=1 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNZ</P> | |||
| | <P><BR></P> | |||
| | <P>if Zf=0 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RP</P> | |||
| | <P><BR></P> | |||
| | <P>if Sf=0 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RM</P> | |||
| | <P><BR></P> | |||
| | <P>if Sf=1 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RC</P> | |||
| | <P><BR></P> | |||
| | <P>if Cf=1 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNC</P> | |||
| | <P><BR></P> | |||
| | <P>if Cf=0 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPE</P> | |||
| | <P><BR></P> | |||
| | <P>if Pf=1 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPO</P> | |||
| | <P><BR></P> | |||
| | <P>if Pf=0 then PC<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>PCHL</P> | |||
| | <P><BR></P> | |||
| | <P>PC<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RST</P> | |||
| | <P>n</P> | |||
| | <P>SP<=SP-2, w[SP]<=PC+1, PC<=n*8 where n | |||
is 0 to 7</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RSTV</P> | |||
| | <P><BR></P> | |||
| | <P>if OVf=1 then SP<=SP-2, w[SP]<=PC+1, | |||
PC<=8*8</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2>Logical Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>CMP</P> | |||
| | <P>reg</P> | |||
| | <P>T<=A-reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CPI</P> | |||
| | <P>byte</P> | |||
| | <P>T<=A-byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CMA</P> | |||
| | <P><BR></P> | |||
| | <P>A<=1's complement of A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CMC</P> | |||
| | <P><BR></P> | |||
| | <P>Cf<=1's complement of Cf</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STC</P> | |||
| | <P><BR></P> | |||
| | <P>Cf<=1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLR</P> | |||
| | <P><BR></P> | |||
| | <P>HL<=HL/2 while H6<=H7 (extend sign) and | |||
Cf<=L0</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>ANA</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A AND reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ANI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A AND byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ORA</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A Inclusive OR reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ORI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A Inclusive OR byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XRA</P> | |||
| | <P>reg</P> | |||
| | <P>A<=A Exclusive OR reg</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XRI</P> | |||
| | <P>byte</P> | |||
| | <P>A<=A Exclusive OR byte</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>RAL</P> | |||
| | <P><BR></P> | |||
| | <P>A<=A*2 where Cf<=A7 while A0<=Cf</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RAR</P> | |||
| | <P><BR></P> | |||
| | <P>A<=A/2 where Cf<=A0 while A7<=Cf</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RLC</P> | |||
| | <P><BR></P> | |||
| | <P>A7..A1<=A6..A0 while A0<=A7 and Cf<=A7</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RRC</P> | |||
| | <P><BR></P> | |||
| | <P>A6..A0<=A7..A1 while A7<=A0 and Cf<=A0</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RDEL</P> | |||
| | <P><BR></P> | |||
| | <P>DE<=DE*2 where: Cf<=DE15 while DE00<=Cf</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H2>Stack, Input/Output, & Machine Control Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>PUSH</P> | |||
| | <P>rp</P> | |||
| | <P>SP<=SP-2, w[SP]<=rp</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>POP</P> | |||
| | <P>rp</P> | |||
| | <P>rp<=w[SP], SP<=SP+2</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SPHL</P> | |||
| | <P><BR></P> | |||
| | <P>SP<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>XTHL</P> | |||
| | <P><BR></P> | |||
| | <P>HL<=w[SP] while w[SP]<=HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>IN</P> | |||
| | <P>port</P> | |||
| | <P>A<=data from port</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>OUT</P> | |||
| | <P>port</P> | |||
| | <P>data to port<=A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DI</P> | |||
| | <P><BR></P> | |||
| | <P>disable interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>EI</P> | |||
| | <P><BR></P> | |||
| | <P>enable interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RIM</P> | |||
| | <P><BR></P> | |||
| | <P>A<=interrupt mask</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SIM</P> | |||
| | <P><BR></P> | |||
| | <P>interrupt mask<=A</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>NOP</P> | |||
| | <P><BR></P> | |||
| | <P>do nothing</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>HLT</P> | |||
| | <P><BR></P> | |||
| | <P>halt 8085 processor</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H1 STYLE="page-break-before: always">8085 Instructions by Mnemonic</H1> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| COLSPAN=4 | <P>Flags</P> | |||
|- | |||
| COLSPAN=3 | <P><BR></P> | |||
| | <P ALIGN=CENTER>Zf</P> | |||
| | <P ALIGN=CENTER>Cf</P> | |||
| | <P ALIGN=CENTER>Pf</P> | |||
| | <P ALIGN=CENTER>Sf</P> | |||
|- | |||
| | <P>ACI</P> | |||
| | <P>byte</P> | |||
| | <P>Add with Carry Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADC</P> | |||
| | <P>reg</P> | |||
| | <P>ADd with Carry</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADD</P> | |||
| | <P>reg</P> | |||
| | <P>ADD</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ADI</P> | |||
| | <P>byte</P> | |||
| | <P>ADd Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ANA</P> | |||
| | <P>reg</P> | |||
| | <P>ANd Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ANI</P> | |||
| | <P>byte</P> | |||
| | <P>ANd Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CALL</P> | |||
| | <P>label</P> | |||
| | <P>CALL unconditional</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CC</P> | |||
| | <P>label</P> | |||
| | <P>Call if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CM</P> | |||
| | <P>label</P> | |||
| | <P>Call if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CMA</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Accumulator</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CMC</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CMP</P> | |||
| | <P>reg</P> | |||
| | <P>CoMPare</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CNC</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CNZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CP</P> | |||
| | <P>label</P> | |||
| | <P>Call if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPE</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CPI</P> | |||
| | <P>byte</P> | |||
| | <P>ComPare Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>CPO</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>CZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DAA</P> | |||
| | <P><BR></P> | |||
| | <P>Decimal Adjust Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DAD</P> | |||
| | <P>rp</P> | |||
| | <P>Dual-register ADd to hl</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DCR</P> | |||
| | <P>reg</P> | |||
| | <P>DeCrement Register</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>DCX</P> | |||
| | <P>rp</P> | |||
| | <P>DeCrement eXtended-register</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DEHL</P> | |||
| | <P>byte</P> | |||
| | <P>DE from HL plus byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DESP</P> | |||
| | <P>byte</P> | |||
| | <P>DE from SP plus byte</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>DI</P> | |||
| | <P><BR></P> | |||
| | <P>Disable Interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>EI</P> | |||
| | <P><BR></P> | |||
| | <P>Enable Interrupts</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>HLMBC</P> | |||
| | <P><BR></P> | |||
| | <P>HL Minus BC</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>h</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>HLT</P> | |||
| | <P><BR></P> | |||
| | <P>HaLT</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>IN</P> | |||
| | <P>port</P> | |||
| | <P>INput from port</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>INR</P> | |||
| | <P>reg</P> | |||
| | <P>INcrement Register</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>INX</P> | |||
| | <P>rp</P> | |||
| | <P>INcrement eXtended-register</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JMP</P> | |||
| | <P>label</P> | |||
| | <P>JuMP unconditional</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JNZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPE</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JPO</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JTP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>JZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDA</P> | |||
| | <P>addr</P> | |||
| | <P>LoaD Accumulator direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>B</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
Bc</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>D</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
De</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Load HL Direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Load HL Indirect via extended register de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>LXI</P> | |||
| | <P>rp, word</P> | |||
| | <P>Load eXtended-register Immediate</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MOV</P> | |||
| | <P>dreg, sreg</P> | |||
| | <P>MOVe</P> | |||
| | <P ALIGN=CENTER><BR></P> | |||
| | <P ALIGN=CENTER><BR></P> | |||
| | <P ALIGN=CENTER><BR></P> | |||
| | <P ALIGN=CENTER><BR></P> | |||
|- | |||
| | <P>MVI</P> | |||
| | <P>reg, byte</P> | |||
| | <P>MoVe Immediate</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>MVX</P> | |||
| | <P>drp, srp</P> | |||
| | <P>MoVe eXtended-register (pseudo for high & | |||
low MOVs)</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>NOP</P> | |||
| | <P><BR></P> | |||
| | <P>No OPeration</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>ORA</P> | |||
| | <P>reg</P> | |||
| | <P>OR Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>ORI</P> | |||
| | <P>byte</P> | |||
| | <P>OR Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>OUT</P> | |||
| | <P>port</P> | |||
| | <P>OUTput to port</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>PCHL</P> | |||
| | <P><BR></P> | |||
| | <P>Program Counter from HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>POP</P> | |||
| | <P>rp</P> | |||
| | <P>POP off stack</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>PUSH</P> | |||
| | <P>rp</P> | |||
| | <P>PUSH on stack</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RAL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Left through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RAR</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Right through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RDEL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate DE Left through carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RET</P> | |||
| | <P><BR></P> | |||
| | <P>RETurn unconditional</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RIM</P> | |||
| | <P><BR></P> | |||
| | <P>Read Interrupt Mask</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RLC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Left Circular</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RM</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Minus</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RNZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RP</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Positive</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPE</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Even</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RPO</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Odd</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RRC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Right Circular</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RST</P> | |||
| | <P>n</P> | |||
| | <P>ReSTart</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RSTV</P> | |||
| | <P><BR></P> | |||
| | <P>ReSTart if oVerflow</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>RZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Zero</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SBB</P> | |||
| | <P>reg</P> | |||
| | <P>SuBtract with Borrow</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SBI</P> | |||
| | <P>byte</P> | |||
| | <P>Subtract with Borrow Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Store HL Direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Store HL Indirect via extended register de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SHLR</P> | |||
| | <P><BR></P> | |||
| | <P>Shift HL Right</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SIM</P> | |||
| | <P><BR></P> | |||
| | <P>Set Interrupt Mask</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SPHL</P> | |||
| | <P><BR></P> | |||
| | <P>Stack Pointer from HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STA</P> | |||
| | <P>addr</P> | |||
| | <P>STore Accumulator direct</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>B</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register Bc</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>D</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register De</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>STC</P> | |||
| | <P><BR></P> | |||
| | <P>SeT Carry</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>1</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>SUB</P> | |||
| | <P>reg</P> | |||
| | <P>SUBtract</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>SUI</P> | |||
| | <P>byte</P> | |||
| | <P>SUbtract Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XCHG</P> | |||
| | <P><BR></P> | |||
| | <P>eXCHanGe hl with de</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|- | |||
| | <P>XRA</P> | |||
| | <P>reg</P> | |||
| | <P>eXclusive oR Accumulator</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XRI</P> | |||
| | <P>byte</P> | |||
| | <P>eXclusive oR Immediate</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>0</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
| | <P ALIGN=CENTER>x</P> | |||
|- | |||
| | <P>XTHL</P> | |||
| | <P><BR></P> | |||
| | <P>eXchange Top of stack with HL</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
| | <P ALIGN=CENTER>.</P> | |||
|} | |||
<H1>8085 Machine Cycles by Functional Group</H1> | |||
<p> | |||
For cycle counts, EC refers to Essential Cycles. MM refers to additional cycles in the case that register M is involved or condition met | |||
</p> | |||
<H2 >Data Transfer Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P><BR></P> | |||
| | <P>Essential Cycles +register M involved or | |||
condition Met</P> | |||
| | <P ALIGN=RIGHT>EC +MM</P> | |||
|- | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| | <P ALIGN=RIGHT>Cycles</P> | |||
|- | |||
| | <P>MOV</P> | |||
| | <P>dreg, sreg</P> | |||
| | <P>MOVe</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>MVI</P> | |||
| | <P>reg, byte</P> | |||
| | <P>MoVe Immediate</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>MVX</P> | |||
| | <P>drp, srp</P> | |||
| | <P>MoVe eXtended-register (pseudo for high & | |||
low MOVs)</P> | |||
| | <P ALIGN=RIGHT>--</P> | |||
|- | |||
| | <P>LXI</P> | |||
| | <P>rp, word</P> | |||
| | <P>Load eXtended-register Immediate</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>XCHG</P> | |||
| | <P><BR></P> | |||
| | <P>eXCHanGe hl with de</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>LDA</P> | |||
| | <P>addr</P> | |||
| | <P>LoaD Accumulator direct</P> | |||
| | <P ALIGN=RIGHT>13</P> | |||
|- | |||
| | <P>STA</P> | |||
| | <P>addr</P> | |||
| | <P>STore Accumulator direct</P> | |||
| | <P ALIGN=RIGHT>13</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>B</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
Bc</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>B</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register Bc</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>LDAX</P> | |||
| | <P>D</P> | |||
| | <P>LoaD Accumulator indirect via eXtended-register | |||
De</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>STAX</P> | |||
| | <P>D</P> | |||
| | <P>Store Accumulator indirect via | |||
eXtended-register De</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>LHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Load HL Direct</P> | |||
| | <P ALIGN=RIGHT>16</P> | |||
|- | |||
| | <P>SHLD</P> | |||
| | <P>addr</P> | |||
| | <P>Store HL Direct</P> | |||
| | <P ALIGN=RIGHT>16</P> | |||
|- | |||
| | <P>LHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Load HL Indirect via extended register de</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- VALIGN=TOP | |||
| | <P>SHLI</P> | |||
| | <P><BR></P> | |||
| | <P>Store HL Indirect via extended register de</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|} | |||
<H2 >Arithmetic Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P><BR></P> | |||
| | <P>Essential Cycles +register M involved or | |||
condition Met</P> | |||
| | <P ALIGN=RIGHT>EC +MM</P> | |||
|- | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| | <P ALIGN=RIGHT>Cycles</P> | |||
|- | |||
| | <P>ADD</P> | |||
| | <P>reg</P> | |||
| | <P>ADD</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>ADI</P> | |||
| | <P>byte</P> | |||
| | <P>ADd Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>ADC</P> | |||
| | <P>reg</P> | |||
| | <P>ADd with Carry</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>ACI</P> | |||
| | <P>byte</P> | |||
| | <P>Add with Carry Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>SUB</P> | |||
| | <P>reg</P> | |||
| | <P>SUBtract</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>SUI</P> | |||
| | <P>byte</P> | |||
| | <P>SUbtract Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>SBB</P> | |||
| | <P>reg</P> | |||
| | <P>SuBtract with Borrow</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>SBI</P> | |||
| | <P>byte</P> | |||
| | <P>Subtract with Borrow Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>DAA</P> | |||
| | <P><BR></P> | |||
| | <P>Decimal Adjust Accumulator</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>INR</P> | |||
| | <P>reg</P> | |||
| | <P>INcrement Register</P> | |||
| | <P ALIGN=RIGHT>04 +06</P> | |||
|- | |||
| | <P>INX</P> | |||
| | <P>rp</P> | |||
| | <P>INcrement eXtended-register</P> | |||
| | <P ALIGN=RIGHT>06</P> | |||
|- | |||
| | <P>DCR</P> | |||
| | <P>reg</P> | |||
| | <P>DeCrement Register</P> | |||
| | <P ALIGN=RIGHT>04 +06</P> | |||
|- | |||
| | <P>DCX</P> | |||
| | <P>rp</P> | |||
| | <P>DeCrement eXtended-register</P> | |||
| | <P ALIGN=RIGHT>06</P> | |||
|- | |||
| | <P>DAD</P> | |||
| | <P>rp</P> | |||
| | <P>Dual-register ADd to hl</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>HLMBC</P> | |||
| | <P><BR></P> | |||
| | <P>HL Minus BC</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>DEHL</P> | |||
| | <P>byte</P> | |||
| | <P>DE from HL plus byte</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- VALIGN=TOP | |||
| | <P>DESP</P> | |||
| | <P>byte</P> | |||
| | <P>DE from SP plus byte</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|} | |||
<H2 >Logical Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P><BR></P> | |||
| | <P>Essential Cycles +register M involved or | |||
condition Met</P> | |||
| | <P ALIGN=RIGHT>EC +MM</P> | |||
|- | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| | <P ALIGN=RIGHT>Cycles</P> | |||
|- | |||
| | <P>CMP</P> | |||
| | <P>reg</P> | |||
| | <P>CoMPare</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>CPI</P> | |||
| | <P>byte</P> | |||
| | <P>ComPare Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>CMA</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Accumulator</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>CMC</P> | |||
| | <P><BR></P> | |||
| | <P>CoMplement Carry</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>STC</P> | |||
| | <P><BR></P> | |||
| | <P>SeT Carry</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>SHLR</P> | |||
| | <P><BR></P> | |||
| | <P>Shift HL Right</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>ANA</P> | |||
| | <P>reg</P> | |||
| | <P>ANd Accumulator</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>ANI</P> | |||
| | <P>byte</P> | |||
| | <P>ANd Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>ORA</P> | |||
| | <P>reg</P> | |||
| | <P>OR Accumulator</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>ORI</P> | |||
| | <P>byte</P> | |||
| | <P>OR Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>XRA</P> | |||
| | <P>reg</P> | |||
| | <P>eXclusive oR Accumulator</P> | |||
| | <P ALIGN=RIGHT>04 +03</P> | |||
|- | |||
| | <P>XRI</P> | |||
| | <P>byte</P> | |||
| | <P>eXclusive oR Immediate</P> | |||
| | <P ALIGN=RIGHT>07</P> | |||
|- | |||
| | <P>RAL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Left through carry</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>RAR</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate Accumulator Right through carry</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>RLC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Left Circular</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>RRC</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate accumulator Right Circular</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- VALIGN=TOP | |||
| | <P>RDEL</P> | |||
| | <P><BR></P> | |||
| | <P>Rotate DE Left through carry</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|} | |||
<H2 >Stack, Input/Output, & Machine Control Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P><BR></P> | |||
| | <P>Essential Cycles +register M involved or | |||
condition Met</P> | |||
| | <P ALIGN=RIGHT>EC +MM</P> | |||
|- | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| | <P ALIGN=RIGHT>Cycles</P> | |||
|- | |||
| | <P>PUSH</P> | |||
| | <P>rp</P> | |||
| | <P>PUSH on stack</P> | |||
| | <P ALIGN=RIGHT>12</P> | |||
|- | |||
| | <P>POP</P> | |||
| | <P>rp</P> | |||
| | <P>POP off stack</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>SPHL</P> | |||
| | <P><BR></P> | |||
| | <P>Stack Pointer from HL</P> | |||
| | <P ALIGN=RIGHT>06</P> | |||
|- | |||
| | <P>XTHL</P> | |||
| | <P><BR></P> | |||
| | <P>eXchange Top of stack with HL</P> | |||
| | <P ALIGN=RIGHT>16</P> | |||
|- | |||
| | <P>IN</P> | |||
| | <P>port</P> | |||
| | <P>INput from port</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>OUT</P> | |||
| | <P>port</P> | |||
| | <P>OUTput to port</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>DI</P> | |||
| | <P><BR></P> | |||
| | <P>Disable Interrupts</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>EI</P> | |||
| | <P><BR></P> | |||
| | <P>Enable Interrupts</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>RIM</P> | |||
| | <P><BR></P> | |||
| | <P>Read Interrupt Mask</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>SIM</P> | |||
| | <P><BR></P> | |||
| | <P>Set Interrupt Mask</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>NOP</P> | |||
| | <P><BR></P> | |||
| | <P>No OPeration</P> | |||
| | <P ALIGN=RIGHT>04</P> | |||
|- | |||
| | <P>HLT</P> | |||
| | <P><BR></P> | |||
| | <P>HaLT</P> | |||
| | <P ALIGN=RIGHT>05</P> | |||
|} | |||
<H2 >Branch Group</H2> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
| COLSPAN=2 | <P><BR></P> | |||
| | <P>Essential Cycles +register M involved or | |||
condition Met</P> | |||
| | <P ALIGN=RIGHT>EC +MM</P> | |||
|- | |||
| COLSPAN=2 | <P>Instruction</P> | |||
| | <P>Mnemonic Meaning</P> | |||
| | <P ALIGN=RIGHT>Cycles</P> | |||
|- | |||
| | <P>JMP</P> | |||
| | <P>label</P> | |||
| | <P>JuMP unconditional</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>JZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Zero</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JNZ</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Zero</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Positive</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Minus</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Carry</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JNC</P> | |||
| | <P>label</P> | |||
| | <P>Jump if No Carry</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JTM</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Minus</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JTP</P> | |||
| | <P>label</P> | |||
| | <P>Jump if True sign Positive</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JPE</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Even</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>JPO</P> | |||
| | <P>label</P> | |||
| | <P>Jump if Parity Odd</P> | |||
| | <P ALIGN=RIGHT>07 +03</P> | |||
|- | |||
| | <P>CALL</P> | |||
| | <P>label</P> | |||
| | <P>CALL unconditional</P> | |||
| | <P ALIGN=RIGHT>18</P> | |||
|- | |||
| | <P>CZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if Zero</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CNZ</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Zero</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CP</P> | |||
| | <P>label</P> | |||
| | <P>Call if Positive</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CM</P> | |||
| | <P>label</P> | |||
| | <P>Call if Minus</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CC</P> | |||
| | <P>label</P> | |||
| | <P>Call if Carry</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CNC</P> | |||
| | <P>label</P> | |||
| | <P>Call if No Carry</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CPE</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Even</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>CPO</P> | |||
| | <P>label</P> | |||
| | <P>Call if Parity Odd</P> | |||
| | <P ALIGN=RIGHT>09 +09</P> | |||
|- | |||
| | <P>RET</P> | |||
| | <P><BR></P> | |||
| | <P>RETurn unconditional</P> | |||
| | <P ALIGN=RIGHT>10</P> | |||
|- | |||
| | <P>RZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Zero</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RNZ</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Zero</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RP</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Positive</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RM</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Minus</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Carry</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RNC</P> | |||
| | <P><BR></P> | |||
| | <P>Return if No Carry</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RPE</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Even</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>RPO</P> | |||
| | <P><BR></P> | |||
| | <P>Return if Parity Odd</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|- | |||
| | <P>PCHL</P> | |||
| | <P><BR></P> | |||
| | <P>Program Counter from HL</P> | |||
| | <P ALIGN=RIGHT>06</P> | |||
|- | |||
| | <P>RST</P> | |||
| | <P>n</P> | |||
| | <P>ReSTart</P> | |||
| | <P ALIGN=RIGHT>12</P> | |||
|- VALIGN=TOP | |||
| | <P>RSTV</P> | |||
| | <P><BR></P> | |||
| | <P>ReSTart if oVerflow</P> | |||
| | <P ALIGN=RIGHT>06 +06</P> | |||
|} | |||
<H1 >8085 Instruction Mnemonics by Op-code</H1> | |||
{| BORDER="1" WIDTH=100% style="font-size:70%" | |||
| | <P><BR></P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x0h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x1h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x2h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x3h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x4h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x5h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x6h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x7h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x8h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">x9h</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xAh</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xBh</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xCh</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xDh</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xEh</P> | |||
| | <P ALIGN=CENTER STYLE="margin-left: -0.04in">xFh</P> | |||
|- | |||
| | <P>00h-0Fh</P> | |||
| | <P>NOP</P> | |||
| | <P>LXI B,w</P> | |||
| | <P>STAX B</P> | |||
| | <P>INX B</P> | |||
| | <P>INR B</P> | |||
| | <P>DCR B</P> | |||
| | <P>MVI B,b</P> | |||
| | <P>RLC</P> | |||
| style="background:lightgreen; color:black" | <P>DSUB<br/>HLMBC</P> | |||
| | <P>DAD B</P> | |||
| | <P>LDAX B</P> | |||
| | <P>DCX B</P> | |||
| | <P>INR C</P> | |||
| | <P>DCR C</P> | |||
| | <P>MVI C,b</P> | |||
| | <P>RRC</P> | |||
|- | |||
| | <P>10h-1Fh</P> | |||
| style="background:lightgreen; color:black" | <P>ARHL<br/>RRHL<br/>SHLR</P> | |||
| | <P>LXI D,w</P> | |||
| | <P>STAX D</P> | |||
| | <P>INX D</P> | |||
| | <P>INR D</P> | |||
| | <P>DCR D</P> | |||
| | <P>MVI D,b</P> | |||
| | <P>RAL</P> | |||
| style="background:lightgreen; color:black" | <P>RDEL<br/>RLDE</P> | |||
| | <P>DAD D</P> | |||
| | <P>LDAX D</P> | |||
| | <P>DCX D</P> | |||
| | <P>INR E</P> | |||
| | <P>DCR E</P> | |||
| | <P>MVI E,b</P> | |||
| | <P>RAR</P> | |||
|- | |||
| | <P>20h-2Fh</P> | |||
| | <P>RIM</P> | |||
| | <P>LXI H,w</P> | |||
| | <P>SHLD @</P> | |||
| | <P>INX H</P> | |||
| | <P>INR H</P> | |||
| | <P>DCR H</P> | |||
| | <P>MVI H,b</P> | |||
| | <P>DAA</P> | |||
| style="background:lightgreen; color:black" | <P>DEHL b<br/>LDHI b</P> | |||
| | <P>DAD H</P> | |||
| | <P>LHLD @</P> | |||
| | <P>DCX H</P> | |||
| | <P>INR L</P> | |||
| | <P>DCR L</P> | |||
| | <P>MVI L,b</P> | |||
| | <P>CMA</P> | |||
|- | |||
| | <P>30h-3Fh</P> | |||
| | <P>SIM</P> | |||
| | <P>LXI SP,w</P> | |||
| | <P>STA @</P> | |||
| | <P>INX SP</P> | |||
| | <P>INR M</P> | |||
| | <P>DCR M</P> | |||
| | <P>MVI M,b</P> | |||
| | <P>STC</P> | |||
| style="background:lightgreen; color:black" | <P>DESP b<br/>LDSI b</P> | |||
| | <P>DAD SP</P> | |||
| | <P>LDA @</P> | |||
| | <P>DCX SP</P> | |||
| | <P>INR A</P> | |||
| | <P>DCR A</P> | |||
| | <P>MVI A,b</P> | |||
| | <P>CMC</P> | |||
|- | |||
| | <P>40h-4Fh</P> | |||
| | <P>MOV B,B</P> | |||
| | <P>MOV B,C</P> | |||
| | <P>MOV B,D</P> | |||
| | <P>MOV B,E</P> | |||
| | <P>MOV B,H</P> | |||
| | <P>MOV B,L</P> | |||
| | <P>MOV B,M</P> | |||
| | <P>MOV B,A</P> | |||
| | <P>MOV C,B</P> | |||
| | <P>MOV C,C</P> | |||
| | <P>MOV C,D</P> | |||
| | <P>MOV C,E</P> | |||
| | <P>MOV C,H</P> | |||
| | <P>MOV C,L</P> | |||
| | <P>MOV C,M</P> | |||
| | <P>MOV C,A</P> | |||
|- | |||
| | <P>50h-5Fh</P> | |||
| | <P>MOV D,B</P> | |||
| | <P>MOV D,C</P> | |||
| | <P>MOV D,D</P> | |||
| | <P>MOV D,E</P> | |||
| | <P>MOV D,H</P> | |||
| | <P>MOV D,L</P> | |||
| | <P>MOV D,M</P> | |||
| | <P>MOV D,A</P> | |||
| | <P>MOV E,B</P> | |||
| | <P>MOV E,C</P> | |||
| | <P>MOV E,D</P> | |||
| | <P>MOV E,E</P> | |||
| | <P>MOV E,H</P> | |||
| | <P>MOV E,L</P> | |||
| | <P>MOV E,M</P> | |||
| | <P>MOV E,A</P> | |||
|- | |||
| | <P>60h-6Fh</P> | |||
| | <P>MOV H,B</P> | |||
| | <P>MOV H,C</P> | |||
| | <P>MOV H,D</P> | |||
| | <P>MOV H,E</P> | |||
| | <P>MOV H,H</P> | |||
| | <P>MOV H,L</P> | |||
| | <P>MOV H,M</P> | |||
| | <P>MOV H,A</P> | |||
| | <P>MOV L,B</P> | |||
| | <P>MOV L,C</P> | |||
| | <P>MOV L,D</P> | |||
| | <P>MOV L,E</P> | |||
| | <P>MOV L,H</P> | |||
| | <P>MOV L,L</P> | |||
| | <P>MOV L,M</P> | |||
| | <P>MOV L,A</P> | |||
|- | |||
| | <P>70h-7Fh</P> | |||
| | <P>MOV M,B</P> | |||
| | <P>MOV M,C</P> | |||
| | <P>MOV M,D</P> | |||
| | <P>MOV M,E</P> | |||
| | <P>MOV M,H</P> | |||
| | <P>MOV M,L</P> | |||
| | <P>HLT</P> | |||
| | <P>MOV M,A</P> | |||
| | <P>MOV A,B</P> | |||
| | <P>MOV A,C</P> | |||
| | <P>MOV A,D</P> | |||
| | <P>MOV A,E</P> | |||
| | <P>MOV A,H</P> | |||
| | <P>MOV A,L</P> | |||
| | <P>MOV A,M</P> | |||
| | <P>MOV A,A</P> | |||
|- | |||
| | <P>80h-8Fh</P> | |||
| | <P>ADD B</P> | |||
| | <P>ADD C</P> | |||
| | <P>ADD D</P> | |||
| | <P>ADD E</P> | |||
| | <P>ADD H</P> | |||
| | <P>ADD L</P> | |||
| | <P>ADD M</P> | |||
| | <P>ADD A</P> | |||
| | <P>ADC B</P> | |||
| | <P>ADC C</P> | |||
| | <P>ADC D</P> | |||
| | <P>ADC E</P> | |||
| | <P>ADC H</P> | |||
| | <P>ADC L</P> | |||
| | <P>ADC M</P> | |||
| | <P>ADC A</P> | |||
|- | |||
| | <P>90h-9Fh</P> | |||
| | <P>SUB B</P> | |||
| | <P>SUB C</P> | |||
| | <P>SUB D</P> | |||
| | <P>SUB E</P> | |||
| | <P>SUB H</P> | |||
| | <P>SUB L</P> | |||
| | <P>SUB M</P> | |||
| | <P>SUB A</P> | |||
| | <P>SBB B</P> | |||
| | <P>SBB C</P> | |||
| | <P>SBB D</P> | |||
| | <P>SBB E</P> | |||
| | <P>SBB H</P> | |||
| | <P>SBB L</P> | |||
| | <P>SBB M</P> | |||
| | <P>SBB A</P> | |||
|- | |||
| | <P>A0h-AFh</P> | |||
| | <P>ANA B</P> | |||
| | <P>ANA C</P> | |||
| | <P>ANA D</P> | |||
| | <P>ANA E</P> | |||
| | <P>ANA H</P> | |||
| | <P>ANA L</P> | |||
| | <P>ANA M</P> | |||
| | <P>ANA A</P> | |||
| | <P>XRA B</P> | |||
| | <P>XRA C</P> | |||
| | <P>XRA D</P> | |||
| | <P>XRA E</P> | |||
| | <P>XRA H</P> | |||
| | <P>XRA L</P> | |||
| | <P>XRA M</P> | |||
| | <P>XRA A</P> | |||
|- | |||
| | <P>B0h-BFh</P> | |||
| | <P>ORA B</P> | |||
| | <P>ORA C</P> | |||
| | <P>ORA D</P> | |||
| | <P>ORA E</P> | |||
| | <P>ORA H</P> | |||
| | <P>ORA L</P> | |||
| | <P>ORA M</P> | |||
| | <P>ORA A</P> | |||
| | <P>CMP B</P> | |||
| | <P>CMP C</P> | |||
| | <P>CMP D</P> | |||
| | <P>CMP E</P> | |||
| | <P>CMP H</P> | |||
| | <P>CMP L</P> | |||
| | <P>CMP M</P> | |||
| | <P>CMP A</P> | |||
|- | |||
| | <P>COh-CFh</P> | |||
| | <P>RNZ</P> | |||
| | <P>POP B</P> | |||
| | <P>JNZ @</P> | |||
| | <P>JMP @</P> | |||
| | <P>CNZ @</P> | |||
| | <P>PUSH B</P> | |||
| | <P>ADI b</P> | |||
| | <P>RST 0</P> | |||
| | <P>RZ</P> | |||
| | <P>RET</P> | |||
| | <P>JZ @</P> | |||
| | <P>RSTV</P> | |||
| | <P>CZ @</P> | |||
| | <P>CALL @</P> | |||
| | <P>ACI b</P> | |||
| | <P>RST 1</P> | |||
|- | |||
| | <P>D0h-DFh</P> | |||
| | <P>RNC</P> | |||
| | <P>POP D</P> | |||
| | <P>JNC @</P> | |||
| | <P>OUT port</P> | |||
| | <P>CNC @</P> | |||
| | <P>PUSH D</P> | |||
| | <P>SUI b</P> | |||
| | <P>RST 2</P> | |||
| | <P>RC</P> | |||
| style="background:lightgreen; color:black" | <P>SHLX<br/>SHLDE<br/>SHLI</P> | |||
| | <P>JC @</P> | |||
| | <P>IN port</P> | |||
| | <P>CC @</P> | |||
| style="background:lightgreen; color:black" | <P>JNX5 @<br/>JNK @<br/>JTP @</P> | |||
| | <P>SBI b</P> | |||
| | <P>RST 3</P> | |||
|- | |||
| | <P>E0h-EFh</P> | |||
| | <P>RPO</P> | |||
| | <P>POP H</P> | |||
| | <P>JPO @</P> | |||
| | <P>XTHL</P> | |||
| | <P>CPO @</P> | |||
| | <P>PUSH H</P> | |||
| | <P>ANI b</P> | |||
| | <P>RST 4</P> | |||
| | <P>RPE</P> | |||
| | <P>PCHL</P> | |||
| | <P>JPE @</P> | |||
| | <P>XCHG</P> | |||
| | <P>CPE @</P> | |||
| style="background:lightgreen; color:black" | <P>LHLI<br/>LHLX<br/>LHLDE</P> | |||
| | <P>XRI b</P> | |||
| | <P>RST 5</P> | |||
|- | |||
| | <P>F0h-FFh</P> | |||
| | <P>RP</P> | |||
| | <P>POP PSW</P> | |||
| | <P>JP @</P> | |||
| | <P>DI</P> | |||
| | <P>CP @</P> | |||
| | <P>PUSH PSW</P> | |||
| | <P>ORI b</P> | |||
| | <P>RST 6</P> | |||
| | <P>RM</P> | |||
| | <P>SPHL</P> | |||
| | <P>JM @</P> | |||
| | <P>EI</P> | |||
| | <P>CM @</P> | |||
| style="background:lightgreen; color:black" | <P>JX5 @<br/>JK @<br/>JTM @</P> | |||
| | <P>CPI b</P> | |||
| | <P>RST 7</P> | |||
|} | |||
<H1>Z80 Equivalent Mnemonics</H1> | |||
{| BORDER=1 WIDTH=70% style="font-size:70%" | |||
|- | |||
! 8085 !! Z80 !! Remarks | |||
|- | |||
| ACI data || ADC A,data || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ADC M || ADC A,(HL) || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ADC reg || ADC A,reg || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ADD M || ADD A,(HL) || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ADD reg || ADD A,reg || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ADI data || ADD A,data || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| ANA M || AND (HL) || | |||
|- | |||
| ANA reg || AND reg || | |||
|- | |||
| ANI data || AND data || | |||
|- | |||
| style="background:lightgreen; color:black" | ARHL / RRHL / SHLR | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as DJNZ @ (Decrement B and jump if not zero)! | |||
|- | |||
| CALL label || CALL label || | |||
|- | |||
| CC label || CALL C,label || | |||
|- | |||
| CM label || CALL M,label || | |||
|- | |||
| CMA || CPL || | |||
|- | |||
| CMC || CCF || | |||
|- | |||
| CMP M || CP (HL) || | |||
|- | |||
| CMP reg || CP reg || | |||
|- | |||
| CNC label || CALL NC,label || | |||
|- | |||
| CNZ label || CALL NZ,label || | |||
|- | |||
| CP label || CALL P,label || | |||
|- | |||
| CPE label || CALL PE,label || | |||
|- | |||
| CPI data || CP data || | |||
|- | |||
| CPO label || CALL PO,label || | |||
|- | |||
| CZ label || CALL Z,label || | |||
|- | |||
| DAA || DAA || Z80 corrects both addition and substraction while 8085 only corrects addition | |||
|- | |||
| DAD rp || ADD HL,rp || | |||
|- | |||
| DCR M || DEC (HL) || | |||
|- | |||
| DCR reg || DEC reg || | |||
|- | |||
| DCX rp || DEC rp || | |||
|- | |||
| style="background:lightgreen; color:black" | DEHL data / LDHI data | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as JR z,@ (Jump Relative if zero)! | |||
|- | |||
| style="background:lightgreen; color:black" | DESP data / LDSI data | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as JR c,@ (Jump Relative if carry)! | |||
|- | |||
| DI || DI || | |||
|- | |||
| style="background:lightgreen; color:black" | DSUB / HLMBC | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as EX AF,AF' (Exchange register AF with AF')! | |||
|- | |||
| EI || EI || | |||
|- | |||
| HLT || HALT || | |||
|- | |||
| IN port || IN A,port || | |||
|- | |||
| INR M || INC (HL) || | |||
|- | |||
| INR reg || INC reg || Z80 takes 4 cycles, 8085 takes 5 cycles | |||
|- | |||
| INX rp || INC rp || Z80 takes 6 cycles, 8085 takes 5 cycles | |||
|- | |||
| JC label || JP C,label || | |||
|- | |||
| JM label || JP M,label || | |||
|- | |||
| JMP label || JP label || | |||
|- | |||
| JNC label || JP NC,label || | |||
|- | |||
| style="background:lightgreen; color:black" | JNX5 @ / JNK @ / JTP @ | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will NOT decode this instruction (0xDD isn't a valid opcode)! | |||
|- | |||
| JNZ label || JP NZ,label || | |||
|- | |||
| JP label || JP P,label || | |||
|- | |||
| JPE label || JP PE,label || | |||
|- | |||
| JPO label || JP PO,label || | |||
|- | |||
| style="background:lightgreen; color:black" | JX5 @ / JK @ / JTM @ | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will try to decode this instruction (Result depends of next byte(s) since 0xFD is the start of an extended opcode)! | |||
|- | |||
| JZ label || JP Z,label || | |||
|- | |||
| LDA addr || LD A,(addr) || | |||
|- | |||
| LDAX B || LD A,(BC) || | |||
|- | |||
| LDAX D || LD A,(DE) || | |||
|- | |||
| LHLD addr || LD HL,(addr) || | |||
|- | |||
| style="background:lightgreen; color:black" | LHLI / LHLX / LHLDE | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will try to decode this instruction (Result depends of next byte(s) since 0xED is the start of an extended opcode)! | |||
|- | |||
| LXI rp,data16 || LD rp,data16 || | |||
|- | |||
| MOV M,reg || LD (HL),reg || | |||
|- | |||
| MOV reg,M || LD reg,(HL) || | |||
|- | |||
| MOV reg,reg || LD reg,reg || | |||
|- | |||
| MVI M,data || LD (HL),data || | |||
|- | |||
| MVI reg,data || LD reg,data || | |||
|- | |||
| NOP || NOP || | |||
|- | |||
| ORA M || OR (HL) || | |||
|- | |||
| ORA reg || OR reg || | |||
|- | |||
| ORI data || OR data || | |||
|- | |||
| OUT port || OUT port,A || | |||
|- | |||
| PCHL || JP (HL) || | |||
|- | |||
| POP rp || POP rp || When POP AF, Z80 preserves all bits while 8085 sets unused flag bits to 1 | |||
|- | |||
| PUSH rp || PUSH rp || | |||
|- | |||
| RAL || RLA || Z80 Clears the half-carry flag while the 8085 leaves it unchanged | |||
|- | |||
| RAR || RRA || | |||
|- | |||
| RC || RET C || | |||
|- | |||
| style="background:lightgreen; color:black" | RDEL / RLDE | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as JR @ (Jump Relative)! | |||
|- | |||
| RET || RET || | |||
|- | |||
|| RIM | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as JR nz,@ (Jump Relative if not zero)! | |||
|- | |||
| RLC || RLCA || Z80 Clears the half-carry flag while the 8085 leaves it unchanged | |||
|- | |||
| RM || RET M || | |||
|- | |||
| RNC || RET NC || | |||
|- | |||
| RNZ || RET NZ || | |||
|- | |||
| RP || RET P || | |||
|- | |||
| RPE || RET PE || | |||
|- | |||
| RPO || RET PO || | |||
|- | |||
| RRC || RRCA || | |||
|- | |||
| RST n || RST n || | |||
|- | |||
| RZ || RET Z || | |||
|- | |||
| SBB M || SBC A,(HL) || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| SBB reg || SBC A,reg || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| SBI data || SBC A,data || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| SHLD addr || LD (addr),HL || | |||
|- | |||
| style="background:lightgreen; color:black" | SHLX / SHLDE / SHLI | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as EXX (Exchange registers with alternate registers)! | |||
|- | |||
|| SIM | |||
| style="background:#ffcccb; color:black; text-align:center" | N/A | |||
| style="background:#ffcccb; color:black; font-weight:bold" | Z80 will decode this instruction as JR nc,@ (Jump Relative if not carry)! | |||
|- | |||
| SPHL || LD SP,HL || | |||
|- | |||
| STA addr || LD (addr),A || | |||
|- | |||
| STAX B || LD (BC),A || | |||
|- | |||
| STAX D || LD (DE),A || | |||
|- | |||
| STC || SCF || | |||
|- | |||
| SUB M || SUB (HL) || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| SUB reg || SUB reg || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| SUI data || SUB data || Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow | |||
|- | |||
| XCHG || EX DE,HL || | |||
|- | |||
| XRA M || XOR (HL) || | |||
|- | |||
| XRA reg || XOR reg || | |||
|- | |||
| XRI data || XOR data || | |||
|- | |||
| XTHL || EX (SP),HL || | |||
|} | |||
Sources for this table: | |||
* [http://www.verycomputer.com/74_195480c497e2c77c_1.htm#p6 8080 -> Z80 mnemonic correspondence] | |||
* [https://retrocomputing.stackexchange.com/questions/1610/how-did-the-z80-instruction-set-differ-from-the-8080/1612#1612 How did the Z80 instruction set differ from the 8080?] | |||
* [http://www.msxarchive.nl/pub/msx/mirrors/hanso/datasheets/chipsz80leventhal3.pdf Z80 Assembly Language Programming (Chapter 3 - 8080A/Z80 compatibility)] | |||
* [https://www.asm80.com/tools/index.html#/i2z Tool for automatic conversion of 8080A assembly to Z80 assembly] | |||
[[Category:Model T Developer Reference]] |
Latest revision as of 01:42, 4 December 2022
8085 Instruction Mnemonic Meanings
Data Transfer Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
MOV |
dreg, sreg |
MOVe |
. |
. |
. |
. |
MVI |
reg, byte |
MoVe Immediate |
. |
. |
. |
. |
MVX |
drp, srp |
MoVe eXtended-register (pseudo for high & low MOVs) |
. |
. |
. |
. |
LXI |
rp, word |
Load eXtended-register Immediate |
. |
. |
. |
. |
XCHG |
eXCHanGe hl with de |
. |
. |
. |
. | |
LDA |
addr |
LoaD Accumulator direct |
. |
. |
. |
. |
STA |
addr |
STore Accumulator direct |
. |
. |
. |
. |
LDAX |
B |
LoaD Accumulator indirect via eXtended-register Bc |
. |
. |
. |
. |
STAX |
B |
Store Accumulator indirect via eXtended-register Bc |
. |
. |
. |
. |
LDAX |
D |
LoaD Accumulator indirect via eXtended-register De |
. |
. |
. |
. |
STAX |
D |
Store Accumulator indirect via eXtended-register De |
. |
. |
. |
. |
LHLD |
addr |
Load HL Direct |
. |
. |
. |
. |
SHLD |
addr |
Store HL Direct |
. |
. |
. |
. |
LHLI |
Load HL Indirect via extended register de |
. |
. |
. |
. | |
SHLI |
Store HL Indirect via extended register de |
. |
. |
. |
. |
Arithmetic Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
ADD |
reg |
ADD |
x |
x |
x |
x |
ADI |
byte |
ADd Immediate |
x |
x |
x |
x |
ADC |
reg |
ADd with Carry |
x |
x |
x |
x |
ACI |
byte |
Add with Carry Immediate |
x |
x |
x |
x |
SUB |
reg |
SUBtract |
x |
x |
x |
x |
SUI |
byte |
SUbtract Immediate |
x |
x |
x |
x |
SBB |
reg |
SuBtract with Borrow |
x |
x |
x |
x |
SBI |
byte |
Subtract with Borrow Immediate |
x |
x |
x |
x |
DAA |
Decimal Adjust Accumulator |
x |
x |
x |
x | |
INR |
reg |
INcrement Register |
x |
. |
x |
x |
INX |
rp |
INcrement eXtended-register |
. |
. |
. |
. |
DCR |
reg |
DeCrement Register |
x |
. |
x |
x |
DCX |
rp |
DeCrement eXtended-register |
. |
. |
. |
. |
DAD |
rp |
Dual-register ADd to hl |
. |
x |
. |
. |
HLMBC |
HL Minus BC |
x |
x |
h |
x | |
DEHL |
byte |
DE from HL plus byte |
. |
. |
. |
. |
DESP |
byte |
DE from SP plus byte |
. |
. |
. |
. |
Logical Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
CMP |
reg |
CoMPare |
x |
x |
x |
x |
CPI |
byte |
ComPare Immediate |
x |
x |
x |
x |
CMA |
CoMplement Accumulator |
. |
. |
. |
. | |
CMC |
CoMplement Carry |
. |
x |
. |
. | |
STC |
SeT Carry |
. |
1 |
. |
. | |
SHLR |
Shift HL Right |
. |
x |
. |
. | |
ANA |
reg |
ANd Accumulator |
x |
0 |
x |
x |
ANI |
byte |
ANd Immediate |
x |
0 |
x |
x |
ORA |
reg |
OR Accumulator |
x |
0 |
x |
x |
ORI |
byte |
OR Immediate |
x |
0 |
x |
x |
XRA |
reg |
eXclusive oR Accumulator |
x |
0 |
x |
x |
XRI |
byte |
eXclusive oR Immediate |
x |
0 |
x |
x |
RAL |
Rotate Accumulator Left through carry |
. |
x |
. |
. | |
RAR |
Rotate Accumulator Right through carry |
. |
x |
. |
. | |
RLC |
Rotate accumulator Left Circular |
. |
x |
. |
. | |
RRC |
Rotate accumulator Right Circular |
. |
x |
. |
. | |
RDEL |
Rotate DE Left through carry |
. |
x |
. |
. |
Stack, Input/Output, & Machine Control Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
PUSH |
rp |
PUSH on stack |
. |
. |
. |
. |
POP |
rp |
POP off stack |
. |
. |
. |
. |
SPHL |
Stack Pointer from HL |
. |
. |
. |
. | |
XTHL |
eXchange Top of stack with HL |
. |
. |
. |
. | |
IN |
port |
INput from port |
. |
. |
. |
. |
OUT |
port |
OUTput to port |
. |
. |
. |
. |
DI |
Disable Interrupts |
. |
. |
. |
. | |
EI |
Enable Interrupts |
. |
. |
. |
. | |
Read Interrupt Mask |
. |
. |
. |
. | ||
SIM |
Set Interrupt Mask |
. |
. |
. |
. | |
NOP |
No OPeration |
. |
. |
. |
. | |
HLT |
HaLT |
. |
. |
. |
. |
Branch Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
JMP |
label |
JuMP unconditional |
. |
. |
. |
. |
JZ |
label |
Jump if Zero |
. |
. |
. |
. |
JNZ |
label |
Jump if No Zero |
. |
. |
. |
. |
JP |
label |
Jump if Positive |
. |
. |
. |
. |
JM |
label |
Jump if Minus |
. |
. |
. |
. |
JC |
label |
Jump if Carry |
. |
. |
. |
. |
JNC |
label |
Jump if No Carry |
. |
. |
. |
. |
JTM |
label |
Jump if True sign Minus |
. |
. |
. |
. |
JTP |
label |
Jump if True sign Positive |
. |
. |
. |
. |
JPE |
label |
Jump if Parity Even |
. |
. |
. |
. |
JPO |
label |
Jump if Parity Odd |
. |
. |
. |
. |
CALL |
label |
CALL unconditioanl |
. |
. |
. |
. |
CZ |
label |
Call if Zero |
. |
. |
. |
. |
CNZ |
label |
Call if No Zero |
. |
. |
. |
. |
CP |
label |
Call if Positive |
. |
. |
. |
. |
CM |
label |
Call if Minus |
. |
. |
. |
. |
CC |
label |
Call if Carry |
. |
. |
. |
. |
CNC |
label |
Call if No Carry |
. |
. |
. |
. |
CPE |
label |
Call if Parity Even |
. |
. |
. |
. |
CPO |
label |
Call if Parity Odd |
. |
. |
. |
. |
RET |
RETurn unconditional |
. |
. |
. |
. | |
RZ |
Return if Zero |
. |
. |
. |
. | |
RNZ |
Return if No Zero |
. |
. |
. |
. | |
RP |
Return if Positive |
. |
. |
. |
. | |
RM |
Return if Minus |
. |
. |
. |
. | |
RC |
Return if Carry |
. |
. |
. |
. | |
RNC |
Return if No Carry |
. |
. |
. |
. | |
RPE |
Return if Parity Even |
. |
. |
. |
. | |
RPO |
Return if Parity Odd |
. |
. |
. |
. | |
PCHL |
Program Counter from HL |
. |
. |
. |
. | |
RST |
n |
ReSTart |
. |
. |
. |
. |
RSTV |
ReSTart if oVerflow |
. |
. |
. |
. |
8085 Instruction Actions by Functional Group
Data Transfer Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
MOV |
dreg, sreg |
dreg<=sreg |
. |
. |
. |
. |
MVI |
reg, byte |
reg<=byte |
. |
. |
. |
. |
MVX |
drp, srp |
drp<=srp (pseudo for high & low MOVs) |
. |
. |
. |
. |
LXI |
rp, word |
rp<=word |
. |
. |
. |
. |
XCHG |
HL<=DE while DE<=HL |
. |
. |
. |
. | |
LDA |
addr |
A<=b[addr] |
. |
. |
. |
. |
STA |
addr |
b[addr]<=A |
. |
. |
. |
. |
LDAX |
B |
A<=b[BC] |
. |
. |
. |
. |
STAX |
B |
b[BC]<=A |
. |
. |
. |
. |
LDAX |
D |
A<=b[DE] |
. |
. |
. |
. |
STAX |
D |
b[DE]<=A |
. |
. |
. |
. |
LHLD |
addr |
HL<=w[addr] |
. |
. |
. |
. |
SHLD |
addr |
w[addr]<=HL |
. |
. |
. |
. |
LHLI |
HL<=w[DE] |
. |
. |
. |
. | |
SHLI |
w[DE]<=HL |
. |
. |
. |
. |
Arithmetic Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
ADD |
reg |
A<=A+reg |
x |
x |
x |
x |
ADI |
byte |
A<=A+byte |
x |
x |
x |
x |
ADC |
reg |
A<=A+reg+Cf |
x |
x |
x |
x |
ACI |
byte |
A<=A+byte+Cf |
x |
x |
x |
x |
SUB |
reg |
A<=A-reg |
x |
x |
x |
x |
SUI |
byte |
A<=A-byte |
x |
x |
x |
x |
SBB |
reg |
A<=A-reg-Cf |
x |
x |
x |
x |
SBI |
byte |
A<=A-byte-Cf |
x |
x |
x |
x |
DAA |
in A3..A0 and A7..A4: if >9 then +6, carry to next |
x |
x |
x |
x | |
INR |
reg |
reg<=reg+1 |
x |
. |
x |
x |
INX |
rp |
rp<=rp+1 |
. |
. |
. |
. |
DCR |
reg |
reg<=reg-1 |
x |
. |
x |
x |
DCX |
rp |
rp<=rp-1 |
. |
. |
. |
. |
DAD |
rp |
HL<=HL+rp |
. |
x |
. |
. |
HLMBC |
HL<=HL-BC |
x |
x |
h |
x | |
DEHL |
byte |
DE<=HL+byte |
. |
. |
. |
. |
DESP |
byte |
DE<=SP+byte |
. |
. |
. |
. |
Branch Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
JMP |
label |
PC<=label |
. |
. |
. |
. |
JZ |
label |
if Zf=1 then PC<=label |
. |
. |
. |
. |
JNZ |
label |
if Zf=0 then PC<=label |
. |
. |
. |
. |
JP |
label |
if Sf=0 then PC<=label |
. |
. |
. |
. |
JM |
label |
if Sf=1 then PC<=label |
. |
. |
. |
. |
JC |
label |
if Cf=1 then PC<=label |
. |
. |
. |
. |
JNC |
label |
if Cf=0 then PC<=label |
. |
. |
. |
. |
JTM |
label |
if TSf=1 then PC<=label |
. |
. |
. |
. |
JTP |
label |
if TSf=0 then PC<=label |
. |
. |
. |
. |
JPE |
label |
if Pf=1 then PC<=label |
. |
. |
. |
. |
JPO |
label |
if Pf=0 then PC<=label |
. |
. |
. |
. |
CALL |
label |
SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CZ |
label |
if Zf=1 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CNZ |
label |
if Zf=0 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CP |
label |
if Sf=0 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CM |
label |
if Sf=1 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CC |
label |
if Cf=1 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CNC |
label |
if Cf=0 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CPE |
label |
if Pf=1 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
CPO |
label |
if Pf=0 then SP<=SP-2, w[SP]<=PC+3, PC<=label |
. |
. |
. |
. |
RET |
PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RZ |
if Zf=1 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RNZ |
if Zf=0 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RP |
if Sf=0 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RM |
if Sf=1 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RC |
if Cf=1 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RNC |
if Cf=0 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RPE |
if Pf=1 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
RPO |
if Pf=0 then PC<=w[SP], SP<=SP+2 |
. |
. |
. |
. | |
PCHL |
PC<=HL |
. |
. |
. |
. | |
RST |
n |
SP<=SP-2, w[SP]<=PC+1, PC<=n*8 where n is 0 to 7 |
. |
. |
. |
. |
RSTV |
if OVf=1 then SP<=SP-2, w[SP]<=PC+1, PC<=8*8 |
. |
. |
. |
. |
Logical Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
CMP |
reg |
T<=A-reg |
x |
x |
x |
x |
CPI |
byte |
T<=A-byte |
x |
x |
x |
x |
CMA |
A<=1's complement of A |
. |
. |
. |
. | |
CMC |
Cf<=1's complement of Cf |
. |
x |
. |
. | |
STC |
Cf<=1 |
. |
1 |
. |
. | |
SHLR |
HL<=HL/2 while H6<=H7 (extend sign) and Cf<=L0 |
. |
x |
. |
. | |
ANA |
reg |
A<=A AND reg |
x |
0 |
x |
x |
ANI |
byte |
A<=A AND byte |
x |
0 |
x |
x |
ORA |
reg |
A<=A Inclusive OR reg |
x |
0 |
x |
x |
ORI |
byte |
A<=A Inclusive OR byte |
x |
0 |
x |
x |
XRA |
reg |
A<=A Exclusive OR reg |
x |
0 |
x |
x |
XRI |
byte |
A<=A Exclusive OR byte |
x |
0 |
x |
x |
RAL |
A<=A*2 where Cf<=A7 while A0<=Cf |
. |
x |
. |
. | |
RAR |
A<=A/2 where Cf<=A0 while A7<=Cf |
. |
x |
. |
. | |
RLC |
A7..A1<=A6..A0 while A0<=A7 and Cf<=A7 |
. |
x |
. |
. | |
RRC |
A6..A0<=A7..A1 while A7<=A0 and Cf<=A0 |
. |
x |
. |
. | |
RDEL |
DE<=DE*2 where: Cf<=DE15 while DE00<=Cf |
. |
x |
. |
. |
Stack, Input/Output, & Machine Control Group
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
PUSH |
rp |
SP<=SP-2, w[SP]<=rp |
. |
. |
. |
. |
POP |
rp |
rp<=w[SP], SP<=SP+2 |
. |
. |
. |
. |
SPHL |
SP<=HL |
. |
. |
. |
. | |
XTHL |
HL<=w[SP] while w[SP]<=HL |
. |
. |
. |
. | |
IN |
port |
A<=data from port |
. |
. |
. |
. |
OUT |
port |
data to port<=A |
. |
. |
. |
. |
DI |
disable interrupts |
. |
. |
. |
. | |
EI |
enable interrupts |
. |
. |
. |
. | |
RIM |
A<=interrupt mask |
. |
. |
. |
. | |
SIM |
interrupt mask<=A |
. |
. |
. |
. | |
NOP |
do nothing |
. |
. |
. |
. | |
HLT |
halt 8085 processor |
. |
. |
. |
. |
8085 Instructions by Mnemonic
Instruction |
Mnemonic Meaning |
Flags | ||||
Zf |
Cf |
Pf |
Sf | |||
ACI |
byte |
Add with Carry Immediate |
x |
x |
x |
x |
ADC |
reg |
ADd with Carry |
x |
x |
x |
x |
ADD |
reg |
ADD |
x |
x |
x |
x |
ADI |
byte |
ADd Immediate |
x |
x |
x |
x |
ANA |
reg |
ANd Accumulator |
x |
0 |
x |
x |
ANI |
byte |
ANd Immediate |
x |
0 |
x |
x |
CALL |
label |
CALL unconditional |
. |
. |
. |
. |
CC |
label |
Call if Carry |
. |
. |
. |
. |
CM |
label |
Call if Minus |
. |
. |
. |
. |
CMA |
CoMplement Accumulator |
. |
. |
. |
. | |
CMC |
CoMplement Carry |
. |
x |
. |
. | |
CMP |
reg |
CoMPare |
x |
x |
x |
x |
CNC |
label |
Call if No Carry |
. |
. |
. |
. |
CNZ |
label |
Call if No Zero |
. |
. |
. |
. |
CP |
label |
Call if Positive |
. |
. |
. |
. |
CPE |
label |
Call if Parity Even |
. |
. |
. |
. |
CPI |
byte |
ComPare Immediate |
x |
x |
x |
x |
CPO |
label |
Call if Parity Odd |
. |
. |
. |
. |
CZ |
label |
Call if Zero |
. |
. |
. |
. |
DAA |
Decimal Adjust Accumulator |
x |
x |
x |
x | |
DAD |
rp |
Dual-register ADd to hl |
. |
x |
. |
. |
DCR |
reg |
DeCrement Register |
x |
. |
x |
x |
DCX |
rp |
DeCrement eXtended-register |
. |
. |
. |
. |
DEHL |
byte |
DE from HL plus byte |
. |
. |
. |
. |
DESP |
byte |
DE from SP plus byte |
. |
. |
. |
. |
DI |
Disable Interrupts |
. |
. |
. |
. | |
EI |
Enable Interrupts |
. |
. |
. |
. | |
HLMBC |
HL Minus BC |
x |
x |
h |
x | |
HLT |
HaLT |
. |
. |
. |
. | |
IN |
port |
INput from port |
. |
. |
. |
. |
INR |
reg |
INcrement Register |
x |
. |
x |
x |
INX |
rp |
INcrement eXtended-register |
. |
. |
. |
. |
JC |
label |
Jump if Carry |
. |
. |
. |
. |
JM |
label |
Jump if Minus |
. |
. |
. |
. |
JMP |
label |
JuMP unconditional |
. |
. |
. |
. |
JNC |
label |
Jump if No Carry |
. |
. |
. |
. |
JNZ |
label |
Jump if No Zero |
. |
. |
. |
. |
JP |
label |
Jump if Positive |
. |
. |
. |
. |
JPE |
label |
Jump if Parity Even |
. |
. |
. |
. |
JPO |
label |
Jump if Parity Odd |
. |
. |
. |
. |
JTM |
label |
Jump if True sign Minus |
. |
. |
. |
. |
JTP |
label |
Jump if True sign Positive |
. |
. |
. |
. |
JZ |
label |
Jump if Zero |
. |
. |
. |
. |
LDA |
addr |
LoaD Accumulator direct |
. |
. |
. |
. |
LDAX |
B |
LoaD Accumulator indirect via eXtended-register Bc |
. |
. |
. |
. |
LDAX |
D |
LoaD Accumulator indirect via eXtended-register De |
. |
. |
. |
. |
LHLD |
addr |
Load HL Direct |
. |
. |
. |
. |
LHLI |
Load HL Indirect via extended register de |
. |
. |
. |
. | |
LXI |
rp, word |
Load eXtended-register Immediate |
. |
. |
. |
. |
MOV |
dreg, sreg |
MOVe |
||||
MVI |
reg, byte |
MoVe Immediate |
. |
. |
. |
. |
MVX |
drp, srp |
MoVe eXtended-register (pseudo for high & low MOVs) |
. |
. |
. |
. |
NOP |
No OPeration |
. |
. |
. |
. | |
ORA |
reg |
OR Accumulator |
x |
0 |
x |
x |
ORI |
byte |
OR Immediate |
x |
0 |
x |
x |
OUT |
port |
OUTput to port |
. |
. |
. |
. |
PCHL |
Program Counter from HL |
. |
. |
. |
. | |
POP |
rp |
POP off stack |
. |
. |
. |
. |
PUSH |
rp |
PUSH on stack |
. |
. |
. |
. |
RAL |
Rotate Accumulator Left through carry |
. |
x |
. |
. | |
RAR |
Rotate Accumulator Right through carry |
. |
x |
. |
. | |
RC |
Return if Carry |
. |
. |
. |
. | |
RDEL |
Rotate DE Left through carry |
. |
x |
. |
. | |
RET |
RETurn unconditional |
. |
. |
. |
. | |
RIM |
Read Interrupt Mask |
. |
. |
. |
. | |
RLC |
Rotate accumulator Left Circular |
. |
x |
. |
. | |
RM |
Return if Minus |
. |
. |
. |
. | |
RNC |
Return if No Carry |
. |
. |
. |
. | |
RNZ |
Return if No Zero |
. |
. |
. |
. | |
RP |
Return if Positive |
. |
. |
. |
. | |
RPE |
Return if Parity Even |
. |
. |
. |
. | |
RPO |
Return if Parity Odd |
. |
. |
. |
. | |
RRC |
Rotate accumulator Right Circular |
. |
x |
. |
. | |
RST |
n |
ReSTart |
. |
. |
. |
. |
RSTV |
ReSTart if oVerflow |
. |
. |
. |
. | |
RZ |
Return if Zero |
. |
. |
. |
. | |
SBB |
reg |
SuBtract with Borrow |
x |
x |
x |
x |
SBI |
byte |
Subtract with Borrow Immediate |
x |
x |
x |
x |
SHLD |
addr |
Store HL Direct |
. |
. |
. |
. |
SHLI |
Store HL Indirect via extended register de |
. |
. |
. |
. | |
SHLR |
Shift HL Right |
. |
x |
. |
. | |
SIM |
Set Interrupt Mask |
. |
. |
. |
. | |
SPHL |
Stack Pointer from HL |
. |
. |
. |
. | |
STA |
addr |
STore Accumulator direct |
. |
. |
. |
. |
STAX |
B |
Store Accumulator indirect via eXtended-register Bc |
. |
. |
. |
. |
STAX |
D |
Store Accumulator indirect via eXtended-register De |
. |
. |
. |
. |
STC |
SeT Carry |
. |
1 |
. |
. | |
SUB |
reg |
SUBtract |
x |
x |
x |
x |
SUI |
byte |
SUbtract Immediate |
x |
x |
x |
x |
XCHG |
eXCHanGe hl with de |
. |
. |
. |
. | |
XRA |
reg |
eXclusive oR Accumulator |
x |
0 |
x |
x |
XRI |
byte |
eXclusive oR Immediate |
x |
0 |
x |
x |
XTHL |
eXchange Top of stack with HL |
. |
. |
. |
. |
8085 Machine Cycles by Functional Group
For cycle counts, EC refers to Essential Cycles. MM refers to additional cycles in the case that register M is involved or condition met
Data Transfer Group
Essential Cycles +register M involved or condition Met |
EC +MM | ||
Instruction |
Mnemonic Meaning |
Cycles | |
MOV |
dreg, sreg |
MOVe |
04 +03 |
MVI |
reg, byte |
MoVe Immediate |
07 +03 |
MVX |
drp, srp |
MoVe eXtended-register (pseudo for high & low MOVs) |
-- |
LXI |
rp, word |
Load eXtended-register Immediate |
10 |
XCHG |
eXCHanGe hl with de |
04 | |
LDA |
addr |
LoaD Accumulator direct |
13 |
STA |
addr |
STore Accumulator direct |
13 |
LDAX |
B |
LoaD Accumulator indirect via eXtended-register Bc |
07 |
STAX |
B |
Store Accumulator indirect via eXtended-register Bc |
07 |
LDAX |
D |
LoaD Accumulator indirect via eXtended-register De |
07 |
STAX |
D |
Store Accumulator indirect via eXtended-register De |
07 |
LHLD |
addr |
Load HL Direct |
16 |
SHLD |
addr |
Store HL Direct |
16 |
LHLI |
Load HL Indirect via extended register de |
10 | |
SHLI |
Store HL Indirect via extended register de |
10 |
Arithmetic Group
Essential Cycles +register M involved or condition Met |
EC +MM | ||
Instruction |
Mnemonic Meaning |
Cycles | |
ADD |
reg |
ADD |
04 +03 |
ADI |
byte |
ADd Immediate |
07 |
ADC |
reg |
ADd with Carry |
04 +03 |
ACI |
byte |
Add with Carry Immediate |
07 |
SUB |
reg |
SUBtract |
04 +03 |
SUI |
byte |
SUbtract Immediate |
07 |
SBB |
reg |
SuBtract with Borrow |
04 +03 |
SBI |
byte |
Subtract with Borrow Immediate |
07 |
DAA |
Decimal Adjust Accumulator |
04 | |
INR |
reg |
INcrement Register |
04 +06 |
INX |
rp |
INcrement eXtended-register |
06 |
DCR |
reg |
DeCrement Register |
04 +06 |
DCX |
rp |
DeCrement eXtended-register |
06 |
DAD |
rp |
Dual-register ADd to hl |
10 |
HLMBC |
HL Minus BC |
10 | |
DEHL |
byte |
DE from HL plus byte |
10 |
DESP |
byte |
DE from SP plus byte |
10 |
Logical Group
Essential Cycles +register M involved or condition Met |
EC +MM | ||
Instruction |
Mnemonic Meaning |
Cycles | |
CMP |
reg |
CoMPare |
04 +03 |
CPI |
byte |
ComPare Immediate |
07 |
CMA |
CoMplement Accumulator |
04 | |
CMC |
CoMplement Carry |
04 | |
STC |
SeT Carry |
04 | |
SHLR |
Shift HL Right |
07 | |
ANA |
reg |
ANd Accumulator |
04 +03 |
ANI |
byte |
ANd Immediate |
07 |
ORA |
reg |
OR Accumulator |
04 +03 |
ORI |
byte |
OR Immediate |
07 |
XRA |
reg |
eXclusive oR Accumulator |
04 +03 |
XRI |
byte |
eXclusive oR Immediate |
07 |
RAL |
Rotate Accumulator Left through carry |
04 | |
RAR |
Rotate Accumulator Right through carry |
04 | |
RLC |
Rotate accumulator Left Circular |
04 | |
RRC |
Rotate accumulator Right Circular |
04 | |
RDEL |
Rotate DE Left through carry |
10 |
Stack, Input/Output, & Machine Control Group
Essential Cycles +register M involved or condition Met |
EC +MM | ||
Instruction |
Mnemonic Meaning |
Cycles | |
PUSH |
rp |
PUSH on stack |
12 |
POP |
rp |
POP off stack |
10 |
SPHL |
Stack Pointer from HL |
06 | |
XTHL |
eXchange Top of stack with HL |
16 | |
IN |
port |
INput from port |
10 |
OUT |
port |
OUTput to port |
10 |
DI |
Disable Interrupts |
04 | |
EI |
Enable Interrupts |
04 | |
RIM |
Read Interrupt Mask |
04 | |
SIM |
Set Interrupt Mask |
04 | |
NOP |
No OPeration |
04 | |
HLT |
HaLT |
05 |
Branch Group
Essential Cycles +register M involved or condition Met |
EC +MM | ||
Instruction |
Mnemonic Meaning |
Cycles | |
JMP |
label |
JuMP unconditional |
10 |
JZ |
label |
Jump if Zero |
07 +03 |
JNZ |
label |
Jump if No Zero |
07 +03 |
JP |
label |
Jump if Positive |
07 +03 |
JM |
label |
Jump if Minus |
07 +03 |
JC |
label |
Jump if Carry |
07 +03 |
JNC |
label |
Jump if No Carry |
07 +03 |
JTM |
label |
Jump if True sign Minus |
07 +03 |
JTP |
label |
Jump if True sign Positive |
07 +03 |
JPE |
label |
Jump if Parity Even |
07 +03 |
JPO |
label |
Jump if Parity Odd |
07 +03 |
CALL |
label |
CALL unconditional |
18 |
CZ |
label |
Call if Zero |
09 +09 |
CNZ |
label |
Call if No Zero |
09 +09 |
CP |
label |
Call if Positive |
09 +09 |
CM |
label |
Call if Minus |
09 +09 |
CC |
label |
Call if Carry |
09 +09 |
CNC |
label |
Call if No Carry |
09 +09 |
CPE |
label |
Call if Parity Even |
09 +09 |
CPO |
label |
Call if Parity Odd |
09 +09 |
RET |
RETurn unconditional |
10 | |
RZ |
Return if Zero |
06 +06 | |
RNZ |
Return if No Zero |
06 +06 | |
RP |
Return if Positive |
06 +06 | |
RM |
Return if Minus |
06 +06 | |
RC |
Return if Carry |
06 +06 | |
RNC |
Return if No Carry |
06 +06 | |
RPE |
Return if Parity Even |
06 +06 | |
RPO |
Return if Parity Odd |
06 +06 | |
PCHL |
Program Counter from HL |
06 | |
RST |
n |
ReSTart |
12 |
RSTV |
ReSTart if oVerflow |
06 +06 |
8085 Instruction Mnemonics by Op-code
x0h |
x1h |
x2h |
x3h |
x4h |
x5h |
x6h |
x7h |
x8h |
x9h |
xAh |
xBh |
xCh |
xDh |
xEh |
xFh | |
00h-0Fh |
NOP |
LXI B,w |
STAX B |
INX B |
INR B |
DCR B |
MVI B,b |
RLC |
DSUB |
DAD B |
LDAX B |
DCX B |
INR C |
DCR C |
MVI C,b |
RRC |
10h-1Fh |
ARHL |
LXI D,w |
STAX D |
INX D |
INR D |
DCR D |
MVI D,b |
RAL |
RDEL |
DAD D |
LDAX D |
DCX D |
INR E |
DCR E |
MVI E,b |
RAR |
20h-2Fh |
RIM |
LXI H,w |
SHLD @ |
INX H |
INR H |
DCR H |
MVI H,b |
DAA |
DEHL b |
DAD H |
LHLD @ |
DCX H |
INR L |
DCR L |
MVI L,b |
CMA |
30h-3Fh |
SIM |
LXI SP,w |
STA @ |
INX SP |
INR M |
DCR M |
MVI M,b |
STC |
DESP b |
DAD SP |
LDA @ |
DCX SP |
INR A |
DCR A |
MVI A,b |
CMC |
40h-4Fh |
MOV B,B |
MOV B,C |
MOV B,D |
MOV B,E |
MOV B,H |
MOV B,L |
MOV B,M |
MOV B,A |
MOV C,B |
MOV C,C |
MOV C,D |
MOV C,E |
MOV C,H |
MOV C,L |
MOV C,M |
MOV C,A |
50h-5Fh |
MOV D,B |
MOV D,C |
MOV D,D |
MOV D,E |
MOV D,H |
MOV D,L |
MOV D,M |
MOV D,A |
MOV E,B |
MOV E,C |
MOV E,D |
MOV E,E |
MOV E,H |
MOV E,L |
MOV E,M |
MOV E,A |
60h-6Fh |
MOV H,B |
MOV H,C |
MOV H,D |
MOV H,E |
MOV H,H |
MOV H,L |
MOV H,M |
MOV H,A |
MOV L,B |
MOV L,C |
MOV L,D |
MOV L,E |
MOV L,H |
MOV L,L |
MOV L,M |
MOV L,A |
70h-7Fh |
MOV M,B |
MOV M,C |
MOV M,D |
MOV M,E |
MOV M,H |
MOV M,L |
HLT |
MOV M,A |
MOV A,B |
MOV A,C |
MOV A,D |
MOV A,E |
MOV A,H |
MOV A,L |
MOV A,M |
MOV A,A |
80h-8Fh |
ADD B |
ADD C |
ADD D |
ADD E |
ADD H |
ADD L |
ADD M |
ADD A |
ADC B |
ADC C |
ADC D |
ADC E |
ADC H |
ADC L |
ADC M |
ADC A |
90h-9Fh |
SUB B |
SUB C |
SUB D |
SUB E |
SUB H |
SUB L |
SUB M |
SUB A |
SBB B |
SBB C |
SBB D |
SBB E |
SBB H |
SBB L |
SBB M |
SBB A |
A0h-AFh |
ANA B |
ANA C |
ANA D |
ANA E |
ANA H |
ANA L |
ANA M |
ANA A |
XRA B |
XRA C |
XRA D |
XRA E |
XRA H |
XRA L |
XRA M |
XRA A |
B0h-BFh |
ORA B |
ORA C |
ORA D |
ORA E |
ORA H |
ORA L |
ORA M |
ORA A |
CMP B |
CMP C |
CMP D |
CMP E |
CMP H |
CMP L |
CMP M |
CMP A |
COh-CFh |
RNZ |
POP B |
JNZ @ |
JMP @ |
CNZ @ |
PUSH B |
ADI b |
RST 0 |
RZ |
RET |
JZ @ |
RSTV |
CZ @ |
CALL @ |
ACI b |
RST 1 |
D0h-DFh |
RNC |
POP D |
JNC @ |
OUT port |
CNC @ |
PUSH D |
SUI b |
RST 2 |
RC |
SHLX |
JC @ |
IN port |
CC @ |
JNX5 @ |
SBI b |
RST 3 |
E0h-EFh |
RPO |
POP H |
JPO @ |
XTHL |
CPO @ |
PUSH H |
ANI b |
RST 4 |
RPE |
PCHL |
JPE @ |
XCHG |
CPE @ |
LHLI |
XRI b |
RST 5 |
F0h-FFh |
RP |
POP PSW |
JP @ |
DI |
CP @ |
PUSH PSW |
ORI b |
RST 6 |
RM |
SPHL |
JM @ |
EI |
CM @ |
JX5 @ |
CPI b |
RST 7 |
Z80 Equivalent Mnemonics
8085 | Z80 | Remarks |
---|---|---|
ACI data | ADC A,data | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ADC M | ADC A,(HL) | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ADC reg | ADC A,reg | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ADD M | ADD A,(HL) | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ADD reg | ADD A,reg | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ADI data | ADD A,data | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
ANA M | AND (HL) | |
ANA reg | AND reg | |
ANI data | AND data | |
ARHL / RRHL / SHLR | N/A | Z80 will decode this instruction as DJNZ @ (Decrement B and jump if not zero)! |
CALL label | CALL label | |
CC label | CALL C,label | |
CM label | CALL M,label | |
CMA | CPL | |
CMC | CCF | |
CMP M | CP (HL) | |
CMP reg | CP reg | |
CNC label | CALL NC,label | |
CNZ label | CALL NZ,label | |
CP label | CALL P,label | |
CPE label | CALL PE,label | |
CPI data | CP data | |
CPO label | CALL PO,label | |
CZ label | CALL Z,label | |
DAA | DAA | Z80 corrects both addition and substraction while 8085 only corrects addition |
DAD rp | ADD HL,rp | |
DCR M | DEC (HL) | |
DCR reg | DEC reg | |
DCX rp | DEC rp | |
DEHL data / LDHI data | N/A | Z80 will decode this instruction as JR z,@ (Jump Relative if zero)! |
DESP data / LDSI data | N/A | Z80 will decode this instruction as JR c,@ (Jump Relative if carry)! |
DI | DI | |
DSUB / HLMBC | N/A | Z80 will decode this instruction as EX AF,AF' (Exchange register AF with AF')! |
EI | EI | |
HLT | HALT | |
IN port | IN A,port | |
INR M | INC (HL) | |
INR reg | INC reg | Z80 takes 4 cycles, 8085 takes 5 cycles |
INX rp | INC rp | Z80 takes 6 cycles, 8085 takes 5 cycles |
JC label | JP C,label | |
JM label | JP M,label | |
JMP label | JP label | |
JNC label | JP NC,label | |
JNX5 @ / JNK @ / JTP @ | N/A | Z80 will NOT decode this instruction (0xDD isn't a valid opcode)! |
JNZ label | JP NZ,label | |
JP label | JP P,label | |
JPE label | JP PE,label | |
JPO label | JP PO,label | |
JX5 @ / JK @ / JTM @ | N/A | Z80 will try to decode this instruction (Result depends of next byte(s) since 0xFD is the start of an extended opcode)! |
JZ label | JP Z,label | |
LDA addr | LD A,(addr) | |
LDAX B | LD A,(BC) | |
LDAX D | LD A,(DE) | |
LHLD addr | LD HL,(addr) | |
LHLI / LHLX / LHLDE | N/A | Z80 will try to decode this instruction (Result depends of next byte(s) since 0xED is the start of an extended opcode)! |
LXI rp,data16 | LD rp,data16 | |
MOV M,reg | LD (HL),reg | |
MOV reg,M | LD reg,(HL) | |
MOV reg,reg | LD reg,reg | |
MVI M,data | LD (HL),data | |
MVI reg,data | LD reg,data | |
NOP | NOP | |
ORA M | OR (HL) | |
ORA reg | OR reg | |
ORI data | OR data | |
OUT port | OUT port,A | |
PCHL | JP (HL) | |
POP rp | POP rp | When POP AF, Z80 preserves all bits while 8085 sets unused flag bits to 1 |
PUSH rp | PUSH rp | |
RAL | RLA | Z80 Clears the half-carry flag while the 8085 leaves it unchanged |
RAR | RRA | |
RC | RET C | |
RDEL / RLDE | N/A | Z80 will decode this instruction as JR @ (Jump Relative)! |
RET | RET | |
RIM | N/A | Z80 will decode this instruction as JR nz,@ (Jump Relative if not zero)! |
RLC | RLCA | Z80 Clears the half-carry flag while the 8085 leaves it unchanged |
RM | RET M | |
RNC | RET NC | |
RNZ | RET NZ | |
RP | RET P | |
RPE | RET PE | |
RPO | RET PO | |
RRC | RRCA | |
RST n | RST n | |
RZ | RET Z | |
SBB M | SBC A,(HL) | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
SBB reg | SBC A,reg | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
SBI data | SBC A,data | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
SHLD addr | LD (addr),HL | |
SHLX / SHLDE / SHLI | N/A | Z80 will decode this instruction as EXX (Exchange registers with alternate registers)! |
SIM | N/A | Z80 will decode this instruction as JR nc,@ (Jump Relative if not carry)! |
SPHL | LD SP,HL | |
STA addr | LD (addr),A | |
STAX B | LD (BC),A | |
STAX D | LD (DE),A | |
STC | SCF | |
SUB M | SUB (HL) | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
SUB reg | SUB reg | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
SUI data | SUB data | Z80 adds the N flag which records whether the last arithmetic operation was an add or subtract (and is use by the DAA instruction) ; Z80 uses P flag for overflow |
XCHG | EX DE,HL | |
XRA M | XOR (HL) | |
XRA reg | XOR reg | |
XRI data | XOR data | |
XTHL | EX (SP),HL |
Sources for this table: