• Home
  • Raw
  • Download

Lines Matching refs:procs

180     struct proc_info **procs;  in main()  local
245 procs = calloc(num_procs, sizeof(struct proc_info*)); in main()
246 if (procs == NULL) { in main()
252 procs[i] = malloc(sizeof(struct proc_info)); in main()
253 if (procs[i] == NULL) { in main()
257 procs[i]->pid = pids[i]; in main()
258 pm_memusage_zero(&procs[i]->usage); in main()
259 pm_memusage_pswap_init_handle(&procs[i]->usage, p_swap); in main()
268 error = pm_process_usage_flags(proc, &procs[i]->usage, flags_mask, in main()
272 error = pm_process_workingset(proc, &procs[i]->usage, 0); in main()
283 if (ws != WS_RESET && procs[i]->usage.swap) { in main()
296 if (procs[i]->usage.vss) { in main()
297 procs[j++] = procs[i]; in main()
299 free(procs[i]); in main()
304 qsort(procs, num_procs, sizeof(procs[0]), compfn); in main()
345 if (getprocname(procs[i]->pid, cmdline, (int)sizeof(cmdline)) < 0) { in main()
350 free(procs[i]); in main()
354 total_pss += procs[i]->usage.pss; in main()
355 total_uss += procs[i]->usage.uss; in main()
356 total_swap += procs[i]->usage.swap; in main()
358 printf("%5d ", procs[i]->pid); in main()
362 procs[i]->usage.rss / 1024, in main()
363 procs[i]->usage.pss / 1024, in main()
364 procs[i]->usage.uss / 1024 in main()
368 procs[i]->usage.vss / 1024, in main()
369 procs[i]->usage.rss / 1024, in main()
370 procs[i]->usage.pss / 1024, in main()
371 procs[i]->usage.uss / 1024 in main()
378 pm_memusage_pswap_get_usage(&procs[i]->usage, &su); in main()
379 printf("%6zuK ", procs[i]->usage.swap / 1024); in main()
384 pm_memusage_pswap_free(&procs[i]->usage); in main()
394 free(procs[i]); in main()
397 free(procs); in main()