Lines Matching refs:proc
181 static bool count_swap_offsets(const ProcessRecord& proc, in count_swap_offsets() argument
183 const std::vector<uint64_t>& swp_offs = proc.SwapOffsets(); in count_swap_offsets()
186 std::cerr << "swap offset " << off << " is out of bounds for process: " << proc.pid() in count_swap_offsets()
192 std::cerr << "swap offset " << off << " ref count overflow in process: " << proc.pid() in count_swap_offsets()
226 static void print_process_record(std::stringstream& ss, ProcessRecord& proc) { in print_process_record() argument
227 ss << ::android::base::StringPrintf("%5d ", proc.pid()); in print_process_record()
229 ss << ::android::base::StringPrintf("%5d ", proc.oomadj()); in print_process_record()
234 proc.Wss().rss / 1024, proc.Wss().pss / 1024, in print_process_record()
235 proc.Wss().uss / 1024); in print_process_record()
239 proc.Usage().vss / 1024, proc.Usage().rss / 1024, in print_process_record()
240 proc.Usage().pss / 1024, proc.Usage().uss / 1024); in print_process_record()
242 ss << ::android::base::StringPrintf("%6" PRIu64 "K ", proc.Usage().swap / 1024); in print_process_record()
243 ss << ::android::base::StringPrintf("%6" PRIu64 "K ", proc.proportional_swap() / 1024); in print_process_record()
244 ss << ::android::base::StringPrintf("%6" PRIu64 "K ", proc.unique_swap() / 1024); in print_process_record()
246 ss << ::android::base::StringPrintf("%6" PRIu64 "K ", (proc.zswap() / 1024)); in print_process_record()
254 for (auto& proc : procs) { in print_processes() local
255 total_pss += show_wss ? proc.Wss().pss : proc.Usage().pss; in print_processes()
256 total_uss += show_wss ? proc.Wss().uss : proc.Usage().uss; in print_processes()
258 proc.CalculateSwap(swap_offset_array, zram_compression_ratio); in print_processes()
259 total_swap += proc.Usage().swap; in print_processes()
260 total_pswap += proc.proportional_swap(); in print_processes()
261 total_uswap += proc.unique_swap(); in print_processes()
263 total_zswap += proc.zswap(); in print_processes()
267 print_process_record(ss, proc); in print_processes()
268 ss << proc.cmdline() << std::endl; in print_processes()
460 ProcessRecord proc(pid, show_wss, pgflags, pgflags_mask); in main() local
461 if (!proc.valid()) { in main()
475 uint64_t vss = show_wss ? proc.Wss().vss : proc.Usage().vss; in main()
480 !count_swap_offsets(proc, swap_offset_array)) { in main()
485 procs.emplace_back(std::move(proc)); in main()