首页> 外国专利> Branch prediction apparatus and process for restoring replaced branch history for use in future branch predictions for an executing program

Branch prediction apparatus and process for restoring replaced branch history for use in future branch predictions for an executing program

机译:分支预测设备和用于恢复替换的分支历史以用于执行程序的未来分支预测中的过程

摘要

Apparatus and methods implemented in a processor semiconductor logic chip for providing novel “hint instructions” that uniquely preserve and reuse branch predictions replaced in a branch history table (BHT). A branch prediction is lost in the BHT after its associated instruction is replaced in an instruction cache. The unique “hint instructions” are generated and stored in a unique instruction cache which associates each hint instruction with a line of instructions. The hint instructions contains the latest branch history for all branch instructions executed in an associated line of instructions, and they are stored in the instruction cache during instruction cache hits in the associated line. During an instruction cache miss in an instruction line, the associated hint instruction is stored in a second level cache with a copy of the associated instruction line being replaced in the instruction cache. In the second level cache, the copy of the line is located through the instruction cache directory entry associated with the line being replaced in the instruction cache. Later, the hint instruction can be retrieved into the instruction cache when its associated instruction line is fetched from the second level cache, and then its associated hint instruction is also retrieved and used to restore the latest branch predictions for that instruction line. In the prior art this branch prediction would have been lost. It is estimated that this invention improves program performance for each replaced branch prediction by about 80%, due to increasing the probability of BHT bits correctly predicting the branch paths in the program from about 50% to over 90%. Each incorrect BHT branch prediction may result in the loss of many execution cycles, resulting in additional instruction re-execution overhead when incorrect branch paths are belatedly discovered.
机译:在处理器半导体逻辑芯片中实现的用于提供新颖的“提示指令”的设备和方法,该“提示指令”唯一地保存和重用在分支历史表(BHT)中替换的分支预测。在指令高速缓存中替换关联的指令后,BHT中的分支预测会丢失。生成唯一的“提示指令”并将其存储在唯一的指令缓存中,该缓存将每个提示指令与一行指令相关联。提示指令包含在相关指令行中执行的所有分支指令的最新分支历史记录,并且在相关行中的指令缓存命中期间将它们存储在指令缓存中。在指令行中的指令高速缓存未命中期间,关联的提示指令存储在第二级缓存中,并且关联的指令行的副本在指令缓存中被替换。在第二级高速缓存中,该行的副本是通过与在指令高速缓存中被替换的行相关联的指令高速缓存目录条目定位的。稍后,当从第二级高速缓存中获取其提示指令时,可以将提示指令检索到指令高速缓存中,然后还可以检索其提示指令,并将其还原为该指令行的最新分支预测。在现有技术中,该分支预测将丢失。据估计,由于BHT位正确地预测程序中的分支路径的可能性从大约50%增加到超过90%,因此本发明将每个替换的分支预测的程序性能提高了约80%。每次错误的BHT分支预测都可能导致许多执行周期的损失,从而导致在迟迟发现错误的分支路径时导致额外的指令重新执行开销。

著录项

  • 公开/公告号US6877089B2

    专利类型

  • 公开/公告日2005-04-05

    原文格式PDF

  • 申请/专利权人 BALARAM SINHAROY;

    申请/专利号US20000748841

  • 发明设计人 BALARAM SINHAROY;

    申请日2000-12-27

  • 分类号G06F9/00;

  • 国家 US

  • 入库时间 2022-08-21 22:19:10

相似文献

  • 专利
  • 外文文献
  • 中文文献
获取专利

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号