Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
unit-1
*Cache memory
Cache memory is small, high speed RAM buffer located
between processor and main memory.
Cache memory holds copy of instructions (instruction cache) or
data (operand or data cache) currently being used by CPU.
the main purpose of cache is to accelerate the computer while
keeping the price of the computer low.
*why we use cache memory..?
Processor is much faster than the main memory as a result, the
processor has to spend much of it’s time waiting while
instructions and data are being fetched from the main
memory.
to achieving good performance speed of the main memory
can't be increased beyond a certain point. to overcome this
problem cache memory is used.
cache memory is an architectural arrangement which makes
the main memory appear faster to the processor than it really
is.
cache memory is based on the property of computer programs
known as locality of reference.
*Computer
Computer Memory System:
System:-
Types of computer memory (RAM and ROM)
Memory is the best essential
ssential element of a computer because computer can’t perform simple tasks.
Computer memory is of two basic type – Primary memory / Volatile memory and Secondary memory
/ non-volatile
volatile memory. Random Access Memory (RAM) is volatile memory and Read Only Memory
Memo
(ROM) is non-volatile memory.
Memory Hierarchy:-
processor Addresss
Address Buffer
Control
Cache Control
Start
Done
64 bits
L2 cache(256 KB)
The cache way size can be varied between 1KB and 16KB in
powers of 2. A 1KB cache size must be implemented as a 1 way
cache, and a 2KB cache must be implemented as a 2 way cache.
All other cache sizes must be implemented as 4 way set
associative. The cache line length is fixed at eight words (32
bytes).
The maximum cache way size that the processor supports is
16KB. The minimum cache way size that the processor supports
is 1KB. You can disable instruction cache and data cache
together or instruction cache and data cache individually.
Note
If a cache is implemented within the ARM1156T2-S processor,
way 0 must be present.
Write operations must occur after the Tag RAM reads and
associated address comparisons have completed. A three-entry
Write Buffer is included in the cache to enable the written
words to be held until they can be written to cache. One or two
words can be written in a single store operation. The addresses
of these outstanding writes provide an additional input into the
Tag RAM comparison for reads.
To avoid a critical path from the Tag RAM comparison to the
enable signals for the data RAMs, there is a minimum of one
cycle of latency between the determination of a hit to a
particular way, and the start of writing to the data RAM of that
way. This requires the Cache Write Buffer to be able to hold
three entries, for back-to-back writes. Accesses that read the
dirty bits must also check the Cache Write Buffer for pending
writes that result in dirty bits being set. The cache dirty bits for
the data cache are updated when the Cache Write Buffer data
is written to the RAM. This requires the dirty bits to be held as a
separate storage array (significantly, the tag arrays cannot be
written, because the arrays are not accessed during the data
RAM writes), but permits the dirty bits to be implemented as a
small RAM.
The other main operations performed by the cache are cache
line refills and write-back. These occur to particular cache ways,
which are determined at the point of the detection of the cache
miss by the victim selection logic.
Internal memory:
Internal memory typically refers to main memory (RAM), but
may also refer to ROM and flash memory. In either
case, internal memory generally refers to chips rather than
disks or tapes.
In a computer, all of the storage spaces that are accessible by
Memory type.
Internal memory
PROM
Static RAM Dynamic RAM
EPROM
Flash
*RAM (Random Access Memory)
Random access memory, or RAM, is memory storage on a
computer that holds data while the computer is running so that
it can be accessed quickly by the processor. RAM holds the
operating system, application programs and data that is
currently being used.
RAM data is much faster to read than data stored on the hard
disk. RAM is stored in microchips and contains much less data
than the hard disk. RAM can never run out of memory, but the
processor must overwrite old data if the RAM is filled, which
results in slower computer function. Any file stored in RAM can
be accessed directly if the user knows the row and column
where the data is stored.
byte level
RAM is the Volatile memory.
Types of RAM
Static RAM
Dynamic RAM
Dynamic RAM
Dynamic RAM data store one bit of information as a payload.
Dynamic RAM using a substrate capacitance gate MOS
transistors as memory cells shut. To keep dynamic RAM stored
data remains intact, the data should be refreshed again by
reading and re-write the data into memory. Dynamic RAM is
used for applications that require large RAM capacity, for
example in a personal computer (PC)
RDRAM (Rambus Dynamic Random Access Memory)and
SDRAM (Synchronous Dynamic Random Access Memory) are
type of Dynamic RAM.
DRAM uses Asynchronous memory address i.e the memory
capacitors
Dynamic RAM is cheaper than static RAM and can be packed
*Error correction:-
There are 2 types of error
Error Signal
Data out
Corrector
Data in M
Memory M K
Compare
f
f K
K
M=Data bit
K=Code bit
f=Code function
Here in the above figure M is data bit and K is the code bit
and f is the code function. There are 2 code function (f ).First
code function is used when data is stored in the Particular
memory location and the second code function is used when
the data is retrieved from the Particular memory Location. Both
the code bits are compared in the comparison function if it
gives any error comparison function gives a signal to the
corrector then corrector collects the data bit from memory and
correct it then data will be out. Suppose after comparing the
code bit there is a error and it will not be corrected then it gives
a error signal.
****************************************************
****************************************************
Unit-2:-
*External memory:-
External memory typically refers to storage in an external hard
drive or internet. It is also known as Auxiliary memory used in
computer system are generally magnetic disks and magnetic
tapes.
Other components are also used in as external storage like
magnetic drums, magnetic bubble memory and optical disks.
*Magnetic disks:-
A magnetic disk is a circular plate constructed of metal or
plastic coated with magnetized material. Both sides of the disk
are used and several disks may stacked on one spindle with
read/write heads available on each surface.
All disks rotate at a high speed and are not stopped or
started for access purpose. Bits are stored in magnetized
surface in spots along concentric circles called tracks.
Tracks are commonly divided into sections called sectors .In
most systems, the minimum quantity of information which can
be transferred is sector.
Some units use a single read/write head for each disk
surface. In this type of unit the track address bits are used by a
mechanical assembly to move the head in to specified track
position before reading or writing in other disk systems,
separate read/write tracks are provided for each track in each
surface.
permanent timing tracks are used in disk to synchronize the
bits and recognize the sectors.
A disk system is addressed by address bits that specify the
disk number, disk surface, sector number and the track within
the sector.
After the read/write heads are positioned in the specified
track, the system has to e wait until the rotating disk reaches
the specified sector under the read/write head.
Information transfer is very fast after once the beginning of a
sector has been reached.
Disks may have multiple heads and simultaneous transfer of
bits from several tracks at the same time.
s Tracks
e
c
t
o
r
s
Read/write head
[Magnetic Disk diagram]
A track in a given sector near the circumference Is longer than
the track near the center of the disk. If bits are recorded with
equal density some tracks will contain more recorded bits than
others. To make all the records in a sector of equal length,
some disks use a variable recording density with higher density
on tracks near the center than on tracks near the
circumference. This equalizes the number of bits on all tracks of
a given sector.
NOTE:-
The disks that are permanently attached to the unit
assembly and can’t be removed by the occasional user are
called hard disks.
A disk drive with removable disks is called a floppy
disk are generally made of plastic coated and magnetic
recording material.
Hard disk driver and solid state driver based systems include
RAID-0(Simple Stripping),RAID-1(simple or multi
mirroring),RAID-3(Byte Level stripping ,plus 1 drive dedicated to
strong parity information),RAID-4(block level striping with a
parity drive),RAID-5(block level stripping with a distributed
parity scheme).
Stripping with no redundancy or parity is often used to
increase performance. Stripping with parity or double parity
strengthens data protection.
In most RAID types stripping redundant data blocks enables
system to reconstruct the lost information in one or more drive
fail.
The term solid state driver Array sometimes used as an
alternative name for a storage array that is equipped with flash
based solid state drivers and uses a form of disk.
*optical memory:-
Optical memories are used for large storage of data. These
devices provide the option of variety of data storage. These can
save up to 20 GB of information.
The data or information is read or written using a laser beam.
Due to its low cost and high data storage capacity these
memories are being freely used.
Apart from low cost these memories have long life. But the
problem is that of low access time.
CD-ROM:-CD ROM or compact disk read only memory are
optical storage device which can be easily read by computer
but not written. CDROMs are stamped by the vendor and once
stamped; they can’t be erased and filled with new data.
To read a CD,CD-Rom player is needed. All CDROM conform to
a standard size and format so any type of CDROM can be
loaded in to any CD-ROM player. In addition, CDROM players
are capable of playing audio. CDs, which share the same
technology.
CD-ROM are particularly well-Studio to information that
requires large storage capacity which includes large software
application that support color, Graphics. Sound and especially
video.
Advantages of CD-ROM:
Storage capacity is high.
storage cost per bit is reasonable.
Easy to carry.
can store variety of data.
Disadvantages of CD-Rom
CD-ROMs are read only
Access tine is more than harddisk.
WORM:- WORM or write once read many or CD-R or CD-
recordable are kind of opctical device which provides the use of
library to write once on the CD-R.
The user can write on the disk using the CD-R disk drive
unity. But this data or information can’t be overwritten or
changed.
CD-R doesn’t allows re-writing through reading can be done
many time.
Advantages of WORM:
Storage capacity is high
Can record once.
Reliable
Runs longer
Access time is good.
Disadvantages or limitation of WORM:-
Can be written only once erasable optical disk.
Erasable optical disk:-Erasable optical are also called CD-RW or
CD rewritable it gives the user liberty of erasing data already
written by burning the microscopic point on the disk surface
the disk can be reused
Advantage of CD-RW:-
Storage capacity is very hiagh
reliablity is high.
runs longer
eassy to rewrite
Limitation of CD-RW:-
Access time is high.
DVD-ROM:
DVD-ROM,DVD-R and DVD-RAM:DVD or digital versatile disk is
another form of optical storage. These are higher in capacity
the CDs.
Pre-record DVDs are mass produce using molding machine
that physically stamp.
Data on to the DVD such disk are known as DVD-Rom
because data can only be read and not written nor erased.
DVD-Rs are the blank recordable DVDs which can be record
once using optical disk recording technology by using DVD
record and then function as DVD-Rom.
DVD-ROM rewritable DVDs DVD-RAM can be record and erased
multiple time.
*Magnetic tapes:-
A magnetic- tape transport consist of the electrical ,
mechanical and electronic components to provides the parts of
control mechanism for a magnetic tape unit.
The tape itself a strip of plastic coated with a magnetic
recording material.
Bits are recorded as magnetic spots on the tape along several
tracks. Usually 7 or 9 bits are recorded simultaneously o form a
character together with a parity bit.
Read/write heads are mounted one in each track so that that
can be recorded and read as a sequence of characters.
Magnetic tape units can be stopped, started and move
forward or in reverse or can be rewound However, they can’t
be started or stopped fast enough between individual
characters.
For this reason, information is recorded in blocks referred to
as records. Gaps of unrecorded tapes are inserted between
records where the tape can be stopped.
The tapes start moving while in a gap and attains it’s
constant speed by the time It reaches the next record.
Each record on tape has a identification bit pattern at the
beginning and end. By reading the bit pattern at the beginning ,
the tape control identifies the record number.
By reading the bit pattern at the end of the record the
control recognizes the beginning of the gap.
-->A tape unit is addressed by specifying the record number
and the number of characters in the record. Records may be
fixed or variable length.
*Input output:-
I/O operations are accomplished through external devices that
provide a means of exchanging data between external
environment and computer.
*External Devices:-
External Devices can be categorized as:-
1. Human Readable: suitable for communicating with
computer user, for example video display terminals and
printers.
2. Machine Readable: suitable for communicating with
equipment. For example- sensor, actuators used in robotic
Applications.
3. Communication: Suitable for communicating with remote
devices. They may be human readable device such as
terminal and machine readable device such as another
computer.
*I/O modules:-
The computer will be no of use if it is not communicating with
the external world. A computer must have a system to receive
information from the outside world and must be able to
communicate to external world. Thus a computer consists of an
I/O devices and the I/O module, which not only consist of I/O
device with the system bus, but plays a very crucial role in
between. A device which Is connected to an I/O module of
computer is called a peripheral device. The I/O module is
normally connected to the computer system one end and one
or more I/O devices on the other.
An I/O module is needed because of:
(a)Diversity of I/O devices makes it difficult to include all the
peripheral device logic (i.e its control commands and data
format etc.) in to CPU.
(b)The I/O devices are usually slower than the memory and
CPU. Therefore it is not advisable to use them on high speed
system bus directly for communication purpose.
(c)The data format and word length used by the peripheral may
be quite different than that of CPU.
*Thus we can say that:-
(i)An I/O module is modulator between the processor and I/O
devices.
(ii)It controls the data exchange between the external devices
and the main memory or external devices and the CPU register.
(iii)An I/O module provide an interface internal to to the
computer which connects it to external device or peripheral.
(iv)The I/O module shouldn’t only communicate the
information from CPU to I/O device but it should also
coordinate these two.
(v)In addition since there are speed difference between CPU
and I/O devices, The I/O module should have facilities like
Buffer (storage area) and error detection mechanism.
Functions of I/O modules:
The major functions of I/O modules are:
1. processor communication:-This Involves the following
tasks:-
a. Exchange of data- between processor and I/O
module.
b. Command decoding- I/O module accepts commands
sent from the processor E.g The I/O module for a disk
drive may accepts the following commands from the
processor. READ SECTOR,WRITE SECTOR,SEEKTRACK
etc.
c. Status reporting- The device must be able to report
its status to the processor. E.g disk drive busy, read
etc. status reporting may also involves reporting
values errors.
d. Address recognition- Each I/O device has a unique
address and the I/O module must recognize this
address.
2. Device communication:- The I/O module must be able to
perform communications such as status reporting.
3. Control and timing:- The I/O module must be able to
coordinate the flow of data between the internal
resources(such as processor and memory) and external
devices.
4. Data buffering:- This is necessary as there is a speed
mismatch between the speed of data transfer between
processor and memory and external devices. Data coming
from the main memory are sent to an I/O module and
then sent to the peripheral device at its rate.
5. Error Detection:- The I/O module must also be able to
detect errors and report them to the processor. These
errors may be mechanical errors (such as paper jam in a
printer). Or changes in the bit pattern of transmitted data.
A common ways of detecting such errors is by using parity
bits.
Data
External
Data Registers Device Data
Status Links
Interface
Status control Registers
Logic Control
Data
External
*Programmed I/O:-
Using this technique data transfer takes place under the direct
control of processor. The processor must continuously check an I/O
device and hence it can’t do another task. Hence this method is
inefficient (slow).
Memory Device
and
MAB CB DB Status FF
DAB DB/ Controller
Register DC
Processor
CB
DB
DB-Data Bus
DAB-Device Address Bus
DC-Device Control Signal
MAB-Memory Address Bus
CB-Control Bus
Characteristics of programmed I/O:-
1. In a programmed I/O, The I/O operations are controlled
Completely by CPU.
2. Used in real time and embedded systems.
3. Used in CPUs, which have a single input and a single output
instruction. Each of these instructions selects one device.
4. The disadvantages of this technique is that the CPU spends
most of its time waiting for the device to become ready.
*Interrupt Driven I/O:-
The basic drawback of programmed I/O is that the speed of I/O
device is much slower in comparison to that of CPU, and because
the CPU has to repeatedly check whether a device is free; or wait till
the comparison of I/O, therefore, the performance of CPU in
programmed I/O goes down tremendously.
Interrupt:-
The term interrupt is used for nay event that causes temporary
transfer of that control of CPU that program to the another which is
causing the interrupt. Interrupts are primarily issued on :-
1. Initiations of I/O operations (interrupt issued by I/O devices)
2. Completion of an I/O operation.
3. Occurrence of Hardware or Software errors.
Interrupts can be generated by various sources internal or external
to the CPU.
In the internal driven I/O the processor issues a READ/WRITE
instruction to the device and then continuous to doing its task.
When the interface buffer Is full, and its ready to send data to the
processor, The interface sends signal to the processor informing it
that data is ready. This signal is called as the interrupt signal. When
the processor receives the interrupt signal it knows that the data is
ready; it suspended its current job and transfers data buffers to its
own registers.
Disadvantages of interrupt driven I/O technique:-
The processor must suspend its work and later resume it. If there
are many devices, each can issue an interrupt and then processor
must be able to attend each of these based on some priority.
The Role Of Processor In Interrupt Driven I/O:-
When an I/O device is ready to send data, the following events
occur:-
1. The device issued an interrupted signal to the processor.
2. The processor finishes execution of the current instruction, it
then responds to the interrupted signal.
3. The processor sends an acknowledgement signal to the device
that sent the interrupt. The device then removes its
interrupted signal.
4. The processor must save the state of current task (i.e the
values of registers, The address of next Instruction to be
executed etc.) These are saved on to a stack.
5. The processor then attends to the device that issued to the
interrupted signal.
6. When an interrupt processing is over the saved registers are
retrieved from the stack and the processor continuous its
previous task signal from the point where it was last stopped.
When the processor detects an interrupt. It executes an
interrupt-service routine. This routine polls each I/O device to
determine which device caused the interrupted. This technique is
called software poll.
*Direct Memory access:-
DMA interface
Status Device
Memory
MAB and MAB
Data Register
DB
Controller
MAR
DB
Processor
MAB
DA and CB
Multiplexer
The Multiplexer channel can be connected to a number of slow
and medium speed devices. It is capable of operating number
of I/O devices simultaneously.
Selector
This channel can handle only one I/O operation at a time and is
used to control one high speed device at a time.
Block-Multiplexer
It combines the features of both multiplexer and selector
channels.
The CPU directly can communicate with the channels
through control lines. Following diagram shows the word
format of channel operation.
Types of Interfaces
In a parallel interface, there are multiple lines connecting the I/O
module and the peripheral, and multiple bits are transferred
simultaneously, just as all of the bits of a word are transferred
simultaneously over the data bus.
In a serial interface, there is only one line used to transmit data,
and bits must be transmitted one at a time. A parallel interface has
traditionally been used for higher-speed peripherals, such as tape
and disk, while the serial interface has traditionally been used for
printers and terminals.
With a new generation of high-speed serial interfaces, parallel
interfaces are becoming much less common. In either case, the I/O
module must engage in a dialogue with the peripheral. In general
terms, the dialogue for a write operation is as follows:
Thunderbolt
InfiniBand
Channel Structure
The zEnterprise 196 has a dedicated I/O subsystem that manages all
I/O operations, completely off-loading this processing and memory
burden from the main processors. up to 4 of these can be dedicated
for I/O use, creating 4 channel subsystems(CSS). Each CSS is made
up of the following elements:
*****************************************************************************************************************************
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
*****************************************************************************************************************************