【摘要】

TAGE被认为是最有存储效率的全局历史信息分支预测器。Andre就指出TAGE加上statistical corrector(SC)和loop predictor会更加高效。CBP-4traces下,32Kbits:3.315MPKI,256Kbits:2.365MPKI,no-limit budget(<2G):1.782MPKI。

【整体结构】

 

    TAGE-SC-L预测器如上图,由a TAGE predictor, a statistical corrector predictor, a loop Predictor三部分构成。

【TAGE conditional branch predictor】

 

   TAGE预测器由一个base 预测和M个tagged预测表Ti(1<i<M)构成,base是PC索引的2位计数器双峰预测。

  索引Ti的历史长度满足几何级数序列L(i) = (int)(alpha^(i-1)*L(1)+0.5)。Ti中的一个entry包括3个域: ctr(提供预测值、带符号,3bit)、tag、u(有用位计数器、无符号,2bit)

  Provider:tage hit中,由最长历史索引的部件。

  Alternate:provider以外的 tag hit的部件。Tage表中没有,就是base表。

【预测计算】给pc,计算taken/not taken

    Base 和taged同时计算。使用taged表命中里面,历史信息最长的;如果没有,就用base。存在alternate可能比provider更准确的情况。用4 bit计数器(USE ALT ON NA)来捕获这种全局现象。

1. Find the longest matching component and the alternate component

2. if (the confidence counter is not weak or USE ALT ON NA is negative)

    then the provider component provides the prediction

  else

    the prediction is provided by the alternate component

【更新TAGE】

--预测正确时

  更新ctr,当预测的置信度低的时候,alt也需要更新。

--预测错误时

1.更新provider的ctr

2.分配新entry

--更新u

  预测正确自增,

  周期性重置。

【Statistical Corrector Predictor】

TAGE在预测非常相关的branch时很有效。但是,TAGE在预测统计偏好的branch时效果较差,例如一些branch的相关性较差,但都有偏好一个方向。这种情况下,TAGE性能比简单PC-index计数器性能还差。

矫正的目标是侦测不大可能的预测值,做翻转处理。输入有:来自tage的pred,分支的其他信息(address, global history, global path, local history)。Tage的正确率一般都很高,SC就可以做得小一点。

【32Kbits predictor: The Corrector Filter】

         在存储限制下,SC做成一个相连表来监视来自TAGE的mispred。Mispred包括PC和preddirection被存下来(置一个低的可能性水平)。当在SC中命中后,可能性水平高的话,就翻转。Entry的换出策略是替换低可能性水平的entry。

posted on 2016-07-13 16:56  chaob  阅读(2306)  评论(0编辑  收藏  举报