Unlimited Flash Breakpoints

J-Link software comes with an additional features, called Unlimited Flash Breakpoints. Unlimited Flash Breakpoints allow the user to set an unlimited number of breakpoints when debugging in flash memory.

Overview

J-Link software comes with an additional feature, called Unlimited Flash Breakpoints. Unlimited Flash Breakpoints allow the user to set an unlimited number of breakpoints when debugging in flash memory. Without this feature, the number of breakpoints which can be set in flash is limited to the number of hardware breakpoints supported by the debug unit of the CPU (2 on ARM 7/9, 4-6 on Cortex-M).

J-Link's "Unlimited flash breakpoints" works in both internal and external flash, even memory mapped QSPI flashes! J-Link has a smart strategy of using hardware breakpoints as much as possible, but once the CPU runs out of hardware breakpoints, J-Link automatically uses Flash breakpoints (J-Link PLUS, J-Link ULTRA+ or J-Link PRO required).

J-Link's "Unlimited flash breakpoints" actually work even in situations where hardware breakpoints can not be used, such as external memory or memory mapped QSPI flashes that are outside of the area on which hardware breakpoints can be set. On most Cortex-M3 and M4 devices, hardware breakpoints can not be used on external memory, "J-Link's Unlimited flash breakpoints" can.

flash breakpoints

System Requirements

Supported OS
WindowsMicrosoft Windows (x86/x64)
macOSmacOS (x86/Apple Silicon)
LinuxLinux (x86/x64/Arm)

How Breakpoints Work

There are basically 2 types of breakpoints in a computer system: Hardware breakpoints and software breakpoints. Hardware breakpoints require a dedicated hardware unit for every breakpoint. In other words, the hardware dictates how many hardware breakpoints can be set simultaneously. ARM7, ARM9, and some devices implemented with the Cortex-M0+ cores have 2 breakpoint units (called "watchpoint units" in ARM's documentation), allowing 2 hardware breakpoints to be set. Hardware breakpoints do not require modification of the program code. Software breakpoints are different: The debugger modifies the program and replaces the breakpointed instruction with a special value. Additional software breakpoints do not require additional hardware units in the processor, since instructions are replaced inside the code to indicate the breakpoint. This is a standard procedure that most debuggers are capable of, however, it requires the program to be located in RAM.