Why memory costs more than math
In 2014 Mark Horowitz, at Stanford, measured how much energy the operations inside a chip cost. Multiplying two 32-bit numbers with a decimal point costs about 3.7 picojoules. Reading those same 32 bits from external memory costs about 640, almost two hundred times as much.
That's why models for phones try to move as little data as they can. They use smaller numbers, 8 bits instead of 32, and networks that reuse the same numbers many times once they reach the chip. With 8-bit numbers the multiplication costs less too, about 0.2 picojoules.
- 640 pJreading 32 bits from memory
- 3.7 pJmultiplying two 32-bit numbers
- 0.2 pJmultiplying two 8-bit numbers