Hardware Security
Which is NOT used as a countermeasure to speculative-execution vulnerabilities such as Spectre?
- AInserting barrier instructions that stop speculation after dangerous branches
- BRaising the CPU clock frequency
- CMasking array indices into range so out-of-bounds data cannot be read speculatively
Show answer and explanation
Answer: B. Raising the CPU clock frequency
Countermeasures to Spectre include inserting instructions that halt speculation after conditional branches (such as x86 lfence), masking indices so out-of-range data cannot be read, coding patterns that prevent abuse of indirect branch prediction (such as retpoline) and CPU microcode updates that control predictors. Disabling all speculation would cripple performance, so these measures are usually applied only at dangerous locations.
- A. This is a real countermeasure.
- B. Correct. Frequency is unrelated to speculation.
- C. This is a real countermeasure.