M1 10x faster than Intel at integral division, throughput one 64-bit divide in two cycles
Ola Fosheim Grostad
ola.fosheim.grostad at gmail.com
Thu May 27 12:25:54 UTC 2021
On Thursday, 27 May 2021 at 08:46:20 UTC, Manu wrote:
> It's a strange thing to optimise... I seem to do an integer
> divide so infrequently, that I can't imagine a measurable
> improvement in most code I've ever written if it were
> substantially faster. I feel like I stopped doing frequent
> integer divides right about the same time computers got FPU's...
Maybe Swift programmers dont think in terms of 2^n? Apple wants
Swift to be a system level language that is as easy to use as a
high level language. Or maybe they have analyzed apps in appstore
and found that people use div more than we know?
I personally feel bad if I don't make a datastructure compatible
with 2^n algos... Except in Python, there I only feel bad if the
code isnt looking clean.
More information about the Digitalmars-d
mailing list