Google Answers Logo
View Question
 
Q: Branch Target Buffer ( No Answer,   0 Comments )
Question  
Subject: Branch Target Buffer
Category: Computers
Asked by: lovkraft-ga
List Price: $40.00
Posted: 18 May 2004 13:31 PDT
Expires: 24 May 2004 07:22 PDT
Question ID: 348379
I'm revising for my BSc exam in "OS and computer architecture".
There's a question from a previous year's exam which I'm not sure how
to solve and it might come this year in some variation. As I'm aiming
for a 80% score, I want to be able to answer this one (as well as the
other one I posted on google answers). Please give a detailed
step-by-step guide on how you solved question (a)(ii) and (a)(iii). To
give an idea of the scope: it's a 2-hour exam and this question
represented 20% of the total exam mark when it occured. Each mark is a
percent.

Note that I have consulted my university's code of conduct and
guidelines on academic honesty and don't see anything preventing me
from seeking tutor help on past papers.


(a) The Intel Pentium I processor incorporates a Branch Target Buffer
(BTB). This BTB is a 4-way set associative cache with 256 sets; each
line in this cache can store a tag, the destination address of the
branch, and two history bits. Assuming that a branch receives an entry
in the BTB when it is taken for the first time, and its history bits
are then set to 11(binary), after which the history bits operate thus:
- each time the branch is not taken, the bits are decremented by 1
(but are never decremented below 0
- each time the branch is taken, the bits are incremented by 1 (but
are never incremented above 11 (binary)
- when a BTB miss occurs, the prediction is that the branch will not be taken
- when a BTB hit occurs, the prediction is that the branch will be
taken if the history bits are greater than 1, otherwise the prediction
is that the branch will not be taken.

(i) Briefly describe the purpose and operation of the BTB. [4 marks]
(ii) How many bits will be stored in the Tag field of each line of the
BTB ? [2 marks]
(iii) Assuming that the BTB is initially empty, and the processor then
encounters the conditional branch instructions shown in sequence in
the table below, copy and complete the table, showing your working.
[10 Marks]


Address of branch  |  Actual outcome  of  |  BTB  Hit  |  Prediction
instruction (hex)  |  branch instruction  |  or Miss?  | Taken or Not
----------------------------------------------------------------------
00246802           |  Taken               |            |            |  
00246804           |  Taken               |            |            |  
00244202           |  Taken               |            |            |  
00246802           |  Not taken           |            |            |  
00240202           |  Taken               |            |            |  
00246802           |  Not taken           |            |            |  
00244202           |  Taken               |            |            |  
00246804           |  Taken               |            |            |  
00246802           |  Not taken           |            |            |  
00246802           |  Taken               |            |            |  
 

(iv) Discuss possible ways in which this BTB could be improved when
designing a new processor, in order to deliver superior branch
prediction performance. [4 Marks]
Answer  
There is no answer at this time.

Comments  
There are no comments at this time.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy