Skip to content

Commit

Permalink
[TRACE] Added stack top function name decoding when applicable
Browse files Browse the repository at this point in the history
  • Loading branch information
ptitSeb committed Aug 26, 2023
1 parent df8930a commit 299ddb2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/emu/x86run_private.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include "x86trace.h"
#endif
#include "x86tls.h"
#include "x86emu.h"

#define PARITY(x) (((emu->x86emu_parity_tab[(x) / 32] >> ((x) % 32)) & 1) == 0)
#define XOR2(x) (((x) ^ ((x)>>1)) & 0x1)
Expand Down Expand Up @@ -882,6 +883,7 @@ void PrintTrace(x86emu_t* emu, uintptr_t ip, int dynarec)
printFunctionAddr(*(uintptr_t*)(R_ESP), "=> ");
} else if(peek==0x55) {
printf_log(LOG_NONE, " => STACK_TOP: %p", *(void**)(R_ESP));
printFunctionAddr(*(uintptr_t*)(R_ESP), "top:");
printFunctionAddr(ip, "here: ");
} else if(peek==0xE8) { // Call
uintptr_t nextaddr = ip + 5 + PK32(1);
Expand Down

0 comments on commit 299ddb2

Please sign in to comment.