Skip to content

Commit c13b7b6

Browse files
Merge pull request #528 from Treece-Burgess/12-30-2025-require-event-prefix
2 parents d5792ad + f51536f commit c13b7b6

13 files changed

+188
-146
lines changed

src/components/appio/tests/appio_test_fread_fwrite.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626
int main(int argc, char** argv) {
2727
int EventSet = PAPI_NULL;
28-
const char* names[NUM_EVENTS] = {"READ_CALLS", "READ_BYTES","READ_USEC","READ_ERR", "READ_EOF", "WRITE_CALLS","WRITE_BYTES","WRITE_USEC"};
28+
const char* names[NUM_EVENTS] = {"appio:::READ_CALLS", "appio:::READ_BYTES", "appio:::READ_USEC", "appio:::READ_ERR", "appio:::READ_EOF", "appio:::WRITE_CALLS", "appio:::WRITE_BYTES", "appio:::WRITE_USEC"};
2929
long long values[NUM_EVENTS];
3030

3131
char *infile = "/etc/group";

src/components/appio/tests/appio_test_pthreads.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
#include "papi_test.h"
2323

2424
#define NUM_EVENTS 6
25-
const char* names[NUM_EVENTS] = {"READ_CALLS", "READ_BYTES","READ_USEC","WRITE_CALLS","WRITE_BYTES","WRITE_USEC"};
25+
const char* names[NUM_EVENTS] = {"appio:::READ_CALLS", "appio:::READ_BYTES", "appio:::READ_USEC", "appio:::WRITE_CALLS", "appio:::WRITE_BYTES", "appio:::WRITE_USEC"};
2626

2727
#define NUM_INFILES 4
2828
static const char* files[NUM_INFILES] = {"/etc/passwd", "/etc/group", "/etc/protocols", "/etc/nsswitch.conf"};

src/components/appio/tests/appio_test_read_write.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
int main(int argc, char** argv) {
2525
int EventSet = PAPI_NULL;
26-
const char* names[NUM_EVENTS] = {"OPEN_CALLS", "OPEN_FDS", "READ_CALLS", "READ_BYTES", "READ_USEC", "READ_ERR", "READ_INTERRUPTED", "READ_WOULD_BLOCK", "WRITE_CALLS","WRITE_BYTES","WRITE_USEC","WRITE_WOULD_BLOCK"};
26+
const char* names[NUM_EVENTS] = {"appio:::OPEN_CALLS", "appio:::OPEN_FDS", "appio:::READ_CALLS", "appio:::READ_BYTES", "appio:::READ_USEC", "appio:::READ_ERR", "appio:::READ_INTERRUPTED", "appio:::READ_WOULD_BLOCK", "appio:::WRITE_CALLS", "appio:::WRITE_BYTES", "appio:::WRITE_USEC", "appio:::WRITE_WOULD_BLOCK"};
2727
long long values[NUM_EVENTS];
2828

2929
char *infile = "/etc/group";

src/components/appio/tests/appio_test_recv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
main(int argc, char *argv[]) {
1717
int EventSet = PAPI_NULL;
18-
const char* names[NUM_EVENTS] = {"RECV_CALLS", "RECV_BYTES", "RECV_USEC", "RECV_ERR", "RECV_INTERRUPTED", "RECV_WOULD_BLOCK"};
18+
const char* names[NUM_EVENTS] = {"appio:::RECV_CALLS", "appio:::RECV_BYTES", "appio:::RECV_USEC", "appio:::RECV_ERR", "appio:::RECV_INTERRUPTED", "appio:::RECV_WOULD_BLOCK"};
1919
long long values[NUM_EVENTS];
2020

2121
/* Set TESTS_QUIET variable */

src/components/appio/tests/appio_test_seek.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
int main(int argc, char** argv) {
2424
int EventSet = PAPI_NULL;
25-
const char* names[NUM_EVENTS] = {"READ_CALLS", "READ_BYTES", "READ_BLOCK_SIZE", "READ_USEC", "SEEK_CALLS", "SEEK_USEC", "SEEK_ABS_STRIDE_SIZE"};
25+
const char* names[NUM_EVENTS] = {"appio:::READ_CALLS", "appio:::READ_BYTES", "appio:::READ_BLOCK_SIZE", "appio:::READ_USEC", "appio:::SEEK_CALLS", "appio:::SEEK_USEC", "appio:::SEEK_ABS_STRIDE_SIZE"};
2626
long long values[NUM_EVENTS];
2727

2828
char *infile = "/etc/group";

src/components/appio/tests/appio_test_select.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
int main(int argc, char** argv) {
2525
int EventSet = PAPI_NULL;
26-
const char* names[NUM_EVENTS] = {"SELECT_USEC"};
26+
const char* names[NUM_EVENTS] = {"appio:::SELECT_USEC"};
2727
long long values[NUM_EVENTS];
2828

2929
/* Set TESTS_QUIET variable */

src/components/appio/tests/appio_test_socket.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
main(int argc, char *argv[]) {
1717
int EventSet = PAPI_NULL;
18-
const char* names[NUM_EVENTS] = {"READ_CALLS", "READ_BYTES", "READ_USEC", "READ_WOULD_BLOCK", "SOCK_READ_CALLS", "SOCK_READ_BYTES", "SOCK_READ_USEC", "SOCK_READ_WOULD_BLOCK", "WRITE_BYTES", "WRITE_CALLS", "WRITE_WOULD_BLOCK", "WRITE_USEC", "SOCK_WRITE_BYTES", "SOCK_WRITE_CALLS", "SOCK_WRITE_USEC"};
18+
const char* names[NUM_EVENTS] = {"appio:::READ_CALLS", "appio:::READ_BYTES", "appio:::READ_USEC", "appio:::READ_WOULD_BLOCK", "appio:::SOCK_READ_CALLS", "appio:::SOCK_READ_BYTES", "appio:::SOCK_READ_USEC", "appio:::SOCK_READ_WOULD_BLOCK", "appio:::WRITE_BYTES", "appio:::WRITE_CALLS", "appio:::WRITE_WOULD_BLOCK", "appio:::WRITE_USEC", "appio:::SOCK_WRITE_BYTES", "appio:::SOCK_WRITE_CALLS", "appio:::SOCK_WRITE_USEC"};
1919
long long values[NUM_EVENTS];
2020

2121
/* Set TESTS_QUIET variable */

src/components/appio/tests/appio_values_by_name.c

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,17 @@ int main (int argc, char **argv)
3131
int i, retval;
3232
int EventSet = PAPI_NULL;
3333
char *event_name[NUM_EVENTS] = {
34-
"READ_BYTES",
35-
"READ_CALLS",
36-
"READ_USEC",
37-
"READ_EOF",
38-
"READ_SHORT",
39-
"READ_ERR",
40-
"WRITE_BYTES",
41-
"WRITE_CALLS",
42-
"WRITE_USEC",
43-
"WRITE_ERR",
44-
"WRITE_SHORT"
34+
"appio:::READ_BYTES",
35+
"appio:::READ_CALLS",
36+
"appio:::READ_USEC",
37+
"appio:::READ_EOF",
38+
"appio:::READ_SHORT",
39+
"appio:::READ_ERR",
40+
"appio:::WRITE_BYTES",
41+
"appio:::WRITE_CALLS",
42+
"appio:::WRITE_USEC",
43+
"appio:::WRITE_ERR",
44+
"appio:::WRITE_SHORT"
4545
};
4646
int event_code[NUM_EVENTS] = { 0, 0, 0, 0, 0, 0, 0, 0, 0};
4747
long long event_value[NUM_EVENTS];

src/components/example/tests/example_basic.c

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,10 @@ int main (int argc, char **argv)
139139
"PAPI_create_eventset() failed\n", retval );
140140
}
141141

142-
retval = PAPI_event_name_to_code("EXAMPLE_ZERO", &code);
142+
retval = PAPI_event_name_to_code("example:::EXAMPLE_ZERO", &code);
143143
if ( retval != PAPI_OK ) {
144144
test_fail( __FILE__, __LINE__,
145-
"EXAMPLE_ZERO not found\n",retval );
145+
"example:::EXAMPLE_ZERO not found\n",retval );
146146
}
147147

148148
retval = PAPI_add_event( EventSet, code);
@@ -162,7 +162,7 @@ int main (int argc, char **argv)
162162
test_fail( __FILE__, __LINE__, "PAPI_stop failed\n", retval);
163163
}
164164

165-
if (!quiet) printf("Testing EXAMPLE_ZERO: %lld\n",values[0]);
165+
if (!quiet) printf("Testing example:::EXAMPLE_ZERO: %lld\n",values[0]);
166166

167167
if (values[0]!=0) {
168168
test_fail( __FILE__, __LINE__, "Result should be 0!\n", 0);
@@ -191,10 +191,10 @@ int main (int argc, char **argv)
191191
"PAPI_create_eventset() failed\n", retval );
192192
}
193193

194-
retval = PAPI_event_name_to_code("EXAMPLE_CONSTANT", &code);
194+
retval = PAPI_event_name_to_code("example:::EXAMPLE_CONSTANT", &code);
195195
if ( retval != PAPI_OK ) {
196196
test_fail( __FILE__, __LINE__,
197-
"EXAMPLE_CONSTANT not found\n",retval );
197+
"example:::EXAMPLE_CONSTANT not found\n",retval );
198198
}
199199

200200
retval = PAPI_add_event( EventSet, code);
@@ -214,7 +214,7 @@ int main (int argc, char **argv)
214214
test_fail( __FILE__, __LINE__, "PAPI_stop failed\n", retval);
215215
}
216216

217-
if (!quiet) printf("Testing EXAMPLE_CONSTANT: %lld\n",values[0]);
217+
if (!quiet) printf("Testing example:::EXAMPLE_CONSTANT: %lld\n",values[0]);
218218

219219
if (values[0]!=42) {
220220
test_fail( __FILE__, __LINE__, "Result should be 42!\n", 0);
@@ -244,10 +244,10 @@ int main (int argc, char **argv)
244244
"PAPI_create_eventset() failed\n", retval );
245245
}
246246

247-
retval = PAPI_event_name_to_code("EXAMPLE_AUTOINC", &code);
247+
retval = PAPI_event_name_to_code("example:::EXAMPLE_AUTOINC", &code);
248248
if ( retval != PAPI_OK ) {
249249
test_fail( __FILE__, __LINE__,
250-
"EXAMPLE_AUTOINC not found\n",retval );
250+
"example:::EXAMPLE_AUTOINC not found\n",retval );
251251
}
252252

253253
retval = PAPI_add_event( EventSet, code);
@@ -256,7 +256,7 @@ int main (int argc, char **argv)
256256
"PAPI_add_events failed\n", retval );
257257
}
258258

259-
if (!quiet) printf("Testing EXAMPLE_AUTOINC: ");
259+
if (!quiet) printf("Testing example:::EXAMPLE_AUTOINC: ");
260260

261261
for(i=0;i<10;i++) {
262262

@@ -338,7 +338,7 @@ int main (int argc, char **argv)
338338
}
339339

340340

341-
if (!quiet) printf("Testing EXAMPLE_AUTOINC after PAPI_reset(): %lld\n",
341+
if (!quiet) printf("Testing example:::EXAMPLE_AUTOINC after PAPI_reset(): %lld\n",
342342
values[0]);
343343

344344
if (values[0]!=0) {
@@ -370,10 +370,10 @@ int main (int argc, char **argv)
370370
"PAPI_create_eventset() failed\n", retval );
371371
}
372372

373-
retval = PAPI_event_name_to_code("EXAMPLE_CONSTANT", &code);
373+
retval = PAPI_event_name_to_code("example:::EXAMPLE_CONSTANT", &code);
374374
if ( retval != PAPI_OK ) {
375375
test_fail( __FILE__, __LINE__,
376-
"EXAMPLE_CONSTANT not found\n",retval );
376+
"example:::EXAMPLE_CONSTANT not found\n",retval );
377377
}
378378

379379
retval = PAPI_add_event( EventSet, code);
@@ -382,10 +382,10 @@ int main (int argc, char **argv)
382382
"PAPI_add_events failed\n", retval );
383383
}
384384

385-
retval = PAPI_event_name_to_code("EXAMPLE_GLOBAL_AUTOINC", &code);
385+
retval = PAPI_event_name_to_code("example:::EXAMPLE_GLOBAL_AUTOINC", &code);
386386
if ( retval != PAPI_OK ) {
387387
test_fail( __FILE__, __LINE__,
388-
"EXAMPLE_GLOBAL_AUTOINC not found\n",retval );
388+
"example:::EXAMPLE_GLOBAL_AUTOINC not found\n",retval );
389389
}
390390

391391
retval = PAPI_add_event( EventSet, code);
@@ -394,10 +394,10 @@ int main (int argc, char **argv)
394394
"PAPI_add_events failed\n", retval );
395395
}
396396

397-
retval = PAPI_event_name_to_code("EXAMPLE_ZERO", &code);
397+
retval = PAPI_event_name_to_code("example:::EXAMPLE_ZERO", &code);
398398
if ( retval != PAPI_OK ) {
399399
test_fail( __FILE__, __LINE__,
400-
"EXAMPLE_ZERO not found\n",retval );
400+
"example:::EXAMPLE_ZERO not found\n",retval );
401401
}
402402

403403
retval = PAPI_add_event( EventSet, code);
@@ -457,10 +457,10 @@ int main (int argc, char **argv)
457457
"PAPI_create_eventset() failed\n", retval );
458458
}
459459

460-
retval = PAPI_event_name_to_code("EXAMPLE_CONSTANT", &code);
460+
retval = PAPI_event_name_to_code("example:::EXAMPLE_CONSTANT", &code);
461461
if ( retval != PAPI_OK ) {
462462
test_fail( __FILE__, __LINE__,
463-
"EXAMPLE_CONSTANT not found\n",retval );
463+
"example:::EXAMPLE_CONSTANT not found\n",retval );
464464
}
465465

466466
retval = PAPI_add_event( EventSet, code);
@@ -469,10 +469,10 @@ int main (int argc, char **argv)
469469
"PAPI_add_events failed\n", retval );
470470
}
471471

472-
retval = PAPI_event_name_to_code("EXAMPLE_GLOBAL_AUTOINC", &code);
472+
retval = PAPI_event_name_to_code("example:::EXAMPLE_GLOBAL_AUTOINC", &code);
473473
if ( retval != PAPI_OK ) {
474474
test_fail( __FILE__, __LINE__,
475-
"EXAMPLE_GLOBAL_AUTOINC not found\n",retval );
475+
"example:::EXAMPLE_GLOBAL_AUTOINC not found\n",retval );
476476
}
477477

478478
retval = PAPI_add_event( EventSet, code);
@@ -481,10 +481,10 @@ int main (int argc, char **argv)
481481
"PAPI_add_events failed\n", retval );
482482
}
483483

484-
retval = PAPI_event_name_to_code("EXAMPLE_ZERO", &code);
484+
retval = PAPI_event_name_to_code("example:::EXAMPLE_ZERO", &code);
485485
if ( retval != PAPI_OK ) {
486486
test_fail( __FILE__, __LINE__,
487-
"EXAMPLE_ZERO not found\n",retval );
487+
"example:::EXAMPLE_ZERO not found\n",retval );
488488
}
489489

490490
retval = PAPI_add_event( EventSet, code);

src/components/example/tests/example_multiple_components.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -89,10 +89,10 @@ int main (int argc, char **argv)
8989
"PAPI_create_eventset() failed\n", retval );
9090
}
9191

92-
retval = PAPI_event_name_to_code("EXAMPLE_CONSTANT", &code);
92+
retval = PAPI_event_name_to_code("example:::EXAMPLE_CONSTANT", &code);
9393
if ( retval != PAPI_OK ) {
9494
test_fail( __FILE__, __LINE__,
95-
"EXAMPLE_ZERO not found\n",retval );
95+
"example:::EXAMPLE_ZERO not found\n",retval );
9696
}
9797

9898
retval = PAPI_add_event( EventSet1, code);
@@ -122,7 +122,7 @@ int main (int argc, char **argv)
122122
"NO CPU component found\n", retval );
123123
}
124124

125-
if (!quiet) printf("\nStarting EXAMPLE_CONSTANT and PAPI_TOT_CYC at the same time\n");
125+
if (!quiet) printf("\nStarting example:::EXAMPLE_CONSTANT and PAPI_TOT_CYC at the same time\n");
126126

127127
/* Start CPU component event */
128128
retval = PAPI_start( EventSet2 );
@@ -153,10 +153,10 @@ int main (int argc, char **argv)
153153
test_fail( __FILE__, __LINE__, "PAPI_stop failed\n", retval);
154154
}
155155

156-
if (!quiet) printf("Stopping EXAMPLE_CONSTANT and PAPI_TOT_CYC\n\n");
156+
if (!quiet) printf("Stopping example:::EXAMPLE_CONSTANT and PAPI_TOT_CYC\n\n");
157157

158158

159-
if (!quiet) printf("Results from EXAMPLE_CONSTANT: %lld\n",values1[0]);
159+
if (!quiet) printf("Results from example:::EXAMPLE_CONSTANT: %lld\n",values1[0]);
160160

161161
if (values1[0]!=42) {
162162
test_fail( __FILE__, __LINE__, "Result should be 42!\n", 0);

0 commit comments

Comments
 (0)