ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsdeferred_resndemanglerenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumwith_gc
Last change
on this file since a02842f was
07b8001,
checked in by Peter A. Buhr <pabuhr@…>, 7 years ago
|
adjust size of "time"
|
-
Property mode set to
100644
|
File size:
1.1 KB
|
Line | |
---|
1 | // |
---|
2 | // Cforall Version 1.0.0 Copyright (C) 2018 University of Waterloo |
---|
3 | // |
---|
4 | // The contents of this file are covered under the licence agreement in the |
---|
5 | // file "LICENCE" distributed with Cforall. |
---|
6 | // |
---|
7 | // time_t.h -- |
---|
8 | // |
---|
9 | // Author : Peter A. Buhr |
---|
10 | // Created On : Tue Apr 10 14:42:03 2018 |
---|
11 | // Last Modified By : Peter A. Buhr |
---|
12 | // Last Modified On : Fri Apr 13 07:51:47 2018 |
---|
13 | // Update Count : 6 |
---|
14 | // |
---|
15 | |
---|
16 | #pragma once |
---|
17 | |
---|
18 | |
---|
19 | //######################### Duration ######################### |
---|
20 | |
---|
21 | struct Duration { // private |
---|
22 | int64_t tv; // nanoseconds |
---|
23 | }; // Duration |
---|
24 | |
---|
25 | static inline void ?{}( Duration & dur ) with( dur ) { tv = 0; } |
---|
26 | static inline void ?{}( Duration & dur, zero_t ) with( dur ) { tv = 0; } |
---|
27 | |
---|
28 | |
---|
29 | //######################### Time ######################### |
---|
30 | |
---|
31 | struct Time { // private |
---|
32 | uint64_t tv; // nanoseconds since UNIX epoch |
---|
33 | }; // Time |
---|
34 | |
---|
35 | static inline void ?{}( Time & time ) with( time ) { tv = 0; } |
---|
36 | static inline void ?{}( Time & time, zero_t ) with( time ) { tv = 0; } |
---|
37 | |
---|
38 | // Local Variables: // |
---|
39 | // mode: c // |
---|
40 | // tab-width: 4 // |
---|
41 | // End: // |
---|
Note: See
TracBrowser
for help on using the repository browser.