mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-08-06 06:45:56 +08:00
* dwarf2loc.c (unimplemented): Handle unnamed opcodes.
(compile_dwarf_to_ax) <default>: Use unimplemented. <DW_OP_deref>: Update. (disassemble_dwarf_expression): Update. * dwarf2read.c (dwarf_stack_op_name): Remove 'def' argument. (decode_locdesc): Update. * dwarf2expr.h (dwarf_stack_op_name): Update.
This commit is contained in:
@ -1,3 +1,13 @@
|
|||||||
|
2011-02-16 Tom Tromey <tromey@redhat.com>
|
||||||
|
|
||||||
|
* dwarf2loc.c (unimplemented): Handle unnamed opcodes.
|
||||||
|
(compile_dwarf_to_ax) <default>: Use unimplemented.
|
||||||
|
<DW_OP_deref>: Update.
|
||||||
|
(disassemble_dwarf_expression): Update.
|
||||||
|
* dwarf2read.c (dwarf_stack_op_name): Remove 'def' argument.
|
||||||
|
(decode_locdesc): Update.
|
||||||
|
* dwarf2expr.h (dwarf_stack_op_name): Update.
|
||||||
|
|
||||||
2011-02-16 Tom Tromey <tromey@redhat.com>
|
2011-02-16 Tom Tromey <tromey@redhat.com>
|
||||||
|
|
||||||
* ax.h (struct aop_map) <name>: Now const.
|
* ax.h (struct aop_map) <name>: Now const.
|
||||||
|
@ -229,7 +229,7 @@ const gdb_byte *read_uleb128 (const gdb_byte *buf, const gdb_byte *buf_end,
|
|||||||
const gdb_byte *read_sleb128 (const gdb_byte *buf, const gdb_byte *buf_end,
|
const gdb_byte *read_sleb128 (const gdb_byte *buf, const gdb_byte *buf_end,
|
||||||
LONGEST * r);
|
LONGEST * r);
|
||||||
|
|
||||||
const char *dwarf_stack_op_name (unsigned int, int);
|
const char *dwarf_stack_op_name (unsigned int);
|
||||||
|
|
||||||
void dwarf_expr_require_composition (const gdb_byte *, const gdb_byte *,
|
void dwarf_expr_require_composition (const gdb_byte *, const gdb_byte *,
|
||||||
const char *);
|
const char *);
|
||||||
|
@ -1334,8 +1334,14 @@ dwarf2_loc_desc_needs_frame (const gdb_byte *data, unsigned short size,
|
|||||||
static void
|
static void
|
||||||
unimplemented (unsigned int op)
|
unimplemented (unsigned int op)
|
||||||
{
|
{
|
||||||
error (_("DWARF operator %s cannot be translated to an agent expression"),
|
const char *name = dwarf_stack_op_name (op);
|
||||||
dwarf_stack_op_name (op, 1));
|
|
||||||
|
if (name)
|
||||||
|
error (_("DWARF operator %s cannot be translated to an agent expression"),
|
||||||
|
name);
|
||||||
|
else
|
||||||
|
error (_("Unknown DWARF operator 0x%02x cannot be to an agent expression"),
|
||||||
|
op);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* A helper function to convert a DWARF register to an arch register.
|
/* A helper function to convert a DWARF register to an arch register.
|
||||||
@ -1793,8 +1799,10 @@ compile_dwarf_to_ax (struct agent_expr *expr, struct axs_value *loc,
|
|||||||
ax_simple (expr, aop_ref64);
|
ax_simple (expr, aop_ref64);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
/* Note that dwarf_stack_op_name will never return
|
||||||
|
NULL here. */
|
||||||
error (_("Unsupported size %d in %s"),
|
error (_("Unsupported size %d in %s"),
|
||||||
size, dwarf_stack_op_name (op, 1));
|
size, dwarf_stack_op_name (op));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -2070,7 +2078,7 @@ compile_dwarf_to_ax (struct agent_expr *expr, struct axs_value *loc,
|
|||||||
unimplemented (op);
|
unimplemented (op);
|
||||||
|
|
||||||
default:
|
default:
|
||||||
error (_("Unhandled dwarf expression opcode 0x%x"), op);
|
unimplemented (op);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2295,7 +2303,7 @@ disassemble_dwarf_expression (struct ui_file *stream,
|
|||||||
LONGEST l;
|
LONGEST l;
|
||||||
const char *name;
|
const char *name;
|
||||||
|
|
||||||
name = dwarf_stack_op_name (op, 0);
|
name = dwarf_stack_op_name (op);
|
||||||
|
|
||||||
if (!name)
|
if (!name)
|
||||||
error (_("Unrecognized DWARF opcode 0x%02x at %ld"),
|
error (_("Unrecognized DWARF opcode 0x%02x at %ld"),
|
||||||
|
@ -12497,7 +12497,7 @@ dwarf_form_name (unsigned form)
|
|||||||
/* Convert a DWARF stack opcode into its string name. */
|
/* Convert a DWARF stack opcode into its string name. */
|
||||||
|
|
||||||
const char *
|
const char *
|
||||||
dwarf_stack_op_name (unsigned op, int def)
|
dwarf_stack_op_name (unsigned op)
|
||||||
{
|
{
|
||||||
switch (op)
|
switch (op)
|
||||||
{
|
{
|
||||||
@ -12819,7 +12819,7 @@ dwarf_stack_op_name (unsigned op, int def)
|
|||||||
case DW_OP_GNU_implicit_pointer:
|
case DW_OP_GNU_implicit_pointer:
|
||||||
return "DW_OP_GNU_implicit_pointer";
|
return "DW_OP_GNU_implicit_pointer";
|
||||||
default:
|
default:
|
||||||
return def ? "OP_<unknown>" : NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -13743,8 +13743,17 @@ decode_locdesc (struct dwarf_block *blk, struct dwarf2_cu *cu)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
complaint (&symfile_complaints, _("unsupported stack op: '%s'"),
|
{
|
||||||
dwarf_stack_op_name (op, 1));
|
const char *name = dwarf_stack_op_name (op);
|
||||||
|
|
||||||
|
if (name)
|
||||||
|
complaint (&symfile_complaints, _("unsupported stack op: '%s'"),
|
||||||
|
name);
|
||||||
|
else
|
||||||
|
complaint (&symfile_complaints, _("unsupported stack op: '%02x'"),
|
||||||
|
op);
|
||||||
|
}
|
||||||
|
|
||||||
return (stack[stacki]);
|
return (stack[stacki]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user