bkpt

Breakpoint (A32)

BKPT #<imm>

Causes a software breakpoint.

Details

Causes a software breakpoint exception (BKPT) to be raised. The immediate operand is encoded in the instruction as a 16-bit value for debugging purposes but does not affect processor state directly. This is an A32 instruction that triggers a breakpoint interrupt; execution cannot proceed past this instruction without debugger intervention.

Pseudocode Operation

GenerateException(Breakpoint)
PC ← (unchanged by architecture, debugger determines resumption)

Example

BKPT #16

Encoding

Binary Layout
cond
00010
01
0
imm12
0111
imm4
 
Format System
Opcode 0x01200070
Extension A32 (Base)

Operands

  • imm
    ID

Reference (Arm AArch32 ISA)

Instruction Forms

Encoding Instruction ISA Bit pattern
0x01200070 BKPT{<q>} {#}<imm> A32 cond | 00010 | 01 | 0 | imm12 | 0111 | imm4
0xBE00 BKPT{<q>} {#}<imm> T32 10111110 | imm8

Description

Breakpoint causes a Breakpoint Instruction exception. Breakpoint is always unconditional, even when inside an IT block.

Operation

EncodingSpecificOperations();
AArch32.SoftwareBreakpoint(imm16);