mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-30 04:06:33 +08:00
Don't try to print the idle stack usage (we need to fix it up before the code can be adapted to measure it).
This commit is contained in:
+8
-4
@@ -174,11 +174,15 @@ end
|
|||||||
define showtaskstack
|
define showtaskstack
|
||||||
set $task = (struct _TCB *)$arg0
|
set $task = (struct _TCB *)$arg0
|
||||||
|
|
||||||
set $stack_free = 0
|
if $task == &g_idletcb
|
||||||
while ($stack_free < $task->adj_stack_size) && *(uint8_t *)($task->stack_alloc_ptr + $stack_free)
|
printf "can't measure idle stack\n"
|
||||||
set $stack_free = $stack_free + 1
|
else
|
||||||
|
set $stack_free = 0
|
||||||
|
while ($stack_free < $task->adj_stack_size) && *(uint8_t *)($task->stack_alloc_ptr + $stack_free)
|
||||||
|
set $stack_free = $stack_free + 1
|
||||||
|
end
|
||||||
|
printf" stack 0x%08x-0x%08x (%d) %d free\n", $task->stack_alloc_ptr, $task->adj_stack_ptr, $task->adj_stack_size, $stack_free
|
||||||
end
|
end
|
||||||
printf" stack 0x%08x-0x%08x (%d) %d free\n", $task->stack_alloc_ptr, $task->adj_stack_ptr, $task->adj_stack_size, $stack_free
|
|
||||||
end
|
end
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ end
|
|||||||
|
|
||||||
define _perf_print
|
define _perf_print
|
||||||
set $hdr = (struct perf_ctr_header *)$arg0
|
set $hdr = (struct perf_ctr_header *)$arg0
|
||||||
printf "%p\n", $hdr
|
#printf "%p\n", $hdr
|
||||||
printf "%s: ", $hdr->name
|
printf "%s: ", $hdr->name
|
||||||
# PC_COUNT
|
# PC_COUNT
|
||||||
if $hdr->type == 0
|
if $hdr->type == 0
|
||||||
|
|||||||
Reference in New Issue
Block a user