Branch prediction is a technique used to:
A) Predict the next instruction in the pipeline
B) Predict the outcome of a conditional branch
C) Predict memory addresses
D) Predict arithmetic results
Answer: B
Speculation in CPU architecture refers to:
A) Predicting memory locations
B) Executing instructions before they are known to be needed
C) Predicting user inputs
D) Delaying instructions for accuracy
Answer: B
The accuracy of branch prediction directly affects:
A) CPU clock speed
B) Pipeline performance
C) Instruction set complexity
D) Memory hierarchy
Answer: B
Which type of branch predictor uses the outcome of previous branches to make predictions?
A) Static branch predictor
B) Dynamic branch predictor
C) Local branch predictor
D) Global branch predictor
Answer: B
What is a key advantage of dynamic branch prediction?
A) Simplicity
B) Low power consumption
C) Higher accuracy
D) Reduced cost
Answer: C
A common technique to handle mispredicted branches is:
A) Pipeline stalling
B) Speculative execution
C) Register renaming
D) Re-fetching the instruction
Answer: B
The two-level adaptive branch prediction scheme uses:
A) Two levels of cache
B) Two levels of history
C) Two levels of memory
D) Two types of instructions
Answer: B
In static branch prediction, the CPU makes decisions based on:
A) The branch history
B) A predefined rule
C) User input
D) Compiler optimization
Answer: B
A common static branch prediction technique is:
A) Always predicting “taken”
B) Always predicting “not taken”
C) Random prediction
D) Both A and B
Answer: D
Which of the following is not a type of dynamic branch predictor?
A) Bimodal predictor
B) Two-level adaptive predictor
C) Gshare predictor
D) Constant predictor
Answer: D
Branch target buffer (BTB) stores:
A) The outcomes of branches
B) The target addresses of branches
C) The branch instructions
D) The results of arithmetic operations
Answer: B
A mispredicted branch results in:
A) Correct program execution
B) A pipeline stall or flush
C) Immediate execution of the next instruction
D) An increase in clock speed
Answer: B
In speculative execution, instructions are executed:
A) After confirming branch outcome
B) Before confirming branch outcome
C) Only when required
D) At the end of the program
Answer: B
Which type of branch prediction relies on global branch history?
A) Local predictor
B) Global predictor
C) Bimodal predictor
D) Hybrid predictor
Answer: B
The purpose of speculation in modern processors is to:
A) Increase memory bandwidth
B) Reduce the number of instructions
C) Improve instruction-level parallelism
D) Decrease CPU power consumption
Answer: C
Which of the following is a challenge with speculative execution?
A) Incorrect memory allocation
B) Increased memory latency
C) Handling mispredictions and rollback
D) Decreased instruction throughput
Answer: C
A hybrid branch predictor:
A) Uses both static and dynamic techniques
B) Combines two dynamic prediction strategies
C) Predicts based on compiler hints
D) Always uses a single prediction strategy
Answer: B
Branch prediction is crucial in:
A) Superscalar processors
B) Single-cycle processors
C) In-order execution
D) Memory-mapped I/O
Answer: A
A two-bit predictor helps reduce mispredictions by:
A) Using two predictions at a time
B) Making predictions based on two previous outcomes
C) Only predicting twice per branch
D) Storing two branch addresses
Answer: B
Branch prediction helps to reduce:
A) Register dependency
B) Data hazards
C) Control hazards
D) Cache misses
Answer: C
A highly accurate branch predictor will lead to:
A) Increased pipeline hazards
B) Fewer pipeline flushes
C) Reduced instruction parallelism
D) More cache misses
Answer: B
The branch prediction mechanism is closely tied to:
A) Cache hierarchy
B) Instruction prefetching
C) ALU performance
D) Data forwarding
Answer: B
Which predictor is considered simpler but less accurate?
A) Dynamic predictor
B) Two-level adaptive predictor
C) Static predictor
D) Gshare predictor
Answer: C
When a branch is mispredicted, the CPU must:
A) Execute it again
B) Flush the pipeline
C) Change the instruction set
D) Disable speculation
Answer: B
A return address stack (RAS) is used to predict the:
A) Outcome of branches
B) Address of function returns
C) Address of memory loads
D) CPU cycle time
Answer: B
A benefit of speculative execution is:
A) Higher instruction-level parallelism
B) Lower memory access times
C) Easier debugging
D) Reduced power consumption
Answer: A
Which of the following techniques can be used to recover from a mispredicted branch?
A) Register renaming
B) Re-execution of the correct path
C) Memory interleaving
D) Superscalar execution
Answer: B
Branch prediction helps in improving performance by:
A) Reducing memory accesses
B) Reducing control hazards
C) Increasing cache hits
D) Reducing ALU operations
Answer: B
A bimodal predictor is based on:
A) A single history table
B) Two separate prediction strategies
C) Cache-based predictions
D) A neural network
Answer: A
The Gshare branch predictor uses:
A) A hash of the global branch history
B) Only local branch history
C) Compiler-based hints
D) Static prediction
Answer: A
The main goal of speculative execution is to:
A) Reduce branch misprediction penalties
B) Improve instruction cache performance
C) Avoid memory access delays
D) Reduce power consumption
Answer: A
What happens when speculative execution is incorrect?
A) Instructions are permanently committed
B) Instructions are discarded
C) Cache memory is flushed
D) Branch target buffer is reset
Answer: B
A branch predictor aims to:
A) Speed up arithmetic computations
B) Reduce pipeline stalls
C) Increase cache size
D) Improve instruction decoding
Answer: B
One way to handle speculative execution in multi-core systems is by:
A) Delaying all branch instructions
B) Using branch prediction in each core
C) Centralizing speculation decisions
D) Disabling speculation
Answer: B
A key challenge of branch prediction is:
A) High power consumption
B) Handling indirect branches
C) Improving clock frequency
D) Reducing instruction width
Answer: B
The speculative execution of instructions is most effective when:
A) There are no branch instructions
B) Instruction-level parallelism is high
C) The processor has a single pipeline
D) Memory is limited
Answer: B
Which component helps in deciding whether to speculate a branch?
A) Arithmetic Logic Unit (ALU)
B) Branch predictor
C) Cache controller
D) Instruction fetch unit
Answer: B
A branch that is frequently mispredicted can cause:
A) Increased instruction throughput
B) Pipeline flushing and performance degradation
C) Reduced memory bandwidth
D) Higher clock speeds
Answer: B
A saturating counter is used in:
A) Two-bit branch prediction schemes
B) Cache management
C) Speculative execution
D) Load/store units
Answer: A
Branch prediction works in tandem with:
A) Memory paging
B) Instruction prefetching
C) Cache coherence protocols
D) Clock speed adjustment
Answer: B
Which predictor tries to avoid stalls by predicting indirect branch targets?
A) Static predictor
B) Indirect branch predictor
C) Return address predictor
D) Two-bit predictor
Answer: B
The effectiveness of branch prediction increases when:
A) Control dependencies are low
B) Data dependencies are high
C) Instructions are executed in sequence
D) The processor is single-core
Answer: A
The branch history table (BHT) stores:
A) Branch instruction addresses
B) Global history of branches
C) Cache access patterns
D) Local history of branches
Answer: D
A speculative instruction is typically committed only when:
A) The branch prediction is verified as correct
B) All instructions are executed
C) It reaches the end of the pipeline
D) Memory access is completed
Answer: A
Read More Computer Architecture MCQs
- SET 1: Computer Architecture MCQs
- SET 2: Computer Architecture MCQs
- SET 3: Computer Architecture MCQs
- SET 4: Computer Architecture MCQs
- SET 5: Computer Architecture MCQs
- SET 6: Computer Architecture MCQs
- SET 7: Computer Architecture MCQs
- SET 8: Computer Architecture MCQs
- SET 9: Computer Architecture MCQs
- Introduction to Computer Architecture MCQs
- Basic Components of a Computer System MCQs
- CPU Organization MCQs
- Instruction Set Architecture (ISA) MCQs
- Microarchitecture MCQs
- Memory Hierarchy MCQs
- Cache Memory MCQs
- Input/Output Organization MCQs
- Bus Architecture MCQs
- Performance Metrics MCQs
- Parallelism in Computer Architecture MCQs
- Multicore and Multiprocessor Systems MCQs
- Control Unit Design MCQs
- Pipeline Hazards MCQs
- Branch Prediction and Speculation MCQs
- Arithmetic and Logic Operations MCQs
- Memory Management MCQs
- Power and Energy Efficiency MCQs
- Advanced Topics MCQs
- Emerging Trends