[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1027976: ITP: libcpucycles -- Microlibrary for counting CPU cycles



Package: wnpp
Severity: wishlist
Owner: nick black  <dankamongmen@gmail.com>
X-Debbugs-Cc: debian-devel@lists.debian.org, dankamongmen@gmail.com

* Package name    : libcpucycles
  Version         : 20230105
  Upstream Contact: Daniel J. Bernstein <djb@math.uic.edu>
* URL             : https://cpucycles.cr.yp.to/download.html
* License         : Public domain
  Programming Lang: C
  Description     : Microlibrary for counting CPU cycles

libcpucycles understands machine-level cycle counters for amd64 (both PMC and
TSC), arm32, arm64 (both PMC and VCT), mips64, ppc32, ppc64, riscv32, riscv64,
sparc64, and x86. libcpucycles also understands four OS-level mechanisms, which
give varying levels of accuracy: mach_absolute_time, perf_event,
CLOCK_MONOTONIC, and, as a fallback, microsecond-resolution gettimeofday.

When the program first calls cpucycles(), libcpucycles automatically benchmarks
the available mechanisms and selects the mechanism that does the best job.
Subsequent cpucycles() calls are thread-safe and very fast. An accompanying
cpucycles-info program prints a summary of cycle-counter accuracy.


Reply to: