#include "perfetto/base/build_config.h"
#include "perfetto/ext/base/platform.h"
#include "perfetto/ext/base/unix_task_runner.h"
#include <errno.h>
#include <stdlib.h>
#if PERFETTO_BUILDFLAG(PERFETTO_OS_WIN)
#include <Windows.h>
#include <synchapi.h>
#else
#include <unistd.h>
#endif
#include <algorithm>
#include <limits>
#include "perfetto/ext/base/watchdog.h"
namespace perfetto {
namespace base {
UnixTaskRunner::UnixTaskRunner() { … }
UnixTaskRunner::~UnixTaskRunner() = default;
void UnixTaskRunner::WakeUp() { … }
void UnixTaskRunner::Run() { … }
void UnixTaskRunner::Quit() { … }
bool UnixTaskRunner::QuitCalled() { … }
bool UnixTaskRunner::IsIdleForTesting() { … }
void UnixTaskRunner::UpdateWatchTasksLocked() { … }
void UnixTaskRunner::RunImmediateAndDelayedTask() { … }
void UnixTaskRunner::PostFileDescriptorWatches(uint64_t windows_wait_result) { … }
void UnixTaskRunner::RunFileDescriptorWatch(PlatformHandle fd) { … }
int UnixTaskRunner::GetDelayMsToNextTaskLocked() const { … }
void UnixTaskRunner::PostTask(std::function<void()> task) { … }
void UnixTaskRunner::PostDelayedTask(std::function<void()> task,
uint32_t delay_ms) { … }
void UnixTaskRunner::AddFileDescriptorWatch(PlatformHandle fd,
std::function<void()> task) { … }
void UnixTaskRunner::RemoveFileDescriptorWatch(PlatformHandle fd) { … }
bool UnixTaskRunner::RunsTasksOnCurrentThread() const { … }
}
}