1
$\begingroup$

I was writing up an algorithm that involved knowing the size of integers my hardware can manage without having to resort to software implementations of math operations and the additional computational load that comes with them, and I realized that I've never given this much thought.

In theory, a 64-bit computer has 64 lines on the address/data bus, and thus can't send an integer to the CPU's ALU any higher than 2^64-1, making that the starting point. But I also know that some modern hardware has support for SIMD operations with 256-bit data, or even higher, and how that's possible I don't know (multiple operations to load in the data, 64 bits at a time, I assume?).

Without limiting this question to specific hardware, which would greatly diminish its usefulness, is there a reasonable rule of thumb for how large of an integer a typical modern computer (2015-2020 era) can handle in a single go?

$\endgroup$
2
  • $\begingroup$ A 64 bit computer most definitely doesn't have anywhere near 64 lines on the address bus, and most will have a lot more than 64 lines on the data bus. Your mental model is very, very wrong here - probably because you are ignoring cache memory. $\endgroup$ – gnasher729 Jan 4 at 10:57
  • $\begingroup$ The ALU is part of the CPU. Data doesn't get sent there on any external bus. $\endgroup$ – Yuval Filmus Jan 4 at 14:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.