Profiling utility. More...

Modules

Types
Profiler data types.
Macros
Profiler macros.

Functions

gos_result_t profiler_register (const char *name, const profiler_config_t *config)
Register a profiler. More...
gos_result_t profiler_unregister (const char *name)
Unregister a profiler. More...
gos_result_t profiler_register_all (void)
Register all profilers. More...
gos_result_t profiler_set_parent (const char *name, const char *parent_name)
Set a profiler's 'parent' profiler. More...
gos_result_t profiler_begin (const char *name)
Start profiler. More...
gos_result_t profiler_end (const char *name)
Stop profiler. More...
gos_result_t profiler_reset (const char *name)
Reset a profiler. More...
gos_result_t profiler_get_status (const char *name, profiler_status_t *status)
Get a profiler's status. More...
gos_result_t profiler_print_status (const char *name)
Print profiler's status. More...

Detailed Description

Profiling utility.

Function Documentation

profiler_begin()

gos_result_t profiler_begin ( const char * name )

Start profiler.

Parameters
name Name of profiler
Returns
gos_result_t result of API

profiler_end()

gos_result_t profiler_end ( const char * name )

Stop profiler.

Parameters
name Name of profiler
Returns
gos_result_t result of API

profiler_get_status()

gos_result_t profiler_get_status ( const char * name,
profiler_status_t * status
)

Get a profiler's status.

Parameters
name Name of profiler
status profiler_status_t containing current status of profiler
Returns
gos_result_t result of API

profiler_print_status()

gos_result_t profiler_print_status ( const char * name )

Print profiler's status.

Parameters
name Name of profiler
Returns
gos_result_t result of API

profiler_register()

gos_result_t profiler_register ( const char * name,
const profiler_config_t * config
)

Register a profiler.

Manually register a profiler with a configuration. See DEFINE_PROFILER for automatically registering all profilers.

Parameters
name Name of profiler
config profiler_config_t profiler configuration, leave NULL to use default config
Returns
gos_result_t result of API

profiler_register_all()

gos_result_t profiler_register_all ( void )

Register all profilers.

Register all profilers, see DEFINE_PROFILER for more details.

Returns
gos_result_t result of API

profiler_reset()

gos_result_t profiler_reset ( const char * name )

Reset a profiler.

Reset a profiler's stats

Parameters
name Name of profiler
Returns
gos_result_t result of API

profiler_set_parent()

gos_result_t profiler_set_parent ( const char * name,
const char * parent_name
)

Set a profiler's 'parent' profiler.

Parameters
name Name of profiler
parent_name Name of parent profiler
Returns
gos_result_t result of API

profiler_unregister()

gos_result_t profiler_unregister ( const char * name )

Unregister a profiler.

Unregister a profiler

Parameters
name Name of profiler
Returns
gos_result_t result of API