| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/globals.h" | 5 #include "vm/globals.h" |
| 6 #if defined(TARGET_OS_FUCHSIA) | 6 #if defined(TARGET_OS_FUCHSIA) |
| 7 | 7 |
| 8 #include "vm/os.h" | 8 #include "vm/os.h" |
| 9 | 9 |
| 10 #include <magenta/syscalls.h> | 10 #include <magenta/syscalls.h> |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 return 0; | 43 return 0; |
| 44 } | 44 } |
| 45 | 45 |
| 46 | 46 |
| 47 int64_t OS::GetCurrentTimeMillis() { | 47 int64_t OS::GetCurrentTimeMillis() { |
| 48 return GetCurrentTimeMicros() / 1000; | 48 return GetCurrentTimeMicros() / 1000; |
| 49 } | 49 } |
| 50 | 50 |
| 51 | 51 |
| 52 int64_t OS::GetCurrentTimeMicros() { | 52 int64_t OS::GetCurrentTimeMicros() { |
| 53 return _magenta_current_time() / 1000; | 53 return mx_current_time() / 1000; |
| 54 } | 54 } |
| 55 | 55 |
| 56 | 56 |
| 57 int64_t OS::GetCurrentMonotonicTicks() { | 57 int64_t OS::GetCurrentMonotonicTicks() { |
| 58 return _magenta_current_time(); | 58 return mx_current_time(); |
| 59 } | 59 } |
| 60 | 60 |
| 61 | 61 |
| 62 int64_t OS::GetCurrentMonotonicFrequency() { | 62 int64_t OS::GetCurrentMonotonicFrequency() { |
| 63 return kNanosecondsPerSecond; | 63 return kNanosecondsPerSecond; |
| 64 } | 64 } |
| 65 | 65 |
| 66 | 66 |
| 67 int64_t OS::GetCurrentMonotonicMicros() { | 67 int64_t OS::GetCurrentMonotonicMicros() { |
| 68 int64_t ticks = GetCurrentMonotonicTicks(); | 68 int64_t ticks = GetCurrentMonotonicTicks(); |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 } | 270 } |
| 271 | 271 |
| 272 | 272 |
| 273 void OS::Exit(int code) { | 273 void OS::Exit(int code) { |
| 274 UNIMPLEMENTED(); | 274 UNIMPLEMENTED(); |
| 275 } | 275 } |
| 276 | 276 |
| 277 } // namespace dart | 277 } // namespace dart |
| 278 | 278 |
| 279 #endif // defined(TARGET_OS_FUCHSIA) | 279 #endif // defined(TARGET_OS_FUCHSIA) |
| OLD | NEW |