9.21.1. Hardware breakpoints

To make a watchpoint unit cause hardware breakpoints (on instruction fetches):

  1. Program its address value register with the address of the instruction to be breakpointed.

  2. Program the breakpoint bits for each state as follows:

    For an ARM-state breakpoint

    Set bits [1:0] of the address mask register.

    For a Thumb state breakpoint

    Set bit 0 of the address mask register.

    In either case, clear the remaining bits.

  3. Program the data value register only when you require a data-dependent breakpoint, that is only when you have to match the actual instruction code fetched as well as the address. If the data value is not required, program the data mask register to 0xFFFFFFFF (all bits set). Otherwise program it to 0x00000000.

  4. Program the control value register with PROT[0] = 0.

  5. Program the control mask register with PROT[0]= 0, all other bits set.

  6. When you have to make the distinction between User and non-User mode instruction fetches, program the PROT[1] value and mask bits appropriately.

  7. If required, program the DBGEXT, RANGE, and CHAIN bits in the same way.

  8. Set the mask bits for all unused control values.

    Note

    In monitor mode, you must set the EmbeddedICE-RT disable bit (bit 5 in the Debug Control Register) before changing the register values, and clear it on completion of the programming.

Copyright © 2001, 2003, 2004 ARM Limited. All rights reserved.ARM DDI 0229C
Non-Confidential