The cont Command

Use the cont (dbx) and continue (gdb) command without a parameter value to resume process execution until a breakpoint, a signal , an error, or normal process termination is encountered. Specify a signal parameter value to send an operating system signal to the process.

DBX Mode

 

cont_command

        : cont [ in loc ]

        | cont [ signal ] [ to_source_line ]

        | number_expression cont [ signal ]

        | conti to address_expression

 

to_source_line

        : to line_specifier

 

number_expression

        : expression

 

signal

        : integer_constant

        | signal_name

GDB Mode

 

cont_command

        : continue [number_expression]

        | until [place_detector]

 

When you use the cont (dbx) and continue (gdb) command, the debugger resumes execution of the entire process.

In the following example, a cont (dbx) / continue (gdb) command resumes process execution after it was suspended by a breakpoint.

DBX Mode

 

(idb) list 195:7

>   195     nodeList.append(new IntNode(3)); {static int somethingToReturnTo; somethingToReturnTo++; }

    196

    197     IntNode* newNode2 = new IntNode(4);

    198     nodeList.append(newNode2); {static int somethingToReturnTo; somethingToReturnTo++; }

    199

    200     CompoundNode* cNode2 = new CompoundNode(10.123, 5);

    201     nodeList.append(cNode2); {static int somethingToReturnTo; somethingToReturnTo++; }

(idb) stop at 200

[#2: stop at "src/x_list.cxx":200]

(idb) cont

[2] stopped at [int main(void):200 0x08053214]

    200     CompoundNode* cNode2 = new CompoundNode(10.123, 5);

GDB Mode

 

(idb) list 195,+7

195     nodeList.append(new IntNode(3)); {static int somethingToReturnTo; somethingToReturnTo++; }

196

197     IntNode* newNode2 = new IntNode(4);

198     nodeList.append(newNode2); {static int somethingToReturnTo; somethingToReturnTo++; }

199

200     CompoundNode* cNode2 = new CompoundNode(10.123, 5);

201     nodeList.append(cNode2); {static int somethingToReturnTo; somethingToReturnTo++; }

(idb) break 200

Breakpoint 2 at 0x8053214: file src/x_list.cxx, line 200.

(idb) continue

Continuing.

Breakpoint 2, main () at src/x_list.cxx:200

200     CompoundNode* cNode2 = new CompoundNode(10.123, 5);

DBX Mode

 

The signal parameter value can be either a signal number or a string name (for example, SIGSEGV). The default is 0, which allows the process to continue execution without specifying a signal. If you specify a signal parameter value, the process continues execution with that signal.

Use the in argument to continue until the named function is reached. The function name must be valid. If the function name is overloaded and you do not resolve the scope of the function in the command line, the debugger prompts you with the list of overloaded functions bearing that name from which to choose.

Use the to parameter value to resume execution and then halt when the specified source line is reached. The form of the optional to parameter must be either:

You can repeat the cont command (n +1) times by entering n cont.

You can set a one-time breakpoint on an instruction address before continuing by entering conti to address_expression.

GDB Mode

Use the optional argument number_expression of the continue command to specify a further number of times to ignore a breakpoint at this location.

The until command continues running until a source line past the current line, in the current stack frame, is reached. This command is used to avoid single stepping through a loop more than once.

If place_detector is specified the command continues running until either the specified location is reached, or the current stack frame returns.