From c806b16c6d84f7d52f2ae07a12ae11833c75be44 Mon Sep 17 00:00:00 2001 From: Thaumy Date: Tue, 30 Jan 2024 11:25:24 +0800 Subject: [PATCH] fix `CacheOp::Prefetch` in `CacheOp::as_u64` --- src/perf_event/event/hardware.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/perf_event/event/hardware.rs b/src/perf_event/event/hardware.rs index 2e130e6..1c57efa 100644 --- a/src/perf_event/event/hardware.rs +++ b/src/perf_event/event/hardware.rs @@ -14,7 +14,7 @@ impl CacheOp { let id = match self { Read => PERF_COUNT_HW_CACHE_OP_READ, Write => PERF_COUNT_HW_CACHE_OP_WRITE, - Prefetch => PERF_COUNT_HW_CACHE_OP_WRITE, + Prefetch => PERF_COUNT_HW_CACHE_OP_PREFETCH, }; id as _ }