edited by
2,546 views
0 0 votes
Consider a single level cache with an access time of 2.5ns with a block size of 64 bytes. Main Memory uses a block transfer capability that has a first word (4 bytes) access time of 50ns and an access time of 5ns for each word thereafter. If the hit ratio of the cache memory is 95%, then average memory access time is_______.

 

 

When to consider a Strict memory hierarchy method or Parallel accessing method in Solving these types of questions? By Default which way is followed?

2 Answers

1 1 vote

Given line size is 64 bytes there are 64/4=16 words [since word size is 4] in a cache line fetch and first word is of 4 bytes having access time 50 ns and remaining fifteen have access time 75 ns(i.e., 50+75=125 ns )

Tavg=timecache+(1−hitcache)[timememory]

=2.5+(1−.95)[125]

=2.5+6.25

=8.75

edited by
1 1 vote

level -> simultaneous access or parallel access-> H1(T1) +M1{(H2*T2) +(M2 * Tmemory)}

hierarchal  -> H1(T1) +M1[{H2*(T2+T1)} +{M2 * (T2+T1+Tmemory)}]

--------------------------------------------------------------------------------------------------------------------------------------------------

In question

Consider a single level cache

it means first formula will apply but

Main Memory uses a block transfer capability that has a first word access time of 50ns and an access time of 5ns thereafter

this line means that first we search in cache

if hit then we access in 2.5ns

and

if a miss occurs then

-> we access 16 words and transfer it to cache and access it

-> first transfer takes 50ns and remaining 15 words take 5 ns each

-> So Tmemory = 50+(15*5) ns=50+75 ns = 125 ns.

-> and then we access the word from cache in 2.5ns

---------------------------------------------------------------------------------------------------------------------------------------------------------

hence H1 = 0.95

           T1= 2.5

           M1 = 1-0.95 =0.05

            Tmemory = 125ns.

H1(T1) +M1(Tmemory + T1)

=> 0.95*(2.5)+0.05*(125 + 2.5)

=>2.375 + 6.375

=> 8.75 ns

edited by
Position:
Show:

Related questions

2 2 votes
2 2 answers
3.1k
3.1k views
Na462 asked Jul 23, 2018
3,089 views
Consider the following statements:S1 : Doubling the line size halves the number of tags in the cache.S2 : Doubling the associativity doubles the number of tags in the cac...
0 0 votes
1 1 answer
2.3k
2.3k views
Na462 asked Jul 23, 2018
2,262 views
Suppose after analyzing a new cache design, you discover that the cache has too many conflict misses and this needs to be resolved. You know that you must increase associ...
0 0 votes
0 0 answers
523
523 views
Priyansh Singh asked Jul 2, 2018
523 views
Hi sir, i want to ask that how we'll come to know whether this is an independent memory organization or it is a hierarchical organization ? In case of hierarchical it's a...
1 1 vote
1 1 answer
1.1k
1.1k views
Sumaiya23 asked Jan 18, 2018
1,052 views
Suppose the time taken to write in cache is tc and time to write in main memory is tm. If write back policy is used, only the main memory is written and time taken is tm....