retagged by
1,617 views
5 votes
5 votes

Suppose cache with hit ratio 'Ch' and access time 'Ct' is given and main memory with hit ratio 'Mh' and access time 'Mt' is given and a disk with access time 'Dt' is given. If with only this information average memory access time is asked, does the access time of main memory include time of cache and memory also.

For e.g. should the equation be -

Average memory access time = Ch * Ct + (1-Ch) * Mh * ( Ct + Mt ) + (1-Ch) * (1-Mh) * ( Ct + Mt + Dt)

If so, why the addition and is it implicit always ? 

retagged by

1 Answer

2 votes
2 votes

Yes , CPU takes the blocks data from cache

if their is a cache miss then from main memory we get the block data and place it in cache and then given to CPU

if their is a miss in main memory then from disk ----> main memory -------->cache the block is placed and then the lock is taken by CPU

So Average memory access time = Ch * Ct + (1-Ch) * Mh * ( Ct + Mt ) + (1-Ch) * (1-Mh) * ( Ct + Mt + Dt)

Related questions

1 votes
1 votes
1 answer
1
2 votes
2 votes
2 answers
3