Given a computer system that has a processor of 1 GHz, i.e., at a speed of one n
ID: 3637578 • Letter: G
Question
Given a computer system that has a processor of 1 GHz, i.e., at a speed of one nanosecond per clock cycle. This processor works with its memory through a cache. The cache has an access time of 4 cycles, and the memory has an access time of 400 cycles. This processor can execute one instruction in every clock cycle when there is no stall in accessing data from memory. But it does need to read data once every 5 instructions. 90% of these read operations are cache hits. With this information can you calculate how much time (in seconds) it takes for a processor to finish 1 million instructions? You may state a legitimate assumption for information not given.Can someone please show me how to do this because I am lost. Thanks!
Explanation / Answer
First of all, you know that every instruction takes 1ns to complete. Therefore a 1,000,000 instruction program will take at least 1,000,000 cycles to complete. Now one-fifth of those instructions will require four additional cycles to complete. So add on an additional 1,000,000 / 5 * 4 = 800,000 cycles Now one-fiftieth (10% of 1/5) of those instructions will require 400 additional cycles to complete. So add an additional 1,000,000 / 500 * 400 = 800,000 cycles
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.