N64® Functions Menu
|
al - Audio Library Functions
gDP - DP GBI Macros
gdSP - General GBI Macros
gSP - SP GBI Macros
gt - Turbo Microcode RDP
gu - Graphics Utilities
Math - Math Functions
nuSys - NuSystem
os - N64 Operating System
sp - Sprite Library Functions
uh - Host to Target IO
64DD - N64 Disk Drive
|
|
OS_CYCLES_TO_NSEC
Syntax
#include <ultra64.h>
u64 OS_CYCLES_TO_NSEC(OSTime cycles);
Arguments
- cycles is the number of CPU count register cycles to convert to nanoseconds
Return Value
The number of nanoseconds
Explanation
The macros OS_NSEC_TO_CYCLES, OS_USEC_TO_CYCLES, OS_CYCLES_TO_NSEC,
and OS_CYCLES_TO_USEC convert to/from CPU count register cycles to nanoseconds or microseconds.
OS_NSEC_TO_CYCLES and OS_USEC_TO_CYCLES are cpp(1) macros that
respectively convert from nanoseconds and microseconds to CPU Count
register cycles.
OS_CYCLES_TO_NSEC and OS_CYCLES_TO_USEC are
macros that respectively convert from CPU Count register cycles to
nanoseconds and microseconds.
CPU Count register ticks are the units used by the timer services
osGetTime and osSetTimer. This counter increments at 46.875 Mhz
and each counter tick represents approximately 21.33 nanoseconds.
Note that all types are 64-bit quantities, so formatted print functions
must use the "%ll" size format to print these values correctly.
See Also
OS_NSEC_TO_CYCLES
OS_USEC_TO_CYCLES
OS_CYCLES_TO_USEC
osGetCount
osGetTime
osSetTimer
|
Nintendo® Confidential
Warning: all information in this document is confidential and covered by a non-disclosure agreement. You are responsible for keeping this information confidential and protected. Nintendo will vigorously enforce this responsibility.
Copyright © 1998
Nintendo of America Inc. All rights reserved Nintendo and N64 are registered trademarks of Nintendo
Last updated March 1998
|
|