On 26/05/2020 02:47, Brian Gregory wrote:
> Also in the case of Intel x86 vs AMD64 the code is also often a bit
> bigger for the 64 bit version of a program which means the processor
> reads it a little slower and less of it will fit in any memory cache or
> instruction cache.
>
> I don't know if the same applies to ARM or not.
I've previously been able to play with lots of different architectures
(x86, Itanium, PA-Risc, Power, Sparc, MIPS and ARM), and where the both
64 bit and 32 bit code is supported and otherwise there is very little
difference in instructions sets, the 32 bit is always marginally faster
due to increased code density and reduced cache usage.
The one exception to this is x86, where the 64 bit code is far faster
than the 32 bit code, despite decreased code density and increased cache
usage. This is because the x86 instruction set is just so bad, its old
fashioned CISC style, overly complex, register poor, memory-memory
making it very hard for compilers to produce good code. The 64 bit
instruction set (amd-64) is an entirely different more modern, with far
more registers.
64 bit ARM is quite different 32 bit with twice as many registers but no
conditional instructions, but the 32bit wasn't bad to begin with. So
their are some gains from the instruction set, which sometimes overcome
the disadvantage of code density and cache usage, but sometimes don't.
To muddy the water even further, both amd-64 and ARMv8 have a mode where
you can use the 64 bit instruction set, but produce code which only has
32 bit pointers (requires special libraries so not widely used). Which
for programs which don't need lots of memory, can keep the advantages of
the ISA and lose some of the disadvantage of the cache usage.
Your mileage my vary!
---druck
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|