diff options
author | Jim Wilson <wilson@tuliptree.org> | 2005-11-23 04:58:37 +0000 |
---|---|---|
committer | Jim Wilson <wilson@tuliptree.org> | 2005-11-23 04:58:37 +0000 |
commit | aa2273ba99118d3cb08e8bdace72159cb1e0314e (patch) | |
tree | 160909fe0fb883e46dd9a123302f841b798ff3f6 /opcodes | |
parent | cb3b8d911b227c9ae3ab62ba175688721f86f23e (diff) | |
download | gdb-aa2273ba99118d3cb08e8bdace72159cb1e0314e.zip gdb-aa2273ba99118d3cb08e8bdace72159cb1e0314e.tar.gz gdb-aa2273ba99118d3cb08e8bdace72159cb1e0314e.tar.bz2 |
Fix 32-bit host/target --enable-targets=all build failure from Doug Evans.
* ia64-gen.c (_opcode_int64_low, _opcode_int64_high,
opcode_fprintf_vma): New.
(print_main_table): New opcode_fprintf_vma instead of fprintf_vma.
Diffstat (limited to 'opcodes')
-rw-r--r-- | opcodes/ChangeLog | 6 | ||||
-rw-r--r-- | opcodes/ia64-gen.c | 13 |
2 files changed, 17 insertions, 2 deletions
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index 83dee04..e68bab5 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,3 +1,9 @@ +2005-11-22 James E Wilson <wilson@specifix.com> + + * ia64-gen.c (_opcode_int64_low, _opcode_int64_high, + opcode_fprintf_vma): New. + (print_main_table): New opcode_fprintf_vma instead of fprintf_vma. + 2005-11-16 Alan Modra <amodra@bigpond.net.au> * ppc-opc.c (powerpc_opcodes): Add frin,friz,frip,frim. Correct diff --git a/opcodes/ia64-gen.c b/opcodes/ia64-gen.c index e12c145..cb86e94 100644 --- a/opcodes/ia64-gen.c +++ b/opcodes/ia64-gen.c @@ -54,6 +54,15 @@ #include <libintl.h> #define _(String) gettext (String) +/* This is a copy of fprintf_vma from bfd/bfd-in2.h. We have to use this + always, because we might be compiled without BFD64 defined, if configured + for a 32-bit target and --enable-targets=all is used. This will work for + both 32-bit and 64-bit hosts. */ +#define _opcode_int64_low(x) ((unsigned long) (((x) & 0xffffffff))) +#define _opcode_int64_high(x) ((unsigned long) (((x) >> 32) & 0xffffffff)) +#define opcode_fprintf_vma(s,x) \ + fprintf ((s), "%08lx%08lx", _opcode_int64_high (x), _opcode_int64_low (x)) + const char * program_name = NULL; int debug = 0; @@ -2701,9 +2710,9 @@ print_main_table (void) ptr->name->num, ptr->opcode->type, ptr->opcode->num_outputs); - fprintf_vma (stdout, ptr->opcode->opcode); + opcode_fprintf_vma (stdout, ptr->opcode->opcode); printf ("ull, 0x"); - fprintf_vma (stdout, ptr->opcode->mask); + opcode_fprintf_vma (stdout, ptr->opcode->mask); printf ("ull, { %d, %d, %d, %d, %d }, 0x%x, %d, },\n", ptr->opcode->operands[0], ptr->opcode->operands[1], |