FreeRTOS port on GAP8/RISC-V
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gap9/pmsis/drivers/perf/perf_internal.c File Reference

Macros

#define CSR_PCMR_DISABLE
 
#define CSR_PCMR_ENABLE
 
#define CSR_PCMR_SATURATE
 
#define PCMR_ACTIVE
 
#define PERF_TIMER_FC
 
#define PERF_TIMER_CL
 

Functions

static void __pi_perf_enable_timer (timer_e timer)
 
static void __pi_perf_save (perf_t *perf, timer_e timer)
 
void __pi_perf_fc_conf (uint32_t events)
 Configure FC perf counter. More...
 
void __pi_perf_fc_reset ()
 Reset FC perf counters. More...
 
void __pi_perf_fc_start ()
 Start FC perf counters. More...
 
void __pi_perf_fc_stop ()
 Stop FC perf counters. More...
 
uint32_t __pi_perf_fc_read (int id)
 Read FC perf counters value. More...
 

Variables

static perf_t fc_perf_val
 

Macro Definition Documentation

#define CSR_PCMR_DISABLE

Referenced by __pi_perf_fc_stop().

#define CSR_PCMR_ENABLE

Referenced by __pi_perf_fc_start().

#define CSR_PCMR_SATURATE

Referenced by __pi_perf_fc_start().

#define PCMR_ACTIVE
#define PERF_TIMER_CL

Function Documentation

static void __pi_perf_enable_timer ( timer_e  timer)
static
void __pi_perf_fc_conf ( uint32_t  events)

This function configures Performance Counter with given events mask.

Parameters
eventsEvents mask.

References __pi_perf_mask_events_set(), and perf_t::perf_mask.

uint32_t __pi_perf_fc_read ( int  id)

This function returns Performance Counter for a given event.

Parameters
idID of the event.
Returns
Value Counter's value for the given event.

References __pi_perf_save(), perf_t::perf_counter, and PERF_TIMER_FC.

void __pi_perf_fc_reset ( )

This function resets all Performance Counter.

References __pi_perf_counters_reset(), perf_t::perf_mask, PERF_TIMER_FC, and pi_timer_reset().

void __pi_perf_fc_start ( )
void __pi_perf_fc_stop ( )

This function stops Performance Counter.

References __pi_perf_counter_enable(), __pi_perf_save(), CSR_PCMR_DISABLE, perf_t::perf_mask, PERF_TIMER_FC, and pi_timer_stop().

static void __pi_perf_save ( perf_t perf,
timer_e  timer 
)
static

Variable Documentation

perf_t fc_perf_val
static