What do run controls run?

 

This tip discusses how TotalView understands what to run when you press a run command such as Go, Step, Out, and so on. For example, what does "stepping a group" actually mean? What happens to processes and threads that aren't in this group? TotalView uses three concepts to decide:

  • TOI-Thread of Interest, which is the thread in the current Process Window.
  • POI-Process of Interest, which is the process in which the current threads execute.
  • GOI-Group of Interest, which is the current group. This can be set using the Scope pulldown in the toolbar.

All three can also be set in the CLI.

These concepts let TotalView determine the scope of what it does when it executes a command.

Associated with these constructs is arena. The arena is the collection of processes, threads, and groups that are affected by a debugging command.

You will set the arena by choosing an item in the Scope pulldown list. In addition, you can set the arena using commands in the menubar. For example, there are eight next commands. The difference between them is the arena; that is, the difference between the next commands is the processes and threads that are the target of what the next command runs.

When TotalView executes a run command, figuring out the arena lets it decide what to do with other threads under its control. Depending on the command, TotalView determines the TOI, POI, or GOI, and then executes the command's action on that thread, process, or group. For example, suppose TotalView steps the current control group:

  • TotalView needs to know what the TOI is so that it can determine which threads are in the lockstep group-TotalView only lets you step a lockstep group.
  • The lockstep group is part of a share group.
  • This share group is also contained in a control group.

By knowing what the TOI is, the GUI also knows what the GOI is. Now, TotalView knows what it will step (the threads in the lockstep group). It also knows what it will allow all other threads in the GOI to run freely while it is stepping the threads in the lockstep group.

To be continued ...


You can find tips that we've already sent out in our Tip Archive

Help us improve these tips!