Go to main content

Oracle® Solaris Modular Debugger Guide

Exit Print View

Updated: October 2019
 
 

MDB Commands

A command is one of the following:

pipeline [ ! word ... ] [ ; ]

A simple-command or pipeline can be optionally followed by the exclamation point or bang character (!), indicating that the debugger should open a pipe(2). The standard output of the last dcmd in the MDB pipeline is sent to an external process created by executing $SHELL –c followed by the string formed by concatenating the words after the ! character. For more details, refer to Shell Escapes in MDB.

expression pipeline [ ! word ... ] [ ; ]

A simple-command or pipeline can be prefixed with an expression. Before execution of the pipeline, any occurrence of the dot or period character (.) in the pipeline is set to the value of the expression.

expression1, expression2 pipeline [ ! word ... ] [ ; ]

A simple-command or pipeline can be prefixed with two expressions. The value of the first expression is the new value of dot. The value of the second expression is a repeat count for the first dcmd in the pipeline. The first dcmd in the pipeline is executed expression2 times before the next dcmd in the pipeline is executed. The repeat count applies only to the first dcmd in the pipeline.

, expression pipeline [ ! word ... ] [ ; ]

If the first expression is omitted, dot is not modified. The value of the second expression (the expression after the comma character) is used exactly the same way as expression2 above.

expression [ ! word ... ] [ ; ]

A command can consist of only an arithmetic expression. The value of the expression is the new value of dot. The previous dcmd pipeline is re-executed using the new value of dot.

expression1, expression2 [ ! word ... ] [ ; ]

A command can consist of only a dot expression and repeat count expression. The value of expression1 is the new value of dot. The previous dcmd pipeline is re-executed expression2 times using the new value of dot.

, expression [ ! word ... ] [ ; ]

If the first expression is omitted, dot is not modified. The value of the second expression (the expression after the comma character) is used exactly the same way as expression2 above.

! word ... [ ; ]

If the command begins with the ! character, no dcmds are executed. The debugger executes $SHELL –c followed by the string formed by concatenating the words after the ! character.