xref: /xnu-10002.1.13/osfmk/man/host_load_info.html (revision 1031c584a5e37aff177559b9f69dbd3c8c3fd30a)
1*1031c584SApple OSS Distributions<h2>host_load_info</h2>
2*1031c584SApple OSS Distributions<hr>
3*1031c584SApple OSS Distributions<p>
4*1031c584SApple OSS Distributions<strong>Structure</strong> - Used to present a host's processor load information.
5*1031c584SApple OSS Distributions<h3>SYNOPSIS</h3>
6*1031c584SApple OSS Distributions<pre>
7*1031c584SApple OSS Distributions<strong>#define CPU_STATE_USER     0</strong>
8*1031c584SApple OSS Distributions
9*1031c584SApple OSS Distributions<strong>#define CPU_STATE_SYSTEM   1</strong>
10*1031c584SApple OSS Distributions
11*1031c584SApple OSS Distributions<strong>#define CPU_STATE_IDLE     2</strong>
12*1031c584SApple OSS Distributions
13*1031c584SApple OSS Distributions<strong>struct host_load_info</strong>
14*1031c584SApple OSS Distributions<strong>{</strong>
15*1031c584SApple OSS Distributions       <strong>integer_t</strong>        <var>avenrun</var><strong>[3];</strong>
16*1031c584SApple OSS Distributions       <strong>integer_t</strong>    <var>mach_factor</var><strong>[3];</strong>
17*1031c584SApple OSS Distributions<strong>};</strong>
18*1031c584SApple OSS Distributions
19*1031c584SApple OSS Distributions<strong>typedef struct host_load_info* host_load_info_t;</strong>
20*1031c584SApple OSS Distributions</pre>
21*1031c584SApple OSS Distributions<h3>FIELDS</h3>
22*1031c584SApple OSS Distributions<dl>
23*1031c584SApple OSS Distributions<dt> <var>avenrun</var>
24*1031c584SApple OSS Distributions<dd>
25*1031c584SApple OSS Distributionsload average--average number of runnable processes divided by
26*1031c584SApple OSS Distributionsnumber of CPUs
27*1031c584SApple OSS Distributions<p>
28*1031c584SApple OSS Distributions<dt> <var>mach_factor</var>
29*1031c584SApple OSS Distributions<dd>
30*1031c584SApple OSS DistributionsThe processing resources available to a new thread--the number of
31*1031c584SApple OSS DistributionsCPUs divided by (1 + the number of threads)
32*1031c584SApple OSS Distributions</dl>
33*1031c584SApple OSS Distributions<h3>DESCRIPTION</h3>
34*1031c584SApple OSS Distributions<p>
35*1031c584SApple OSS DistributionsThe <strong>host_load_info</strong> structure defines the loading information
36*1031c584SApple OSS Distributionsavailable about a
37*1031c584SApple OSS Distributionshost.  The information returned is exponential averages over three periods of
38*1031c584SApple OSS Distributionstime: 5, 30 and 60 seconds.
39*1031c584SApple OSS Distributions<h3>RELATED INFORMATION</h3>
40*1031c584SApple OSS Distributions<p>
41*1031c584SApple OSS DistributionsFunctions:
42*1031c584SApple OSS Distributions<a href="host_statistics.html"><strong>host_statistics</strong></a>.
43*1031c584SApple OSS Distributions<p>
44*1031c584SApple OSS DistributionsData Structures:
45*1031c584SApple OSS Distributions<a href="host_basic_info.html"><strong>host_basic_info</strong></a>,
46*1031c584SApple OSS Distributions<a href="host_sched_info.html"><strong>host_sched_info</strong></a>.
47*1031c584SApple OSS Distributions
48