Jump to content

Talk:Zilog Z80

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Merge from Zilog Z280

[edit]

Per User_talk:Mark_viking#Zilog_Z280 and Wikipedia:Articles for deletion/Zilog Z380. @Mark viking

Quite a few other entries in Category:Zilog microprocessors could use similar consideration. Piotr Konieczny aka Prokonsul Piotrus| reply here 00:44, 11 August 2023 (UTC)[reply]

@Pavlor and @Gábor who also participated in Wikipedia:Articles for deletion/Zilog Z380 Piotr Konieczny aka Prokonsul Piotrus| reply here 02:10, 14 August 2023 (UTC)[reply]
No contest. Redirects are cheap and can be turned back into an article, if more sources are found. Pavlor (talk) 05:01, 14 August 2023 (UTC)[reply]

discontinue production of the Z80 CPU

[edit]

Zilog announced in April 2024 that it will discontinue production of the Z80 CPU after 48 years on the market. The Z80's architecture is unable to compete with 8-bit RISC and low-cost 32-bit embedded processors. The discontinued versions include NMOS with clock speeds from 4 MHz to 8 MHz and CMOS from 8 MHz to 20 MHz 103.21.175.23 (talk) 04:50, 9 May 2024 (UTC)[reply]

Z80 in scrolling displays

[edit]

Hi, I have a picture of one here. Where can I upload it for addition please? Thanks!! 78.41.5.98 (talk) 06:43, 9 June 2024 (UTC)[reply]

Doesn't have fourteen registers

[edit]

The intro, rather pompously, states "The Z80 boasted fourteen registers compared to the 8080's seven". The silly 'boasted' part can go, that's a given. The main point though is the Z80 doesn't have 14 registers. I imagine they've seen the alternate registers and implied they're general-purpose registers, which is not how register counts are done in its competitors and therefore not correct an introductory statement that's for comparison to other CPUs.

Its Zilog datasheet (1970s one and the 2004 one) states "These registers include two sets of six general purpose registers which may be used individually as either 8-bit registers or as 16-bit register pairs. In addition, there are two sets of accumulator and flag registers. The Z80 CPU also contains a Stack Pointer, Program Counter, two index registers, a REFRESH register, and an INTERRUPT register."

For general-purpose registers (i.e. not principally used by the hardware, but principally for software to store data in) the Z80 has 7 (A, B, C, D, E, H, L) plus 2 (IX, IY), so that's 9. The remainder (F, SP, PC, R, interrupts) are for hardware and, in the case of the interrupt register not really seen as a register. Unless anyone objects, I'll rewrite that intro (please don't run in and rewrite it first). ToaneeM (talk) 13:38, 25 October 2024 (UTC)[reply]

I’m not opposed to changing the wording. However, I do want to point out that the alternative registers are a primary feature of the Z80. To my understanding, that feature differentiated it from its competitors and contributed to its success, which would make it worthy of inclusion in the intro.
Maybe something like:
Compared to the 8080, the Z80 added an alternate general purpose register along with additional instructions for bit manipulation, making it a more powerful chip.
RickyCourtney (talk) 14:37, 25 October 2024 (UTC)[reply]
  • Zilog's own promotional material (image on this page) gives the register counts as 8 vs. 17. Now why wouldn't the alternate set be counted? They were general purpose registers, with all the same features, and were extremely useful as such in interrupt service routines etc. Andy Dingley (talk) 15:22, 25 October 2024 (UTC)[reply]

Yep, the alternate register set will still be in the introduction as a valuable feature, but not as just being more general-purpose registers. The Z80 instruction set does that. For example, 1x Z80 instruction can load any of A..E/H/L into another. However, loading D with D' needs multiple instructions and management. The alternates aren't just part of a larger register set. The Z80 datasheet (the primary reference source) doesn't claim so either. Us claiming so would give a fake comparison with general register sets of other CPUs, instead of a decent introductory description. (It's a bit like the 6502 registers, where some will claim zero page should be seen as 256 more registers...but it's CPU datasheet doesn't.) ToaneeM (talk) 15:59, 30 October 2024 (UTC)[reply]

You don't have to be able to load each one from the other for them to count as general-purpose registers. As was always the intention with them, they were for dealing with context shifts. Andy Dingley (talk) 16:49, 30 October 2024 (UTC)[reply]
I'm afraid that just reads like more in a series of unsubstantiated 'no's. The manufacturer named them the alternate register set, to differentiate them from the general purpose registers. ToaneeM (talk) 16:54, 30 October 2024 (UTC)[reply]
What is their difference from the other general purpose registers?
Their only difference is which set is selected by default at startup. Apart from that, they're identical. Andy Dingley (talk) 18:07, 30 October 2024 (UTC)[reply]
The Z80 alternate registers are viable programming resource if the programmer wants to use them. As mentioned in the article, they are used to hold the 32-bit mantissas for the ZX80 floating point. Just because you can't load D directly with D' does not disqualify D' as a register. You can't load IX or IY directly from HL. Does that mean IX and IY are not registers? Should we not count R8-R15 on an AMD64 because it requires a REX prefix? The Z80 is no PDP-11. Each register has its hierarchy of usefulness. RastaKins (talk) 18:34, 30 October 2024 (UTC)[reply]

They're not general-purpose registers, they're alternate registers. The manufacturer doesn't claim they're anything else. As said above, the lack of LD D/D' is just an example: anyone who's programmed in Z80 knows you can't do anything whatsoever with the alternate registers while swapped out, but you can do loads with the main register set; clearly they're different. Someone might start arguing that certain main registers have special cases but they all have a general functions that the alternate registers don't, but that's irrelevant. The alternate registers do nothing until made the main registers, in place of those registers. (I can't quite believe that in 2024 I'm having to detail why the 1976 Z80's alternate registers aren't one half of a big general-purpose register set...all the loads of Z80 programmers I had around me by 1984 saw that as page 1 line 1... :-) )

Meanwhile, you find that typical Z80 software uses alternate registers fairly rarely, because of those limitations and inconveniences. For instance, the ZX Spectrum ROM uses 117 EXXs (basically 63 pairs), all in the floating point routines (specifically for the 32-bit tricks) and (I think) in the print floating point stuff to speed up register saving. They're not used in the rest of the 14 KB, all the language processing, tape loading, graphics, etc, etc.

The register count is useful when comparing with other similar CPUs so let's just scrub that single number and expand the explanation to make it clearer and therefore more useful to readers. Zilog's datasheets do so and so should we. Nothing's lost, the Z80 is unharmed - it's just making a better, less cryptic description, that's all.

It's all not really different to bank switching memory. An article saying 'the Z80 could address 1 MB memory' needs to explain that it couldn't natively and needed bank switching, so the Z80's not read as equal to a 68008 which could natively address and process that data space. ToaneeM (talk) 19:34, 30 October 2024 (UTC)[reply]

What is their difference from the other general purpose registers?
What can you do with D that you can't do equally well with D′? Andy Dingley (talk) 20:34, 30 October 2024 (UTC)[reply]
Already covered. If you're still lost, research beginner Z80. ToaneeM (talk) 20:53, 30 October 2024 (UTC)[reply]
OK, you're a jerk who has nothing useful to contribute. Noted. Andy Dingley (talk) 21:06, 30 October 2024 (UTC)[reply]
Don't post petulance or endless repetitions. You've had far more answers than anyone needs so if you don't understand it, read up Z80. ToaneeM (talk) 21:13, 30 October 2024 (UTC)[reply]