+2001-02-24 Kevin Buettner <kevinb@redhat.com>
+
+ * buildsym.c (push_subfile, pop_subfile): Replace call to abort()
+ with call to internal_error().
+ * dbxread.c (process_one_symbol): Likewise.
+ * exec.c (build_section_table, xfer_memory): Likewise.
+ * h8500-tdep.c (h8500_register_size, h8500_register_virtual_type):
+ Likewise.
+ * hpread.c (hpread_type_translate, hpread_read_array_type)
+ (hpread_type_lookup): Likewise.
+ * i386-tdep.c (gdb_print_insn_i386): Likewise.
+ * i960-tdep.c (mem): Likewise
+ * inflow.c (set_sigio_trap, clear_sigio_trap): Likewise.
+ * infptrace.c (child_resume): Likewise.
+ * infttrace.c (_initialize_infttrace): Likewise.
+ * language.c (binop_result_type, add_language): Likewise.
+ * lynx-nat.c (store_inferior_registers): Likewise.
+ * m3-nat.c (port_chain_insert, m3_trace_me): Likewise.
+ * mdebugread.c (parse_partial_symbols): Likewise.
+ * monitor.c (monitor_printf_noecho, monitor_printf)
+ (monitor_dump_regs): Likewise.
+ * ocd.c (stu_put_packet): Likewise.
+ * printcmd.c (decode_format, print_scalar_formatted): Likewise.
+ * remote-bug.c (bug_open): Likewise.
+ * remote-e7000.c (fetch_regs_from_dump, e7000_wait): Likewise.
+ * remote-es.c (es1800_read_bytes): Likewise.
+ * remote-mips.c (common_breakpoint): Likewise.
+ * remote-rdp.c (send_rdp): Likewise.
+ * remote-sds.c (putmessage): Likewise.
+ * sparc-nat.c (fetch_inferior_registers, store_inferior_registers):
+ Likewise.
+ * sparcl-tdep.c (sparclite_download): Likewise.
+ * symtab.c (lookup_partial_symbol): Likewise.
+ * target.c (push_target, pop_target, initialize_targets): Likewise.
+ * utils.c (internal_verror, malloc_botch, wrap_here, decimal2str):
+ Likewise.
+ * valprint.c (print_decimal, print_longest, print_longest)
+ (strcat_longest): Likewise.
+ * w65-tdep.c (init_frame_pc, w65_push_dummy_frame): Likewise.
+ * xmodem.c (xmodem_send_packet): Likewise.
+ * z8k-tdep.c (init_frame_pc, z8k_push_dummy_frame): Likewise.
+ * config/h8500/tm-h8500.h (STORE_STRUCT_RETURN): Likewise.
+ * config/mn10200/tm-mn10200.h (EXTRACT_RETURN_VALUE)
+ (STORE_RETURN_VALUE): Likewise.
+ * config/ns32k/nm-umax.h (REGISTER_U_ADDR): Likewise.
+ * config/ns32k/xm-merlin.h (REGISTER_U_ADDR): Likewise.
+ * config/z8k/tm-z8k.h (STORE_STRUCT_RETURN, STORE_RETURN_VALUE):
+ Likewise.
+
2001-02-23 Andrew Cagney <ac131313@redhat.com>
* CONTRIBUTE: Document how to cite a problem report.
subfile_stack = tem;
if (current_subfile == NULL || current_subfile->name == NULL)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
tem->name = current_subfile->name;
}
if (link == NULL)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
name = link->name;
subfile_stack = link->next;
subroutine will return. This is called from call_function. */
/*#define STORE_STRUCT_RETURN(ADDR, SP) \
- { write_register (0, (ADDR)); abort(); } */
+ { write_register (0, (ADDR)); internal_error (__FILE__, __LINE__, "failed internal consistency check"); } */
/* Extract from an array REGBUF containing the (raw) register state
a function return value of type TYPE, and copy that, in virtual format,
#define EXTRACT_RETURN_VALUE(TYPE, REGBUF, VALBUF) \
{ \
if (TYPE_LENGTH (TYPE) > 8) \
- abort (); \
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); \
else if (TYPE_LENGTH (TYPE) > 2 && TYPE_CODE (TYPE) != TYPE_CODE_PTR) \
{ \
memcpy (VALBUF, REGBUF + REGISTER_BYTE (0), 2); \
#define STORE_RETURN_VALUE(TYPE, VALBUF) \
{ \
if (TYPE_LENGTH (TYPE) > 8) \
- abort (); \
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); \
else if (TYPE_LENGTH (TYPE) > 2 && TYPE_CODE (TYPE) != TYPE_CODE_PTR) \
{ \
write_register_bytes (REGISTER_BYTE (0), VALBUF, 2); \
addr = PU_F0 + (regno - LP0_REGNUM) * sizeof (double); break; \
default: \
printf ("bad argument to REGISTER_U_ADDR %d\n", regno); \
- abort (); \
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); \
} \
}
addr = 76 + (regno - LP0_REGNUM) * sizeof (double); break; \
default: \
printf ("bad argument to REGISTER_U_ADDR %d\n", regno); \
- abort (); \
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); \
} \
}
/* Store the address of the place in which to copy the structure the
subroutine will return. This is called from call_function. */
-#define STORE_STRUCT_RETURN(ADDR, SP) abort();
+#define STORE_STRUCT_RETURN(ADDR, SP) internal_error (__FILE__, __LINE__, "failed internal consistency check");
/* Extract from an array REGBUF containing the (raw) register state
a function return value of type TYPE, and copy that, in virtual format,
/* Write into appropriate registers a function return value
of type TYPE, given in virtual format. */
-#define STORE_RETURN_VALUE(TYPE,VALBUF) abort();
+#define STORE_RETURN_VALUE(TYPE,VALBUF) internal_error (__FILE__, __LINE__, "failed internal consistency check");
/* Extract from an array REGBUF containing the (raw) register state
the address in which a function should return its structure value,
case N_ROSYM:
goto case_N_ROSYM;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
*end = *start;
bfd_map_over_sections (some_bfd, add_to_section_table, (char *) end);
if (*end > *start + count)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
/* We could realloc the table, but it probably loses for most files. */
return 0;
}
asection *section;
if (len <= 0)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (overlay_debugging)
{
case PC_REGNUM:
return 4;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
case PC_REGNUM:
return builtin_type_unsigned_long;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
hpread_type_translate (dnttpointer typep)
{
if (!typep.dntti.immediate)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
switch (typep.dntti.type)
{
case HP_TYPE_FTN_STRING_VAX_COMPAT:
return FT_STRING;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
/* values are not normalized. */
if (!((dn_bufp->darray.arrayisbytes && dn_bufp->darray.elemisbytes)
|| (!dn_bufp->darray.arrayisbytes && !dn_bufp->darray.elemisbytes)))
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
else if (dn_bufp->darray.arraylength == 0x7fffffff)
{
/* The HP debug format represents char foo[]; as an array with
if (dn_bufp->dtype.type.dnttp.index < LNTT_SYMCOUNT (objfile))
dn_bufp = hpread_get_lntt (dn_bufp->dtype.type.dnttp.index, objfile);
else
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (dn_bufp->dblock.kind == DNTT_TYPE_STRUCT)
prefix = "struct ";
return print_insn_i386_intel (memaddr, info);
/* Never reached - disassembly_flavour is always either att_flavor
or intel_flavor */
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* If the disassembly mode is intel, we have to also switch the
{
return len;
}
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* Read the i960 instruction at 'memaddr' and return the address of
set_sigio_trap (void)
{
if (target_activity_function)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
void
clear_sigio_trap (void)
{
if (target_activity_function)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#endif /* No SIGIO. */
\f
if (step)
{
if (SOFTWARE_SINGLE_STEP_P)
- abort (); /* Make sure this doesn't happen. */
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); /* Make sure this doesn't happen. */
else
ptrace (PT_STEP, pid, (PTRACE_ARG3_TYPE) 1,
target_signal_to_host (signal));
/* We do a lot of casts from pointers to TTRACE_ARG_TYPE; make sure
this is okay. */
if (sizeof (TTRACE_ARG_TYPE) < sizeof (void *))
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (errno || (memory_page_dictionary.page_size <= 0))
perror_with_name ("sysconf");
case language_chill:
error ("Missing Chill support in function binop_result_check."); /*FIXME */
}
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
return (struct type *) 0; /* For lint */
}
{
fprintf_unfiltered (gdb_stderr, "Magic number of %s language struct wrong\n",
lang->la_name);
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
if (!languages)
if (regno == -1 || regno == SP_REGNUM)
{
if (!register_valid[L0_REGNUM + 5])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
target_write_memory (sp + FRAME_SAVED_I0,
®isters[REGISTER_BYTE (I0_REGNUM)],
8 * REGISTER_RAW_SIZE (I0_REGNUM));
else if (regno >= L0_REGNUM && regno <= I7_REGNUM)
{
if (!register_valid[regno])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (regno >= L0_REGNUM && regno <= L0_REGNUM + 7)
regoffset = REGISTER_BYTE (regno) - REGISTER_BYTE (L0_REGNUM)
+ FRAME_SAVED_L0;
}
}
else
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
new = (port_chain_t) obstack_alloc (port_chain_obstack,
sizeof (struct port_chain));
ret = task_get_bootstrap_port (mach_task_self (),
&original_server_port_name);
if (ret != KERN_SUCCESS)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
ret = mach_port_deallocate (mach_task_self (),
original_server_port_name);
if (ret != KERN_SUCCESS)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
/* Suspend this task to let the parent change my ports.
Resumed by the debugger */
ret = task_suspend (mach_task_self ());
if (ret != KERN_SUCCESS)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
\f
/*
CORE_ADDR svalue;
if (ext_ptr->ifd != f_idx)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
psh = &ext_ptr->asym;
/* Do not add undefined symbols to the partial symbol table. */
len = strlen (sndbuf);
if (len + 1 > sizeof sndbuf)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (monitor_debug_p)
{
len = strlen (sndbuf);
if (len + 1 > sizeof sndbuf)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (monitor_debug_p)
{
parse_register_dump (buf, resp_len);
}
else
- abort (); /* Need some way to read registers */
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); /* Need some way to read registers */
}
static void
unsigned char c;
if (len == 0 || len > 256)
- abort (); /* Can't represent 0 length packet */
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); /* Can't represent 0 length packet */
reset_packet ();
val.size = osize ? 'h' : osize;
else
/* Bad value for TARGET_PTR_BIT */
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
break;
case 'f':
/* Floating point has to be word or giantword. */
break;
case 0:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
case 't':
/* Binary; 't' stands for "two". */
target_is_m88110 = 1;
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
}
else
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
store_signed_integer (buf,
REGISTER_RAW_SIZE (regno),
break;
default:
/* Get the user's attention - this should never happen. */
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
return 0;
if (len > PBUFSIZ / 2 - 1)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
if (len == 1) /* The emulator does not like expressions like: */
flags = "f";
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
cmd = 'B';
*pi = get_byte ();
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
va_end (alist);
if (dst != buf)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
and giving it a checksum. */
if (len > 170) /* Prosanity check */
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (remote_debug)
{
/* We should never be called with deferred stores, because a prerequisite
for writing regs is to have fetched them all (PREPARE_TO_STORE), sigh. */
if (deferred_stores)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
DO_DEFERRED_STORES;
if (regno < 0 || regno == SP_REGNUM)
{
if (!register_valid[L0_REGNUM + 5])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
target_write_memory (sp,
®isters[REGISTER_BYTE (L0_REGNUM)],
16 * REGISTER_RAW_SIZE (L0_REGNUM));
else
{
if (!register_valid[regno])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
target_write_memory (sp + REGISTER_BYTE (regno) - REGISTER_BYTE (L0_REGNUM),
®isters[REGISTER_BYTE (regno)],
REGISTER_RAW_SIZE (regno));
if (wanna_store & INT_REGS)
{
if (!register_valid[G1_REGNUM])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
memcpy (&inferior_registers.r_g1, ®isters[REGISTER_BYTE (G1_REGNUM)],
15 * REGISTER_RAW_SIZE (G1_REGNUM));
if (wanna_store & FP_REGS)
{
if (!register_valid[FP0_REGNUM + 9])
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
memcpy (&inferior_fp_registers, ®isters[REGISTER_BYTE (FP0_REGNUM)],
sizeof inferior_fp_registers.fpu_fr);
memcpy (&inferior_fp_registers.Fpu_fsr,
download (remote_target_name, filename, from_tty, sparclite_udp_write,
sparclite_udp_start);
#else
- abort (); /* sparclite_open should prevent this! */
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); /* sparclite_open should prevent this! */
#endif
else
download (remote_target_name, filename, from_tty, sparclite_serial_write,
{
center = bottom + (top - bottom) / 2;
if (!(center < top))
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (!do_linear_search
&& (SYMBOL_LANGUAGE (*center) == language_java))
{
}
}
if (!(top == bottom))
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
/* djb - 2000-06-03 - Use SYMBOL_MATCHES_NAME, not a strcmp, so
we don't have to force a linear search on C++. Probably holds true
fprintf_unfiltered (gdb_stderr,
"Magic number of %s target struct wrong\n",
t->to_shortname);
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* Find the proper stratum to install this target in. */
fprintf_unfiltered (gdb_stderr,
"pop_target couldn't find target %s\n",
current_target.to_shortname);
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#undef MIN
target_dcache = dcache_init();
if (!STREQ (signals[TARGET_SIGNAL_LAST].string, "TARGET_SIGNAL_MAGIC"))
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
case 1:
dejavu = 2;
fputs_unfiltered (msg, gdb_stderr);
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
default:
dejavu = 3;
write (STDERR_FILENO, msg, sizeof (msg));
if (dump_core_p)
{
if (fork () == 0)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
else
{
if (dump_core_p)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
else
exit (1);
}
malloc_botch (void)
{
fprintf_unfiltered (gdb_stderr, "Memory corruption\n");
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* Attempt to install hooks in mmalloc/mrealloc/mfree for the heap specified
{
/* This should have been allocated, but be paranoid anyway. */
if (!wrap_buffer)
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
if (wrap_buffer[0])
{
sign, temp[2], temp[1], temp[0]);
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
}
sign, temp[2], temp[1], temp[0]);
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
return;
}
fprintf_filtered (stream, local_hex_format_custom ("016ll"), val_long);
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#else /* !CC_HAS_LONG_LONG || !PRINTF_HAS_LONG_LONG */
/* In the following it is important to coerce (val_long) to a long. It does
(unsigned long) val_long);
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#endif /* CC_HAS_LONG_LONG || PRINTF_HAS_LONG_LONG */
}
sprintf (buf, local_hex_format_custom ("016ll"), val_long);
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#else /* !PRINTF_HAS_LONG_LONG */
/* In the following it is important to coerce (val_long) to a long. It does
((long) val_long));
break;
default:
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
#endif /* !PRINTF_HAS_LONG_LONG */
init_frame_pc (void)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
void
w65_push_dummy_frame (void)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* Put here the code to store, into a struct frame_saved_regs,
datasize = XMODEM_1KDATASIZE;
}
else
- abort (); /* Packet way too large */
+ internal_error (__FILE__, __LINE__, "failed internal consistency check"); /* Packet way too large */
/* Add ^Z padding if packet < 128 (or 1024) bytes */
void
init_frame_pc (void)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
/* Put here the code to store, into a struct frame_saved_regs,
void
z8k_push_dummy_frame (void)
{
- abort ();
+ internal_error (__FILE__, __LINE__, "failed internal consistency check");
}
int