0% found this document useful (0 votes)
84 views5 pages

W3 A3 Detailed

This document provides the detailed solution to an assignment on multi-core computer architecture storage and interconnects from the NPTEL Online Certification Course NOC22-CS110 taught at the Indian Institute of Technology Guwahati. The document contains 9 multiple choice questions about cache memory architecture including cache hit rate, miss rate, block size, associativity, and multi-level caching. It provides the questions, explanations of the concepts, and the answers to each question.

Uploaded by

Rama Devi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
84 views5 pages

W3 A3 Detailed

This document provides the detailed solution to an assignment on multi-core computer architecture storage and interconnects from the NPTEL Online Certification Course NOC22-CS110 taught at the Indian Institute of Technology Guwahati. The document contains 9 multiple choice questions about cache memory architecture including cache hit rate, miss rate, block size, associativity, and multi-level caching. It provides the questions, explanations of the concepts, and the answers to each question.

Uploaded by

Rama Devi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

NPTEL Online Certification Course

NOC22-CS110: Multi-Core Computer Architecture -


Storage and Interconnects
Assignment-3: Detailed Solution
Indian Institute of Technology Guwahati

i
at
ah
1. Which one of the following is the most optimum way to reduce the cache miss penalty?

uw
A) Larger block size
(B) Multi-level caching

G
(C) Larger cache size

gy
(D) Higher Associativity

lo
A miss penalty refers to the extra time required to bring the data into the cache from the
main memory whenever there is a miss in the cache. Multilevel caches are one way to
no
improve cache performance by reducing the miss penalty.
ch
2. Compulsory misses in a cache can be reduced by _
Te

(A) increasing associativity


of

(B) increasing the number of sets in the cache


te

(C) increasing cache block size


itu

(D) increasing read ports


st

Cache misses at the first encounter of a block are called "compulsory misses." When we
have a larger block, the probability of a cache hit will increase, thereby reducing
In

compulsory misses.
an

3. A computer system has 16 MB byte addressable main memory and 64 KB 4-way set
di

associative cache memory with a block size of 256 bytes. Consider the following physical
addresses.
In

A1=0x42C84A, A2=0x5E485A
Which one of the following statements is FALSE?
(A) A1 and A2 are mapped to the same set.
(B) A1 and A2 have different tag values.
(C) A1 and A2 are mapped to a different set.
(D) A1 and A2 have different block offset
NPTEL Online Certification Course
NOC22-CS110: Multi-Core Computer Architecture -
Storage and Interconnects
Assignment-3: Detailed Solution
Indian Institute of Technology Guwahati

No. of sets = Cache Size / (Block size * Associativity)

i
at
= 64 KB/ 256 B * 4

ah
= 2^6 * 2^10 / 2^8 * 2^2

uw
= 2^6

G
No. of bits representing Set Index = 6

gy
No. of bits representing Block Offset = 8 (since Block Size is 256 B)

lo
No. of bits representing Physical Address = 24 bits (since Main memory Size = 16MB)
no
No. of bits representing Tag = 24 - 6 - 8 = 10
ch
Te

A1 = 0x42C8A4 = 0100001011 001000 01001010


of

A4 = 0x5E48A5 = 0101111001 001000 01011010


te
itu

4. For a cache memory of a given capacity, as block size reduces, there is


st

(A) a decrease in both compulsory misses and conflict misses.


In

(B) a decrease in compulsory misses and an increase in conflict misses.


an

(C) an increase in both compulsory misses and conflict misses.


di

(D) an increase in compulsory misses and a decrease in conflict misses.


In

Without changing the cache capacity and by reducing the block size only, compulsory misses
would be increased as only a small amount of data (small block) can be brought to the cache in
one cache miss. Since less data is brought and if the program shows spatial locality there will be
frequent cache misses. When block size reduces, it will accommodate more cache blocks in the
cache. This will spread the mapping more widely and reduce conflict misses.

5. Avoiding address translation from virtual to physical before cache indexing will __
NPTEL Online Certification Course
NOC22-CS110: Multi-Core Computer Architecture -
Storage and Interconnects
Assignment-3: Detailed Solution
Indian Institute of Technology Guwahati
(A) increase hit time
(B) decrease hit time

i
(C) increase miss rate

at
(D) increase miss penalty

ah
Address translation is the process of converting virtual addresses into physical addresses.

uw
To access the cache before indexing and tag comparison, it has to perform address
translation, which increases the hit time. Therefore, avoiding address translation will

G
reduce hit time.

gy
6. Which of the following is TRUE for inclusive cache?

lo
no
(A) L1 and L2 caches will not have any data in common
ch
(B) contents of L2 cache is a subset of contents L1 cache

(C) contents of L1 cache is a subset of contents of L2 cache


Te

(D) every data item present in L2 is present in L1 also


of
te

If L1 cache is a subset of L2, it is called inclusive cache. Since L2 cache is larger than
itu

L1, L2 cannot be a subset of L1 cache.


st

7. Assume an L1 cache with a hit rate of 70% and an L2 cache with a local miss rate of 6%.
In

If there are 1000 memory access initiated by CPU, then the number of access that will
find a hit in the L2 cache is ___________.
an

(A) 940
di

(B 700
In

(C) 18
(D) 282

Number of access that will miss in L1 cache = (Miss rate_L1 * # memory access to L1)

= 0.3*1000 = 300
NPTEL Online Certification Course
NOC22-CS110: Multi-Core Computer Architecture -
Storage and Interconnects
Assignment-3: Detailed Solution
Indian Institute of Technology Guwahati
Hence, there are 300 memory accesses to the L2 cache.

i
at
Number of misses in L2 cache = (Miss rate_L2 * # memory access to L2)

ah
= 0.06*300 = 18.

uw
Number of memory accesses that will hit in L2 = 300-18=282

G
gy
8. A cache has a hit time of 10 ns and hit rate of 60%. An optimization was made to
increase hit rate to 70% but the hit time was increased to 15 ns. The optimization resulted

lo
in a 10% reduction in average memory access time. Assume that the miss penalty is
no
unaffected by the optimization. The miss penalty of the cache (in ns) is _____.
ch
Te

(A) 115
(B 110
of

(C) 90
(D) 100
te
itu

Ans: 100
st

Hit time_old = 10 ns
In

Hit rate_old = 0.6


Hit time_opt = 15 ns
an

Hit rate_opt = 0.7


AMAT_opt = 0.9 AMAT_old
di
In

AMAT = Hit time + Miss rate * Miss penalty_L1

AMAT_opt/AMAT_old = 0.9

0.9 = (15 + (0.3 * x) / (10 + (0.4 * x))


x = 100
Miss Penalty_L1 = 100 ns
NPTEL Online Certification Course
NOC22-CS110: Multi-Core Computer Architecture -
Storage and Interconnects
Assignment-3: Detailed Solution
Indian Institute of Technology Guwahati

i
at
9. Consider a memory system with L1 and L2 caches. From the CPU, there are 300 requests

ah
to the L1 cache. Among those requests, 260 are hit at L1. If there are 8 misses in the L2
cache, then the local miss rate at the L2 cache (rounded to one decimal place) is

uw
________.

G
gy
Correct answer: 0.2

lo
No of misses at L1 = No of requests at L2 = 300-260 = 40
No of misses at L2 = 8 no
Local miss rate at L2 = number of misses at L2 / total number of requests at L2
ch
= 8/40 = 0.2
Te

10. The average memory access time for a memory hierarchy system with one level of cache
of

and the main memory is 5 ns. The hit time and miss penalty of the cache are 2 ns and 100
ns, respectively. The hit rate of the cache (round off to two decimal places) is ______.
te
itu

Ans: 0.97
st

AMAT = Hit time + Miss rate * Miss penalty_L1


In

Putting the values in the formula we get,


an

5 = 2 + (1- Hit_rate) * 100


Hit_rate = 0.97
di
In

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy