题目
题目

CS-6290-O01 Branches: Branch Prediction Benefit Quiz

数值题

  Speedup of perfect predictor is

题目图片
查看解析

查看解析

标准答案
Please login to view
思路分析
The prompt provided a numerical question: "Speedup of perfect predictor is" with an answer of 1.66, but there are no answer options to analyze. Because there are no given options, I cannot enumerate and compare each choice as the instructions request. Instead, I can outline how you would reason about this kind of question if you had the full context and options: - Understand the setup: A 5-stage pipeline with a branch predictor, where a branch is resolved in the 3rd stage. The predictor’s quality affects how many cycles are wasted d......Login to view full explanation

登录即可查看完整答案

我们收录了全球超50000道考试原题与详细解析,现在登录,立即获得答案。

类似问题

Consider the code fragment shown below. We show source code, the actual instructions the compiler generates without using predication, and the instructions generated when using conditional-move predication. Note that lines that begin with "//" are comments. The predicated code is not complete - you need to complete the predicated code by entering register numbers for the last instruction before answering the rest of this question. Suppose that "cond" is true 75% of the time, i.e. out of 1000 times that this code is executes, R1 is zero 250 times and is non-zero 750 times. Recall that "BEQZ" stands for "branch on equal to zero" and that the "N" in MOVN stands for "non-zero". Also suppose that we have a processor with a CPI of exactly 1 when there are no branch mispredictions, and with a branch misprediction penalty of 10 cycles. Complete the following statements (your answers should be numbers):

A processor is executing a long-running program, in which the most frequently executed branch instruction is encountered 8 million times per second. This branch has the following sequence of outcomes (where N stands for not-taken and T stands for taken): N, N, N, T, N, N, N, T, N, N, N, T, etc. In other words, this branch has a repeating pattern where it is not taken three times then taken once. For the first five occurrences of this branch instruction, the following table shows the counter values for the one-bit counter predictor, along with its predictions, and the actual branch outcomes (see above). Note that the counter starts out with an initial value of 1. Fill out the missing entries in the table: Note that the pattern has four branch occurrences while this table has five, i.e. the 5th occurrence of the branch in the table belongs to the second "round" of the pattern. Now suppose that we are measuring the accuracy of this branch during the third second of execution, i.e. after the predictor has already been trained by the first 16 million occurrences of this branch. To simplify things, you should assume that the predictor entries that are used for predicting this branch are only used for this branch, i.e. no other branches are interfering with the prediction, and that the initial values of all bits in the predictor were zeroes - but note that these values have been updated during the first two seconds of execution. Based on this, complete the following statements (your answers should be numbers):

  Is there a sequence of branch outcomes that result in never predicting correctly? Type Yes/No [Fill in the blank], If Yes, then type the sequence 1.[Fill in the blank], 2.[Fill in the blank], 3.[Fill in the blank], 4.[Fill in the blank], 5.[Fill in the blank],

  Speedup of perfect predictor is

更多留学生实用工具

加入我们,立即解锁 海量真题独家解析,让复习快人一步!