Hi
Why does much literature on the web claim Z80 backwards software compatibility with the 8080A when the op codes in assemblers are different and the hex values of the op codes are different? I have read that only the Z80A variant has the 8080A instruction set as a subset. I also read that the instruction set of the Z80 had to be different from the 8080A or else Zilog would get into legal trouble with Intel.
Andrew
Z80 8080 backwards compatibility
Re: Z80 8080 backwards compatibility
Personally I largely prefer the Z80 style mnemonics they are rather intuitive but possibly less suitable for simple assemblers (the three characters mnemonics help the decoders).
An early dialect of the 8080 mnemonics was created for the TDL assembler, and obviously several macros and extensions existed for using the original 8080 assemblers on the z80, I don't know about copyright issues for the mnemonics but surely the Z80 was retro compatible, I think the copyright was a major concern for Mr Faggin, it must have been taken seriously.
Most of the 8080 opcodes are present on the Z80, what do you mean by saying the hex codes are different?
If you are comparing our z80asm output when in retro compatibility mode, beware it's substituting some of the missing instructions (like ex de,hl) with an equivalent sequence.
An early dialect of the 8080 mnemonics was created for the TDL assembler, and obviously several macros and extensions existed for using the original 8080 assemblers on the z80, I don't know about copyright issues for the mnemonics but surely the Z80 was retro compatible, I think the copyright was a major concern for Mr Faggin, it must have been taken seriously.
Most of the 8080 opcodes are present on the Z80, what do you mean by saying the hex codes are different?
If you are comparing our z80asm output when in retro compatibility mode, beware it's substituting some of the missing instructions (like ex de,hl) with an equivalent sequence.
Re: Z80 8080 backwards compatibility
Thanks, Stefano, message appreciated and thanks for retro-compatibility note.
I stand corrected, instruction codes are "mostly" the same between Z80 and 8080A, for some reason I got it in my head that they were different since the instructions are different.
e.g. Z80 op code to increment HL is INC HL and in 8080A its INX H, but instruction code in hex is 0x23 in both CPUs
Andrew.
I stand corrected, instruction codes are "mostly" the same between Z80 and 8080A, for some reason I got it in my head that they were different since the instructions are different.
e.g. Z80 op code to increment HL is INC HL and in 8080A its INX H, but instruction code in hex is 0x23 in both CPUs
Andrew.
Re: Z80 8080 backwards compatibility
exactly. Even if with a lot of limits Intel produced the 8086 to be partially retro - compatible with the 8080, at the time the software compatibility at cpu level mattered. I remember someone in the eights telling that the 6502 initially was competitive compared to the z80 because of the sw compatibility ( I can't confirm it was true and honestly I don't believe it could have been so relevant, just I heard it ).
The " toz80.awk" tool in the support directory maps most of the z80 mnemonics to the 486 ones, in case you are interested.
The " toz80.awk" tool in the support directory maps most of the z80 mnemonics to the 486 ones, in case you are interested.