1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-19 23:22:16 +03:00

Corrected stack start and end in stack_thunk_dump_stack().

This commit is contained in:
M Hightower 2020-02-14 11:05:04 -08:00
parent 5efdc7762a
commit c07a1fd1b7

View File

@ -111,14 +111,14 @@ uint32_t stack_thunk_get_max_usage()
/* Print the stack from the first used 16-byte chunk to the top, decodable by the exception decoder */ /* Print the stack from the first used 16-byte chunk to the top, decodable by the exception decoder */
void stack_thunk_dump_stack() void stack_thunk_dump_stack()
{ {
uint32_t *pos = stack_thunk_top; uint32_t *pos = stack_thunk_ptr;
while (pos < stack_thunk_ptr) { while (pos < stack_thunk_top) {
if ((pos[0] != _stackPaint) || (pos[1] != _stackPaint) || (pos[2] != _stackPaint) || (pos[3] != _stackPaint)) if ((pos[0] != _stackPaint) || (pos[1] != _stackPaint) || (pos[2] != _stackPaint) || (pos[3] != _stackPaint))
break; break;
pos += 4; pos += 4;
} }
ets_printf(">>>stack>>>\n"); ets_printf(">>>stack>>>\n");
while (pos < stack_thunk_ptr) { while (pos < stack_thunk_top) {
ets_printf("%08x: %08x %08x %08x %08x\n", (int32_t)pos, pos[0], pos[1], pos[2], pos[3]); ets_printf("%08x: %08x %08x %08x %08x\n", (int32_t)pos, pos[0], pos[1], pos[2], pos[3]);
pos += 4; pos += 4;
} }