0

Based from what I read, it seems like the cost might be 0 cycles. Is it really 0 cycles? If the cost is 0 cycles, does this include the jump instruction itself instead of just the possible flush in the CPU instruction cache? I appreciate answers on any CPU architecture.

cpp plus 1
  • 67
  • 9

1 Answers1

0

In general, when someone says that a correctly predicted conditional branch is "free", they don't mean that it magically happens instantaneously, they mean that it has the same cost as an unconditional jump, i.e. that the "conditional" is free, not the whole branch.

Jörg W Mittag
  • 363,080
  • 75
  • 446
  • 653