Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
9.2.2023: Due to updates GitLab will be unavailable for some minutes between 9:00 and 11:00.
Open sidebar
dcdb
dcdb
Commits
3719b5dc
Commit
3719b5dc
authored
Jul 24, 2018
by
Michael Ott
Browse files
Add macros for ns to us,ms,s conversion
parent
25835b1e
Changes
1
Hide whitespace changes
Inline
Side-by-side
include/timestamp.h
View file @
3719b5dc
...
...
@@ -14,6 +14,10 @@
#define S_TO_NS(x) x*1000000000ll
#define MS_TO_NS(x) x*1000000ll
#define US_TO_NS(x) x*1000ll
#define NS_TO_US(x) x/1000ll
#define NS_TO_MS(x) x/1000000ll
#define NS_TO_S(x) x/1000000000ll
static
uint64_t
getTimestamp
()
{
boost
::
posix_time
::
ptime
epoch
(
boost
::
gregorian
::
date
(
1970
,
1
,
1
));
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment