Module Name: src
Committed By: drochner
Date: Fri Feb 18 18:00:52 UTC 2011
Modified Files:
src/sys/arch/amd64/amd64: db_disasm.c
Log Message:
fix misinterpretation of REX prefixes where use of the accumulator
as operand is hardwired into the instruction code,
mostly from Wolfgang Stukenbrock per PR port-amd64/44405
To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/amd64/amd64/db_disasm.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/amd64/amd64/db_disasm.c
diff -u src/sys/arch/amd64/amd64/db_disasm.c:1.13 src/sys/arch/amd64/amd64/db_disasm.c:1.14
--- src/sys/arch/amd64/amd64/db_disasm.c:1.13 Sat Mar 14 21:04:03 2009
+++ src/sys/arch/amd64/amd64/db_disasm.c Fri Feb 18 18:00:52 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: db_disasm.c,v 1.13 2009/03/14 21:04:03 dsl Exp $ */
+/* $NetBSD: db_disasm.c,v 1.14 2011/02/18 18:00:52 drochner Exp $ */
/*
* Mach Operating System
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_disasm.c,v 1.13 2009/03/14 21:04:03 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_disasm.c,v 1.14 2011/02/18 18:00:52 drochner Exp $");
#ifndef _KERNEL
#include "stubs.h"
@@ -1393,11 +1393,9 @@
case Si:
db_printf("%s", db_seg_reg[f_reg(inst)]);
break;
- case A: {
- int ext = ((rex & REX_w) != 0);
- db_printf("%s", db_reg[ext][size][0]); /* acc */
+ case A:
+ db_printf("%s", db_reg[0][size][0]); /* acc */
break;
- }
case BX:
if (seg)
db_printf("%s:", seg);