Nothing Special   »   [go: up one dir, main page]

Chapter 04

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 8

Memory system

Characteristics of storage.
 Storage technology at all levels of the storage hierarchy can be differentiating by evaluating
certain core characteristics.
 These core characteristics are volatility mutability, accessibility & addressability the
characteristics worth measuring are capacity & performance.

Volatility.
Non-volatile memory:- Will retain the stored information ever if it is not constantly supplied with
electric power. It is suitable long-term storage of information.

Volatile memory:- Requires constants power to maintain the store information. The faster memory
technologies of today. Primary storage is required to be very fast.

Differentiation.
Dynamic random access memory:- A from of volatile memory while also requires the stored
information to be periodically re-read & re-written or refreshed, otherwise it would vanish.

Static memory:- A from of volatile memory similar to DRAM with the expectation that is never needs
to be refreshed as long as power is applied (It loses its content if power is removed).

Mutability.
Read write storage or mutable storage:- Allows information to be overwritten at any time.

Read only storage:- Retains the information stored at the time of manufacture and write once
storage (write once read many). These are called immutable storage. Immutable storage is used for
off-lines storage. Example includes CD-ROM & CO-R.

Slow write, facts read storage:- Read/Write storage allows information to be overwritten multiple
times. Write operation must slower than the read operation. CD-RW & flash memory.

Accessibility:-
Random access:- Ant location in storage can be accessed at any movement in such characteristic is
well suited for primary & secondary storage.

Sequential access:- The accessing of pieces of information will be in a serial order. One after the
other, such characteristic is typical of off-line storage.

Addressability:-
Location addressable:- In modern computers location addressable storage usually limits to primary
storage accessed internally by computer programs.
File addressable:-Information is divided into files of variables length & a particular file is selected
with human readable directory and file names.

Capacity:-
Law capacity:- The total amount of stored information that a storage device or medium can hold. It
is expressed as a quantity of bits or byte.

Memory hierarchy:- The memory hierarchy system consist of all storage devices employed in a
computer system from the slow but high capacity auxiliary memory to relative faster main memory
to an even smaller and faster cache memory access unite to the high speed processing.

Magnetic tape Main memory

I/O processor

Magnetic disk CPU Cache memory

At the bottom of hierarchy are the relatively slow magnetic tapes are used to removal files.
Next are magnetic disk used as backup storage. The main memory communicates directly with the
CPU & with auxiliary memory devices through an I/O processor. When program not residing in main
memory are needed by the CPU, they are brought in from auxiliary memory. Programs not currently
needed transferred into auxiliary memory.

CACHE MEMORY:-

It is very high speed memory. Its stands between main memory and CPU. Cache holds the most
heavily used data and program. It is increases the performance rate of the computer. Cache transfer
the information between main memory and CPU. CPU directly access this memory.

Main memory:-

The main memory occupies a central position by being able to communicate directly with the CPU.
When programs not residing in main memory are needed by CPU. They are brought in from auxiliary
memory. Programs not needed memory CPU directly access the main memory.

Auxiliary memory :-

Auxiliary memory is slow and high capacity memory. This memory holds the data and program
which is presently not used by CPU.

31. Access time in 1000 times of main memory. Transferring black size range in 266 to 2048 words.
Magnetic taps relative slow used for removal files. Magnetic disk used as backup storage.
Semiconductor RAM memory:-
Semiconductor memory or RAM is used in all types of computers. It is also known as read/write
memory. Semiconductor RAM use either a read cycle or a write cycle depending on the type of
request. This memory is normally destructive & volatile memory. It is very fast memory & expensive.
There are two main types of semiconductor RAM, S RAM, D RAM. The semiconductor RAM made up
of chips. Each chip contains large number of cell. Each all has at least two stable stages that are 0 &
1.

S RAM:-
 Fast memory technology that requires power to hold its content.
 It used high speed register. Transistor.
 S RAM used as cache memory.
 Its access time is 10 to 30 Nano seconds range.

D-RAM:-
 D-RAM chips are very dense because-

32. They use only one transistor & one capacitor. The capacitor stresses the electrical pulse. Due
to capacitor constantly counts one teak even when power is on. So it requires approximately 15
times per seconds refreshment is needed to maintain the change in the capacitor and retain the
information.

 It is used as main memory.


 It’s access time usually above 30 Nano seconds.

Read only memory:-


 Read only memory (ROM) is a class of storage media used in computers & other electronic
devices. Data stored in RAM cannot be modified or can be modified only slowly or with
difficulty.
 ROM refers only to mask ROM permanently stored in it and thus can never modified.

Type:-
 ROM chips are integrated circuits that physically encode the data to be stored & thus it is
impossible to change their contents after fabrication
Programmable Read only memory (PROM) or one time programmed ROM (OTP) can
be written to or programmed via a special device called a PROM programmer. Typically this
device uses high voltage to permanently destroy. A PROM can only be programmed once.
 Erasable programmable read-only memory (F PROM) can be erased by exposure to strong
ultra violet light, then rewritten with a Process that again needs higher than usual voltage
applied. EPROM chip can be identified by the "window" which allows UV light enters after
programming the window is typically covered with a label to prevent accidental erasure.
 Electrically erasable programmable read only memory, (EEPROM) is based similar
semiconductor structure to EPROM, but allows its entire contents electrically erased then ne
written electrically so that they need not be removed from the computer writing or Flashing
an EEPROM is much slower.

 Flash memory type of be a modern type EEPROM. Flash memory erased & rewritten. Faster
than ordinary EEPROM. Flash memory is sometimes called flash ROM or flash EPROM.

Cache memory:-
It is a special very high speed memory used to increase speed of processing. Its function is making
current programs & dada available to the CPU at a rapid rate it is logical placed between the cache &
main memory. The cache is the fastest component of memory hierarchy. The performance of cache
memory to measure by hit ratio.

Hit: when the by memory & finds hit ratio. CPU meters to the world in cache, it is said hit.

Miss: if the word is not found in cache, it is in the main memory, it is said miss.

Hit ratio:-
The ratio of the number of hides by total CPU reference to memory chits + misses is the hit ratio.

CPU CACHE MAIN MEMORY

Mapping:-
The transformation of data from main memory to cache memory is called as “mapping process”.
e.g. - consider a cache consisting of 128 blocks of 116 words each, for a total of 2048 (2k) words &
assume.

36. That the main memory has 64k words which in viewed as 4k blocks of 16 words each.

 Three types of mapping function are there


1. Direct mapping
2. Associative mapping
3. Set associative mapping.
1. Direct mapping function :-

Simplest way to determine cache location. In this technique block J module 128 of the cache.
Whenever one of the main memory blocks 0,128,256….. is located in the cache. It is stored in
cache block O. Blocks 1,129,257…. Are store in block block 1 & 50 00. The main memory address is
divided into three field. 4 bits select one of the 16 words in a block .7 cache position in which the
block must be stored.5 bit form a tag contain the location.
2. Associative mapping:-
If is much more flexible method of mapping. In this case a main memory block can be placed
into any cache block position. 12 tag bits are required to identify a memory block when it is
resident in the cache. The tag bit of an address received from the cup are compared to the tag
bit of each block of the cache to see if present. This is called associative mapping technique;

3. Set associative mapping :-


It is the combination of direct & associative mapping techniques. In this technique a set consist
of two blocks. Memory blocks 0,64,128….4032 map into cache set 0 & .they can occupy either
of the two block position within this set. The tag field of the address must be compaired to the
tags of the two blocks of the set to check if the desired block is present.
4. Inter leaved memory :-
-which works by partitioning the main memory into several independent memory module &
distributing It allows the concurrent access to more than one module the interleaving of
address of ‘M’ modules of memory is called ‘M-way interleaving’.
A memory module is a memory array together with its own address & data register figure
shows a memory unit four modules. Each module has its own AR & VR. AR receivers in
formation from communicate with common bidirecti onal data bus the advantage of a
module memory is that it allows the use of a technique called interleaving.
A modular memory is useful with pipeline & vector processor.

Array in the series of memory location or boxes

Demand Paging-

 In demand paging pages are loaded only on demand, not in advance.


 To implement paging it is necessary for the operating system to keep track of which Pages
are currently in use ,The page map table contains an entry bit for each virtual page of the
related process. Each page actually swapped in memory. Page map table points in actual
location that contains the corresponding page frame & marked as No if a particular page is
not in the memory.
If the program tries to access a page that was not swapped in memory?

 In that case page fault trap occurs, it is the result of the operation system’s failure.
 Here is a list of steps operating system follows in handling a page fault-
 If a process refers to a page which is not in the physical memory then an
internal table checked to verify weather a memory reference to a page was valid
or invalid.
 If the memory reference to a page was valid, but the page is missing the process
of bringing a page into the physical memory starts.

 By reading a disk, the desired page is brought back into the free memory
location.
 Once the page is in the physical memory , the internal table kept with the
process & page map table is updated to indicate that the page is now in
memory.
 Restart the instruction that was interrupted due to the missing page.

Steps in handling a Page Fault


Segmentation – It is a memory management scheme view of memory .Each segment has a
name a length. User address specify both the segment name & the offset within the
segment .The logical address consists of two parts a segment number ‘s’ & an offset ‘d’. The
segment number is used as an index into the segment table. The offset ‘d’ of the logical
address must be between O segment limit. If it is not trap to the a.s (logical addressing
attempt beyond end of the segment) .

Example – we have five segment number from O through 4. The segments are
stored in physical memory. The segment table has a separate entry foe each
segment, giving the beginning address of the segment in the physical memory (or
baseb ) & the length of that segment (or limit).If it is not logical addressing attempt
beyond end of segment.
Example - segment 2 is 400 byte long & begins at location 4300.A reference to
segment 3 .byte 853 is mapped to 3200+853= 4053 .A reference to bye 1222 of
segment O would results in a trap to the o,s as this segment is only 1000 byes long.

You might also like