PAPI 7.1.0.0
Loading...
Searching...
No Matches
common.h
Go to the documentation of this file.
1
8#ifndef __COMMON_H__
9#define __COMMON_H__
10
11#include "papi.h"
12#include "papi_test.h"
13#include "matmul.h"
14
15static inline void
16hip_test_fail(const char *file __attribute__((unused)), int line,
17 const char *call, hipError_t retval)
18{
19 const char *string;
20
21 fprintf(stdout, "FAILER!!!");
22 fprintf(stdout, "\nLine # %d ", line);
23
24 string = hipGetErrorString(retval);
25 fprintf(stdout, "Error in %s: %s\n", call, string);
26
27 if (PAPI_is_initialized()) {
29 }
30
31 exit(1);
32}
33
34static inline int
35match_expected_counter(long long expected, long long value)
36{
37 return (expected == value);
38}
39
40#endif /* End of __COMMON_H__ */
check for initialization
Finish using PAPI and free all related resources.
static void hip_test_fail(const char *file __attribute__((unused)), int line, const char *call, hipError_t retval)
Definition: common.h:16
static int match_expected_counter(long long expected, long long value)
Definition: common.h:35
static int expected[NUM_THREADS]
unsigned long AO_t __attribute__((__aligned__(4)))
Definition: m68k.h:21
Return codes and api definitions.
FILE * stdout
const char FILE * file
Definition: pscanf.h:13
int retval
Definition: zero_fork.c:53