Search code examples
memorymemory-managementcpu-architecturememory-address

Difference between memory size and memory locations?


I am trying to understand the Memory size and locations of a 8 bits architecture main memory , just tell me if a cell of memory contains 8 bits= 1 byte storage/size, then how much data of instructions CPU fetch from that particular cell of that memory , is it 8 bits(1 byte) or 2^8= 256 bits? if your answer is 256 bits then why it is written in the book that each cell contains 8 bits not 256 bits , in my general knowledge a CPU should fetch 8 bits of instructions if that cell contains 8 bits.


Solution

  • Your question needs more clarification, but for the simple case, a very basic CPU working on a single instruction at a time will read 8 bits from this memory cell assuming its instruction size is 8 bits.

    However in modern CPU architecture, It simply contains multi-level instruction caches and uses them to store multiple instructions from a single read to the main memory. (i.e. CPU reads a block (multiple memory cells) from main memory and get multiple instructions at once storing them to the caches). Although, you didn't mention a cache in your question, The book could meant that the CPU will read multiple blocks/locations representing multiple instructions and store them in the cache.