Re:Reversing Sinclair's 1974 calculator hack (2013)
by fsckboy on Friday September 17, 2021 @02:44AM
(#28562039)
> through repeated addition, digit by digit
when i read ideas like this I'm not sure what they mean
none of the early microprocessors had multiply instructions, but you can carry out a binary multiply using repeated shift+add, and if you don't have a shift you can add a number to itself and that's a shift... so all you are doing is adding but it's not the naive idea of adding a number over and over to simulate multiplication
or do they mean digit by digit and they are doing BCD multiplies? again, not that many adds are being performed so it's not a performance nightmare.
youngbloods don't realize how rarely a C programmer would invoke a multiply (or really need to) (and NEVER inside a loop) even a decade after these early calculators
I believe all the ultra-cheap 4-function calculator ASICs do this or something similar; the speed is not at all important, but die area and resulting price are.