This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit] Fix mi-disassemble.exp regression


Jan Kratochvil wrote:

> On Sat, 11 Jul 2009 16:15:00 +0200, Hui Zhu wrote:
> > Fixed and checked-in.
> 
> this check-in
> 	http://sourceware.org/ml/gdb-cvs/2009-07/msg00089.html
> 	http://sourceware.org/ml/gdb-cvs/2009-07/msg00092.html
[snip]
> causes a regression on {x86_64,x86_64-32,i686}-fedora11-linux-gnu.

This is caused by this part of Hui's patch:

--- a/mi/mi-cmd-disas.c
+++ b/mi/mi-cmd-disas.c
@@ -156,6 +156,6 @@ mi_cmd_disassemble (char *command, char

   gdb_disassembly (gdbarch, uiout,
   		   file_string,
-		   mixed_source_and_assembly, how_many, low, high);
+		   DISASSEMBLY_SOURCE, how_many, low, high);

 }

Note how the new code completely ignores the mixed_source_and_assembly
flag (which is set from the mixed_mode MI parameter).

The following patch fixes this.
Tested on powerpc64-linux, committed to mainline.

Bye,
Ulrich

ChangeLog:

	* mi/mi-cmd-disas.c (mi_cmd_disassemble): Respect mixed_mode flag.

Index: gdb/mi/mi-cmd-disas.c
===================================================================
RCS file: /cvs/src/src/gdb/mi/mi-cmd-disas.c,v
retrieving revision 1.31
diff -u -p -r1.31 mi-cmd-disas.c
--- gdb/mi/mi-cmd-disas.c	11 Jul 2009 14:04:23 -0000	1.31
+++ gdb/mi/mi-cmd-disas.c	17 Jul 2009 15:50:06 -0000
@@ -156,6 +156,6 @@ mi_cmd_disassemble (char *command, char 
 
   gdb_disassembly (gdbarch, uiout,
   		   file_string,
-		   DISASSEMBLY_SOURCE, how_many, low, high);
-
+		   mixed_source_and_assembly? DISASSEMBLY_SOURCE : 0,
+		   how_many, low, high);
 }


-- 
  Dr. Ulrich Weigand
  GNU Toolchain for Linux on System z and Cell BE
  Ulrich.Weigand@de.ibm.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]