Implement get_cyclecount().

This commit is contained in:
Olivier Houchard 2004-11-04 19:15:43 +00:00
parent a61369085e
commit 3ce6572f9f

View File

@ -9,11 +9,17 @@
void cpu_halt(void); void cpu_halt(void);
void swi_vm(void *); void swi_vm(void *);
#ifdef _KERNEL
static __inline uint64_t static __inline uint64_t
get_cyclecount(void) get_cyclecount(void)
{ {
return (0); struct bintime bt;
binuptime(&bt);
return (bt.frac ^ bt.sec);
} }
#endif
#define CPU_CONSDEV 1 #define CPU_CONSDEV 1
#define CPU_ADJKERNTZ 2 /* int: timezone offset (seconds) */ #define CPU_ADJKERNTZ 2 /* int: timezone offset (seconds) */