Static branch prediction

Tim Frink <>
Mon, 3 Mar 2008 10:37:54 +0000 (UTC)

          From comp.compilers

Related articles
Static branch prediction (Tim Frink) (2008-03-03)
Re: Static branch prediction (Markus Armbruster) (2008-03-04)
Re: Static branch prediction (2008-03-05)
Re: Static branch prediction (2008-03-05)
Re: Static Branch Prediction (Aaron W. Hsu) (2012-12-01)
| List of all articles for this month |

From: Tim Frink <>
Newsgroups: comp.compilers
Date: Mon, 3 Mar 2008 10:37:54 +0000 (UTC)
Organization: CS Department, University of Dortmund, Germany
Keywords: optimize, architecture, question
Posted-Date: 03 Mar 2008 13:58:10 EST


Some processors use a static branch prediction. The predicted outcome
of a jump depends on the instruction, i.e. a 16-bit conditional jump
instruction is predicted as taken while a 32-bit instruction with a
forward displacement is predicted as not taken.

If the outcome of a jump would be known in advance, one could use the
appropriate jump instructions to avoid misprediction, thus
accelerating the program execution. I assume that profiling data could
be used for that to figure out the more probable jump behavior.

This idea is probably not new, so I wonder if you know any
compilers/optimizers that apply this technique? Do you have own
experiences or know any papers/reports where any results are


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.