From f980561ee073a7f24f65ed572852fa96edfa1708 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Mon, 10 Mar 2014 10:04:09 +0100 Subject: score: Add per-CPU profiling Add per-CPU profiling stats API. Implement the thread dispatch disable level profiling. The interrupt profiling must be implemented in CPU port specific parts (mostly assembler code). Add a support function _Profiling_Outer_most_interrupt_entry_and_exit() for this purpose. --- cpukit/score/src/threaddispatch.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'cpukit/score/src/threaddispatch.c') diff --git a/cpukit/score/src/threaddispatch.c b/cpukit/score/src/threaddispatch.c index ecf6810716..da357c4a44 100644 --- a/cpukit/score/src/threaddispatch.c +++ b/cpukit/score/src/threaddispatch.c @@ -40,6 +40,7 @@ void _Thread_Dispatch( void ) per_cpu = _Per_CPU_Get(); _Assert( per_cpu->thread_dispatch_disable_level == 0 ); + _Profiling_Thread_dispatch_disable( per_cpu, 0 ); per_cpu->thread_dispatch_disable_level = 1; #if defined( RTEMS_SMP ) @@ -170,6 +171,7 @@ void _Thread_Dispatch( void ) post_switch: _Assert( per_cpu->thread_dispatch_disable_level == 1 ); per_cpu->thread_dispatch_disable_level = 0; + _Profiling_Thread_dispatch_enable( per_cpu, 0 ); _Per_CPU_Release_and_ISR_enable( per_cpu, level ); -- cgit v1.2.3