mirror of https://github.com/geohot/qira
move thumb flag to front of log
This commit is contained in:
parent
856fcb365e
commit
4a6a82c903
|
@ -23,5 +23,6 @@ CALLED_AS_CDA = False
|
|||
# turn this off for now on releases
|
||||
WITH_STATIC = False
|
||||
WITH_CAPSTONE = False
|
||||
|
||||
WITH_IDA = False
|
||||
|
||||
|
|
|
@ -267,8 +267,8 @@ class Program:
|
|||
continue
|
||||
#print repr(d)
|
||||
if self.fb == 0x28: # ARM
|
||||
inst = d[d.rfind(" ")+2:-1] #last bit now the thumb bit
|
||||
thumb_flag = d[-1]
|
||||
inst = d[d.rfind(" ")+2] #last bit now the thumb bit
|
||||
thumb_flag = d[0]
|
||||
if thumb_flag == 't':
|
||||
thumb = True
|
||||
elif thumb_flag == 'n':
|
||||
|
|
|
@ -309,6 +309,10 @@ void real_target_disas(FILE *out, CPUArchState *env, target_ulong code,
|
|||
}
|
||||
|
||||
for (pc = code; size > 0; pc += count, size -= count) {
|
||||
#ifdef TARGET_ARM
|
||||
if (flags & 1) fprintf(out, "t");
|
||||
else fprintf(out, "n");
|
||||
#endif
|
||||
fprintf(out, "0x" TARGET_FMT_lx ": ", pc);
|
||||
count = print_insn(pc, &s.info);
|
||||
#if 0
|
||||
|
@ -323,10 +327,6 @@ void real_target_disas(FILE *out, CPUArchState *env, target_ulong code,
|
|||
fprintf(out, " }");
|
||||
}
|
||||
#endif
|
||||
#ifdef TARGET_ARM
|
||||
if (flags & 1) fprintf(out, "t");
|
||||
else fprintf(out, "n");
|
||||
#endif
|
||||
fprintf(out, "\n");
|
||||
if (count < 0)
|
||||
break;
|
||||
|
|
|
@ -57,11 +57,6 @@ Trace::~Trace() {
|
|||
char Trace::get_type_from_flags(uint32_t flags) {
|
||||
if (!(flags & IS_VALID)) return '?';
|
||||
if (flags & IS_START) return 'I';
|
||||
/*
|
||||
if (flags & IS_START) {
|
||||
if (flags & IS_THUMB) return 'T'; // IS_THUMB implies IS_START
|
||||
else return 'I';
|
||||
*/
|
||||
if (flags & IS_SYSCALL) return 's';
|
||||
|
||||
if (flags & IS_MEM) {
|
||||
|
|
|
@ -85,7 +85,6 @@ struct change {
|
|||
#define IS_MEM 0x20000000
|
||||
#define IS_START 0x10000000
|
||||
#define IS_SYSCALL 0x08000000
|
||||
//#define IS_THUMB 0x04000000
|
||||
#define SIZE_MASK 0xFF
|
||||
|
||||
#define PAGE_INSTRUCTION 1
|
||||
|
|
Loading…
Reference in New Issue