## NPTEL Advanced Computer Architecture Week 2 Assignment Answers 2024

1. Consider the following statements.

S1: If we ensure *precise exceptions*, there will be serious violations in correctness.

S2: It is simpler to ensure *precise exceptions* in an *out of order* processor compared to an *in-order* processor.

- Only S1 is true
- Only S2 is true
- Both S1 and S2 are true
- Both S1 and S2 are false

Answer :-For AnswerClick Here

2. Consider the following statements.

S1: To predict if an instruction is a branch or not, we check its *PC (Program Counter) *value.

S2: To predict a branch using an *Instruction Status Table (IST),* we take the n most significant bits of the *PC(Program Counter)* of the instruction to index the IST.

- Only S1 is true
- Only S2 is true
- Both S1 and S2 are true
- Both S1 and S2 are false

Answer :-For AnswerClick Here

3. Consider the following statements.

S1: When two branch instructions share entries in a predictor table and can overwrite each other’s state, we observe destructive interference.

S2: We consider the LSB of the PC for indexing predictor tables because it incorporates more randomness.

- Only S1 is true
- Only S2 is true
- Both S1 and S2 are true
- Both S1 and S2 are false

Answer :-For AnswerClick Here

4. An Instruction Status Table, which is indexed using n bits from the Program Counter of the instruction, will contain _________ entries.

- n
- 2
^{n} - 2
^{n}– 1 - 2
^{n}+1

Answer :-

5. Consider the following statements.

S1: A bimodal predictor is a single-bit branch predictor.

S2: Adding saturating counters to predictors decreases the degree of hysteresis in the branch predictor.

- Only S1 is true
- Only S2 is true
- Both S1 and S2 are true
- Both S1 and S2 are false

Answer :-

6. Consider the following statements.

S1: A saturating counter doesn’t work very well when the branch is biased.

S2: A saturating counter saturates at both the maximum and minimum value.

- Only S1 is true
- Only S2 is true
- Both S1 and S2 are true
- Both S1 and S2 are false

Answer :-For AnswerClick Here

7. A *p*-bits *GHR(Global History Register)* records the history of the last ______ branches encountered by the processor.

- 2
^{p} - 2
^{p}-1 - 2
^{p}+1 - p

Answer :-

8. Which of the following branch predictors only considers global history?

- GAp
- GAg
- PAg
- PAp

Answer :-

9. Which bits of the PC should be used to choose the appropriate BHR/GHR in the PAg and PAp predictors?

- Least significant bit
- Most significant bits
- Bits from somewhere in the middle of the address
- Anywhere

Answer :-

10. How many entries are there in the Pattern History Table of the GShare Predictor (where n is the number of PC bits considered and the BHR is m-bits wide)?

- 2
^{(m+n)} - 2
^{m} - 2
^{n} - 2
^{max(m,n)}

Answer :-For AnswerClick Here