4.1 __breakpoint intrinsic

This intrinsic inserts a BKPT instruction into the instruction stream generated by the compiler.

To use this intrinsic, your source file must contain #include <arm_compat.h>. This is only available for targets in AArch32 state.

It enables you to include a breakpoint instruction in your C or C++ code.

Syntax

void __breakpoint(int val)

Where:

val

is a compile-time constant integer whose range is:

0 ... 65535
if you are compiling source as A32 code
0 ... 255
if you are compiling source as T32 code.

Errors

The __breakpoint intrinsic is not available when compiling for a target that does not support the BKPT instruction. The compiler generates an error in this case.

Example

void func(void)
{
    ...
    __breakpoint(0xF02C);
    ...
}
Non-ConfidentialPDF file icon PDF version100067_0609_00_en
Copyright © 2014–2017 Arm Limited (or its affiliates). All rights reserved.