Download PGI Tools Guide

Transcript
If the wait command appears in a ‘do’ clause, the current thread is added to the wait set of the
current process.
Pgdbg [all] 0> [*] break func if (glob!=0) do {set f = 0; c; wait}
‘if’ conditionals and ‘do’ bodies cannot be parallelized with prefix p/t-sets.
Example:
pgdbg [all] 0> break func if (glob!=0) do {[*] set f = 0} ILLEGAL
This is illegal. The body of a ‘do’ statement cannot be parallelized.
1.14.17 Parallel Statements
This section describes how to use a p/t-set to define a statement across multiple threads and
processes.
1.14.17.1 Parallel Compound/Block Statements
Example:
i)pgdbg [all] 0>[*] break main;
cont; wait; print f@11@i
ii) pgdbg [all] 0>[*] break main;
[*]cont; [*]wait; [*]print f@11@i
(i) and (ii) are equivalent. Each command in a compound statement is executed in order. The
target p/t-set is broadcast to all statements. Use the wait command if subsequent commands
require threads to be stopped (the print command above). The commands in a compound
statement are executed together in order.
The threadwait and procwait environment variables do not affect how commands within a
compound statement are processed. These pgienv environment variables describe to PGDBG
under what conditions (runstate of program) it should accept the next (compound) statement.
1.14.17.2 Parallel If, Else Statements
This section describes parallel 'if' and 'else' statements.
Example:
The PGDBG Debugger
121