Branch Misprediction

Turkish equivalent: Dallanma yanlış tahminiDomain: Computer Architecture

A CPU event in which a conditional branch is predicted incorrectly and speculative work on the wrong path must be discarded.

A modern pipeline tries to continue execution before every branch outcome is known. When the prediction is wrong, speculative instructions on the wrong path are discarded and the pipeline has to recover, making the cost much larger than a single comparison.

Branch-heavy code over irregular data can therefore underperform despite a low instruction count. When profiling, the effect should be separated from cache misses and dependency stalls rather than inferred from source structure alone.