Add a testase for BZ #14602
[glibc.git] / manual / platform.texi
blobe387ff4cc9bdad3bd8a38fc846a158e112d1f409
1 @node Platform, Contributors, Maintenance, Top
2 @c %MENU% Describe all platform-specific facilities provided
3 @appendix Platform-specific facilities
5 @Theglibc{} can provide machine-specific functionality.
7 @menu
8 * PowerPC::           Facilities Specific to the PowerPC Architecture
9 @end menu
11 @node PowerPC
12 @appendixsec PowerPC-specific Facilities
14 Facilities specific to PowerPC that are not specific to a particular
15 operating system are declared in @file{sys/platform/ppc.h}.
17 @deftypefun {uint64_t} __ppc_get_timebase (void)
18 Read the current value of the Time Base Register.
20 The @dfn{Time Base Register} is a 64-bit register that stores a monotonically
21 incremented value updated at a system-dependent frequency that may be
22 different from the processor frequency.  More information is available in
23 @cite{Power ISA 2.06b - Book II - Section 5.2}.
25 @code{__ppc_get_timebase} uses the processor's time base facility directly
26 without requiring assistance from the operating system, so it is very
27 efficient.
28 @end deftypefun
30 @deftypefun {uint64_t} __ppc_get_timebase_freq (void)
31 Read the current frequency at which the Time Base Register is updated.
33 This frequency is not related to the processor clock or the bus clock.
34 It is also possible that this frequency is not constant.  More information is
35 available in @cite{Power ISA 2.06b - Book II - Section 5.2}.
36 @end deftypefun