| 281 | |
| 282 | #ifndef USE_CPU_NANOSECONDS |
| 283 | uint64_t |
| 284 | nanoseconds(void) |
| 285 | { |
| 286 | struct bintime bt; |
| 287 | uint64_t ns; |
| 288 | |
| 289 | binuptime(&bt); |
| 290 | /* From bintime2timespec */ |
| 291 | ns = bt.sec * (uint64_t)1000000000; |
| 292 | ns += ((uint64_t)1000000000 * (uint32_t)(bt.frac >> 32)) >> 32; |
| 293 | return (ns); |
| 294 | } |
| 295 | #endif |
| 296 | |
| 297 | static void |
no test coverage detected