This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
[PATCH] z8k fixes
- To: binutils at sources dot redhat dot com
- Subject: [PATCH] z8k fixes
- From: Christian Groessler <cpg at aladdin dot de>
- Date: 24 Sep 2001 17:45:41 +0200
- Cc: cpg at aladdin dot de
Hi,
gas/config/tc-z8k.c did not build since a change from last week.
Another change in the disassembler creates the same format as the
assembler uses for an indirect register access.
regards,
chris
gas/ChangeLog:
2001-09-24 Christian Groessler <cpg@aladdin.de>
* config/tc-z8k.c: Include opcodes/z8k-opc.h after bfd.h
since z8k-opc.h now uses the PARAMS macro.
opcodes/ChangeLog:
2001-09-24 Christian Groessler <cpg@aladdin.de>
* z8k-dis.c (unparse_intstr): Fixed formatting. Change
disassembly of indirect register memory accesses to be same
format the assembler accepts.
Index: gas/config/tc-z8k.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-z8k.c,v
retrieving revision 1.13
diff -p -u -r1.13 tc-z8k.c
--- tc-z8k.c 2001/09/19 05:33:31 1.13
+++ tc-z8k.c 2001/09/24 15:32:57
@@ -24,11 +24,10 @@
#define DEFINE_TABLE
#include <stdio.h>
-#include "opcodes/z8k-opc.h"
-
#include "as.h"
#include "bfd.h"
#include "safe-ctype.h"
+#include "opcodes/z8k-opc.h"
const char comment_chars[] = "!";
const char line_comment_chars[] = "#";
Index: opcodes/z8k-dis.c
===================================================================
RCS file: /cvs/src/src/opcodes/z8k-dis.c,v
retrieving revision 1.9
diff -p -u -r1.9 z8k-dis.c
--- z8k-dis.c 2001/08/26 11:47:39 1.9
+++ z8k-dis.c 2001/09/24 15:32:58
@@ -540,7 +540,10 @@ unparse_instr (instr_data, is_segmented)
strcat (out_str, tmp_str);
break;
case CLASS_IR:
- sprintf (tmp_str, "@R%ld", instr_data->arg_reg[datum_value]);
+ if (is_segmented)
+ sprintf (tmp_str, "rr%ld", instr_data->arg_reg[datum_value]);
+ else
+ sprintf (tmp_str, "r%ld", instr_data->arg_reg[datum_value]);
strcat (out_str, tmp_str);
break;
case CLASS_FLAGS:
@@ -549,14 +552,10 @@ unparse_instr (instr_data, is_segmented)
break;
case CLASS_REG_BYTE:
if (instr_data->arg_reg[datum_value] >= 0x8)
- {
- sprintf (tmp_str, "rl%ld",
- instr_data->arg_reg[datum_value] - 0x8);
- }
+ sprintf (tmp_str, "rl%ld",
+ instr_data->arg_reg[datum_value] - 0x8);
else
- {
- sprintf (tmp_str, "rh%ld", instr_data->arg_reg[datum_value]);
- }
+ sprintf (tmp_str, "rh%ld", instr_data->arg_reg[datum_value]);
strcat (out_str, tmp_str);
break;
case CLASS_REG_WORD: