There are some other interesting OS related things we could keep track of. Note 
that these did not all come from me; others had input. I dont want to take all 
the credit; nor all the blame, lol.

1) Maximum amount of time interrupts were disabled.
2) Maximum amount of time a task stayed awake (i.e. time between waking up and 
going back to sleep on its own).
3) Maximum amount of time a task that a task spent waiting to run.
4) For semaphores and mutexes, we could also keep track of the maximum amount 
of time that a semaphore or mutex was held.


> On Jan 27, 2016, at 2:44 PM, Sterling Hughes <[email protected]> wrote:
> 
> Heehaw,
> 
> I'm looking to add statistics to the core RTOS (libs/os), to improve
> instrumentation.
> 
> Here are the commands, and data I'm bring back in those commands.  I'd
> love people's input on what else they think should be included here.
> 
> Taskinfo:
> 
> - Array of tasks, each containing:
>  - Task Name
>  - Priority
>  - Number of context switches
>  - Task Run Time
>  - State (RUN, SLEEP, SEM_WAIT, MUTEX_WAIT)
>  - Stack Usage
>  - Stack Size
>  - Last Sanity Checkin
>  - Next Sanity Checkin
> 
> Memory Pool Info:
> 
> - Array of memory pools, each containing:
>  - Memory Pool Name
>  - Pool Element Size
>  - Number of blocks in the pool
>  - Number of free blocks in the pool
>  - Address of last free, and allocate from this pool
>    (Should this be a variable size array?)
> 
> Also, right now memory pools are not centrally linked.  This change
> would require there to be a list of all memory pools initialized by
> the system, adding 4 bytes to the mempool structure, and 4 bytes of
> .bss.  Any objections?
> 
> Sterling

Reply via email to