From 3dc7e4f496ad3ddab3010f8e7fdfce683ffdbdfb Mon Sep 17 00:00:00 2001 From: Erik Tomusk Date: Thu, 6 Dec 2012 09:31:06 -0600 Subject: TournamentBP: Fix some bugs with table sizes and counters globalHistoryBits, globalPredictorSize, and choicePredictorSize are decoupled. globalHistoryBits controls how much history is kept, global and choice predictor sizes control how much of that history is used when accessing predictor tables. This way, global and choice predictors can actually be different sizes, and it is no longer possible to walk off the predictor arrays and cause a seg fault. There are now individual thresholds for choice, global, and local saturating counters, so that taken/not taken decisions are correct even when the predictors' counters' sizes are different. The interface for localPredictorSize has been removed from TournamentBP because the value can be calculated from localHistoryBits. Committed by: Nilay Vaish --- src/cpu/o3/bpred_unit_impl.hh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/cpu/o3') diff --git a/src/cpu/o3/bpred_unit_impl.hh b/src/cpu/o3/bpred_unit_impl.hh index 7231d8f8c..74fe27a6a 100644 --- a/src/cpu/o3/bpred_unit_impl.hh +++ b/src/cpu/o3/bpred_unit_impl.hh @@ -65,8 +65,7 @@ BPredUnit::BPredUnit(DerivO3CPUParams *params) params->instShiftAmt); predictor = Local; } else if (params->predType == "tournament") { - tournamentBP = new TournamentBP(params->localPredictorSize, - params->localCtrBits, + tournamentBP = new TournamentBP(params->localCtrBits, params->localHistoryTableSize, params->localHistoryBits, params->globalPredictorSize, -- cgit v1.2.3