/system/unwinding/libunwindstack/utils/ |
D | ProcessTracer.h | 29 ProcessTracer(pid_t pid, bool is_tracing_threads); 40 pid_t pid() const { return pid_; } in pid() 42 const std::set<pid_t>& tids() const { return tids_; } in tids() 52 bool Detach(pid_t tid); 54 bool Attach(pid_t tid); 67 static bool UsesSharedLibrary(pid_t pid, const std::string& desired_elf_name); 70 static bool ProcIsInDesiredElf(pid_t tid, const std::string& desired_elf_name); 76 static constexpr pid_t kNoThreadAttached = -2; 77 static constexpr pid_t kKillFailed = -1; 78 static constexpr pid_t kPtraceFailed = -1; [all …]
|
D | PidUtils.h | 32 bool Quiesce(pid_t pid); 34 bool Attach(pid_t pid); 36 bool Detach(pid_t pid); 38 bool WaitForPidState(pid_t pid, const std::function<PidRunEnum()>& state_check_func); 40 bool WaitForPidStateAfterAttach(pid_t pid, const std::function<PidRunEnum()>& state_check_func);
|
D | PidUtils.cpp | 30 static bool Exited(pid_t pid) { in Exited() 32 pid_t wait_pid = waitpid(pid, &status, WNOHANG); in Exited() 47 bool Quiesce(pid_t pid) { in Quiesce() 74 bool Attach(pid_t pid) { in Attach() 97 bool Detach(pid_t pid) { in Detach() 107 bool WaitForPidState(pid_t pid, const std::function<PidRunEnum()>& state_check_func) { in WaitForPidState() 131 bool WaitForPidStateAfterAttach(pid_t pid, const std::function<PidRunEnum()>& state_check_func) { in WaitForPidStateAfterAttach()
|
/system/core/libprocessgroup/include/processgroup/ |
D | processgroup.h | 36 bool CgroupGetAttributePathForTask(const std::string& attr_name, pid_t tid, std::string* path); 38 bool SetTaskProfiles(pid_t tid, const std::vector<std::string>& profiles, 40 bool SetProcessProfiles(uid_t uid, pid_t pid, const std::vector<std::string>& profiles); 45 bool SetTaskProfiles(pid_t tid, std::initializer_list<std::string_view> profiles, 47 bool SetProcessProfiles(uid_t uid, pid_t pid, std::initializer_list<std::string_view> profiles); 49 bool SetTaskProfiles(pid_t tid, std::span<const std::string_view> profiles, 51 bool SetProcessProfiles(uid_t uid, pid_t pid, std::span<const std::string_view> profiles); 58 bool SetProcessProfilesCached(uid_t uid, pid_t pid, const std::vector<std::string>& profiles); 71 int killProcessGroup(uid_t uid, pid_t initialPid, int signal); 75 int killProcessGroupOnce(uid_t uid, pid_t initialPid, int signal); [all …]
|
/system/core/libprocessgroup/ |
D | task_profiles.h | 39 virtual bool GetPathForProcess(uid_t uid, pid_t pid, std::string* path) const = 0; 40 virtual bool GetPathForTask(pid_t tid, std::string* path) const = 0; 59 bool GetPathForProcess(uid_t uid, pid_t pid, std::string* path) const override; 60 bool GetPathForTask(pid_t tid, std::string* path) const override; 79 virtual bool ExecuteForProcess(uid_t, pid_t) const { return false; } in ExecuteForProcess() argument 85 virtual bool IsValidForProcess(uid_t, pid_t) const { return false; } in IsValidForProcess() argument 86 virtual bool IsValidForTask(pid_t) const { return false; } in IsValidForTask() argument 98 bool ExecuteForProcess(uid_t uid, pid_t pid) const override; 99 bool ExecuteForTask(pid_t tid) const override; 111 bool ExecuteForTask(pid_t tid) const override; [all …]
|
/system/memory/libmemunreachable/ |
D | ThreadCapture.cpp | 55 static char* pid_to_str(char* buf, size_t len, pid_t pid) { in pid_to_str() 76 ThreadCaptureImpl(pid_t pid, Allocator<ThreadCaptureImpl>& allocator); 81 bool ReleaseThread(pid_t tid); 83 void InjectTestFunc(std::function<void(pid_t)>&& f) { inject_test_func_ = f; } in InjectTestFunc() 86 int CaptureThread(pid_t tid); 87 bool ReleaseThread(pid_t tid, unsigned int signal); 88 int PtraceAttach(pid_t tid); 89 void PtraceDetach(pid_t tid, unsigned int signal); 90 bool PtraceThreadInfo(pid_t tid, ThreadInfo& thread_info); 92 allocator::map<pid_t, unsigned int> captured_threads_; [all …]
|
D | ThreadCapture.h | 27 pid_t tid; 32 using TidList = allocator::vector<pid_t>; 39 ThreadCapture(pid_t pid, Allocator<ThreadCapture> allocator); 45 bool ReleaseThread(pid_t tid); 47 void InjectTestFunc(std::function<void(pid_t)>&& f);
|
/system/extras/iotop/ |
D | tasklist.cpp | 40 pid_t pid = atoi(entry->d_name); in ScanPidsInDir() 48 bool TaskList::Scan(std::map<pid_t, std::vector<pid_t>>& tgid_map) { in Scan() argument 51 return ScanPidsInDir("/proc", [&tgid_map](pid_t tgid) { in Scan() 52 std::vector<pid_t> pid_list; in Scan() 59 bool TaskList::ScanPid(pid_t tgid, std::vector<pid_t>& pid_list) { in ScanPid() 62 return ScanPidsInDir(filename, [&pid_list](pid_t pid) { pid_list.push_back(pid); }); in ScanPid()
|
D | tasklist.h | 23 static bool Scan(std::map<pid_t, std::vector<pid_t>>&); 27 static bool ScanPid(pid_t pid, std::vector<pid_t>&);
|
/system/memory/libmeminfo/libdmabufinfo/include/dmabufinfo/ |
D | dmabufinfo.h | 41 void AddFdRef(pid_t pid) { in AddFdRef() 47 void AddMapRef(pid_t pid) { in AddMapRef() 54 const std::unordered_map<pid_t, int>& fdrefs() const { return fdrefs_; } in fdrefs() 55 const std::unordered_map<pid_t, int>& maprefs() const { return maprefs_; } in maprefs() 59 const std::set<pid_t>& pids() const { return pids_; } in pids() 77 std::set<pid_t> pids_; 80 std::unordered_map<pid_t, int> fdrefs_; 81 std::unordered_map<pid_t, int> maprefs_; 82 void AddRefToPidMap(pid_t pid, std::unordered_map<pid_t, int>* map) { in AddRefToPidMap() 94 bool ReadDmaBufInfo(pid_t pid, std::vector<DmaBuffer>* dmabufs, bool read_fdrefs = true, [all …]
|
/system/unwinding/libunwindstack/include/unwindstack/ |
D | AndroidUnwinder.h | 60 AndroidUnwinder(pid_t pid) : pid_(pid) {} in AndroidUnwinder() 61 AndroidUnwinder(pid_t pid, std::shared_ptr<Memory>& memory) in AndroidUnwinder() 63 AndroidUnwinder(pid_t pid, ArchEnum arch) : pid_(pid), arch_(arch) {} in AndroidUnwinder() 64 AndroidUnwinder(pid_t pid, const std::vector<std::string> initial_map_names_to_skip) in AndroidUnwinder() 66 AndroidUnwinder(pid_t pid, const std::vector<std::string> initial_map_names_to_skip, in AndroidUnwinder() 84 bool Unwind(std::optional<pid_t> tid, AndroidUnwinderData& data); 90 static AndroidUnwinder* Create(pid_t pid); 95 virtual bool InternalUnwind(std::optional<pid_t> tid, AndroidUnwinderData& data) = 0; 97 pid_t pid_; 140 bool InternalUnwind(std::optional<pid_t> tid, AndroidUnwinderData& data) override; [all …]
|
/system/libprocinfo/include/procinfo/ |
D | process.h | 53 pid_t tid; 54 pid_t pid; 55 pid_t ppid; 56 pid_t tracer; 67 bool GetProcessInfo(pid_t tid, ProcessInfo* process_info, std::string* error = nullptr); 78 typename std::enable_if<sizeof(typename Collection::value_type) >= sizeof(pid_t), bool>::type { 90 pid_t tid; 91 if (!android::base::ParseInt(dent->d_name, &tid, 1, std::numeric_limits<pid_t>::max())) { 103 auto GetProcessTids(pid_t pid, Collection* out, std::string* error = nullptr) -> 104 typename std::enable_if<sizeof(typename Collection::value_type) >= sizeof(pid_t), bool>::type {
|
/system/extras/simpleperf/ |
D | environment.h | 65 bool GetThreadMmapsInProcess(pid_t pid, std::vector<ThreadMmap>* thread_mmaps); 73 bool IsThreadAlive(pid_t tid); 74 std::vector<pid_t> GetAllProcesses(); 75 std::vector<pid_t> GetThreadsInProcess(pid_t pid); 76 bool ReadThreadNameAndPid(pid_t tid, std::string* comm, pid_t* pid); 77 bool GetProcessForThread(pid_t tid, pid_t* pid); 78 bool GetThreadName(pid_t tid, std::string* name); 93 std::set<pid_t> WaitForAppProcesses(const std::string& package_name); 135 std::string GetCompleteProcessName(pid_t pid); 165 std::optional<uint32_t> GetProcessUid(pid_t pid);
|
/system/core/debuggerd/ |
D | util.h | 26 std::vector<std::string> get_command_line(pid_t pid); 27 std::string get_process_name(pid_t pid); 28 std::string get_thread_name(pid_t tid); 31 bool iterate_tids(pid_t, std::function<void(pid_t)>);
|
D | crash_dump.cpp | 88 static bool pid_contains_tid(int pid_proc_fd, pid_t tid) { in pid_contains_tid() 94 static pid_t get_tracer(pid_t tracee) { in get_tracer() 104 static bool ptrace_seize_thread(int pid_proc_fd, pid_t tid, std::string* error, int flags = 0) { in ptrace_seize_thread() 108 pid_t tracer_pid = get_tracer(tid); in ptrace_seize_thread() 132 static bool wait_for_stop(pid_t tid, int* received_signal) { in wait_for_stop() 135 pid_t result = waitpid(tid, &status, __WALL); in wait_for_stop() 153 static bool ptrace_interrupt(pid_t tid, int* received_signal) { in ptrace_interrupt() 162 static bool activity_manager_notify(pid_t pid, int signal, const std::string& amfd_data, in activity_manager_notify() 223 static pid_t g_target_thread = -1; 267 static void ParseArgs(int argc, char** argv, pid_t* pseudothread_tid, DebuggerdDumpType* dump_type)… in ParseArgs() [all …]
|
/system/memory/libmeminfo/libsmapinfo/include/ |
D | smapinfo.h | 37 bool get_all_pids(std::set<pid_t>* pids); 44 bool run_procrank(uint64_t pgflags, uint64_t pgflags_mask, const std::set<pid_t>& pids, 46 std::map<pid_t, ProcessRecord>* processrecords_ptr, std::ostream& out, 51 bool run_librank(uint64_t pgflags, uint64_t pgflags_mask, const std::set<pid_t>& pids, 55 std::map<pid_t, ProcessRecord>* processrecords_ptr, std::ostream& out, 61 bool run_showmap(pid_t pid, const std::string& filename, bool terse, bool verbose, bool show_addr, 63 std::map<pid_t, ProcessRecord>* processrecords_ptr, std::ostream& out,
|
/system/hwservicemanager/ |
D | HidlService.h | 44 const pid_t pid); 51 static_cast<pid_t>(IServiceManager::PidConstant::NO_PID)) in HidlService() 60 void setService(sp<IBase> service, pid_t pid); 61 pid_t getDebugPid() const; 67 void registerPassthroughClient(pid_t pid); 92 const std::set<pid_t> &getPassthroughClients() const; 112 std::set<pid_t> mPassthroughClients{}; 113 …pid_t mPid = static_cast<pid_t>(IServiceManager::PidConstant::NO_P…
|
/system/memory/libmeminfo/tools/ |
D | procrank.cpp | 73 std::vector<pid_t> descendant_filter; in main() 87 pid_t p; in main() 134 std::set<pid_t> pids; in main() 142 std::unordered_map<pid_t, std::vector<pid_t>> pid_tree; in main() 144 for (pid_t pid : pids) { in main() 156 std::set<pid_t> final_pids; in main() 157 std::vector<pid_t>& frontier = descendant_filter; in main() 161 pid_t pid = frontier.back(); in main() 180 for (pid_t pid : pids) { in main()
|
/system/libbase/include/android-base/ |
D | process.h | 41 using difference_type = pid_t; 42 using value_type = pid_t; 43 using pointer = const pid_t*; 44 using reference = const pid_t&; 50 pid_t pid_ = -1;
|
/system/logging/logd/ |
D | PruneList.h | 29 static const pid_t PID_ALL = (pid_t)-1; 31 Prune(uid_t uid, pid_t pid) : uid_(uid), pid_(pid) {} in Prune() 37 pid_t pid() const { return pid_; } in pid() 41 const pid_t pid_;
|
D | LogStatistics.h | 52 pid_t pid; 53 pid_t tid; 100 void MaxEntries(uid_t uid, pid_t pid, std::array<const TKey*, len>& out_keys, in MaxEntries() 114 pid_t entry_pid = 0; in MaxEntries() 232 pid_t pid() const { return pid_; } in pid() 245 pid_t pid_; 249 uid_t pidToUid(pid_t pid); 254 explicit PidEntry(pid_t pid) in PidEntry() 267 void Add(pid_t new_pid) { in Add() 290 std::string format(const LogStatistics& stat, log_id_t id, pid_t pid) const; [all …]
|
/system/core/init/ |
D | lmkd_service.h | 33 void LmkdRegister(const std::string& name, uid_t uid, pid_t pid, int oom_score_adjust); 34 void LmkdUnregister(const std::string& name, pid_t pid); 38 static inline void LmkdRegister(const std::string&, uid_t, pid_t, int) {} in LmkdRegister() argument 39 static inline void LmkdUnregister(const std::string&, pid_t) {} in LmkdUnregister() argument
|
D | sigchld_handler.cpp | 49 static pid_t ReapOneProcess() { in ReapOneProcess() 58 const pid_t pid = siginfo.si_pid; in ReapOneProcess() 121 std::set<pid_t> ReapAnyOutstandingChildren() { in ReapAnyOutstandingChildren() 122 std::set<pid_t> reaped_pids; in ReapAnyOutstandingChildren() 124 const pid_t pid = ReapOneProcess(); in ReapAnyOutstandingChildren() 132 static void ReapAndRemove(std::vector<pid_t>& alive_pids) { in ReapAndRemove() 150 void WaitToBeReaped(int sigchld_fd, const std::vector<pid_t>& pids, in WaitToBeReaped() 170 std::vector<pid_t> alive_pids(pids); in WaitToBeReaped() 187 for (pid_t pid : alive_pids) { in WaitToBeReaped()
|
/system/chre/host/hal_generic/common/ |
D | hal_client_manager.h | 91 static constexpr pid_t kPidUnset = 0; 101 const HalClientId clientId, pid_t pid, in Client() 112 void reset(pid_t processId, in reset() 124 pid_t pid{}; 173 HalClientId getClientId(pid_t pid); 194 bool registerCallback(pid_t pid, 210 pid_t pid, std::unique_ptr<chre::FragmentedLoadTransaction> transaction); 254 bool registerPendingUnloadTransaction(pid_t pid, uint32_t transactionId, 281 bool registerEndpointId(pid_t pid, const HostEndpointId &endpointId); 291 bool removeEndpointId(pid_t pid, const HostEndpointId &endpointId); [all …]
|
/system/memory/libmemunreachable/tests/ |
D | ThreadCapture_test.cpp | 98 std::vector<pid_t>& tids() { return tids_; } in tids() 121 std::vector<pid_t> tids_; 131 auto expected_tids = allocator::vector<pid_t>(1, getpid(), heap); in TEST_F() 132 auto list_tids = allocator::vector<pid_t>(heap); in TEST_F() 147 std::vector<pid_t> expected_tids = tids(); in TEST_P() 150 auto list_tids = allocator::vector<pid_t>(heap); in TEST_P() 180 std::function<void(pid_t)>&& parent) { in Fork() 221 [&](pid_t child) { in TEST_P() 229 auto list_tids = allocator::vector<pid_t>(heap); in TEST_P() 264 thread_capture.InjectTestFunc([&](pid_t tid) { in TEST_F() [all …]
|