summaryrefslogtreecommitdiffstats
path: root/rtemsbsd/freebsd/machine/cpu.h
blob: 625cd9623fcc1a3f7f8b4322b8f081a01c101680 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/**
 * @file
 *
 * @ingroup rtems_bsd_rtems
 *
 * @brief TODO.
 */

/*
 * COPYRIGHT (c) 2012.
 * On-Line Applications Research Corporation (OAR).
 *
 * The license and distribution terms for this file may be
 * found in the file LICENSE in this distribution or at
 * http://www.rtems.com/license/LICENSE.
 */

#ifndef _MACHINE_CPU_H_
#define _MACHINE_CPU_H_


#include <string.h>
#include <stdio.h>
#include <rtems.h>

#ifdef _KERNEL
static __inline u_int64_t
get_cyclecount(void)
{
  return rtems_clock_get_ticks_since_boot();
}
#endif /* _KERNEL */

#endif /* !MACHINE_CPU_H */