2

Why is the cost of memory non-linear, while the cost of storage is linear?

I wonder why the cost function of memory vs. storage differ? While storage is associated with a constant cost, this is not the case for memory. Why is that?

  • I wonder if there's some connection to RAM being much more expensive and smaller than HDD like in ethereum.stackexchange.com/questions/1232/… – eth Nov 5 '17 at 5:52
  • A different guess: one can assume an essentially infinite amount of storage in the blockchain: as time tends towards infinity, more blocks will be stored and thus an infinite amount of storage will be required. However, it is possible to execute smart contracts by reusing RAM and hence there is no need to provide an unlimited amount of it. Also, it's much harder to add RAM to a computer than disk space (limits on RAM slots vs. daisy chaining external disk arrays), so maybe it's a question of "democratizing" Ethereum nodes? – lungj Nov 5 '17 at 6:53
1

Its due to the way that the memory market works. The average buyer of memory tends to buy it with the computer system. This means companies like Dell and other PC builders tend to buy in bulk but the amount that they put into the average PC is in the 1-16Gb range. The mainboards that most PC builders use will accept a single memory DIMM that is in the 1-4Gb range - so that's what they order - and hence what the chip manufacturers make.

This means that memory manufacturers align their factories to the production of DIMMs in that range so if you want a higher capacity DIMM (i.e more memory) - they need to reconfigure their plants to produce the higher capacity chips - which has a cost associated with it that must be passed on to the consumer - i.e higher capacity memory costs more.

As time goes on though and production is ramped up they will be able to produce large quantities of higher capacity RAM at lower cost - but only if there is associated demand to justify it.

With hard drives - the innovations tend to be in the density of data that can be stored on the same basic device (apart from microwave drives - the basic design of platter drives has stayed the same for a while). This means that the changes to increase density cost much less to implement and can generally use the same plant equipment - so (almost) linear cost.

  • Sorry if my comment caused confusion, but OP's question is about the EVM's (Ethereum Virtual Machine) memory and storage cost... So the question is in this virtual computer, why does memory have non-linear cost? – eth Nov 6 '17 at 4:29
  • It's the answer that you're looking for. The EVM is a virtual machine - so its bound by the same rules as physical machines. Memory is more expensive in the EVM to prevent the abuse of the physical memory on your machine. Ethereum exposes the computational resources of your machine to anyone using the blockchain through code (smart contracts etc) so the blockchain cost needs to be in line with the physical cost associated with those resources. – xygZen Nov 6 '17 at 13:46

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.