PAPI_reset(3)
π NAME π
okay so this is PAPI_reset(3), straight from the PAPI manual, and it's literally about one thing: resetting the hardware event counts in an event set. slay β¨
PAPI_reset β reset the hardware event counts in an event set.
β¨ SYNOPSIS β¨
Detailed Description π¦
C Prototype:
#include <papi.h>
int PAPI_reset( int EventSet );
Parameters π
EventSetβ an integer handle for a PAPI event set as created byPAPI_create_eventset.
Return values π
PAPI_OKPAPI_ESYSβ a system or C library call failed inside PAPI, see theerrnovariable.PAPI_ENOEVSTβ the EventSet specified does not exist.
PAPI_reset() zeroes the values of the counters contained in EventSet. This call assumes an initialized PAPI library and a properly added event set, bestie β don't skip those steps, fr fr.
Example: πΈ
int EventSet = PAPI_NULL;
int Events[] = {PAPI_TOT_INS, PAPI_FP_OPS};
int ret;
// Create an empty EventSet
ret = PAPI_create_eventset(&EventSet);
if (ret != PAPI_OK) handle_error(ret);
// Add two events to our EventSet
ret = PAPI_add_events(EventSet, Events, 2);
if (ret != PAPI_OK) handle_error(ret);
// Start counting
ret = PAPI_start(EventSet);
if (ret != PAPI_OK) handle_error(ret);
// Stop counting, ignore values
ret = PAPI_stop(EventSet, NULL);
if (ret != PAPI_OK) handle_error(ret);
// reset the counters in this EventSet
ret = PAPI_reset(EventSet);
if (ret != PAPI_OK) handle_error(ret);
π See also π
PAPI_create_eventset
π«Ά Author π«Ά
Generated automatically by Doxygen for PAPI from the source code.
okay bye bestie π this was PAPI_reset(3) from PAPI version 7.2.0.0, dated Wed Jun 25 2025 19:30:49. iconic, no cap π
β¨
π¦ where this page comes from
- nixos 26.05: papi 7.2.0
- nixpkgs unstable: papi 7.2.0
- opensuse-leap 16.0: papi-devel 7.2.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: papi-devel 7.2.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: papi-devel 7.2.0-160000.2.2 Β· BSD-3-Clause
- ubuntu resolute: libpapi-dev 7.2.0-2 Β· BSD-3-Clause
- ubuntu stonking: libpapi-dev 7.2.0-2 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms