arch: arc: Added benchmark related hooks.

The benchmark application timing_info needs certain hooks to be
present in the kernel to get the accurate measurements. This
patch adds these hook at all the required locations.

Signed-off-by: Adithya Baglody <adithya.nagaraj.baglody@intel.com>
This commit is contained in:
Adithya Baglody 2018-06-27 14:10:30 +05:30 committed by Anas Nashif
commit db0c5ca08b
4 changed files with 145 additions and 0 deletions

View file

@ -185,6 +185,10 @@ static inline void program_max_cycles(void)
*/
void _timer_int_handler(void *unused)
{
#ifdef CONFIG_EXECUTION_BENCHMARKING
extern void read_timer_start_of_tick_handler(void);
read_timer_start_of_tick_handler();
#endif
ARG_UNUSED(unused);
/* clear the interrupt by writing 0 to IP bit of the control register */
timer0_control_register_set(_ARC_V2_TMR_CTRL_NH | _ARC_V2_TMR_CTRL_IE);
@ -230,6 +234,10 @@ void _timer_int_handler(void *unused)
update_accumulated_count();
#endif
#ifdef CONFIG_EXECUTION_BENCHMARKING
extern void read_timer_end_of_tick_handler(void);
read_timer_end_of_tick_handler();
#endif
}
#ifdef CONFIG_TICKLESS_KERNEL