Browse Prior Art Database

Condition Code Branch Prediction

IP.com Disclosure Number: IPCOM000100156D
Original Publication Date: 1990-Mar-01
Included in the Prior Art Database: 2005-Mar-15
Document File: 1 page(s) / 43K

Publishing Venue

IBM

Related People

Kahle, JA: AUTHOR

Abstract

This article describes a better way to guess if a branch is going to be taken or not taken. With a higher percentage of branches 'guessed' the correct way, cycle per instruction (CPI) can be reduced, thus increasing system performance.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 71% of the total text.

Condition Code Branch Prediction

       This article describes a better way to guess if a branch
is going to be taken or not taken.  With a higher percentage of
branches 'guessed' the correct way, cycle per instruction (CPI) can
be reduced, thus increasing system performance.

      This invention describes a way to guess if a branch will be
taken or not taken from the previous condition code setting.  In a
RISC architecture, many novelties can be used to make branch
decisions as early as possible.  These include unconditional
branches, branch on count and a record bit to mark which instructions
would affect the condition code.  The compiler can be optimized to
move the branch decision as far up in the code as possible; but there
are still many cases where the branch processing chip must guess if a
branch will be taken or not.  It can use this guess to prefetch these
instructions.  If the branch processor guesses wrong, then the other
instruction stream must be fetched, which can cause a loss of
performance.

      In a RISC processor, the guess can always be made so that the
branch would not be taken.  This invention says that the branch
processor should look at the current state of the condition code bits
to make this guess.  The branch instructions specify which bit out of
32 condition code bits are to be used to make the branch decision.
Making a good guess is based on the idea that the previous setting of
the condition code is a good indication of...