Home
last modified time | relevance | path

Searched refs:EventFd (Results 1 – 10 of 10) sorted by relevance

/system/extras/simpleperf/
Devent_fd.cpp48 std::unique_ptr<EventFd> EventFd::OpenEventFile(const perf_event_attr& attr, pid_t tid, int cpu, in OpenEventFile()
49 EventFd* group_event_fd, in OpenEventFile()
88 return std::unique_ptr<EventFd>(new EventFd(real_attr, perf_event_fd, event_name, tid, cpu)); in OpenEventFile()
91 EventFd::~EventFd() { in ~EventFd()
97 std::string EventFd::Name() const { in Name()
102 uint64_t EventFd::Id() const { in Id()
112 bool EventFd::SetEnableEvent(bool enable) { in SetEnableEvent()
121 bool EventFd::SetFilter(const std::string& filter) { in SetFilter()
129 bool EventFd::InnerReadCounter(PerfCounter* counter) const { in InnerReadCounter()
138 bool EventFd::ReadCounter(PerfCounter* counter) { in ReadCounter()
[all …]
Devent_fd.h41 class EventFd {
43 static std::unique_ptr<EventFd> OpenEventFile(const perf_event_attr& attr, pid_t tid, int cpu,
44 EventFd* group_event_fd,
48 virtual ~EventFd();
74 bool ShareMappedBuffer(const EventFd& event_fd, bool report_error);
112 EventFd(const perf_event_attr& attr, int perf_event_fd, const std::string& event_name, pid_t tid, in EventFd() function
153 DISALLOW_COPY_AND_ASSIGN(EventFd);
DRecordReadThread.h100 KernelRecordReader(EventFd* event_fd);
102 EventFd* GetEventFd() const { return event_fd_; } in GetEventFd()
115 EventFd* event_fd_;
143 bool AddEventFds(const std::vector<EventFd*>& event_fds);
145 bool RemoveEventFds(const std::vector<EventFd*>& event_fds);
173 bool HandleAddEventFds(IOEventLoop& loop, const std::vector<EventFd*>& event_fds);
174 bool HandleRemoveEventFds(const std::vector<EventFd*>& event_fds);
Dcpu_hotplug_test.cpp260 std::unique_ptr<EventFd> event_fd = in TEST()
261 EventFd::OpenEventFile(attr, -1, test_cpu, nullptr, event_type_modifier->name, false); in TEST()
316 std::unique_ptr<EventFd> event_fd = in TEST()
317 EventFd::OpenEventFile(attr, -1, test_cpu, nullptr, event_type_modifier->name, false); in TEST()
401 ASSERT_TRUE(EventFd::OpenEventFile(attr, 0, -1, nullptr, event_type_modifier->name, true) != in TEST()
404 std::unique_ptr<EventFd> event_fd = EventFd::OpenEventFile( in TEST()
427 ASSERT_TRUE(EventFd::OpenEventFile(attr, -1, test_cpu, nullptr, event_type_modifier->name, in TEST()
456 std::unique_ptr<EventFd> event_fd = in TEST()
457 EventFd::OpenEventFile(attr, getpid(), record_cpu, nullptr, event_type_modifier->name); in TEST()
464 EventFd::OpenEventFile(attr, getpid(), record_cpu, nullptr, event_type_modifier->name); in TEST()
DRecordReadThread.cpp170 KernelRecordReader::KernelRecordReader(EventFd* event_fd) : event_fd_(event_fd) { in KernelRecordReader()
261 bool RecordReadThread::AddEventFds(const std::vector<EventFd*>& event_fds) { in AddEventFds()
262 return SendCmdToReadThread(CMD_ADD_EVENT_FDS, const_cast<std::vector<EventFd*>*>(&event_fds)); in AddEventFds()
265 bool RecordReadThread::RemoveEventFds(const std::vector<EventFd*>& event_fds) { in RemoveEventFds()
266 return SendCmdToReadThread(CMD_REMOVE_EVENT_FDS, const_cast<std::vector<EventFd*>*>(&event_fds)); in RemoveEventFds()
352 result = HandleAddEventFds(loop, *static_cast<std::vector<EventFd*>*>(cmd_arg_)); in HandleCmd()
355 result = HandleRemoveEventFds(*static_cast<std::vector<EventFd*>*>(cmd_arg_)); in HandleCmd()
376 const std::vector<EventFd*>& event_fds) { in HandleAddEventFds()
377 std::unordered_map<int, EventFd*> cpu_map; in HandleAddEventFds()
381 for (EventFd* fd : event_fds) { in HandleAddEventFds()
[all …]
Dtest_util.cpp59 std::unique_ptr<EventFd> event_fd = in HasNonZeroInstructionEventCount()
60 EventFd::OpenEventFile(attr, gettid(), -1, nullptr, type->name, false); in HasNonZeroInstructionEventCount()
DRecordReadThread_test.cpp116 struct MockEventFd : public EventFd {
119 : EventFd(attr, -1, "", 0, cpu) { in MockEventFd()
215 std::vector<EventFd*> CreateFakeEventFds(const perf_event_attr& attr, size_t event_fd_count) { in CreateFakeEventFds()
242 std::vector<EventFd*> result; in CreateFakeEventFds()
257 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, 2); in TEST_F()
297 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, event_fd_count); in TEST_F()
317 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, 1); in TEST_F()
379 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, 1); in TEST_F()
396 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, 1); in TEST_F()
422 std::vector<EventFd*> event_fds = CreateFakeEventFds(attr, 1); in TEST_F()
Devent_selection_set.cpp91 std::unique_ptr<EventFd> event_fd = in IsDumpingRegsForTracepointEventsSupported()
92 EventFd::OpenEventFile(attr, thread_id, -1, nullptr, event_type->name); in IsDumpingRegsForTracepointEventsSupported()
564 std::vector<std::unique_ptr<EventFd>> event_fds; in OpenEventFilesOnGroup()
567 EventFd* group_fd = nullptr; in OpenEventFilesOnGroup()
569 std::unique_ptr<EventFd> event_fd = EventFd::OpenEventFile( in OpenEventFilesOnGroup()
706 static bool ReadCounter(EventFd* event_fd, CounterInfo* counter) { in ReadCounter()
753 std::vector<EventFd*> event_fds; in PrepareToReadMmapEventData()
Dcmd_list.cpp62 std::unique_ptr<EventFd> event_fd = in IsEventTypeSupported()
63 EventFd::OpenEventFile(attr, gettid(), -1, nullptr, event_type.name, false); in IsEventTypeSupported()
Devent_selection_set.h182 std::vector<std::unique_ptr<EventFd>> event_fds;