PAPI
7.1.0.0
Loading...
Searching...
No Matches
display_error.c
Go to the documentation of this file.
1
#include <stdio.h>
2
#include <stdlib.h>
3
#include <unistd.h>
4
5
#include "
display_error.h
"
6
7
double
display_error
(
long
long
average,
8
long
long
high,
9
long
long
low,
10
long
long
expected
,
11
int
quiet
) {
12
13
double
error;
14
15
error=(((double)average-
expected
)/
expected
)*100.0;
16
17
if
(!
quiet
) {
18
printf(
" Expected: %lld\n"
,
expected
);
19
printf(
" High: %lld Low: %lld Average: %lld\n"
,
20
high,low,average);
21
22
printf(
" ( note, a small value above %lld may be expected due\n"
,
23
expected
);
24
printf(
" to overhead and interrupt noise, among other reasons)\n"
);
25
26
printf(
" Average Error = %.2f%%\n"
,error);
27
}
28
29
return
error;
30
31
}
expected
static int expected[NUM_THREADS]
Definition:
ctests/overflow_pthreads.c:29
display_error
double display_error(long long average, long long high, long long low, long long expected, int quiet)
Definition:
display_error.c:7
display_error.h
quiet
int quiet
Definition:
rapl_overflow.c:19
src
validation_tests
display_error.c
Generated on Wed Dec 20 2023 18:12:52 for PAPI by
1.9.6