* h8300-dis.c, mips-dis.c: Don't use true and false.
This commit is contained in:
parent
22691fe7be
commit
fea3fe6407
2 changed files with 24 additions and 6 deletions
|
@ -1,3 +1,11 @@
|
|||
Tue Jun 28 13:22:06 1994 Stan Shebs (shebs@andros.cygnus.com)
|
||||
|
||||
* h8300-dis.c, mips-dis.c: Don't use true and false.
|
||||
|
||||
Thu Jun 23 12:53:19 1994 David J. Mackenzie (djm@rtl.cygnus.com)
|
||||
|
||||
* configure.in: Change --with-targets to --enable-targets.
|
||||
|
||||
Wed Jun 22 13:38:32 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
|
||||
|
||||
* mips-dis.c (_print_insn_mips): Build a static hash table mapping
|
||||
|
|
|
@ -93,10 +93,12 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
int rdisp = 0;
|
||||
int abs = 0;
|
||||
int plen = 0;
|
||||
static boolean init;
|
||||
static boolean init = 0;
|
||||
struct h8_opcode *q = h8_opcodes;
|
||||
char CONST **pregnames = hmode ? lregnames : wregnames;
|
||||
int status;
|
||||
int l;
|
||||
|
||||
unsigned char data[20];
|
||||
void *stream = info->stream;
|
||||
fprintf_ftype fprintf = info->fprintf_func;
|
||||
|
@ -104,7 +106,7 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
if (!init)
|
||||
{
|
||||
bfd_h8_disassemble_init ();
|
||||
init = true;
|
||||
init = 1;
|
||||
}
|
||||
|
||||
status = info->read_memory_func(addr, data, 2, info);
|
||||
|
@ -113,8 +115,11 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
info->memory_error_func(status, addr, info);
|
||||
return -1;
|
||||
}
|
||||
status = info->read_memory_func(addr, data+2, 8, info);
|
||||
|
||||
for (l = 2; status == 0 && l < 10; l+=2)
|
||||
{
|
||||
status = info->read_memory_func(addr+l, data+l, 2, info);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Find the exact opcode/arg combo */
|
||||
|
@ -132,7 +137,7 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
|
||||
thisnib = (len & 1) ? (thisnib & 0xf) : ((thisnib >> 4) & 0xf);
|
||||
|
||||
if (looking_for < 16)
|
||||
if (looking_for < 16 && looking_for >=0)
|
||||
{
|
||||
|
||||
if (looking_for != thisnib)
|
||||
|
@ -185,7 +190,10 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
| (data[2] << 8)
|
||||
| (data[3]);
|
||||
}
|
||||
|
||||
else if(looking_for & MEMIND)
|
||||
{
|
||||
abs = data[1];
|
||||
}
|
||||
else if (looking_for & L_32)
|
||||
{
|
||||
int i = len >> 1;
|
||||
|
@ -318,6 +326,8 @@ bfd_h8_disassemble (addr, info, hmode)
|
|||
|
||||
else if (x & PCREL)
|
||||
{
|
||||
if (x & L_16)
|
||||
abs +=2;
|
||||
fprintf (stream, ".%s%d (%x)", (char) abs > 0 ? "+" : "", (char) abs,
|
||||
addr + (char) abs + 2);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue