Sets hardware breakpoint and activates it. 80x86 compatible processors support 4 hardware breakpoints. If all available slots are in use, function asks user to delete one of active breakpoints. Returns 0 on success and -1 on error or if user cancelled action. It is allowed to call Sethardwarebreakpoint "on the fly", i.e. when debugged application is running.
Note that hardware breakpoints are not supported by Windows 95 and Windows 98. To assure that you can use this function, call Plugingetvalue(VAL_HARDBP).
int Sethardwarebreakpoint(ulong addr,int size,int type);
Parameters:
addr - address of breakpoint;
size - size of memory covered by hardware breakpoint (1, 2 or 4 bytes). addr must be aligned on the corresponding boundary. This parameter must be 1 in case of breakpoint on execution;
type - type of hardware breakpoint:
HB_CODE | Active on command execution |
HB_ACCESS | Active on read/write access |
HB_WRITE | Active on write access |
See also: Hardbreakpoints, Deletehardwarebreakpoint, Deletehardwarebreakbyaddr