Eric Pouech : winedbg: Correctly display whether we're in 32 vs 64 bit code .
Alexandre Julliard
julliard at winehq.org
Tue Apr 20 11:32:21 CDT 2010
Module: wine
Branch: master
Commit: 3833600c7956c7f377b7ec8042e58d59508f1365
URL: http://source.winehq.org/git/wine.git/?a=commit;h=3833600c7956c7f377b7ec8042e58d59508f1365
Author: Eric Pouech <eric.pouech at orange.fr>
Date: Mon Apr 19 22:33:19 2010 +0200
winedbg: Correctly display whether we're in 32 vs 64 bit code.
---
programs/winedbg/tgt_active.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/programs/winedbg/tgt_active.c b/programs/winedbg/tgt_active.c
index 0511063..0572d95 100644
--- a/programs/winedbg/tgt_active.c
+++ b/programs/winedbg/tgt_active.c
@@ -131,7 +131,8 @@ static unsigned dbg_exception_prolog(BOOL is_debug, BOOL first_chance, const EXC
switch (addr.Mode)
{
case AddrModeFlat:
- dbg_printf(" in 32-bit code (%s)",
+ dbg_printf(" in %d-bit code (%s)",
+ be_cpu->pointer_size * 8,
memory_offset_to_string(hexbuf, addr.Offset, 0));
break;
case AddrModeReal:
@@ -141,7 +142,7 @@ static unsigned dbg_exception_prolog(BOOL is_debug, BOOL first_chance, const EXC
dbg_printf(" in 16-bit code (%04x:%04x)", addr.Segment, (unsigned) addr.Offset);
break;
case AddrMode1632:
- dbg_printf(" in 32-bit code (%04x:%08lx)", addr.Segment, (unsigned long) addr.Offset);
+ dbg_printf(" in segmented 32-bit code (%04x:%08lx)", addr.Segment, (unsigned long) addr.Offset);
break;
default: dbg_printf(" bad address");
}
@@ -164,15 +165,14 @@ static unsigned dbg_exception_prolog(BOOL is_debug, BOOL first_chance, const EXC
if (addr.Mode != dbg_curr_thread->addr_mode)
{
const char* name = NULL;
-
+
switch (addr.Mode)
{
case AddrMode1616: name = "16 bit"; break;
- case AddrMode1632: name = "32 bit"; break;
+ case AddrMode1632: name = "segmented 32 bit"; break;
case AddrModeReal: name = "vm86"; break;
- case AddrModeFlat: name = "32 bit"; break;
+ case AddrModeFlat: name = be_cpu->pointer_size == 4 ? "32 bit" : "64 bit"; break;
}
-
dbg_printf("In %s mode.\n", name);
dbg_curr_thread->addr_mode = addr.Mode;
}
More information about the wine-cvs
mailing list