Subversion Repositories HelenOS

Rev

Rev 4132 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4132 Rev 4137
Line 39... Line 39...
39
#include <interrupt.h>
39
#include <interrupt.h>
40
#include <arch/asm.h>
40
#include <arch/asm.h>
41
#include <arch/register.h>
41
#include <arch/register.h>
42
#include <debug.h>
42
#include <debug.h>
43
#include <print.h>
43
#include <print.h>
44
 
-
 
45
#ifdef CONFIG_SYMTAB
-
 
46
#include <symtab.h>
44
#include <symtab.h>
47
#endif
-
 
48
 
45
 
49
void dump_istate(istate_t *istate)
46
void dump_istate(istate_t *istate)
50
{
47
{
51
    char *tpcs, *tnpcs;
48
    char *tpcs, *tnpcs;
52
 
49
 
53
#ifdef CONFIG_SYMTAB
-
 
54
    tpcs = get_symtab_entry(istate->tpc);
50
    tpcs = symtab_fmt_name_lookup(istate->tpc);
55
    tnpcs = get_symtab_entry(istate->tnpc);
51
    tnpcs = symtab_fmt_name_lookup(istate->tnpc);
56
#else
52
 
57
    tpcs = tnpcs = "n/a";
-
 
58
#endif
-
 
59
    printf("TSTATE=%#" PRIx64 "\n", istate->tstate);
53
    printf("TSTATE=%#" PRIx64 "\n", istate->tstate);
60
    printf("TPC=%#" PRIx64 " (%s)\n", istate->tpc, tpcs);
54
    printf("TPC=%#" PRIx64 " (%s)\n", istate->tpc, tpcs);
61
    printf("TNPC=%#" PRIx64 " (%s)\n", istate->tnpc, tnpcs);
55
    printf("TNPC=%#" PRIx64 " (%s)\n", istate->tnpc, tnpcs);
62
}
56
}
63
 
57