Improving branch prediction accuracy in embedded processors in the presence of context switches
Sudeep Pasricha, Alex V. Veidenbaum · 2004
Embedded processors like Intel's XScale use dynamic branch prediction to improve performance. Due to the presence of context switches, the accuracy of these predictors is reduced because they end up storing prediction histories for several processes. We show that the loss in accuracy can be significant and depends on predictor type and size. Several new schemes are proposed to save and restore the predictor state, on context switches in order to improve prediction accuracy. The schemes differ in the amount of information they save and vary in their accuracy improvement. It is shown that even for a small 128 entry skew predictor, 2-6% improvement in prediction rate can be achieved (for an average context interval of 100K instructions) for different embedded applications while saving and restoring a minimal amount of state information (less than 32bits) on a context switch.