+2013-12-06 Andrew Burgess <aburgess@broadcom.com>
+ Pedro Alves <palves@redhat.com>
+
+ * exceptions.h (errors): Add OPTIMIZED_OUT_ERROR.
+ * dwarf2loc.c (write_pieced_value): Throw OPTIMIZED_OUT_ERROR.
+ * frame.c (frame_unwind_register): Throw OPTIMIZED_OUT_ERROR.
+ * spu-tdep.c (spu_software_single_step): Throw
+ OPTIMIZED_OUT_ERROR.
+ * valops.c (value_assign): Throw OPTIMIZED_OUT_ERROR.
+
2013-12-06 Tom Tromey <tromey@redhat.com>
* objfiles.c (free_objfile): Update comment.
&optim, &unavail))
{
if (optim)
- error (_("Can't do read-modify-write to "
- "update bitfield; containing word has been "
- "optimized out"));
+ throw_error (OPTIMIZED_OUT_ERROR,
+ _("Can't do read-modify-write to "
+ "update bitfield; containing word "
+ "has been optimized out"));
if (unavail)
throw_error (NOT_AVAILABLE_ERROR,
_("Can't do read-modify-write to update "
traceframe. */
NOT_AVAILABLE_ERROR,
+ /* Value was optimized out. Note: if the value was a register, this
+ means the register was not saved in the frame. */
+ OPTIMIZED_OUT_ERROR,
+
/* DW_OP_GNU_entry_value resolving failed. */
NO_ENTRY_VALUE_ERROR,
&lval, &addr, &realnum, buf);
if (optimized)
- error (_("Register %d was not saved"), regnum);
+ throw_error (OPTIMIZED_OUT_ERROR,
+ _("Register %d was not saved"), regnum);
if (unavailable)
throw_error (NOT_AVAILABLE_ERROR,
_("Register %d is not available"), regnum);
else
{
if (optim)
- error (_("Could not determine address of "
- "single-step breakpoint."));
+ throw_error (OPTIMIZED_OUT_ERROR,
+ _("Could not determine address of "
+ "single-step breakpoint."));
if (unavail)
throw_error (NOT_AVAILABLE_ERROR,
_("Could not determine address of "
&optim, &unavail))
{
if (optim)
- error (_("value has been optimized out"));
+ throw_error (OPTIMIZED_OUT_ERROR,
+ _("value has been optimized out"));
if (unavail)
throw_error (NOT_AVAILABLE_ERROR,
_("value is not available"));