PC vs ZX - it all comes down to trashing the hostile platform and elevating your own.

(c) freeman.psycho ....................................................

PC vs ZX.

Reading the ZX (and also PC) press, sometimes you come across some
strange parallels drawn by the authors of the articles between these
platforms.  And it all comes down to slandering the hostile platform and
his elevation. In my opinion, this is absolutely unacceptable, so
as the authors are either not aware of the possibilities of this or that
platforms, or they only know their platform, without understanding anything about
another.  I mean its hardware part. Here, for example,
favorite phrase of spektrumists: pussy Mazda, because... yes
because programs on pisyuk are written not in assembler, but in SI
etc. As a result, programs run slower due to their lameness
pisish programmers. Hm. Let me clarify something here.
Yes, a program written in SI for ZX will indeed
work more slowly. But! What's right for ZX isn't always right
for PC! Let's say some super-brained hardware guy manages to
overclock the ZX to 300 Mhz.  I understand that this is impossible, but-
let's say!  And you believe that a similar program running
this ZX will run at the same speed on a PC Celeron
300 MHz?  Funny!  On PC it will work 5 times faster and
even 8 timesif the SI version of the program is launched on the PC!
Why?  I'll explain.  The structure of the PC processor is _VERY_ different
from the structure of the ZX processor.  It's not even that PC
the processor works with registers of 8...64 bits and has an average
6 times larger instruction set (new processors are equipped with
additional instructions approximately once a year, so
It is inappropriate to give this figure at all).  But what
difference? Here's an example:

asm ZX:
 ld a,20             
 ld de,40000
  
asm PC:
 mov al,20
 mov dx,4000

These are similar programs for PC and ZX, written in
assembler.  Or rather, not programs, but elements of programs. So,
What is the speed of the programs? ZX = 15 cycles. PC = 1 clock cycle!
Strange?  Not at all. On a PC there are two instructions that are not related to each other
in no way executed in one clock cycle!  When compiling SI
you can force the program to be compiled in such a way that
As a result, the teams were arranged exactly this way - for
increasing performance.  Imagine a programmer
writing on a PC,which, in the process of writing assembly language
program, in addition to thinking about the program algorithm, also
At the same time, he is engaged in arranging teams! Stupid? Of course! Not
Is it easier to put all this into SI and let this process happen?
automatically?  But PC is a master! Frankly, at first
coming to the PC, I also stubbornly, with Spectromovsky conviction,
I tried to write programs in assembler. So what's the result? Slow
programs!  Did you expect anything different?  But this is only one
side of the problem.  After all, on a PC there is such a thing as a cache. B
in the established understanding of a real spektrumist, cache is
optional ROM.  Hm. And in the understanding of the pisishnik, cache is RAM,
access to which is comparable to the speed of access to registers
processor - the fastest memory in a computer
(true for both PC and ZX). That is, in the process
the work of the percent loads part of the program 'into itself' (for example -
sprite) and works with it as a register.  Maximum
speed!   So on PC, of course, the cache size is  
limited.  I imagine a programmer writing a program in
assembler and at the same time counting on a calculator, when 
this very cache will run out and when should it be given (!) to the processor
instructions to load data into the cache from another address! It's not easier
let the SI itself calculate when it endscache? Of course
this is wrong!  After all, ASM rules! So guys stop it
you all this nonsense about the coolness of platforms and remember - in the world
processors with ZX architecture are no longer produced - the most
the minimum that is available is RISK processors - the following
generation of processors after ZX.  And even in washing machines
Nowadays the processors are at least 2 times cooler than the ZX. And
not because it is necessary. Or necessary. But just 'tube'
processors are much more expensive!

Share your thoughts about the article