0 votes 0 votes If cache access time is $100ns$, main memory access time is $1000ns$ and the hit ratio is $0.9$. Find the average access time and also define hit ratio. CO and Architecture co-and-architecture cache-memory + – Shivani gaikawad asked May 24, 2018 • edited May 27, 2018 by Subarna Das Shivani gaikawad 530 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes Average time to access = Hit rate x Cache access time + Miss rate x (Cache access time + Memory access time) Putting values, we get = 0.9 x 100 + 0.1 (100 + 1000) = 90 + 110 = 200 ns Hit ratio is defined as "percentage of memory accesses satisfied by the cache" Ref: http://homepage.divms.uiowa.edu/~ghosh/4-1-10.pdf Arunav Khare answered May 24, 2018 Arunav Khare comment Share Follow See all 4 Comments See all 4 4 Comments reply jatinkumar commented May 24, 2018 reply Follow Share Hi, why didn't you use this formula Average time to access = Hit rate x Cache access time + Miss rate x (Memory access time) then answer will be 190ns 0 votes 0 votes Arunav Khare commented May 24, 2018 reply Follow Share Well, there are two types of cache access policies. Hierarchal - Here access to cache takes place first and then when it fails, we go to main memory. So, we need to count the time (wasted) in cache access in case of cache miss. Here the formula which I have used is to be used. Simultaneous - Here access to cache as well as main memory happen simultaneously. So, in case of miss in cache, we do not need to count cache access time again. Here the formula which you have used is to be used. Ref: https://gateoverflow.in/108780/simultaneous-vs-hierarchical-memory 0 votes 0 votes jatinkumar commented May 25, 2018 reply Follow Share if it is not given in question like it is Hierarchal or Simultaneous access then by default we have to take which access ? 0 votes 0 votes Arunav Khare commented May 25, 2018 reply Follow Share I am not really sure of that, but you can try this approach - Do both and see which ans is in option. if both are there / or you have to type, go with hierarchal. However, some questions in some exams like that of ISRO use simultaneous access. May be others can help here 0 votes 0 votes Please log in or register to add a comment.