SHORT Branch prediction miss rate/ratio

EVENTSET
PMC0  INSTRUCTIONS_RETIRED
PMC1  BRANCH_RETIRED
PMC2  BRANCH_MISPREDICT_RETIRED

METRICS
Runtime (RDTSC) [s] time
Branch rate   PMC1/PMC0
Branch misprediction rate  PMC2/PMC0
Branch misprediction ratio  PMC2/PMC1
Instructions per branch  PMC0/PMC1

LONG
Formulas:
Branch rate = BRANCH_RETIRED/INSTRUCTIONS_RETIRED
Branch misprediction rate = BRANCH_MISPREDICT_RETIRED/INSTRUCTIONS_RETIRED
Branch misprediction ratio = BRANCH_MISPREDICT_RETIRED/BRANCH_RETIRED
Instructions per branch = INSTRUCTIONS_RETIRED/BRANCH_RETIRED
-
The rates state how often on average a branch or a mispredicted branch occurred
per instruction retired in total. The branch misprediction ratio sets directly
into relation what ration of all branch instruction where mispredicted.
Instructions per branch is 1/branch rate.

