What is the main advantage of a 2-bit saturating counter branch predictor over a 1-bit predictor?

Correct answer D. A loop branch that is mispredicted once on loop exit does not change the prediction for the next entry

Explanation

A 2-bit counter must be wrong twice in a row before its prediction flips. For a loop branch that is taken many times and not taken once at exit, a 1-bit predictor mispredicts twice per loop visit (exit and re-entry), while a 2-bit counter mispredicts only once. No dynamic predictor is perfect, and the target buffer is still needed to supply target addresses.

Report a problem

Answer checked How we write and check questions

Tip: press A, B, C or D to answer, and N for the next question.

Advertisement

Have a question about this answer?

Your email address will not be published. Required fields are marked *

Links and website addresses are not allowed in comments.