RetroArch
Classes | Macros | Typedefs | Functions
time.h File Reference
#include <wiiu/types.h>
Include dependency graph for time.h:

Go to the source code of this file.

Classes

struct  OSCalendarTime
 

Macros

#define OSOneSecond   ((OSGetSystemInfo()->clockSpeed) / 4)
 
#define OSMilliseconds(val)   ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000ull)
 
#define OSMicroseconds(val)   ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000ull)
 
#define OSNanoseconds(val)   ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000000ull)
 
#define wiiu_bus_clock   (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2*2*2) /* 248.625000 Mhz */
 
#define wiiu_cpu_clock   (17 * 13 * 5*5*5 * 5*5*5 * 5 * 3*3 * 2*2*2) /* 1243.125000 Mhz */
 
#define wiiu_timer_clock   (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2) /* 62.156250 Mhz */
 
#define sec_to_ticks(s)   (((17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2) * (uint64_t)(s)))
 
#define ms_to_ticks(ms)   (((17 * 13 * 5*5*5 * 3*3) * (uint64_t)(ms)) / (2*2))
 
#define us_to_ticks(us)   (((17 * 13 * 3*3) * (uint64_t)(us)) / (2*2* 2*2*2))
 
#define ns_to_ticks(ns)   (((17 * 13 * 3*3) * (uint64_t)(ns)) / (2*2* 2*2*2* 2*2*2 *5*5*5))
 
#define ticks_to_sec(ticks)   (((uint64_t)(ticks)) / (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2))
 
#define ticks_to_ms(ticks)   (((uint64_t)(ticks) * (2*2)) / (17 * 13 * 5*5*5 * 3*3))
 
#define ticks_to_us(ticks)   (((uint64_t)(ticks) * (2*2 * 2*2*2)) / (17 * 13 * 3*3))
 
#define ticks_to_ns(ticks)   (((uint64_t)(ticks) * (2*2 * 2*2*2 * 2*2*2 * 5*5*5)) / (17 * 13 * 3*3))
 

Typedefs

typedef int32_t OSTick
 
typedef int64_t OSTime
 

Functions

OSTime OSGetTime ()
 
OSTime OSGetSystemTime ()
 
OSTick OSGetTick ()
 
OSTick OSGetSystemTick ()
 
OSTime OSCalendarTimeToTicks (OSCalendarTime *calendarTime)
 
void OSTicksToCalendarTime (OSTime time, OSCalendarTime *calendarTime)
 

Macro Definition Documentation

◆ ms_to_ticks

#define ms_to_ticks (   ms)    (((17 * 13 * 5*5*5 * 3*3) * (uint64_t)(ms)) / (2*2))

◆ ns_to_ticks

#define ns_to_ticks (   ns)    (((17 * 13 * 3*3) * (uint64_t)(ns)) / (2*2* 2*2*2* 2*2*2 *5*5*5))

◆ OSMicroseconds

#define OSMicroseconds (   val)    ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000ull)

◆ OSMilliseconds

#define OSMilliseconds (   val)    ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000ull)

◆ OSNanoseconds

#define OSNanoseconds (   val)    ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000000ull)

◆ OSOneSecond

#define OSOneSecond   ((OSGetSystemInfo()->clockSpeed) / 4)

◆ sec_to_ticks

#define sec_to_ticks (   s)    (((17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2) * (uint64_t)(s)))

◆ ticks_to_ms

#define ticks_to_ms (   ticks)    (((uint64_t)(ticks) * (2*2)) / (17 * 13 * 5*5*5 * 3*3))

◆ ticks_to_ns

#define ticks_to_ns (   ticks)    (((uint64_t)(ticks) * (2*2 * 2*2*2 * 2*2*2 * 5*5*5)) / (17 * 13 * 3*3))

◆ ticks_to_sec

#define ticks_to_sec (   ticks)    (((uint64_t)(ticks)) / (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2))

◆ ticks_to_us

#define ticks_to_us (   ticks)    (((uint64_t)(ticks) * (2*2 * 2*2*2)) / (17 * 13 * 3*3))

◆ us_to_ticks

#define us_to_ticks (   us)    (((17 * 13 * 3*3) * (uint64_t)(us)) / (2*2* 2*2*2))

◆ wiiu_bus_clock

#define wiiu_bus_clock   (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2*2*2) /* 248.625000 Mhz */

◆ wiiu_cpu_clock

#define wiiu_cpu_clock   (17 * 13 * 5*5*5 * 5*5*5 * 5 * 3*3 * 2*2*2) /* 1243.125000 Mhz */

◆ wiiu_timer_clock

#define wiiu_timer_clock   (17 * 13 * 5*5*5 * 5*5*5 * 3*3 * 2) /* 62.156250 Mhz */

Typedef Documentation

◆ OSTick

typedef int32_t OSTick

◆ OSTime

typedef int64_t OSTime

Function Documentation

◆ OSCalendarTimeToTicks()

OSTime OSCalendarTimeToTicks ( OSCalendarTime calendarTime)

◆ OSGetSystemTick()

OSTick OSGetSystemTick ( )
Here is the caller graph for this function:

◆ OSGetSystemTime()

OSTime OSGetSystemTime ( )
Here is the caller graph for this function:

◆ OSGetTick()

OSTick OSGetTick ( )

◆ OSGetTime()

OSTime OSGetTime ( )
Here is the caller graph for this function:

◆ OSTicksToCalendarTime()

void OSTicksToCalendarTime ( OSTime  time,
OSCalendarTime calendarTime 
)