Some OS APIs provide a stack trace; I know that the Windows API has StackWalk64 or something like that that can do a stack trace.
However, if you cannot depend on such a thing, then almost all you can do is either debug the assembly or do it manually.
Puppy source
share