]>
Commit | Line | Data |
---|---|---|
13fec989 A |
1 | <h2>thread_basic_info</h2> |
2 | <hr> | |
3 | <p> | |
4 | <strong>Structure</strong> - Defines basic information for a thread. | |
5 | <h3>SYNOPSIS</h3> | |
6 | <pre> | |
7 | <strong>struct thread_basic_info</strong> | |
8 | <strong>{</strong> | |
9 | <strong>time_value_t</strong> <var>user_time</var><strong>;</strong> | |
10 | <strong>time_value_t</strong> <var>system_time</var><strong>;</strong> | |
11 | <strong>integer_t</strong> <var>cpu_usage</var><strong>;</strong> | |
12 | <strong>policy_t</strong> <var>policy</var><strong>;</strong> | |
13 | <strong>integer_t</strong> <var>run_state</var><strong>;</strong> | |
14 | <strong>integer_t</strong> <var>flags</var><strong>;</strong> | |
15 | <strong>integer_t</strong> <var>suspend_count</var><strong>;</strong> | |
16 | <strong>integer_t</strong> <var>sleep_time</var><strong>;</strong> | |
17 | <strong>};</strong> | |
18 | ||
19 | <strong>typedef struct thread_basic_info* thread_basic_info_t;</strong> | |
20 | </pre> | |
21 | <h3>FIELDS</h3> | |
22 | <dl> | |
23 | <dt> <var>user_time</var> | |
24 | <dd> | |
25 | The total user run time for the thread. | |
26 | <p> | |
27 | <dt> <var>system_time</var> | |
28 | <dd> | |
29 | The total system run time for the thread. | |
30 | <p> | |
31 | <dt> <var>cpu_usage</var> | |
32 | <dd> | |
33 | Scaled <strong>CPU</strong> usage percentage for the thread. | |
34 | <p> | |
35 | <dt> <var>policy</var> | |
36 | <dd> | |
37 | Scheduling policy in effect | |
38 | <p> | |
39 | <dt> <var>run_state</var> | |
40 | <dd> | |
41 | The thread's run state. Possible values are: | |
42 | <dl> | |
43 | <p> | |
44 | <dt> <strong>TH_STATE_RUNNING</strong> | |
45 | <dd> | |
46 | The thread is running normally. | |
47 | <p> | |
48 | <dt> <strong>TH_STATE_STOPPED</strong> | |
49 | <dd> | |
50 | The thread is stopped. | |
51 | <p> | |
52 | <dt> <strong>TH_STATE_WAITING</strong> | |
53 | <dd> | |
54 | The thread is waiting normally. | |
55 | <p> | |
56 | <dt> <strong>TH_STATE_UNINTERRUPTIBLE</strong> | |
57 | <dd> | |
58 | The thread is in an un-interruptible wait state. | |
59 | <p> | |
60 | <dt> <strong>TH_STATE_HALTED</strong> | |
61 | <dd> | |
62 | The thread is halted at a clean point. | |
63 | </dl> | |
64 | <p> | |
65 | <dt> <var>flags</var> | |
66 | <dd> | |
67 | Swap/idle flags for the thread. Possible values are: | |
68 | <dl> | |
69 | <p> | |
70 | <dt> <strong>TH_FLAGS_SWAPPED</strong> | |
71 | <dd> | |
72 | The thread is swapped out. | |
73 | <p> | |
74 | <dt> <strong>TH_FLAGS_IDLE</strong> | |
75 | <dd> | |
76 | The thread is an idle thread. | |
77 | </dl> | |
78 | <p> | |
79 | <dt> <var>suspend_count</var> | |
80 | <dd> | |
81 | The current suspend count for the thread. | |
82 | <p> | |
83 | <dt> <var>sleep_time</var> | |
84 | <dd> | |
85 | The number of seconds that the thread has been sleeping. | |
86 | </dl> | |
87 | <h3>DESCRIPTION</h3> | |
88 | <p> | |
89 | The <strong>thread_basic_info</strong> structure defines the basic information | |
90 | array for threads. | |
91 | The <strong>thread_info</strong> function returns this array for a specified thread. | |
92 | <h3>RELATED INFORMATION</h3> | |
93 | <p> | |
94 | Functions: | |
95 | <a href="thread_info.html"><strong>thread_info</strong></a>. | |
96 | <p> | |
97 | Data Structures: | |
98 | <a href="policy_fifo_info.html"><strong>policy_fifo_info</strong></a>, | |
99 | <a href="policy_rr_info.html"><strong>policy_rr_info</strong></a>, | |
100 | <a href="policy_timeshare_info.html"><strong>policy_timeshare_info</strong></a>. |