mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-09-12 09:07:46 -04:00
Print task priority value in vTaskGetRunTimeStats()
Show task priority for better understanding of task run time consumption
This commit is contained in:
parent
bda9869271
commit
b9b6987344
2 changed files with 3 additions and 2 deletions
|
@ -1741,8 +1741,8 @@
|
|||
*
|
||||
* vTaskGetRunTimeStats() calls uxTaskGetSystemState(), then formats part of the
|
||||
* uxTaskGetSystemState() output into a human readable table that displays the
|
||||
* amount of time each task has spent in the Running state in both absolute and
|
||||
* percentage terms.
|
||||
* task priority and amount of time each task has spent in the Running state
|
||||
* in both absolute and percentage terms.
|
||||
*
|
||||
* vTaskGetRunTimeStats() has a dependency on the sprintf() C library function
|
||||
* that might bloat the code size, use a lot of stack, and provide different
|
||||
|
|
1
tasks.c
1
tasks.c
|
@ -4601,6 +4601,7 @@ static void prvResetNextTaskUnblockTime( void )
|
|||
* spaces so it can be printed in tabular form more
|
||||
* easily. */
|
||||
pcWriteBuffer = prvWriteNameToBuffer( pcWriteBuffer, pxTaskStatusArray[ x ].pcTaskName );
|
||||
pcWriteBuffer += sprintf( pcWriteBuffer, "\t\t%u", ( unsigned int ) pxTaskStatusArray[ x ].uxBasePriority );
|
||||
|
||||
if( ulStatsAsPercentage > 0UL )
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue