Multithread programs have multiple threads of execution within a
process and include the following:
- Programs written in any language that use DECthreads or POSIX
1003.1b services.
- Programs that use language-specific threads services (services
provided directly by the language). Currently, Ada is the only
language with built-in threads services that the debugger supports.
Within the debugger, the term thread or task denotes such a flow of
control regardless of the language or implementation. The debugger's
threads support applies to all such programs.
The debugger lets you display thread information and modify task
characteristics to control thread execution, priority, state
transitions, and so on.
The following paragraphs summarize the multithread features of the
debugger's DECwindows Motif interface. For more information about the
debugger's threads support, see the manual provided with this debugger.
Displaying Information about Threads:
To display information about one or more threads of your program,
choose Views... from the Options menu on the main or optional view
window. When the Views dialog box appears, click the button for
Threads. The Threads View dialog box is displayed.
The thread view gives information about all currently existing
(nonterminated) tasks of your program. The information is updated
whenever the debugger regains control from the program.
The displayed information includes:
- The Thread ID. The arrow in the left column marks the active
thread, that is, the task that runs when you click on the Go or
Step push button.
- The current state of the thread. The running thread (thread in the
RUN state) is the active thread.
- Whether the thread has been put on hold.
- The thread priority.
- The current substate of the thread. The substate helps indicate
the possible cause of a thread's state.
- A debugger path name for the thread object or the address of the
thread object if the debugger cannot symbolize the thread object.
Changing Thread Characteristics:
To modify thread characteristics or the thread environment while
debugging, choose one of the following items from the Threads menu on
the optional view window:
Action Function
------ --------
Abort Requests that the selected thread be terminated at the
next allowed opportunity. The exact effect depends
on the current event facility (language dependent).
For Ada tasks, this is equivalent to executing an
abort statement.
Activate Makes the selected thread the active thread.
Hold Places the selected thread on hold.
Nohold Releases the selected thread from hold.
Make Makes the selected thread the visible task.
Visible
All -> Uses the submenu to:
Abort all threads
Hold all threads
NoHold all threads
To save these modifications for subsequent debugger sessions, choose
Save Options from the Options menu on the main or optional view window.
This creates a new version of the debugger resource file with the new
definitions.