Lines Matching +full:- +full:- +full:max +full:- +full:time
13 from time import sleep, strftime
20 klockstat -d 5 # trace for 5 seconds only
21 klockstat -i 5 # display stats every 5 seconds
22 klockstat -p 123 # trace locks for PID 123
23 klockstat -t 321 # trace locks for TID 321
24 klockstat -c pipe_ # display stats only for lock callers with 'pipe_' substring
25 klockstat -S acq_count # sort lock acquired results on acquired count
26 klockstat -S hld_total # sort lock held results on total held time
27 klockstat -S acq_count,hld_total # combination of above
28 klockstat -n 3 # display 3 locks
29 klockstat -s 3 # display 3 levels of stack
50 # -EFAULT in get_stackid normally means the stack-trace is not available,
52 return (stack_id < 0) and (stack_id != -errno.EFAULT)
60 time_group.add_argument("-d", "--duration", type=int,
62 time_group.add_argument("-i", "--interval", type=int,
64 parser.add_argument("-n", "--locks", type=int, default=99999999,
66 parser.add_argument("-s", "--stacks", type=int, default=1,
68 parser.add_argument("-c", "--caller",
70 parser.add_argument("-S", "--sort",
71 help="sort data on <aq_field,hd_field>, fields: acq_[max|total|count] hld_[max|total|count]")
72 parser.add_argument("-p", "--pid",
74 parser.add_argument("-t", "--tid",
76 parser.add_argument("--stack-storage-size", default=16384,
190 static void update_aq_report_max(int *stackid, u64 time)
192 u64 *max;
194 max = aq_report_max.lookup(stackid);
195 if (!max || *max < time)
196 aq_report_max.update(stackid, &time);
199 static void update_hl_report_max(int *stackid, u64 time)
201 u64 *max;
203 max = hl_report_max.lookup(stackid);
204 if (!max || *max < time)
205 hl_report_max.update(stackid, &time);
210 u64 *count, *time;
216 time = aq_report_total.lookup(stackid);
217 if (!time) {
220 *time = *time + delta;
226 u64 *count, *time;
232 time = hl_report_total.lookup(stackid);
233 if (!time) {
236 *time = *time + delta;
263 .depth = *depth - 1,
278 int val = cur - *aq;
303 *depth -= 1;
323 u64 val = cur - *held;
410 exit(-1)
418 has_enomem = has_enomem or (k.value == -errno.ENOMEM)
475 print("Tracing lock events... Hit Ctrl-C to end.")
500 print("\n%40s %10s %6s %10s %10s" % ("Caller", "Avg Spin", "Count", "Max spin", "Total spin"))
504 print("\n%40s %10s %6s %10s %10s" % ("Caller", "Avg Hold", "Count", "Max hold", "Total hold"))
519 enomem_str = " Consider increasing --stack-storage-size."