ARGOBOTS
1.1
src
include
abti_timer.h
Go to the documentation of this file.
1
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */
2
/*
3
* See COPYRIGHT in top-level directory.
4
*/
5
6
#ifndef ABTI_TIMER_H_INCLUDED
7
#define ABTI_TIMER_H_INCLUDED
8
9
/* Inlined functions for Timer */
10
11
static
inline
double
ABTI_get_wtime
(
void
)
12
{
13
ABTD_time t;
14
ABTD_time_get
(&t);
15
return
ABTD_time_read_sec
(&t);
16
}
17
18
static
inline
ABTI_timer
*
ABTI_timer_get_ptr
(
ABT_timer
timer)
19
{
20
#ifndef ABT_CONFIG_DISABLE_ERROR_CHECK
21
ABTI_timer
*p_timer;
22
if
(timer ==
ABT_TIMER_NULL
) {
23
p_timer = NULL;
24
}
else
{
25
p_timer = (
ABTI_timer
*)timer;
26
}
27
return
p_timer;
28
#else
29
return
(
ABTI_timer
*)timer;
30
#endif
31
}
32
33
static
inline
ABT_timer
ABTI_timer_get_handle
(
ABTI_timer
*p_timer)
34
{
35
#ifndef ABT_CONFIG_DISABLE_ERROR_CHECK
36
ABT_timer
h_timer;
37
if
(p_timer == NULL) {
38
h_timer =
ABT_TIMER_NULL
;
39
}
else
{
40
h_timer = (
ABT_timer
)p_timer;
41
}
42
return
h_timer;
43
#else
44
return
(
ABT_timer
)p_timer;
45
#endif
46
}
47
48
#endif
/* ABTI_TIMER_H_INCLUDED */
ABTI_timer_get_ptr
static ABTI_timer * ABTI_timer_get_ptr(ABT_timer timer)
Definition:
abti_timer.h:18
ABTI_timer_get_handle
static ABT_timer ABTI_timer_get_handle(ABTI_timer *p_timer)
Definition:
abti_timer.h:33
ABTI_timer
Definition:
abti.h:483
ABT_TIMER_NULL
#define ABT_TIMER_NULL
Definition:
abt.h:1073
ABT_timer
struct ABT_timer_opaque * ABT_timer
Timer handle type.
Definition:
abt.h:994
ABTD_time_read_sec
double ABTD_time_read_sec(ABTD_time *p_time)
Definition:
abtd_time.c:35
ABTD_time_get
void ABTD_time_get(ABTD_time *p_time)
Definition:
abtd_time.c:21
ABTI_get_wtime
static double ABTI_get_wtime(void)
Definition:
abti_timer.h:11
Generated on Thu Apr 1 2021 07:02:51 for ARGOBOTS by
1.8.17