blob: bd8f324a3368229bc3b06b1b76d6d01f96f664f0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
/* SPDX-License-Identifier: BSD-3-Clause
* Copyright (c) 2013-2018 Linaro Limited
* Copyright (c) 2020-2023 Nokia
*/
/**
* @file
*
* ODP time
*/
#ifndef ODP_API_SPEC_TIME_TYPES_H_
#define ODP_API_SPEC_TIME_TYPES_H_
#include <odp/visibility_begin.h>
#ifdef __cplusplus
extern "C" {
#endif
/** @defgroup odp_time ODP TIME
* @{
*/
/** A microsecond in nanoseconds */
#define ODP_TIME_USEC_IN_NS 1000ULL
/** A millisecond in nanoseconds */
#define ODP_TIME_MSEC_IN_NS 1000000ULL
/** A second in nanoseconds */
#define ODP_TIME_SEC_IN_NS 1000000000ULL
/** A minute in nanoseconds */
#define ODP_TIME_MIN_IN_NS 60000000000ULL
/** An hour in nanoseconds */
#define ODP_TIME_HOUR_IN_NS 3600000000000ULL
/**
* @typedef odp_time_t
* ODP time stamp. Time stamp can represent a time stamp from local or global
* time source. A local time stamp must not be shared between threads. API calls
* work correctly only when all time stamps for input are from the same time
* source.
*/
/**
* @def ODP_TIME_NULL
* Zero time stamp
*/
/**
* Time stamp values at ODP startup
*/
typedef struct odp_time_startup_t {
/** Global time at ODP startup */
odp_time_t global;
/** Global time in nanoseconds at ODP startup */
uint64_t global_ns;
} odp_time_startup_t;
/**
* @}
*/
#ifdef __cplusplus
}
#endif
#include <odp/visibility_end.h>
#endif
|