Dlcoa Question Bank
Dlcoa Question Bank
List different
Q
Hardwired techniques.
Ans:
Q2. Explain with a neat block diagram Microprogrammed control unit.
Ans:
3. Write a note on microinstruction sequencing.
Q
Ans:
4. List and explain the key characteristics of Memory.
Q
Ans:
1. V olatile Memory: Volatile memory loses its data when the power supply is
turned off. Eg RAM.
2. Non-Volatile Memory: Non-volatile memory retains its data even when the
power is turned off. Examples include hard disk drives (HDDs), solid-state
drives (SSDs), and flash memory.
3. Latency is the delay between requesting data from memory and the moment the
data becomes available. Low-latency memory is important for tasks that
require rapid data access, such as gaming or real-time data processing.
4. Access time is the time it takes to retrieve data from memory. In general, lower
access times are desirable because they allow for faster data retrieval, which is
crucial for system performance.
5. Memory is categorised by its speed in terms of data access and retrieval. Faster
memory types, such as RAM (Random Access Memory), are used for
temporary data storage because they offer quick access to data that the CPU
needs for processing.
. Registers: The fastest, smallest memory directly within the CPU, used for
1
immediate data access.
. Cache Memory: High-speed memory between the CPU and RAM, storing
2
frequently accessed data to reduce access times.
. Random Access Memory (RAM): The main working memory for active data
3
and instructions during program execution.
his hierarchy optimises the trade-offs between speed, capacity, and cost,
T
allowing the computer to efficiently manage data at various stages of
processing.
8.What is the necessity of cache memory? Explain set associative cache mapping
Q
technique with an example.
Ans:
Cache memory is essential in computer systems due to the significant speed
difference between the CPU and main memory. It is necessary for the following
reasons:
. Speed Mismatch: CPUs operate much faster than main memory, and fetching
1
data directly from RAM would lead to performance bottlenecks.
. Spatial Locality: Programs often access data located near the current
3
memory location. Caches take advantage of this behaviour by storing adjacent
data blocks, improving data access efficiency.
- Cache Organization:4 sets, each with 4 lines (0-3, 4-7, 8-11, and 12-15).
- Address Format: Memory addresses are divided into three parts: Set Index (2
bits), Block Offset (2 bits), and Tag (remaining bits).
- Cache Operation: When the CPU wants to read data, it uses the Set Index to
select one of the four sets. Within the selected set, the cache controller checks
the Tags to find a match. If found, it's a cache hit, and the data is retrieved
quickly. If no match is found, it's a cache miss, and data is fetched from main
memory.
et-associative cache mapping balances the trade-offs between the simplicity of
S
direct-mapped caches and the flexibility of fully associative caches. It reduces
the likelihood of cache conflicts while maintaining efficiency in memory
access, making it a common choice for modern computer architectures.
ache Operation: When the CPU requests data, the cache controller compares
C
the Tag portion of the address with the Tags stored in all cache lines. A match
results in a cache hit, while no match is a cache miss, requiring data retrieval
from main memory.
xample: Imagine a fully associative cache with four cache lines (Line 0, Line
E
1, Line 2, and Line 3) and a main memory. The CPU sends a memory address,
and the cache controller searches all cache lines for a matching Tag. If found,
it's a cache hit, otherwise, it's a cache miss, and data is fetched from main
memory.
ully associative caches are flexible but complex, allowing any memory block
F
to reside in any cache line. This flexibility minimises cache conflicts but
involves extensive tag comparisons, making them suitable for specialised
caches where flexibility is critical.
10. Consider a fully associative mapped cache of size 8KB with block size 32 bytes.
Q
The size of the main memory is 4GB. Find-
1. Number of bits in tag
2. Word size
Ans:
Note to self: always right the unit for tag and block.
11 Consider a fully associative mapped cache of size 512 KB with block size 1 KB.
Q
There are 17 bits in the tag. Find-
1. Size of main memory
2. Size of word.
Ans:
12. Consider a direct mapped cache of size 16 KB with block size 256 bytes. The
Q
size of the main memory is 128 KB. Find-
1. No. of bits in a Tag
2. No. of bits in a set.
3. Length of word.
Ans:
13. Consider a 2-way set associative mapped cache of size 8 KB with block size 32
Q
bytes. The size of the main memory is 4GB. Find-
1. Number of bits in tag
2. No. of sets in main memory.
3. No. of bits in a set.
4. Word size
Ans:
14. Draw and explain the delay element method with an example.
Q
Ans:
Q15. Write a note on microinstruction format.
Ans:
16. Write micro operations for Add R1, R3 .
Q
Ans:
Micro-operations are the basic operations performed by the control unit of a CPU to
execute machine instructions. To perform an addition instruction like "Add R1, R3,"
several micro-operations are involved. Below are the micro-operations typically
performed in a simple microarchitecture for this instruction: