/* Disassemble V850 instructions.
- Copyright (C) 1996 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
#include <stdio.h>
-#include "ansidecl.h"
+#include "sysdep.h"
#include "opcode/v850.h"
#include "dis-asm.h"
+#include "opintl.h"
static const char *const v850_reg_names[] =
{ "r0", "r1", "r2", "sp", "gp", "r5", "r6", "r7",
static const char *const v850_sreg_names[] =
{ "eipc", "eipsw", "fepc", "fepsw", "ecr", "psw", "sr6", "sr7",
"sr8", "sr9", "sr10", "sr11", "sr12", "sr13", "sr14", "sr15",
-/* start-sanitize-v850e */
"ctpc", "ctpsw", "dbpc", "dbpsw", "ctbp", "sr21", "sr22", "sr23",
"sr24", "sr25", "sr26", "sr27", "sr28", "sr29", "sr30", "sr31",
-/* end-sanitize-v850e */
"sr16", "sr17", "sr18", "sr19", "sr20", "sr21", "sr22", "sr23",
"sr24", "sr25", "sr26", "sr27", "sr28", "sr29", "sr30", "sr31" };
int bytes_read;
int target_processor;
-/* start-sanitize-v850e */
/* Special case: 32 bit MOV */
if ((insn & 0xffe0) == 0x0620)
short_op = true;
-/* end-sanitize-v850e */
bytes_read = short_op ? 2 : 4;
target_processor = PROCESSOR_V850;
break;
-/* start-sanitize-v850e */
case bfd_mach_v850e:
target_processor = PROCESSOR_V850E;
break;
- case bfd_mach_v850eq:
- target_processor = PROCESSOR_V850EQ;
+ case bfd_mach_v850ea:
+ target_processor = PROCESSOR_V850EA;
break;
-/* end-sanitize-v850e */
}
/* Find the opcode. */
match = 1;
(*info->fprintf_func) (info->stream, "%s\t", op->name);
-//fprintf (stderr, "match: mask: %x insn: %x, opcode: %x, name: %s\n", op->mask, insn, op->opcode, op->name );
+/*fprintf (stderr, "match: mask: %x insn: %x, opcode: %x, name: %s\n", op->mask, insn, op->opcode, op->name );*/
memop = op->memop;
/* Now print the operands.
break;
}
-/* start-sanitize-v850e */
case V850E_PUSH_POP:
{
static int list12_regs[32] = { 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 31, 29, 28, 23, 22, 21, 20, 27, 26, 25, 24 };
case 0xfff8000f: regs = list18_h_regs; break;
case 0xfff8001f: regs = list18_l_regs; value &= ~0x10; break; /* Do not include magic bit */
default:
- fprintf (stderr, "unknown operand shift: %x\n", operand->shift );
+ /* xgettext:c-format */
+ fprintf (stderr, _("unknown operand shift: %x\n"), operand->shift );
abort();
}
switch (regs[ i ])
{
default: mask |= (1 << regs[ i ]); break;
- case 0: fprintf (stderr, "unknown pop reg: %d\n", i ); abort();
+ /* xgettext:c-format */
+ case 0: fprintf (stderr, _("unknown pop reg: %d\n"), i ); abort();
case -1: pc = true; break;
case -2: sr = true; break;
}
info->memory_error_func (status, memaddr + bytes_read, info);
}
break;
-/* end-sanitize-v850e */
}
/* Handle jmp correctly. */
{
int status;
bfd_byte buffer[ 4 ];
- unsigned long insn;
+ unsigned long insn = 0;
/* First figure out how big the opcode is. */