For example, to set a breakpoint at the library function SendMessage:
break SendMessage
Memorypoints require that an additional kernel module to be loaded before the feature may be used. This module is supplied in source form and is in the source directory src/modules/bp. In that directory, issue the make command to build the module bp.o. After that is completed, install the module using the command:
insmod bp.o
You must be the superuser to issue the previous command. After the module bp.o is installed in the kernel, memorypoints may be set.
For example, to stop when the variable x is accessed:
mp x
You may disable and enable breakpoints and memorypoints using the commands:
enable bp NUM
enable mp NUM
disable bp NUM
disable mp NUM
Number is the number that the debugger assigned to the breakpoint or memorypoint. The command, ``info break'', will give you a listing of all the breakpoints and memorypoints.
Additionally, breakpoints may have conditions attached to them.
For example, to stop at breakpoint 1 only if the contents of AVariable has the value 10:
condition 1 *AVariable = 10
To resume execution, you may use one of four commands. ``c'' or ``cont'' stands for continue and resumes execution of the program until the next breakpoint or memorypoint. ``s'' or ``step'' cause the next instruction to be executed. ``n'' or ``next'' is similar to step, but if the next instruction is a ``call'' instruction, execution is continued until the call returns. Finally, ``trace'' allows you to watch every single instruction as it executes.
You may also force execution of a library or native application function.
For example, to execute the solitaire program:
WinExec(``sol.exe'', 0)