csdb

Consumption of Speculative Data Barrier (A32)

CSDB

Prevents speculative data consumption (v8.0).

Details

Consumption of Speculative Data Barrier (v8.0) prevents the CPU from using speculatively-loaded data in subsequent operations, protecting against attacks that exploit speculative data consumption side channels. Instructions following CSDB cannot use data speculatively loaded before this barrier. Available in A32 instruction set; does not modify condition flags.

Pseudocode Operation

// Prevent consumption of speculatively-loaded data
ConsumptionBarrier()
// Subsequent instructions cannot use data obtained through speculative execution prior to this barrier

Example

CSDB

Encoding

Binary Layout
cond
00110
0
10
0000
1
1
1
1
000000010100
 
Format System Hint
Opcode 0x0320F014
Extension A32 (v8.0)

Operands

Reference (Arm AArch32 ISA)

Instruction Forms

Encoding Instruction ISA Bit pattern
0x0320F014 CSDB{<c>}{<q>} A32 cond | 00110 | 0 | 10 | 0000 | 1 | 1 | 1 | 1 | 000000010100
0xF3AF8014 CSDB{<c>}{<q>} T32 111100111010 | 1 | 1 | 1 | 1 | 10 | 0 | 0 | 0 | 000 | 0001 | 0100

Description

Consumption of Speculative Data Barrier is a memory barrier that controls speculative execution and data value prediction. No instruction other than branch instructions and instructions that write to the PC appearing in program order after the CSDB can be speculatively executed using the results of any:

Operation

if ConditionPassed() then
    EncodingSpecificOperations();

    ConsumptionOfSpeculativeDataBarrier();