Memory and Storage

21
Memory and Storage Aldon Tom

description

Memory and Storage. Aldon Tom. What is Memory?. Memory is a solid-state digital device that stores data values. Memory holds running programs and the data that those programs use. It also stores data that is not currently being used, although - PowerPoint PPT Presentation

Transcript of Memory and Storage

Memory and Storage

Aldon Tom

What is Memory?

Memory is a solid-state digital device that stores data values.Memory holds running programs and the data that those programsuse. It also stores data that is not currently being used, althoughmost memory falls into the category of temporary storage.

The Key Aspects of Memory

There are two basic aspects of memory:

•Technology The properties of the underlying hardware that are used to construct the memory system.

•Organization

The format of the memory system.

Memory Volatility

Memory is considered volatile if the contents of the memorydisappears when the power is shut off. RAM (not magnetic) is acommon example of volatile memory.

Nonvolatile memory is the exact opposite. Its contents remain evenafter power is shut off. An example would be your hard drive.

Nonvolatile Memory (cont)

Nonvolatile memory is usually much larger than volatile memory

-Additionally nonvolatile memory is in the form of rotating disks -hard disks, floppy disks, CDs, etc -it is also usually much slower, but much cheaper Data access must wait for seek time, which is the positioning of the head. It also must wait for rotational latency.

Types of Memory Access

The most common types of memory is random access. That is tosay that any value in the memory can be accessed at any point intime.

The alternative to random access is sequential access. Sequential access memory must be read in the same order that they were inputted. An example is the FIFO: First-In-First-Out method.

There are also methods that combine both forms of access in various ways.

Just what is a memory chip made of?

Well each chip is an integrated circuit made up of millions oftransistors and capacitors. Capacitors are paired with transistorsto make a memory cell which holds one bit and can thus storea 1 or 0 by filling or emptying the capacitor.

There are still many other forms of memory, but this is the mostcommon form of RAM.

Each memory cell has an address. This is how it can be randomly accessed. The cells are then further dividedinto a grid layout. This is why your RAM modules havesomething called RAS and CAS delays. The delays are time it takes for the Row Access Select and ColumnAccess Select to execute between cycles. Then the system fetches what is stored at a particular address and then itstores it to a register for use in calculations.

Permanence of Values

Memory is characterized by whether it can be read, written, or both. The primary form of memorycan be both read and written at anytime. There are some types of memory that are more permanent, namelyROM: Read Only Memory

Types of ROM

The standard ROM contains values that can only be accessed, butnot changed.

There is also PROM: Programmable ROM which allows data valuesto be written only once, and then accessed many times.

Intermediate forms also exist. For example, EEPROM: ElectronicallyErasable Programmable ROM. Although it is an oxymoron, it allowsdata to be electronically burned into the memory, but it takes a longtime. A popular form of EEPROM is Flash Memory, which is commonly used in digital cameras. Although it is slow, the memory works faster than a human can aim and take a picture.

Primary and Secondary Memory

Primary memory refers to the fast, volatile, internal memory ofthe computer: -RAM -Cache

Secondary memory refers to the slower, nonvolatile, external storage usually provided by electromechanical devices such as: -Hard Disk -CDs

Memory Hierarchy

Primary and Secondary memory arose from the idea of a MemoryHierarchy. This hierarchy came about due to the economy of production. That is to say the cost versus the performance.Research revealed that using given budget, the best performanceis not achieved by using the same type of memory throughout thesystem. It is most efficient to use a very small amount of thehighest performance memory, which is backed up by a slightlylarger amount of a slightly slower memory, and so on. This createsa sort of pyramid or a funnel.

The CPU accesses memory according to a distincthierarchy. Whether it comes from permanent storageor input, it is all stored in RAM first. The CPU then stores pieces of information that it will need to accessoften in the cache and then it maintains certain instructions in registers.

CPU Cache RAM VirtualMemory

Disk Storage

In order to maximize performance with powerful CPUs, the datahas to be easy and quick to access. If the CPU does not get thedata it needs it stops and waits for it, therefore you need memorythat can keep up with the CPU. The problem is that memory fast enough to keep up with the CPU is extremely expensive.

The solution is to tier the memory as described earlier.Using progressively cheaper memory to back up eachother provides maximal efficiency in terms of price.From slowest to fastest:-Hard Drive-RAM-Cache

Instruction and Data Store

The earliest computers used to have separate memoriesfor programs and data. Later, most architects adopted the Von Neumann Architecture which combines both intoone memory.

With the advent of new memory technologies, the separationof data and programs has come back into use, but only in special-purpose systems.

Memory used to hold a program is called instruction store. Memory used to hold data is called data store.

The motivations for separating data and instructions is basicallysince the data for a program only needs to be loaded less frequently, but the instructions that utilize that data are executedmuch more often. Therefore if both data and instruction are both in the same memory, the extra speed is useless for the dataportion, where as the instructions suffer from lack of speed.

By separating the data and instructions into separate memories, faster memory can be used for instructions, while slower memory can be used for the data.

Fetching and Storing

All memory uses a fetch-store architecture.

That is there are only two operations that memory understands:

Read and Write

This is also known as a load-store architecture, or read-write, butthey all just refer to the same thing.

Executing a Program

After the system loads the necessary data, all that is really leftis the instructions. The system only retrieves new data a smallpercentage of the time. The rest of the time is spent on instructions

-Each instruction is fetched from memory-Decoded-Executed-Then next, where next can be the next in the sequence or a jump