/* Helper functions for INNER_THAN */
int
-core_addr_lessthan (lhs, rhs)
- CORE_ADDR lhs;
- CORE_ADDR rhs;
+core_addr_lessthan (CORE_ADDR lhs, CORE_ADDR rhs)
{
return (lhs < rhs);
}
int
-core_addr_greaterthan (lhs, rhs)
- CORE_ADDR lhs;
- CORE_ADDR rhs;
+core_addr_greaterthan (CORE_ADDR lhs, CORE_ADDR rhs)
{
return (lhs > rhs);
}
/* Misc helper functions for targets. */
int
-frame_num_args_unknown (fi)
- struct frame_info *fi;
+frame_num_args_unknown (struct frame_info *fi)
{
return -1;
}
int
-generic_register_convertible_not (num)
- int num;
+generic_register_convertible_not (int num)
{
return 0;
}
+int
+default_register_sim_regno (int num)
+{
+ return num;
+}
+
/* Functions to manipulate the endianness of the target. */
#ifdef TARGET_BYTE_ORDER_SELECTABLE
struct gdbarch_info info;
memset (&info, 0, sizeof info);
info.byte_order = LITTLE_ENDIAN;
- gdbarch_update (info);
+ if (! gdbarch_update_p (info))
+ {
+ printf_unfiltered ("Little endian target not supported by GDB\n");
+ }
}
else
{
struct gdbarch_info info;
memset (&info, 0, sizeof info);
info.byte_order = BIG_ENDIAN;
- gdbarch_update (info);
+ if (! gdbarch_update_p (info))
+ {
+ printf_unfiltered ("Big endian target not supported by GDB\n");
+ }
}
else
{
info.bfd_arch_info = bfd_scan_arch (set_architecture_string);
if (info.bfd_arch_info == NULL)
internal_error ("set_architecture: bfd_scan_arch failed");
- if (gdbarch_update (info))
+ if (gdbarch_update_p (info))
target_architecture_auto = 0;
else
printf_unfiltered ("Architecture `%s' not reconized.\n",
printf_filtered ("\n");
}
-/* Set the dynamic target-system-dependant parameters (architecture,
+/* Set the dynamic target-system-dependent parameters (architecture,
byte-order) using information found in the BFD */
void
-set_gdbarch_from_file (abfd)
- bfd *abfd;
+set_gdbarch_from_file (bfd *abfd)
{
if (GDB_MULTI_ARCH)
{
struct gdbarch_info info;
memset (&info, 0, sizeof info);
info.abfd = abfd;
- gdbarch_update (info);
+ if (! gdbarch_update_p (info))
+ error ("Architecture of file not reconized.\n");
}
else
{
if (GDB_MULTI_ARCH)
{
- gdbarch_update (info);
+ if (! gdbarch_update_p (info))
+ {
+ internal_error ("initialize_current_architecture: Selection of initial architecture failed");
+ }
}
/* Create the ``set architecture'' command appending ``auto'' to the