CPU time = ( CPU execution clock cycles +The memory-stall clock cycles come primarily from cache misses, and we make that assumption here. Memory-stall clock cycles can be defined as the sum of the stall cycles coming from reads plus those coming from writes:
Memory-stall clock cycles ) × Clock cycle time
Memory-stall clock cycles = Read-stall cycles +The read-stall can be defined in terms of the number of read accesses per program, the miss penalty in clock cycles for a read, and the read miss rate:
Write-stall cycles
Read-stall cycles = ( Reads / Program ) ×Writes are more complicated. For a write-through scheme, we have two sources of stalls:
Read miss rate × Read miss penalty
Write-stall cycles = [ ( Writes / Program ) ×
Write miss rate × Write miss penalty ] +
Write buffer stalls
“Mama used to say, you have to know someone a thousand days before you can glimpse her soul.” ― Shannon Hale, Book of a Thousand Days |