From 8024b387131858e8237f5231df0f3a7e0ed64428 Mon Sep 17 00:00:00 2001 From: Andreas Abel Date: Mon, 7 Feb 2022 20:17:58 +0100 Subject: [PATCH] add function prototype for perf_event_open --- timing-harness/rdpmc.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/timing-harness/rdpmc.h b/timing-harness/rdpmc.h index d903db5..5095bdc 100644 --- a/timing-harness/rdpmc.h +++ b/timing-harness/rdpmc.h @@ -23,13 +23,16 @@ extern "C" { #endif +int perf_event_open(struct perf_event_attr *attr, pid_t pid, + int cpu, int group_fd, unsigned long flags); + struct rdpmc_ctx { int fd; struct perf_event_mmap_page *buf; }; int rdpmc_open(unsigned counter, struct rdpmc_ctx *ctx); -int rdpmc_open_attr(struct perf_event_attr *attr, struct rdpmc_ctx *ctx, +int rdpmc_open_attr(struct perf_event_attr *attr, struct rdpmc_ctx *ctx, struct rdpmc_ctx *leader_ctx); void rdpmc_close(struct rdpmc_ctx *ctx); unsigned long long rdpmc_read(struct rdpmc_ctx *ctx);