Browse Source

papi: Reset index in papi_events on startup

Samuel Thibault 4 years ago
parent
commit
6b0bc9dbd7
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/profiling/profiling.c

+ 1 - 0
src/profiling/profiling.c

@@ -161,6 +161,7 @@ void _starpu_profiling_init(void)
 		char *conf_papi_events;
 		char *papi_event_name;
 		conf_papi_events = starpu_getenv("STARPU_PROF_PAPI_EVENTS");
+		papi_nevents = 0;
 		if (conf_papi_events != NULL)
 		{
 			while ((papi_event_name = strtok_r(conf_papi_events, " ,", &conf_papi_events)))