1 10/17/84  sample_refs
 2 
 3 Syntax as a command:  sample_refs -control_args
 4 
 5 
 6 Function:  periodically samples the machine registers to determine
 7 which segments a process is referencing.  Three output segments are
 8 produced that are interpretable by the print_sample_refs command.
 9 
10 
11 Control arguments:
12 -segment name, -sm name
13    specifies the names to be given the three output segments; name can
14    be either an absolute or relative pathname.  If name does not end
15    with the suffix srf, it is assumed.  The output segments are named
16    as follows:
17       (entry portion of) name.srf1
18       (entry portion of) name.srf2
19       (entry portion of) name.srf3
20 
21 
22    The default places the output segments in your working directory,
23    with entrynames as follows:
24       mm/dd/yy__hhmm.m_zzz_www.srf1
25       mm/dd/yy__hhmm.m_zzz_www.srf2
26       mm/dd/yy__hhmm.m_zzz_www.srf3
27 -time N, -tm N
28    specifies the rate in milliseconds at which the process is sampled.
29    N must be a positive integer.  (Default: N = 1000; i.e., the
30    process is sampled once every second)
31 
32 
33 Notes:  You are allowed one active invocation per process--a second
34 invocation terminates the first, whereupon the new invocation proceeds
35 normally.
36 
37 You can sample the machine registers only when the process is running
38 in a ring other than 0.  For example, a process using a total of 100
39 seconds of processor time and sample_refs running at the default sample
40 rate and recording 23 samples indicate that 77 seconds of processor
41 time were spent in ring 0.
42 
43 Under certain conditions, the contents of one of the machine registers
44 sampled--the Temporary Segment Register (TSR)--can be invalid.  This
45 invalidity is noted, but does not necessarily indicate that the process
46 is in error.
47 
48 
49 At the maximum sample rate (one millisecond) execution time can be
50 increased by as much as 50 percent.  Using a one-second sample rate,
51 the increase in execution time is negligible.
52 
53 The accuracy of sample rates less than 1000 milliseconds is not
54 guaranteed due to load factors.  The accuracy of such sample rates
55 increases with load.
56 
57 If the process being sampled is terminated without an invocation of
58 sample_refs with the -reset option, interpretable output segments are
59 still produced; however, both the off-time and the last recorded sample
60 may be invalid.