发明名称 BRANCH TARGET BUFFER COLUMN PREDICTOR
摘要 A processor receives a first instruction with a first instruction address within a first instruction stream. The processor selects a row of a branch target buffer and a row of a one-dimensional array based on the first instruction address. The processor reads information in the current row of the one-dimensional array, where the current row of one-dimensional array includes a first target address and a column of the row of the branch target buffer expected to contain a second target address. The processor receives a second instruction within a second instruction stream, which includes a second instruction address equal to the first target address. The processor reads information included in the row of the branch target buffer, where the information included the row of the branch target buffer includes the second target address. The processor encounters a branch including a third target address within the first instruction stream.
申请公布号 US2016239305(A1) 申请公布日期 2016.08.18
申请号 US201615089928 申请日期 2016.04.04
申请人 International Business Machines Corporation 发明人 Bonanno James J.;Curran Brian W.;Lipetz Daniel B.;Prasky Brian R.;Saporito Anthony
分类号 G06F9/38;G06F9/30 主分类号 G06F9/38
代理机构 代理人
主权项 1. A method for predicting a branch in an instruction stream, the method comprising: receiving, by a processor, a first instruction within a first instruction stream, wherein the first instruction includes at least a first instruction address; selecting, by the processor, a current row of a branch target buffer and a corresponding current row of a one-dimensional array based, at least in part, on the first instruction address; reading, by the processor, information included in the current row of the one-dimensional array, wherein the current row of one-dimensional array includes at least a first target address of a first prediction and a column of the current row of the branch target buffer expected to contain a second target address of a second prediction, wherein each prediction comprises an expected address, within the first instruction stream, of a taken branch and a target address of the taken branch; receiving, by the processor, a second instruction within a second instruction stream, wherein the second instruction includes a second instruction address and the second instruction address is equal to the first target address, and wherein the second instruction stream comprises at least a portion of the first instruction stream; reading, by the processor, information included in the current row of the branch target buffer, wherein the information included in at least one column of the current row of the branch target buffer includes at least the second target address of the second prediction; determining, by the processor, that the first target address differs from the second target address based, at least in part, on the information read from the current row of the branch target buffer and the information read from the current row of the one-dimensional array; updating, by the processor, the information included in the current row of the one-dimensional array to include the second target address of the second prediction and the at least one column of the current row of the branch target buffer that includes at least the second target address of the second prediction; encountering, by the processor, a branch present within the first instruction stream, wherein the encountered branch includes at least a third target address; determining, by the processor, that the first target address is equivalent to the second target address and differs from the third target address based, at least in part, on the information read from the current row of the one-dimensional array and the branch encountered within the first instruction stream; updating, by the processor, the information included in the current row of the one-dimensional array to include the third target address; determining, by the processor, that first target address is equivalent to the second target address and the third target address based, at least in part, on the information read from the current row of the one-dimensional array, the column of the current row of the branch target buffer containing the second prediction, and the branch encountered within the first instruction stream; executing, by the processor, at least the second instruction and a third instruction present within the second instruction stream; and removing, by the processor, the second instruction stream.
地址 Armonk NY US