Header Ads

Calculate the Effective Memory Access Time (`T_effective`) by using the formula. Show each step of the calculation.

The performance measure in paging is the effective memory access time. With part of the page table in the TLB and the rest in the main memory. In the context of paging, you are required to calculate the `T_effective` by considering the following factors.

`T_mem` = 200 nsec

`T_TLB` = 20 nsec

Hit ratio = 90%

Calculate the Effective Memory Access Time (`T_effective`) by using the formula. Show each step of the calculation.

Solution:


To calculate the Effective Memory Access Time (`T_effective`) in the context of paging, we need to consider the time required for accessing the TLB (Translation Lookaside Buffer) and the time required for accessing the main memory.

Let's break down the calculation step by step:

Calculate the average time for accessing the TLB (`T_TLB`) when there is a hit:
Given: `T_TLB` = 20 nsec
Hit ratio = 90%

The average time for accessing the TLB on a hit can be calculated as:
Average time for TLB hit = `T_TLB` * Hit ratio

Substituting the values, we get:
Average time for TLB hit = 20 nsec * 0.9 = 18 nsec

Calculate the time for accessing the main memory when there is a TLB miss:
Given: `T_mem` = 200 nsec

When there is a TLB miss, we need to access the main memory directly. Therefore, the time for accessing the main memory on a TLB miss is simply equal to `T_mem`.
Time for main memory access on TLB miss = `T_mem` = 200 nsec

Calculate the average time for accessing the main memory taking into account TLB hits and misses:
Given: Hit ratio = 90%

The average time for accessing the main memory can be calculated as:
Average time for main memory access = (Time for main memory access on TLB miss) * (1 - Hit ratio)

Substituting the values, we get:
Average time for main memory access = 200 nsec * (1 - 0.9) = 200 nsec * 0.1 = 20 nsec

Calculate the Effective Memory Access Time (`T_effective`):
The `T_effective` is the weighted sum of the average time for TLB hits and the average time for main memory access, based on their respective probabilities (hit ratio and miss ratio):
`T_effective` = (Average time for TLB hit) + (Average time for main memory access)

Substituting the values, we get:
`T_effective` = 18 nsec + 20 nsec = 38 nsec

Therefore, the Effective Memory Access Time (`T_effective`) in this case is 38 nsec.

No comments

Powered by Blogger.