OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/time.h" | 5 #include "base/time.h" |
6 | 6 |
7 #include <CoreFoundation/CFDate.h> | 7 #include <CoreFoundation/CFDate.h> |
8 #include <CoreFoundation/CFTimeZone.h> | 8 #include <CoreFoundation/CFTimeZone.h> |
9 #include <mach/mach_time.h> | 9 #include <mach/mach_time.h> |
10 #include <sys/time.h> | 10 #include <sys/time.h> |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 // reported in nanoseconds is enough to last nearly 585 years. | 141 // reported in nanoseconds is enough to last nearly 585 years. |
142 | 142 |
143 return TimeTicks(absolute_micro); | 143 return TimeTicks(absolute_micro); |
144 } | 144 } |
145 | 145 |
146 // static | 146 // static |
147 TimeTicks TimeTicks::HighResNow() { | 147 TimeTicks TimeTicks::HighResNow() { |
148 return Now(); | 148 return Now(); |
149 } | 149 } |
150 | 150 |
| 151 // static |
| 152 TimeTicks TimeTicks::NowFromSystemTraceTime() { |
| 153 return HighResNow(); |
| 154 } |
| 155 |
151 } // namespace base | 156 } // namespace base |
OLD | NEW |