+2000-07-29 Kevin Buettner <kevinb@redhat.com>
+
+ * a29k-tdep.c, a68v-nat.c, abug-rom.c, alpha-nat.c,
+ alpha-tdep.c, annotate.c, arc-tdep.c, arch-utils.c, ax-gdb.c,
+ ax-general.c, blockframe.c, breakpoint.c, buildsym.c,
+ c-lang.c, c-typeprint.c, c-valprint.c, ch-exp.c, ch-lang.c,
+ ch-typeprint.c, ch-valprint.c, cli-out.c, coff-solib.c,
+ coffread.c, command.c, complaints.c, copying.c, core-aout.c,
+ core-regset.c, core-sol2.c, corefile.c, corelow.c,
+ cp-valprint.c, cpu32bug-rom.c, cxux-nat.c, d10v-tdep.c,
+ d30v-tdep.c, dbug-rom.c, dbxread.c, dcache.c, delta68-nat.c,
+ demangle.c, dink32-rom.c, dpx2-nat.c, dsrec.c, dstread.c,
+ dve3900-rom.c, dwarf2read.c, dwarfread.c, elfread.c,
+ environ.c, eval.c, event-top.c, exec.c, expprint.c, f-lang.c,
+ f-typeprint.c, f-valprint.c, findvar.c, fork-child.c,
+ fr30-tdep.c, gdbarch.c, gdbserver/gdbreplay.c,
+ gdbserver/low-hppabsd.c, gdbserver/low-linux.c,
+ gdbserver/low-lynx.c, gdbserver/low-nbsd.c,
+ gdbserver/low-sim.c, gdbserver/low-sparc.c,
+ gdbserver/low-sun3.c, gdbserver/remote-utils.c,
+ gdbserver/utils.c, gdbtypes.c, gnu-nat.c, h8300-tdep.c,
+ h8500-tdep.c, hp-psymtab-read.c, hp-symtab-read.c,
+ hp300ux-nat.c, hppa-tdep.c, hppab-nat.c, hppah-nat.c,
+ hppam3-nat.c, hpread.c, hpux-thread.c, i386-linux-nat.c,
+ i386-stub.c, i386-tdep.c, i386aix-nat.c, i386b-nat.c,
+ i386ly-tdep.c, i386m3-nat.c, i386mach-nat.c, i386nbsd-nat.c,
+ i386v-nat.c, i386v4-nat.c, i387-tdep.c, i960-tdep.c,
+ ia64-linux-nat.c, ia64-tdep.c, infcmd.c, inflow.c,
+ infptrace.c, infrun.c, inftarg.c, infttrace.c, irix4-nat.c,
+ irix5-nat.c, jv-lang.c, jv-typeprint.c, jv-valprint.c,
+ kdb-start.c, kod-cisco.c, kod.c, language.c, lin-thread.c,
+ linux-thread.c, lynx-nat.c, m2-lang.c, m2-typeprint.c,
+ m2-valprint.c, m3-nat.c, m32r-rom.c, m32r-stub.c, m32r-tdep.c,
+ m68hc11-tdep.c, m68k-stub.c, m68k-tdep.c, m68klinux-nat.c,
+ m68knbsd-nat.c, m88k-nat.c, m88k-tdep.c, mac-nat.c,
+ mac-xdep.c, maint.c, mcore-rom.c, mcore-tdep.c, mdebugread.c,
+ mem-break.c, mi/mi-cmds.c, mi/mi-main.c, mi/mi-out.c,
+ mi/mi-parse.c, minsyms.c, mips-nat.c, mips-tdep.c,
+ mipsm3-nat.c, mipsread.c, mipsv4-nat.c, mn10200-tdep.c,
+ mn10300-tdep.c, mon960-rom.c, monitor.c, news-xdep.c,
+ nindy-tdep.c, nlm/gdbserve.c, nlm/i386.c, nlm/ppc.c,
+ nlmread.c, ns32k-tdep.c, ns32km3-nat.c, ns32knbsd-nat.c,
+ objfiles.c, ocd.c, op50-rom.c, os9kread.c, osfsolib.c,
+ p-lang.c, p-typeprint.c, p-valprint.c, pa64solib.c, parse.c,
+ ppc-bdm.c, ppc-linux-nat.c, ppc-linux-tdep.c, ppcbug-rom.c,
+ ppcnbsd-nat.c, printcmd.c, proc-api.c, proc-events.c,
+ proc-flags.c, proc-why.c, procfs.c, ptx4-nat.c,
+ remote-adapt.c, remote-array.c, remote-bug.c, remote-e7000.c,
+ remote-eb.c, remote-es.c, remote-est.c, remote-hms.c,
+ remote-mips.c, remote-mm.c, remote-nindy.c, remote-nrom.c,
+ remote-os9k.c, remote-rdi.c, remote-rdp.c, remote-sds.c,
+ remote-sim.c, remote-st.c, remote-udi.c, remote-utils.c,
+ remote-vx.c, remote-vx29k.c, remote-vx68.c, remote-vx960.c,
+ remote-vxmips.c, remote-vxsparc.c, remote.c, rom68k-rom.c,
+ rs6000-tdep.c, scm-exp.c, scm-lang.c, scm-valprint.c,
+ ser-e7kpc.c, ser-go32.c, ser-mac.c, ser-ocd.c, ser-unix.c,
+ sh-stub.c, sh-tdep.c, sh3-rom.c, sol-thread.c, solib.c,
+ somread.c, somsolib.c, source.c, sparc-nat.c, sparc-stub.c,
+ sparc-tdep.c, sparcl-stub.c, sparcl-tdep.c, sparclet-rom.c,
+ sparclet-stub.c, stabsread.c, stack.c, standalone.c,
+ stop-gdb.c, stuff.c, sun3-nat.c, sun386-nat.c, symfile.c,
+ symm-nat.c, symm-tdep.c, symmisc.c, symtab.c, target.c,
+ thread.c, tic80-tdep.c, top.c, tracepoint.c, tui/tui-file.c,
+ tui/tui.c, tui/tuiLayout.c, tui/tuiRegs.c, tui/tuiStack.c,
+ tui/tuiWin.c, typeprint.c, ui-file.c, ui-out.c, ultra3-nat.c,
+ ultra3-xdep.c, umax-xdep.c, utils.c, v850-tdep.c, v850ice.c,
+ valarith.c, valops.c, valprint.c, values.c, varobj.c,
+ vax-tdep.c, w65-tdep.c, w89k-rom.c, win32-nat.c, wince.c,
+ wrapper.c, xcoffread.c, xcoffsolib.c, xmodem.c, z8k-tdep.c:
+ Convert old-style, pre-ISO function definitions to prototyped
+ form.
+
2000-07-28 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
* sh-tdep.c (sh_gdbarch_init): For sh4 initialize
/* Should call_function allocate stack space for a struct return? */
/* On the a29k objects over 16 words require the caller to allocate space. */
int
-a29k_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+a29k_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 16 * 4);
}
frame pointer is being used. */
CORE_ADDR
-examine_prologue (pc, rsize, msize, mfp_used)
- CORE_ADDR pc;
- unsigned *msize;
- unsigned *rsize;
- int *mfp_used;
+examine_prologue (CORE_ADDR pc, unsigned *rsize, unsigned *msize, int *mfp_used)
{
long insn;
CORE_ADDR p = pc;
to reach some "real" code. */
CORE_ADDR
-a29k_skip_prologue (pc)
- CORE_ADDR pc;
+a29k_skip_prologue (CORE_ADDR pc)
{
return examine_prologue (pc, NULL, NULL, NULL);
}
*/
static int /* 0/1 - failure/success of finding the tag word */
-examine_tag (p, is_trans, argcount, msize, mfp_used)
- CORE_ADDR p;
- int *is_trans;
- int *argcount;
- unsigned *msize;
- int *mfp_used;
+examine_tag (CORE_ADDR p, int *is_trans, int *argcount, unsigned *msize,
+ int *mfp_used)
{
unsigned int tag1, tag2;
of stacks and the frame cache in tm-a29k.h for more detail. */
static void
-init_frame_info (innermost_frame, frame)
- int innermost_frame;
- struct frame_info *frame;
+init_frame_info (int innermost_frame, struct frame_info *frame)
{
CORE_ADDR p;
long insn;
}
void
-init_extra_frame_info (frame)
- struct frame_info *frame;
+init_extra_frame_info (struct frame_info *frame)
{
if (frame->next == 0)
/* Assume innermost frame. May produce strange results for "info frame"
}
void
-init_frame_pc (fromleaf, frame)
- int fromleaf;
- struct frame_info *frame;
+init_frame_pc (int fromleaf, struct frame_info *frame)
{
frame->pc = (fromleaf ? SAVED_PC_AFTER_CALL (frame->next) :
frame->next ? FRAME_SAVED_PC (frame->next) : read_pc ());
saved_msp (gcc). */
CORE_ADDR
-frame_locals_address (fi)
- struct frame_info *fi;
+frame_locals_address (struct frame_info *fi)
{
if (fi->flags & MFP_USED)
return fi->saved_msp;
on where it came from. The contents written into MYADDR are in
target format. */
void
-read_register_stack (memaddr, myaddr, actual_mem_addr, lval)
- CORE_ADDR memaddr;
- char *myaddr;
- CORE_ADDR *actual_mem_addr;
- enum lval_type *lval;
+read_register_stack (CORE_ADDR memaddr, char *myaddr,
+ CORE_ADDR *actual_mem_addr, enum lval_type *lval)
{
long rfb = read_register (RFB_REGNUM);
long rsp = read_register (RSP_REGNUM);
/* Analogous to read_memory_integer
except the length is understood to be 4. */
long
-read_register_stack_integer (memaddr, len)
- CORE_ADDR memaddr;
- int len;
+read_register_stack_integer (CORE_ADDR memaddr, int len)
{
char buf[4];
read_register_stack (memaddr, buf, NULL, NULL);
at MEMADDR and put the actual address written into in
*ACTUAL_MEM_ADDR. */
static void
-write_register_stack (memaddr, myaddr, actual_mem_addr)
- CORE_ADDR memaddr;
- char *myaddr;
- CORE_ADDR *actual_mem_addr;
+write_register_stack (CORE_ADDR memaddr, char *myaddr,
+ CORE_ADDR *actual_mem_addr)
{
long rfb = read_register (RFB_REGNUM);
long rsp = read_register (RSP_REGNUM);
The argument RAW_BUFFER must point to aligned memory. */
void
-a29k_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lvalp)
- char *raw_buffer;
- int *optimized;
- CORE_ADDR *addrp;
- struct frame_info *frame;
- int regnum;
- enum lval_type *lvalp;
+a29k_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
+ struct frame_info *frame, int regnum,
+ enum lval_type *lvalp)
{
struct frame_info *fi;
CORE_ADDR addr;
restoring all saved registers. */
void
-pop_frame ()
+pop_frame (void)
{
struct frame_info *frame = get_current_frame ();
CORE_ADDR rfb = read_register (RFB_REGNUM);
/* Push an empty stack frame, to record the current PC, etc. */
void
-push_dummy_frame ()
+push_dummy_frame (void)
{
long w;
CORE_ADDR rab, gr1;
good job. */
struct frame_info *
-setup_arbitrary_frame (argc, argv)
- int argc;
- CORE_ADDR *argv;
+setup_arbitrary_frame (int argc, CORE_ADDR *argv)
{
struct frame_info *frame;
}
int
-gdb_print_insn_a29k (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_a29k (bfd_vma memaddr, disassemble_info *info)
{
if (TARGET_BYTE_ORDER == BIG_ENDIAN)
return print_insn_big_a29k (memaddr, info);
enum a29k_processor_types processor_type = a29k_unknown;
void
-a29k_get_processor_type ()
+a29k_get_processor_type (void)
{
unsigned int cfg_reg = (unsigned int) read_register (CFG_REGNUM);
This routine returns true on success */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
CORE_ADDR jb_addr;
char buf[sizeof (CORE_ADDR)];
#endif /* GET_LONGJMP_TARGET */
void
-_initialize_a29k_tdep ()
+_initialize_a29k_tdep (void)
{
extern CORE_ADDR text_end;
extern int errno;
void
-fetch_inferior_registers (ignored)
- int ignored;
+fetch_inferior_registers (int ignored)
{
struct ptrace_$data_regs_m68k inferior_registers;
struct ptrace_$floating_regs_m68k inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct ptrace_$data_regs_m68k inferior_registers;
struct ptrace_$floating_regs_m68k inferior_fp_registers;
static void abug_open (char *args, int from_tty);
static void
-abug_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+abug_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
};
static void
-abug_open (args, from_tty)
- char *args;
- int from_tty;
+abug_open (char *args, int from_tty)
{
monitor_open (args, &abug_cmds, from_tty);
}
void
-_initialize_abug_rom ()
+_initialize_abug_rom (void)
{
init_abug_cmds ();
init_monitor_ops (&abug_ops);
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
CORE_ADDR jb_addr;
char raw_buffer[MAX_REGISTER_RAW_SIZE];
*/
static void
-fetch_osf_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR reg_addr;
+fetch_osf_core_registers (char *core_reg_sect, unsigned core_reg_size,
+ int which, CORE_ADDR reg_addr)
{
register int regno;
register int addr;
}
static void
-fetch_elf_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR reg_addr;
+fetch_elf_core_registers (char *core_reg_sect, unsigned core_reg_size,
+ int which, CORE_ADDR reg_addr)
{
if (core_reg_size < 32 * 8)
{
/* Return the ptrace ``address'' of register REGNO. */
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
return REGISTER_PTRACE_ADDR (regno);
}
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
*/
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register long *regp = ALPHA_REGSET_BASE (gregsetp);
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register long *regp = ALPHA_REGSET_BASE (gregsetp);
*/
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
register long *regp = ALPHA_REGSET_BASE (fpregsetp);
}
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
register long *regp = ALPHA_REGSET_BASE (fpregsetp);
};
void
-_initialize_core_alpha ()
+_initialize_core_alpha (void)
{
add_core_fns (&alpha_osf_core_fns);
add_core_fns (&alpha_elf_core_fns);
long alpha_linux_sigtramp_offset (CORE_ADDR pc);
#endif
long
-alpha_linux_sigtramp_offset (pc)
- CORE_ADDR pc;
+alpha_linux_sigtramp_offset (CORE_ADDR pc)
{
unsigned int i[3], w;
long off;
/* Under OSF/1, the __sigtramp routine is frameless and has a frame
size of zero, but we are able to backtrace through it. */
CORE_ADDR
-alpha_osf_skip_sigtramp_frame (frame, pc)
- struct frame_info *frame;
- CORE_ADDR pc;
+alpha_osf_skip_sigtramp_frame (struct frame_info *frame, CORE_ADDR pc)
{
char *name;
find_pc_partial_function (pc, &name, (CORE_ADDR *) NULL, (CORE_ADDR *) NULL);
descriptor is added to the linked_proc_desc_table. */
static alpha_extra_func_info_t
-push_sigtramp_desc (low_addr)
- CORE_ADDR low_addr;
+push_sigtramp_desc (CORE_ADDR low_addr)
{
struct linked_proc_info *link;
alpha_extra_func_info_t proc_desc;
NULL). */
void
-alpha_find_saved_regs (frame)
- struct frame_info *frame;
+alpha_find_saved_regs (struct frame_info *frame)
{
int ireg;
CORE_ADDR reg_position;
}
static CORE_ADDR
-read_next_frame_reg (fi, regno)
- struct frame_info *fi;
- int regno;
+read_next_frame_reg (struct frame_info *fi, int regno)
{
for (; fi; fi = fi->next)
{
}
CORE_ADDR
-alpha_frame_saved_pc (frame)
- struct frame_info *frame;
+alpha_frame_saved_pc (struct frame_info *frame)
{
alpha_extra_func_info_t proc_desc = frame->proc_desc;
/* We have to get the saved pc from the sigcontext
}
CORE_ADDR
-alpha_saved_pc_after_call (frame)
- struct frame_info *frame;
+alpha_saved_pc_after_call (struct frame_info *frame)
{
CORE_ADDR pc = frame->pc;
CORE_ADDR tmp;
$zero,($ra),1" on alpha. */
static int
-alpha_about_to_return (pc)
- CORE_ADDR pc;
+alpha_about_to_return (CORE_ADDR pc)
{
return read_memory_integer (pc, 4) == 0x6bfa8001;
}
lines. */
static CORE_ADDR
-heuristic_proc_start (pc)
- CORE_ADDR pc;
+heuristic_proc_start (CORE_ADDR pc)
{
CORE_ADDR start_pc = pc;
CORE_ADDR fence = start_pc - heuristic_fence_post;
}
static alpha_extra_func_info_t
-heuristic_proc_desc (start_pc, limit_pc, next_frame)
- CORE_ADDR start_pc, limit_pc;
- struct frame_info *next_frame;
+heuristic_proc_desc (CORE_ADDR start_pc, CORE_ADDR limit_pc,
+ struct frame_info *next_frame)
{
CORE_ADDR sp = read_next_frame_reg (next_frame, SP_REGNUM);
CORE_ADDR cur_pc;
find the prologue, then return 0. */
static CORE_ADDR
-after_prologue (pc, proc_desc)
- CORE_ADDR pc;
- alpha_extra_func_info_t proc_desc;
+after_prologue (CORE_ADDR pc, alpha_extra_func_info_t proc_desc)
{
struct symtab_and_line sal;
CORE_ADDR func_addr, func_end;
are definitively *not* in a function prologue. */
static int
-alpha_in_prologue (pc, proc_desc)
- CORE_ADDR pc;
- alpha_extra_func_info_t proc_desc;
+alpha_in_prologue (CORE_ADDR pc, alpha_extra_func_info_t proc_desc)
{
CORE_ADDR after_prologue_pc;
}
static alpha_extra_func_info_t
-find_proc_desc (pc, next_frame)
- CORE_ADDR pc;
- struct frame_info *next_frame;
+find_proc_desc (CORE_ADDR pc, struct frame_info *next_frame)
{
alpha_extra_func_info_t proc_desc;
struct block *b;
alpha_extra_func_info_t cached_proc_desc;
CORE_ADDR
-alpha_frame_chain (frame)
- struct frame_info *frame;
+alpha_frame_chain (struct frame_info *frame)
{
alpha_extra_func_info_t proc_desc;
CORE_ADDR saved_pc = FRAME_SAVED_PC (frame);
}
void
-init_extra_frame_info (frame)
- struct frame_info *frame;
+init_extra_frame_info (struct frame_info *frame)
{
/* Use proc_desc calculated in frame_chain */
alpha_extra_func_info_t proc_desc =
arguments without difficulty. */
struct frame_info *
-setup_arbitrary_frame (argc, argv)
- int argc;
- CORE_ADDR *argv;
+setup_arbitrary_frame (int argc, CORE_ADDR *argv)
{
if (argc != 2)
error ("ALPHA frame specifications require two arguments: sp and pc");
structure to be returned is passed as a hidden first argument. */
CORE_ADDR
-alpha_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+alpha_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int i;
int accumulate_size = struct_return ? 8 : 0;
}
void
-alpha_push_dummy_frame ()
+alpha_push_dummy_frame (void)
{
int ireg;
struct linked_proc_info *link;
}
void
-alpha_pop_frame ()
+alpha_pop_frame (void)
{
register int regnum;
struct frame_info *frame = get_current_frame ();
stuff some day. */
CORE_ADDR
-alpha_skip_prologue (pc, lenient)
- CORE_ADDR pc;
- int lenient;
+alpha_skip_prologue (CORE_ADDR pc, int lenient)
{
unsigned long inst;
int offset;
STARTADDR? */
static int
-alpha_in_lenient_prologue (startaddr, pc)
- CORE_ADDR startaddr;
- CORE_ADDR pc;
+alpha_in_lenient_prologue (CORE_ADDR startaddr, CORE_ADDR pc)
{
CORE_ADDR end_prologue = alpha_skip_prologue (startaddr, 1);
return pc >= startaddr && pc < end_prologue;
memory format is an integer with 4 bytes or less, as the representation
of integers in floating point registers is different. */
void
-alpha_register_convert_to_virtual (regnum, valtype, raw_buffer, virtual_buffer)
- int regnum;
- struct type *valtype;
- char *raw_buffer;
- char *virtual_buffer;
+alpha_register_convert_to_virtual (int regnum, struct type *valtype,
+ char *raw_buffer, char *virtual_buffer)
{
if (TYPE_LENGTH (valtype) >= REGISTER_RAW_SIZE (regnum))
{
}
void
-alpha_register_convert_to_raw (valtype, regnum, virtual_buffer, raw_buffer)
- struct type *valtype;
- int regnum;
- char *virtual_buffer;
- char *raw_buffer;
+alpha_register_convert_to_raw (struct type *valtype, int regnum,
+ char *virtual_buffer, char *raw_buffer)
{
if (TYPE_LENGTH (valtype) >= REGISTER_RAW_SIZE (regnum))
{
write its value into the appropriate register. */
void
-alpha_store_return_value (valtype, valbuf)
- struct type *valtype;
- char *valbuf;
+alpha_store_return_value (struct type *valtype, char *valbuf)
{
char raw_buffer[MAX_REGISTER_RAW_SIZE];
int regnum = V0_REGNUM;
callable as an sfunc. */
static void
-reinit_frame_cache_sfunc (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+reinit_frame_cache_sfunc (char *args, int from_tty, struct cmd_list_element *c)
{
reinit_frame_cache ();
}
*/
CORE_ADDR
-alpha_call_dummy_address ()
+alpha_call_dummy_address (void)
{
CORE_ADDR entry;
struct minimal_symbol *sym;
}
void
-_initialize_alpha_tdep ()
+_initialize_alpha_tdep (void)
{
struct cmd_list_element *c;
static int ignore_count_changed = 0;
static void
-print_value_flags (t)
- struct type *t;
+print_value_flags (struct type *t)
{
if (can_dereference (t))
printf_filtered ("*");
}
\f
void
-breakpoints_changed ()
+breakpoints_changed (void)
{
if (annotation_level > 1)
{
}
void
-annotate_breakpoint (num)
- int num;
+annotate_breakpoint (int num)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032breakpoint %d\n", num);
}
void
-annotate_catchpoint (num)
- int num;
+annotate_catchpoint (int num)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032catchpoint %d\n", num);
}
void
-annotate_watchpoint (num)
- int num;
+annotate_watchpoint (int num)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032watchpoint %d\n", num);
}
void
-annotate_starting ()
+annotate_starting (void)
{
if (annotate_starting_hook)
}
void
-annotate_stopped ()
+annotate_stopped (void)
{
if (annotate_stopped_hook)
annotate_stopped_hook ();
}
void
-annotate_exited (exitstatus)
- int exitstatus;
+annotate_exited (int exitstatus)
{
if (annotate_exited_hook)
annotate_exited_hook ();
}
void
-annotate_signalled ()
+annotate_signalled (void)
{
if (annotate_signalled_hook)
annotate_signalled_hook ();
}
void
-annotate_signal_name ()
+annotate_signal_name (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032signal-name\n");
}
void
-annotate_signal_name_end ()
+annotate_signal_name_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032signal-name-end\n");
}
void
-annotate_signal_string ()
+annotate_signal_string (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032signal-string\n");
}
void
-annotate_signal_string_end ()
+annotate_signal_string_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032signal-string-end\n");
}
void
-annotate_signal ()
+annotate_signal (void)
{
if (annotate_signal_hook)
annotate_signal_hook ();
}
\f
void
-annotate_breakpoints_headers ()
+annotate_breakpoints_headers (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032breakpoints-headers\n");
}
void
-annotate_field (num)
- int num;
+annotate_field (int num)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032field %d\n", num);
}
void
-annotate_breakpoints_table ()
+annotate_breakpoints_table (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032breakpoints-table\n");
}
void
-annotate_record ()
+annotate_record (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032record\n");
}
void
-annotate_breakpoints_table_end ()
+annotate_breakpoints_table_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032breakpoints-table-end\n");
}
void
-annotate_frames_invalid ()
+annotate_frames_invalid (void)
{
if (annotation_level > 1)
{
}
void
-annotate_field_begin (type)
- struct type *type;
+annotate_field_begin (struct type *type)
{
if (annotation_level > 1)
{
}
void
-annotate_field_name_end ()
+annotate_field_name_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032field-name-end\n");
}
void
-annotate_field_value ()
+annotate_field_value (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032field-value\n");
}
void
-annotate_field_end ()
+annotate_field_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032field-end\n");
}
\f
void
-annotate_quit ()
+annotate_quit (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032quit\n");
}
void
-annotate_error ()
+annotate_error (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032error\n");
}
void
-annotate_error_begin ()
+annotate_error_begin (void)
{
if (annotation_level > 1)
fprintf_filtered (gdb_stderr, "\n\032\032error-begin\n");
}
void
-annotate_value_history_begin (histindex, type)
- int histindex;
- struct type *type;
+annotate_value_history_begin (int histindex, struct type *type)
{
if (annotation_level > 1)
{
}
void
-annotate_value_begin (type)
- struct type *type;
+annotate_value_begin (struct type *type)
{
if (annotation_level > 1)
{
}
void
-annotate_value_history_value ()
+annotate_value_history_value (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032value-history-value\n");
}
void
-annotate_value_history_end ()
+annotate_value_history_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032value-history-end\n");
}
void
-annotate_value_end ()
+annotate_value_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032value-end\n");
}
void
-annotate_display_begin ()
+annotate_display_begin (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-begin\n");
}
void
-annotate_display_number_end ()
+annotate_display_number_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-number-end\n");
}
void
-annotate_display_format ()
+annotate_display_format (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-format\n");
}
void
-annotate_display_expression ()
+annotate_display_expression (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-expression\n");
}
void
-annotate_display_expression_end ()
+annotate_display_expression_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-expression-end\n");
}
void
-annotate_display_value ()
+annotate_display_value (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-value\n");
}
void
-annotate_display_end ()
+annotate_display_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032display-end\n");
}
void
-annotate_arg_begin ()
+annotate_arg_begin (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032arg-begin\n");
}
void
-annotate_arg_name_end ()
+annotate_arg_name_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032arg-name-end\n");
}
void
-annotate_arg_value (type)
- struct type *type;
+annotate_arg_value (struct type *type)
{
if (annotation_level > 1)
{
}
void
-annotate_arg_end ()
+annotate_arg_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032arg-end\n");
}
void
-annotate_source (filename, line, character, mid, pc)
- char *filename;
- int line;
- int character;
- int mid;
- CORE_ADDR pc;
+annotate_source (char *filename, int line, int character, int mid, CORE_ADDR pc)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032source ");
}
void
-annotate_frame_begin (level, pc)
- int level;
- CORE_ADDR pc;
+annotate_frame_begin (int level, CORE_ADDR pc)
{
if (annotation_level > 1)
{
}
void
-annotate_function_call ()
+annotate_function_call (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032function-call\n");
}
void
-annotate_signal_handler_caller ()
+annotate_signal_handler_caller (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032signal-handler-caller\n");
}
void
-annotate_frame_address ()
+annotate_frame_address (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-address\n");
}
void
-annotate_frame_address_end ()
+annotate_frame_address_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-address-end\n");
}
void
-annotate_frame_function_name ()
+annotate_frame_function_name (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-function-name\n");
}
void
-annotate_frame_args ()
+annotate_frame_args (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-args\n");
}
void
-annotate_frame_source_begin ()
+annotate_frame_source_begin (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-source-begin\n");
}
void
-annotate_frame_source_file ()
+annotate_frame_source_file (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-source-file\n");
}
void
-annotate_frame_source_file_end ()
+annotate_frame_source_file_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-source-file-end\n");
}
void
-annotate_frame_source_line ()
+annotate_frame_source_line (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-source-line\n");
}
void
-annotate_frame_source_end ()
+annotate_frame_source_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-source-end\n");
}
void
-annotate_frame_where ()
+annotate_frame_where (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-where\n");
}
void
-annotate_frame_end ()
+annotate_frame_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032frame-end\n");
}
\f
void
-annotate_array_section_begin (index, elttype)
- int index;
- struct type *elttype;
+annotate_array_section_begin (int index, struct type *elttype)
{
if (annotation_level > 1)
{
}
void
-annotate_elt_rep (repcount)
- unsigned int repcount;
+annotate_elt_rep (unsigned int repcount)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032elt-rep %u\n", repcount);
}
void
-annotate_elt_rep_end ()
+annotate_elt_rep_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032elt-rep-end\n");
}
void
-annotate_elt ()
+annotate_elt (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032elt\n");
}
void
-annotate_array_section_end ()
+annotate_array_section_end (void)
{
if (annotation_level > 1)
printf_filtered ("\n\032\032array-section-end\n");
}
static void
-breakpoint_changed (b)
- struct breakpoint *b;
+breakpoint_changed (struct breakpoint *b)
{
breakpoints_changed ();
}
void
-_initialize_annotate ()
+_initialize_annotate (void)
{
if (annotation_level > 1)
{
: codestream_buf[codestream_off++])
static unsigned int
-codestream_fill (peek_flag)
- int peek_flag;
+codestream_fill (int peek_flag)
{
codestream_addr = codestream_next_addr;
codestream_next_addr += CODESTREAM_BUFSIZ * sizeof (codestream_buf[0]);
}
static void
-codestream_seek (place)
- CORE_ADDR place;
+codestream_seek (CORE_ADDR place)
{
codestream_next_addr = place / CODESTREAM_BUFSIZ;
codestream_next_addr *= CODESTREAM_BUFSIZ;
/* This function is currently unused but leave in for now. */
static void
-codestream_read (buf, count)
- unsigned int *buf;
- int count;
+codestream_read (unsigned int *buf, int count)
{
unsigned int *p;
int i;
/* Set up prologue scanning and return the first insn. */
static unsigned int
-setup_prologue_scan (pc)
- CORE_ADDR pc;
+setup_prologue_scan (CORE_ADDR pc)
{
unsigned int insn;
*/
static long
-arc_get_frame_setup (pc)
- CORE_ADDR pc;
+arc_get_frame_setup (CORE_ADDR pc)
{
unsigned int insn;
/* Size of frame or -1 if unrecognizable prologue. */
This allows a quicker answer. */
CORE_ADDR
-arc_skip_prologue (pc, frameless_p)
- CORE_ADDR pc;
- int frameless_p;
+arc_skip_prologue (CORE_ADDR pc, int frameless_p)
{
unsigned int insn;
int i, frame_size;
This is taken from frameless_look_for_prologue. */
CORE_ADDR
-arc_frame_saved_pc (frame)
- struct frame_info *frame;
+arc_frame_saved_pc (struct frame_info *frame)
{
CORE_ADDR func_start;
unsigned int insn;
*/
void
-frame_find_saved_regs (fip, fsrp)
- struct frame_info *fip;
- struct frame_saved_regs *fsrp;
+frame_find_saved_regs (struct frame_info *fip, struct frame_saved_regs *fsrp)
{
long locals;
unsigned int insn;
/* ??? Need to verify all cases are properly handled. */
static insn_type
-get_insn_type (insn, pc, target)
- unsigned long insn;
- CORE_ADDR pc, *target;
+get_insn_type (unsigned long insn, CORE_ADDR pc, CORE_ADDR *target)
{
unsigned long limm;
set up a simulated single-step, we undo our damage. */
void
-arc_software_single_step (ignore, insert_breakpoints_p)
- enum target_signal ignore; /* sig but we don't need it */
- int insert_breakpoints_p;
+arc_software_single_step (enum target_signal ignore, /* sig but we don't need it */
+ int insert_breakpoints_p)
{
static CORE_ADDR next_pc, target;
static int brktrg_p;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR sp, jb_addr;
/* Disassemble one instruction. */
static int
-arc_print_insn (vma, info)
- bfd_vma vma;
- disassemble_info *info;
+arc_print_insn (bfd_vma vma, disassemble_info *info)
{
static int current_mach;
static int current_endian;
}
static void
-arc_show_cpu_type_command (args, from_tty)
- char *args;
- int from_tty;
+arc_show_cpu_type_command (char *args, int from_tty)
{
}
Result is a boolean indicating success. */
static int
-arc_set_cpu_type (str)
- char *str;
+arc_set_cpu_type (char *str)
{
int i, j;
}
\f
void
-_initialize_arc_tdep ()
+_initialize_arc_tdep (void)
{
struct cmd_list_element *c;
/* 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;
}
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)
{
proletariat? */
static struct value *
-const_var_ref (var)
- struct symbol *var;
+const_var_ref (struct symbol *var)
{
struct type *type = SYMBOL_TYPE (var);
advanced to the end of it. If we return zero, *PC could be
anywhere. */
static struct value *
-const_expr (pc)
- union exp_element **pc;
+const_expr (union exp_element **pc)
{
enum exp_opcode op = (*pc)->opcode;
struct value *v1;
/* Like const_expr, but guarantee also that *PC is undisturbed if the
expression is not constant. */
static struct value *
-maybe_const_expr (pc)
- union exp_element **pc;
+maybe_const_expr (union exp_element **pc)
{
union exp_element *tentative_pc = *pc;
struct value *v = const_expr (&tentative_pc);
the value. Useful on the left side of a comma, and at the end of
an expression being used for tracing. */
static void
-gen_traced_pop (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_traced_pop (struct agent_expr *ax, struct axs_value *value)
{
if (trace_kludge)
switch (value->kind)
/* Assume that the lower bits of the top of the stack is a value of
type TYPE, and the upper bits are zero. Sign-extend if necessary. */
static void
-gen_sign_extend (ax, type)
- struct agent_expr *ax;
- struct type *type;
+gen_sign_extend (struct agent_expr *ax, struct type *type)
{
/* Do we need to sign-extend this? */
if (!TYPE_UNSIGNED (type))
TYPE, and the upper bits are garbage. Sign-extend or truncate as
needed. */
static void
-gen_extend (ax, type)
- struct agent_expr *ax;
- struct type *type;
+gen_extend (struct agent_expr *ax, struct type *type)
{
int bits = type->length * TARGET_CHAR_BIT;
/* I just had to. */
to TYPE"; generate code to fetch its value. Note that TYPE is the
target type, not the pointer type. */
static void
-gen_fetch (ax, type)
- struct agent_expr *ax;
- struct type *type;
+gen_fetch (struct agent_expr *ax, struct type *type)
{
if (trace_kludge)
{
right shift it by -DISTANCE bits if DISTANCE < 0. This generates
unsigned (logical) right shifts. */
static void
-gen_left_shift (ax, distance)
- struct agent_expr *ax;
- int distance;
+gen_left_shift (struct agent_expr *ax, int distance)
{
if (distance > 0)
{
/* Generate code to push the base address of the argument portion of
the top stack frame. */
static void
-gen_frame_args_address (ax)
- struct agent_expr *ax;
+gen_frame_args_address (struct agent_expr *ax)
{
long frame_reg, frame_offset;
/* Generate code to push the base address of the locals portion of the
top stack frame. */
static void
-gen_frame_locals_address (ax)
- struct agent_expr *ax;
+gen_frame_locals_address (struct agent_expr *ax)
{
long frame_reg, frame_offset;
programming in ML, it would be clearer why these are the same
thing. */
static void
-gen_offset (ax, offset)
- struct agent_expr *ax;
- int offset;
+gen_offset (struct agent_expr *ax, int offset)
{
/* It would suffice to simply push the offset and add it, but this
makes it easier to read positive and negative offsets in the
address (stack frame, base register, etc.) Generate code to add
VAR's value to the top of the stack. */
static void
-gen_sym_offset (ax, var)
- struct agent_expr *ax;
- struct symbol *var;
+gen_sym_offset (struct agent_expr *ax, struct symbol *var)
{
gen_offset (ax, SYMBOL_VALUE (var));
}
symbol VAR. Set VALUE to describe the result. */
static void
-gen_var_ref (ax, value, var)
- struct agent_expr *ax;
- struct axs_value *value;
- struct symbol *var;
+gen_var_ref (struct agent_expr *ax, struct axs_value *value, struct symbol *var)
{
/* Dereference any typedefs. */
value->type = check_typedef (SYMBOL_TYPE (var));
/* Generating bytecode from GDB expressions: literals */
static void
-gen_int_literal (ax, value, k, type)
- struct agent_expr *ax;
- struct axs_value *value;
- LONGEST k;
- struct type *type;
+gen_int_literal (struct agent_expr *ax, struct axs_value *value, LONGEST k,
+ struct type *type)
{
ax_const_l (ax, k);
value->kind = axs_rvalue;
try to make an rvalue out of it. Signal an error if we can't do
that. */
static void
-require_rvalue (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+require_rvalue (struct agent_expr *ax, struct axs_value *value)
{
switch (value->kind)
{
lvalue through unchanged, and let `+' raise an error. */
static void
-gen_usual_unary (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_usual_unary (struct agent_expr *ax, struct axs_value *value)
{
/* We don't have to generate any code for the usual integral
conversions, since values are always represented as full-width on
/* Return non-zero iff the type TYPE1 is considered "wider" than the
type TYPE2, according to the rules described in gen_usual_arithmetic. */
static int
-type_wider_than (type1, type2)
- struct type *type1, *type2;
+type_wider_than (struct type *type1, struct type *type2)
{
return (TYPE_LENGTH (type1) > TYPE_LENGTH (type2)
|| (TYPE_LENGTH (type1) == TYPE_LENGTH (type2)
/* Return the "wider" of the two types TYPE1 and TYPE2. */
static struct type *
-max_type (type1, type2)
- struct type *type1, *type2;
+max_type (struct type *type1, struct type *type2)
{
return type_wider_than (type1, type2) ? type1 : type2;
}
/* Generate code to convert a scalar value of type FROM to type TO. */
static void
-gen_conversion (ax, from, to)
- struct agent_expr *ax;
- struct type *from, *to;
+gen_conversion (struct agent_expr *ax, struct type *from, struct type *to)
{
/* Perhaps there is a more graceful way to state these rules. */
/* Return non-zero iff the type FROM will require any bytecodes to be
emitted to be converted to the type TO. */
static int
-is_nontrivial_conversion (from, to)
- struct type *from, *to;
+is_nontrivial_conversion (struct type *from, struct type *to)
{
struct agent_expr *ax = new_agent_expr (0);
int nontrivial;
and promotes each argument to that type. *VALUE1 and *VALUE2
describe the values as they are passed in, and as they are left. */
static void
-gen_usual_arithmetic (ax, value1, value2)
- struct agent_expr *ax;
- struct axs_value *value1, *value2;
+gen_usual_arithmetic (struct agent_expr *ax, struct axs_value *value1,
+ struct axs_value *value2)
{
/* Do the usual binary conversions. */
if (TYPE_CODE (value1->type) == TYPE_CODE_INT
the value on the top of the stack, as described by VALUE. Assume
the value has integral type. */
static void
-gen_integral_promotions (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_integral_promotions (struct agent_expr *ax, struct axs_value *value)
{
if (!type_wider_than (value->type, builtin_type_int))
{
/* Generate code for a cast to TYPE. */
static void
-gen_cast (ax, value, type)
- struct agent_expr *ax;
- struct axs_value *value;
- struct type *type;
+gen_cast (struct agent_expr *ax, struct axs_value *value, struct type *type)
{
/* GCC does allow casts to yield lvalues, so this should be fixed
before merging these changes into the trunk. */
/* Scale the integer on the top of the stack by the size of the target
of the pointer type TYPE. */
static void
-gen_scale (ax, op, type)
- struct agent_expr *ax;
- enum agent_op op;
- struct type *type;
+gen_scale (struct agent_expr *ax, enum agent_op op, struct type *type)
{
struct type *element = TYPE_TARGET_TYPE (type);
they've undergone the usual binary conversions. Used by both
BINOP_ADD and BINOP_SUBSCRIPT. NAME is used in error messages. */
static void
-gen_add (ax, value, value1, value2, name)
- struct agent_expr *ax;
- struct axs_value *value, *value1, *value2;
- char *name;
+gen_add (struct agent_expr *ax, struct axs_value *value,
+ struct axs_value *value1, struct axs_value *value2, char *name)
{
/* Is it INT+PTR? */
if (value1->type->code == TYPE_CODE_INT
value; we assume VALUE1 and VALUE2 describe the two operands, and
that they've undergone the usual binary conversions. */
static void
-gen_sub (ax, value, value1, value2)
- struct agent_expr *ax;
- struct axs_value *value, *value1, *value2;
+gen_sub (struct agent_expr *ax, struct axs_value *value,
+ struct axs_value *value1, struct axs_value *value2)
{
if (value1->type->code == TYPE_CODE_PTR)
{
result needs to be extended. NAME is the English name of the
operator, used in error messages */
static void
-gen_binop (ax, value, value1, value2, op, op_unsigned, may_carry, name)
- struct agent_expr *ax;
- struct axs_value *value, *value1, *value2;
- enum agent_op op, op_unsigned;
- int may_carry;
- char *name;
+gen_binop (struct agent_expr *ax, struct axs_value *value,
+ struct axs_value *value1, struct axs_value *value2, enum agent_op op,
+ enum agent_op op_unsigned, int may_carry, char *name)
{
/* We only handle INT op INT. */
if ((value1->type->code != TYPE_CODE_INT)
static void
-gen_logical_not (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_logical_not (struct agent_expr *ax, struct axs_value *value)
{
if (TYPE_CODE (value->type) != TYPE_CODE_INT
&& TYPE_CODE (value->type) != TYPE_CODE_PTR)
static void
-gen_complement (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_complement (struct agent_expr *ax, struct axs_value *value)
{
if (TYPE_CODE (value->type) != TYPE_CODE_INT)
error ("Illegal type of operand to `~'.");
/* Dereference the value on the top of the stack. */
static void
-gen_deref (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_deref (struct agent_expr *ax, struct axs_value *value)
{
/* The caller should check the type, because several operators use
this, and we don't know what error message to generate. */
/* Produce the address of the lvalue on the top of the stack. */
static void
-gen_address_of (ax, value)
- struct agent_expr *ax;
- struct axs_value *value;
+gen_address_of (struct agent_expr *ax, struct axs_value *value)
{
/* Special case for taking the address of a function. The ANSI
standard describes this as a special case, too, so this
/* Find the field in the structure type TYPE named NAME, and return
its index in TYPE's field array. */
static int
-find_field (type, name)
- struct type *type;
- char *name;
+find_field (struct type *type, char *name)
{
int i;
starting and one-past-ending *bit* numbers of the field within the
structure. */
static void
-gen_bitfield_ref (ax, value, type, start, end)
- struct agent_expr *ax;
- struct axs_value *value;
- struct type *type;
- int start, end;
+gen_bitfield_ref (struct agent_expr *ax, struct axs_value *value,
+ struct type *type, int start, int end)
{
/* Note that ops[i] fetches 8 << i bits. */
static enum agent_op ops[]
the operator being compiled, and OPERAND_NAME is the kind of thing
it operates on; we use them in error messages. */
static void
-gen_struct_ref (ax, value, field, operator_name, operand_name)
- struct agent_expr *ax;
- struct axs_value *value;
- char *field;
- char *operator_name;
- char *operand_name;
+gen_struct_ref (struct agent_expr *ax, struct axs_value *value, char *field,
+ char *operator_name, char *operand_name)
{
struct type *type;
int i;
stack slots, doing weird things with sizeof, etc. So we require
the right operand to be a constant expression. */
static void
-gen_repeat (pc, ax, value)
- union exp_element **pc;
- struct agent_expr *ax;
- struct axs_value *value;
+gen_repeat (union exp_element **pc, struct agent_expr *ax,
+ struct axs_value *value)
{
struct axs_value value1;
/* We don't want to turn this into an rvalue, so no conversions
*PC should point at the start of the operand expression; we advance it
to the first instruction after the operand. */
static void
-gen_sizeof (pc, ax, value)
- union exp_element **pc;
- struct agent_expr *ax;
- struct axs_value *value;
+gen_sizeof (union exp_element **pc, struct agent_expr *ax,
+ struct axs_value *value)
{
/* We don't care about the value of the operand expression; we only
care about its type. However, in the current arrangement, the
/* A gen_expr function written by a Gen-X'er guy.
Append code for the subexpression of EXPR starting at *POS_P to AX. */
static void
-gen_expr (pc, ax, value)
- union exp_element **pc;
- struct agent_expr *ax;
- struct axs_value *value;
+gen_expr (union exp_element **pc, struct agent_expr *ax,
+ struct axs_value *value)
{
/* Used to hold the descriptions of operand expressions. */
struct axs_value value1, value2;
which computes its value. Return the agent expression, and set
*VALUE to describe its type, and whether it's an lvalue or rvalue. */
struct agent_expr *
-expr_to_agent (expr, value)
- struct expression *expr;
- struct axs_value *value;
+expr_to_agent (struct expression *expr, struct axs_value *value)
{
struct cleanup *old_chain = 0;
struct agent_expr *ax = new_agent_expr (0);
Not sure this function is useful at all. */
struct agent_expr *
-expr_to_address_and_size (expr)
- struct expression *expr;
+expr_to_address_and_size (struct expression *expr)
{
struct axs_value value;
struct agent_expr *ax = expr_to_agent (expr, &value);
caller can then use the ax_reqs function to discover which
registers it relies upon. */
struct agent_expr *
-gen_trace_for_expr (scope, expr)
- CORE_ADDR scope;
- struct expression *expr;
+gen_trace_for_expr (CORE_ADDR scope, struct expression *expr)
{
struct cleanup *old_chain = 0;
struct agent_expr *ax = new_agent_expr (scope);
/* The "agent" command, for testing: compile and disassemble an expression. */
static void
-print_axs_value (f, value)
- struct ui_file *f;
- struct axs_value *value;
+print_axs_value (struct ui_file *f, struct axs_value *value)
{
switch (value->kind)
{
static void
-agent_command (exp, from_tty)
- char *exp;
- int from_tty;
+agent_command (char *exp, int from_tty)
{
struct cleanup *old_chain = 0;
struct expression *expr;
void _initialize_ax_gdb (void);
void
-_initialize_ax_gdb ()
+_initialize_ax_gdb (void)
{
add_cmd ("agent", class_maintenance, agent_command,
"Translate an expression into remote agent bytecode.",
/* Allocate a new, empty agent expression. */
struct agent_expr *
-new_agent_expr (scope)
- CORE_ADDR scope;
+new_agent_expr (CORE_ADDR scope)
{
struct agent_expr *x = xmalloc (sizeof (*x));
x->len = 0;
/* Free a agent expression. */
void
-free_agent_expr (x)
- struct agent_expr *x;
+free_agent_expr (struct agent_expr *x)
{
free (x->buf);
free (x);
/* Make sure that X has room for at least N more bytes. This doesn't
affect the length, just the allocated size. */
static void
-grow_expr (x, n)
- struct agent_expr *x;
- int n;
+grow_expr (struct agent_expr *x, int n)
{
if (x->len + n > x->size)
{
/* Append the low N bytes of VAL as an N-byte integer to the
expression X, in big-endian order. */
static void
-append_const (x, val, n)
- struct agent_expr *x;
- LONGEST val;
- int n;
+append_const (struct agent_expr *x, LONGEST val, int n)
{
int i;
/* Extract an N-byte big-endian unsigned integer from expression X at
offset O. */
static LONGEST
-read_const (x, o, n)
- struct agent_expr *x;
- int o, n;
+read_const (struct agent_expr *x, int o, int n)
{
int i;
LONGEST accum = 0;
/* Append a simple operator OP to EXPR. */
void
-ax_simple (x, op)
- struct agent_expr *x;
- enum agent_op op;
+ax_simple (struct agent_expr *x, enum agent_op op)
{
grow_expr (x, 1);
x->buf[x->len++] = op;
/* Append a sign-extension or zero-extension instruction to EXPR, to
extend an N-bit value. */
static void
-generic_ext (x, op, n)
- struct agent_expr *x;
- enum agent_op op;
- int n;
+generic_ext (struct agent_expr *x, enum agent_op op, int n)
{
/* N must fit in a byte. */
if (n < 0 || n > 255)
/* Append a sign-extension instruction to EXPR, to extend an N-bit value. */
void
-ax_ext (x, n)
- struct agent_expr *x;
- int n;
+ax_ext (struct agent_expr *x, int n)
{
generic_ext (x, aop_ext, n);
}
/* Append a zero-extension instruction to EXPR, to extend an N-bit value. */
void
-ax_zero_ext (x, n)
- struct agent_expr *x;
- int n;
+ax_zero_ext (struct agent_expr *x, int n)
{
generic_ext (x, aop_zero_ext, n);
}
/* Append a trace_quick instruction to EXPR, to record N bytes. */
void
-ax_trace_quick (x, n)
- struct agent_expr *x;
- int n;
+ax_trace_quick (struct agent_expr *x, int n)
{
/* N must fit in a byte. */
if (n < 0 || n > 255)
can backpatch it once we do know the target offset. Use ax_label
to do the backpatching. */
int
-ax_goto (x, op)
- struct agent_expr *x;
- enum agent_op op;
+ax_goto (struct agent_expr *x, enum agent_op op)
{
grow_expr (x, 3);
x->buf[x->len + 0] = op;
ax_label (EXPR, PATCH, TARGET)
to patch TARGET into the ax_goto instruction. */
void
-ax_label (x, patch, target)
- struct agent_expr *x;
- int patch;
- int target;
+ax_label (struct agent_expr *x, int patch, int target)
{
/* Make sure the value is in range. Don't accept 0xffff as an
offset; that's our magic sentinel value for unpatched branches. */
/* Assemble code to push a constant on the stack. */
void
-ax_const_l (x, l)
- struct agent_expr *x;
- LONGEST l;
+ax_const_l (struct agent_expr *x, LONGEST l)
{
static enum agent_op ops[]
=
void
-ax_const_d (x, d)
- struct agent_expr *x;
- LONGEST d;
+ax_const_d (struct agent_expr *x, LONGEST d)
{
/* FIXME: floating-point support not present yet. */
error ("GDB bug: ax-general.c (ax_const_d): floating point not supported yet");
/* Assemble code to push the value of register number REG on the
stack. */
void
-ax_reg (x, reg)
- struct agent_expr *x;
- int reg;
+ax_reg (struct agent_expr *x, int reg)
{
/* Make sure the register number is in range. */
if (reg < 0 || reg > 0xffff)
/* Disassemble the expression EXPR, writing to F. */
void
-ax_print (f, x)
- struct ui_file *f;
- struct agent_expr *x;
+ax_print (struct ui_file *f, struct agent_expr *x)
{
int i;
int is_float = 0;
/* Given an agent expression AX, fill in an agent_reqs structure REQS
describing it. */
void
-ax_reqs (ax, reqs)
- struct agent_expr *ax;
- struct agent_reqs *reqs;
+ax_reqs (struct agent_expr *ax, struct agent_reqs *reqs)
{
int i;
int height;
frame is the outermost one and has no caller. */
int
-file_frame_chain_valid (chain, thisframe)
- CORE_ADDR chain;
- struct frame_info *thisframe;
+file_frame_chain_valid (CORE_ADDR chain, struct frame_info *thisframe)
{
return ((chain) != 0
&& !inside_entry_file (FRAME_SAVED_PC (thisframe)));
the comments in objfiles.h. */
int
-func_frame_chain_valid (chain, thisframe)
- CORE_ADDR chain;
- struct frame_info *thisframe;
+func_frame_chain_valid (CORE_ADDR chain, struct frame_info *thisframe)
{
return ((chain) != 0
&& !inside_main_func ((thisframe)->pc)
/* A very simple method of determining a valid frame */
int
-nonnull_frame_chain_valid (chain, thisframe)
- CORE_ADDR chain;
- struct frame_info *thisframe;
+nonnull_frame_chain_valid (CORE_ADDR chain, struct frame_info *thisframe)
{
return ((chain) != 0);
}
A PC of zero is always considered to be the bottom of the stack. */
int
-inside_entry_file (addr)
- CORE_ADDR addr;
+inside_entry_file (CORE_ADDR addr)
{
if (addr == 0)
return 1;
A PC of zero is always considered to be the bottom of the stack. */
int
-inside_main_func (pc)
- CORE_ADDR pc;
+inside_main_func (CORE_ADDR pc)
{
if (pc == 0)
return 1;
A PC of zero is always considered to be the bottom of the stack. */
int
-inside_entry_func (pc)
- CORE_ADDR pc;
+inside_entry_func (CORE_ADDR pc)
{
if (pc == 0)
return 1;
static struct obstack frame_cache_obstack;
void *
-frame_obstack_alloc (size)
- unsigned long size;
+frame_obstack_alloc (unsigned long size)
{
return obstack_alloc (&frame_cache_obstack, size);
}
void
-frame_saved_regs_zalloc (fi)
- struct frame_info *fi;
+frame_saved_regs_zalloc (struct frame_info *fi)
{
fi->saved_regs = (CORE_ADDR *)
frame_obstack_alloc (SIZEOF_FRAME_SAVED_REGS);
/* Return the innermost (currently executing) stack frame. */
struct frame_info *
-get_current_frame ()
+get_current_frame (void)
{
if (current_frame == NULL)
{
}
void
-set_current_frame (frame)
- struct frame_info *frame;
+set_current_frame (struct frame_info *frame)
{
current_frame = frame;
}
Always returns a non-NULL value. */
struct frame_info *
-create_new_frame (addr, pc)
- CORE_ADDR addr;
- CORE_ADDR pc;
+create_new_frame (CORE_ADDR addr, CORE_ADDR pc)
{
struct frame_info *fi;
char *name;
frame). */
struct frame_info *
-get_next_frame (frame)
- struct frame_info *frame;
+get_next_frame (struct frame_info *frame)
{
return frame->next;
}
/* Flush the entire frame cache. */
void
-flush_cached_frames ()
+flush_cached_frames (void)
{
/* Since we can't really be sure what the first object allocated was */
obstack_free (&frame_cache_obstack, 0);
/* Flush the frame cache, and start a new one if necessary. */
void
-reinit_frame_cache ()
+reinit_frame_cache (void)
{
flush_cached_frames ();
function. */
int
-frameless_look_for_prologue (frame)
- struct frame_info *frame;
+frameless_look_for_prologue (struct frame_info *frame)
{
CORE_ADDR func_start, after_prologue;
if there is no such frame. */
struct frame_info *
-get_prev_frame (next_frame)
- struct frame_info *next_frame;
+get_prev_frame (struct frame_info *next_frame)
{
CORE_ADDR address = 0;
struct frame_info *prev;
}
CORE_ADDR
-get_frame_pc (frame)
- struct frame_info *frame;
+get_frame_pc (struct frame_info *frame)
{
return frame->pc;
}
/* Find the addresses in which registers are saved in FRAME. */
void
-get_frame_saved_regs (frame, saved_regs_addr)
- struct frame_info *frame;
- struct frame_saved_regs *saved_regs_addr;
+get_frame_saved_regs (struct frame_info *frame,
+ struct frame_saved_regs *saved_regs_addr)
{
if (frame->saved_regs == NULL)
{
in a specified stack frame. The frame address is assumed valid. */
struct block *
-get_frame_block (frame)
- struct frame_info *frame;
+get_frame_block (struct frame_info *frame)
{
CORE_ADDR pc;
}
struct block *
-get_current_block ()
+get_current_block (void)
{
return block_for_pc (read_pc ());
}
CORE_ADDR
-get_pc_function_start (pc)
- CORE_ADDR pc;
+get_pc_function_start (CORE_ADDR pc)
{
register struct block *bl;
register struct symbol *symbol;
/* Return the symbol for the function executing in frame FRAME. */
struct symbol *
-get_frame_function (frame)
- struct frame_info *frame;
+get_frame_function (struct frame_info *frame)
{
register struct block *bl = get_frame_block (frame);
if (bl == 0)
is NULL, we don't pass this information back to the caller. */
struct blockvector *
-blockvector_for_pc_sect (pc, section, pindex, symtab)
- register CORE_ADDR pc;
- struct sec *section;
- int *pindex;
- struct symtab *symtab;
-
+blockvector_for_pc_sect (register CORE_ADDR pc, struct sec *section,
+ int *pindex, struct symtab *symtab)
{
register struct block *b;
register int bot, top, half;
Backward compatibility, no section. */
struct blockvector *
-blockvector_for_pc (pc, pindex)
- register CORE_ADDR pc;
- int *pindex;
+blockvector_for_pc (register CORE_ADDR pc, int *pindex)
{
return blockvector_for_pc_sect (pc, find_pc_mapped_section (pc),
pindex, NULL);
in the specified section, or 0 if there is none. */
struct block *
-block_for_pc_sect (pc, section)
- register CORE_ADDR pc;
- struct sec *section;
+block_for_pc_sect (register CORE_ADDR pc, struct sec *section)
{
register struct blockvector *bl;
int index;
or 0 if there is none. Backward compatibility, no section. */
struct block *
-block_for_pc (pc)
- register CORE_ADDR pc;
+block_for_pc (register CORE_ADDR pc)
{
return block_for_pc_sect (pc, find_pc_mapped_section (pc));
}
Returns 0 if function is not known. */
struct symbol *
-find_pc_sect_function (pc, section)
- CORE_ADDR pc;
- struct sec *section;
+find_pc_sect_function (CORE_ADDR pc, struct sec *section)
{
register struct block *b = block_for_pc_sect (pc, section);
if (b == 0)
Returns 0 if function is not known. Backward compatibility, no section */
struct symbol *
-find_pc_function (pc)
- CORE_ADDR pc;
+find_pc_function (CORE_ADDR pc)
{
return find_pc_sect_function (pc, find_pc_mapped_section (pc));
}
/* Clear cache, e.g. when symbol table is discarded. */
void
-clear_pc_function_cache ()
+clear_pc_function_cache (void)
{
cache_pc_function_low = 0;
cache_pc_function_high = 0;
returns 0. */
int
-find_pc_sect_partial_function (pc, section, name, address, endaddr)
- CORE_ADDR pc;
- asection *section;
- char **name;
- CORE_ADDR *address;
- CORE_ADDR *endaddr;
+find_pc_sect_partial_function (CORE_ADDR pc, asection *section, char **name,
+ CORE_ADDR *address, CORE_ADDR *endaddr)
{
struct partial_symtab *pst;
struct symbol *f;
/* Backward compatibility, no section argument */
int
-find_pc_partial_function (pc, name, address, endaddr)
- CORE_ADDR pc;
- char **name;
- CORE_ADDR *address;
- CORE_ADDR *endaddr;
+find_pc_partial_function (CORE_ADDR pc, char **name, CORE_ADDR *address,
+ CORE_ADDR *endaddr)
{
asection *section;
or NULL if there is no such frame. If BLOCK is NULL, just return NULL. */
struct frame_info *
-block_innermost_frame (block)
- struct block *block;
+block_innermost_frame (struct block *block)
{
struct frame_info *frame;
register CORE_ADDR start;
or NULL if no FRAME on the chain corresponds to CORE_ADDR. */
struct frame_info *
-find_frame_addr_in_frame_chain (frame_addr)
- CORE_ADDR frame_addr;
+find_frame_addr_in_frame_chain (CORE_ADDR frame_addr)
{
struct frame_info *frame = NULL;
/* Get saved user PC for sigtramp from sigcontext for BSD style sigtramp. */
CORE_ADDR
-sigtramp_saved_pc (frame)
- struct frame_info *frame;
+sigtramp_saved_pc (struct frame_info *frame)
{
CORE_ADDR sigcontext_addr;
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
extern CORE_ADDR text_end;
int
-pc_in_call_dummy_before_text_end (pc, sp, frame_address)
- CORE_ADDR pc;
- CORE_ADDR sp;
- CORE_ADDR frame_address;
+pc_in_call_dummy_before_text_end (CORE_ADDR pc, CORE_ADDR sp,
+ CORE_ADDR frame_address)
{
return ((pc) >= text_end - CALL_DUMMY_LENGTH
&& (pc) <= text_end + DECR_PC_AFTER_BREAK);
}
int
-pc_in_call_dummy_after_text_end (pc, sp, frame_address)
- CORE_ADDR pc;
- CORE_ADDR sp;
- CORE_ADDR frame_address;
+pc_in_call_dummy_after_text_end (CORE_ADDR pc, CORE_ADDR sp,
+ CORE_ADDR frame_address)
{
return ((pc) >= text_end
&& (pc) <= text_end + CALL_DUMMY_LENGTH + DECR_PC_AFTER_BREAK);
allocate other kinds of code on the stack. */
int
-pc_in_call_dummy_on_stack (pc, sp, frame_address)
- CORE_ADDR pc;
- CORE_ADDR sp;
- CORE_ADDR frame_address;
+pc_in_call_dummy_on_stack (CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR frame_address)
{
return (INNER_THAN ((sp), (pc))
&& (frame_address != 0)
}
int
-pc_in_call_dummy_at_entry_point (pc, sp, frame_address)
- CORE_ADDR pc;
- CORE_ADDR sp;
- CORE_ADDR frame_address;
+pc_in_call_dummy_at_entry_point (CORE_ADDR pc, CORE_ADDR sp,
+ CORE_ADDR frame_address)
{
return ((pc) >= CALL_DUMMY_ADDRESS ()
&& (pc) <= (CALL_DUMMY_ADDRESS () + DECR_PC_AFTER_BREAK));
This is the work-horse for pc_in_call_dummy and read_register_dummy */
char *
-generic_find_dummy_frame (pc, fp)
- CORE_ADDR pc;
- CORE_ADDR fp;
+generic_find_dummy_frame (CORE_ADDR pc, CORE_ADDR fp)
{
struct dummy_frame *dummyframe;
Return true if this is a dummy frame created by gdb for an inferior call */
int
-generic_pc_in_call_dummy (pc, sp, fp)
- CORE_ADDR pc;
- CORE_ADDR sp;
- CORE_ADDR fp;
+generic_pc_in_call_dummy (CORE_ADDR pc, CORE_ADDR sp, CORE_ADDR fp)
{
/* if find_dummy_frame succeeds, then PC is in a call dummy */
/* Note: SP and not FP is passed on. */
Find a saved register from before GDB calls a function in the inferior */
CORE_ADDR
-generic_read_register_dummy (pc, fp, regno)
- CORE_ADDR pc;
- CORE_ADDR fp;
- int regno;
+generic_read_register_dummy (CORE_ADDR pc, CORE_ADDR fp, int regno)
{
char *dummy_regs = generic_find_dummy_frame (pc, fp);
where a breakpoint is laying in wait. */
void
-generic_push_dummy_frame ()
+generic_push_dummy_frame (void)
{
struct dummy_frame *dummy_frame;
CORE_ADDR fp = (get_current_frame ())->frame;
}
void
-generic_save_dummy_frame_tos (sp)
- CORE_ADDR sp;
+generic_save_dummy_frame_tos (CORE_ADDR sp)
{
dummy_frame_stack->top = sp;
}
Restore the machine state from a saved dummy stack frame. */
void
-generic_pop_dummy_frame ()
+generic_pop_dummy_frame (void)
{
struct dummy_frame *dummy_frame = dummy_frame_stack;
and false for the CRT0 start-up frame. Purpose is to terminate backtrace */
int
-generic_file_frame_chain_valid (fp, fi)
- CORE_ADDR fp;
- struct frame_info *fi;
+generic_file_frame_chain_valid (CORE_ADDR fp, struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (FRAME_SAVED_PC (fi), fp, fp))
return 1; /* don't prune CALL_DUMMY frames */
}
int
-generic_func_frame_chain_valid (fp, fi)
- CORE_ADDR fp;
- struct frame_info *fi;
+generic_func_frame_chain_valid (CORE_ADDR fp, struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY ((fi)->pc, fp, fp))
return 1; /* don't prune CALL_DUMMY frames */
the frame being created */
void
-generic_fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR pc;
- CORE_ADDR fun;
- int nargs;
- struct value **args;
- struct type *type;
- int gcc_p;
+generic_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
+ struct value **args, struct type *type, int gcc_p)
{
return;
}
The argument RAW_BUFFER must point to aligned memory. */
void
-generic_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval)
- char *raw_buffer;
- int *optimized;
- CORE_ADDR *addrp;
- struct frame_info *frame;
- int regnum;
- enum lval_type *lval;
+generic_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
+ struct frame_info *frame, int regnum,
+ enum lval_type *lval)
{
if (!target_has_registers)
error ("No registers.");
/* Set breakpoint count to NUM. */
void
-set_breakpoint_count (num)
- int num;
+set_breakpoint_count (int num)
{
breakpoint_count = num;
set_internalvar (lookup_internalvar ("bpnum"),
/* Used in run_command to zero the hit count when a new run starts. */
void
-clear_breakpoint_hit_counts ()
+clear_breakpoint_hit_counts (void)
{
struct breakpoint *b;
TRAILER is a character which can be found after the number; most
commonly this is `-'. If you don't want a trailer, use \0. */
static int
-get_number_trailer (pp, trailer)
- char **pp;
- int trailer;
+get_number_trailer (char **pp, int trailer)
{
int retval = 0; /* default */
char *p = *pp;
/* Like get_number_trailer, but don't allow a trailer. */
int
-get_number (pp)
- char **pp;
+get_number (char **pp)
{
return get_number_trailer (pp, '\0');
}
*/
int
-get_number_or_range (pp)
- char **pp;
+get_number_or_range (char **pp)
{
static int last_retval, end_value;
static char *end_ptr;
/* condition N EXP -- set break condition of breakpoint N to EXP. */
static void
-condition_command (arg, from_tty)
- char *arg;
- int from_tty;
+condition_command (char *arg, int from_tty)
{
register struct breakpoint *b;
char *p;
/* ARGSUSED */
static void
-commands_command (arg, from_tty)
- char *arg;
- int from_tty;
+commands_command (char *arg, int from_tty)
{
register struct breakpoint *b;
char *p;
shadow contents, not the breakpoints themselves. From breakpoint.c. */
int
-read_memory_nobpt (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- unsigned len;
+read_memory_nobpt (CORE_ADDR memaddr, char *myaddr, unsigned len)
{
int status;
struct breakpoint *b;
or an `errno' value if could not write the inferior. */
int
-insert_breakpoints ()
+insert_breakpoints (void)
{
register struct breakpoint *b, *temp;
int return_val = 0; /* return success code. */
int
-remove_breakpoints ()
+remove_breakpoints (void)
{
register struct breakpoint *b;
int val;
}
int
-reattach_breakpoints (pid)
- int pid;
+reattach_breakpoints (int pid)
{
register struct breakpoint *b;
int val;
}
void
-update_breakpoints_after_exec ()
+update_breakpoints_after_exec (void)
{
struct breakpoint *b;
struct breakpoint *temp;
}
int
-detach_breakpoints (pid)
- int pid;
+detach_breakpoints (int pid)
{
register struct breakpoint *b;
int val;
}
static int
-remove_breakpoint (b, is)
- struct breakpoint *b;
- insertion_state_t is;
+remove_breakpoint (struct breakpoint *b, insertion_state_t is)
{
int val;
/* Clear the "inserted" flag in all breakpoints. */
void
-mark_breakpoints_out ()
+mark_breakpoints_out (void)
{
register struct breakpoint *b;
void
-breakpoint_init_inferior (context)
- enum inf_context context;
+breakpoint_init_inferior (enum inf_context context)
{
register struct breakpoint *b, *temp;
static int warning_needed = 0;
the target, to advance the PC past the breakpoint. */
enum breakpoint_here
-breakpoint_here_p (pc)
- CORE_ADDR pc;
+breakpoint_here_p (CORE_ADDR pc)
{
register struct breakpoint *b;
int any_breakpoint_here = 0;
at PC. */
int
-breakpoint_inserted_here_p (pc)
- CORE_ADDR pc;
+breakpoint_inserted_here_p (CORE_ADDR pc)
{
register struct breakpoint *b;
bp_call_dummy breakpoint. */
int
-frame_in_dummy (frame)
- struct frame_info *frame;
+frame_in_dummy (struct frame_info *frame)
{
struct breakpoint *b;
PC is valid for process/thread PID. */
int
-breakpoint_thread_match (pc, pid)
- CORE_ADDR pc;
- int pid;
+breakpoint_thread_match (CORE_ADDR pc, int pid)
{
struct breakpoint *b;
int thread;
in breakpoint.h. */
int
-ep_is_catchpoint (ep)
- struct breakpoint *ep;
+ep_is_catchpoint (struct breakpoint *ep)
{
return
(ep->type == bp_catch_load)
}
int
-ep_is_shlib_catchpoint (ep)
- struct breakpoint *ep;
+ep_is_shlib_catchpoint (struct breakpoint *ep)
{
return
(ep->type == bp_catch_load)
}
int
-ep_is_exception_catchpoint (ep)
- struct breakpoint *ep;
+ep_is_exception_catchpoint (struct breakpoint *ep)
{
return
(ep->type == bp_catch_catch)
Also free any storage that is part of a bpstat. */
void
-bpstat_clear (bsp)
- bpstat *bsp;
+bpstat_clear (bpstat *bsp)
{
bpstat p;
bpstat q;
is part of the bpstat is copied as well. */
bpstat
-bpstat_copy (bs)
- bpstat bs;
+bpstat_copy (bpstat bs)
{
bpstat p = NULL;
bpstat tmp;
/* Find the bpstat associated with this breakpoint */
bpstat
-bpstat_find_breakpoint (bsp, breakpoint)
- bpstat bsp;
- struct breakpoint *breakpoint;
+bpstat_find_breakpoint (bpstat bsp, struct breakpoint *breakpoint)
{
if (bsp == NULL)
return NULL;
See wait_for_inferior's use of this function. */
struct breakpoint *
-bpstat_find_step_resume_breakpoint (bsp)
- bpstat bsp;
+bpstat_find_step_resume_breakpoint (bpstat bsp)
{
if (bsp == NULL)
error ("Internal error (bpstat_find_step_resume_breakpoint)");
Return 0 if passed a bpstat which does not indicate any breakpoints. */
int
-bpstat_num (bsp)
- bpstat *bsp;
+bpstat_num (bpstat *bsp)
{
struct breakpoint *b;
/* Modify BS so that the actions will not be performed. */
void
-bpstat_clear_actions (bs)
- bpstat bs;
+bpstat_clear_actions (bpstat bs)
{
for (; bs != NULL; bs = bs->next)
{
/* Stub for cleaning up our state if we error-out of a breakpoint command */
/* ARGSUSED */
static void
-cleanup_executing_breakpoints (ignore)
- PTR ignore;
+cleanup_executing_breakpoints (PTR ignore)
{
executing_breakpoint_commands = 0;
}
the global "breakpoint_proceeded" after each command. */
void
-bpstat_do_actions (bsp)
- bpstat *bsp;
+bpstat_do_actions (bpstat *bsp)
{
bpstat bs;
struct cleanup *old_chain;
analysis. */
static enum print_stop_action
-print_it_typical (bs)
- bpstat bs;
+print_it_typical (bpstat bs)
{
#ifdef UI_OUT
struct cleanup *old_chain;
further info to be printed.*/
enum print_stop_action
-bpstat_print (bs)
- bpstat bs;
+bpstat_print (bpstat bs)
{
int val;
make it pass through catch_errors. */
static int
-breakpoint_cond_eval (exp)
- PTR exp;
+breakpoint_cond_eval (PTR exp)
{
value_ptr mark = value_mark ();
int i = !value_true (evaluate_expression ((struct expression *) exp));
/* Check watchpoint condition. */
static int
-watchpoint_check (p)
- PTR p;
+watchpoint_check (PTR p)
{
bpstat bs = (bpstat) p;
struct breakpoint *b;
commands, FIXME??? fields. */
bpstat
-bpstat_stop_status (pc, not_a_breakpoint)
- CORE_ADDR *pc;
- int not_a_breakpoint;
+bpstat_stop_status (CORE_ADDR *pc, int not_a_breakpoint)
{
register struct breakpoint *b, *temp;
CORE_ADDR bp_addr;
\f
/* Tell what to do about this bpstat. */
struct bpstat_what
-bpstat_what (bs)
- bpstat bs;
+bpstat_what (bpstat bs)
{
/* Classify each bpstat as one of the following. */
enum class
just to things like whether watchpoints are set. */
int
-bpstat_should_step ()
+bpstat_should_step (void)
{
struct breakpoint *b;
ALL_BREAKPOINTS (b)
/* Nonzero if there are enabled hardware watchpoints. */
int
-bpstat_have_active_hw_watchpoints ()
+bpstat_have_active_hw_watchpoints (void)
{
struct breakpoint *b;
ALL_BREAKPOINTS (b)
function returns another bpstat which contains only the catchpoints
on that first list, if any. */
void
-bpstat_get_triggered_catchpoints (ep_list, cp_list)
- bpstat ep_list;
- bpstat *cp_list;
+bpstat_get_triggered_catchpoints (bpstat ep_list, bpstat *cp_list)
{
struct bpstats root_bs[1];
bpstat bs = root_bs;
is nonzero, process only watchpoints. */
static void
-breakpoint_1 (bnum, allflag)
- int bnum;
- int allflag;
+breakpoint_1 (int bnum, int allflag)
{
register struct breakpoint *b;
CORE_ADDR last_addr = (CORE_ADDR) -1;
/* ARGSUSED */
static void
-breakpoints_info (bnum_exp, from_tty)
- char *bnum_exp;
- int from_tty;
+breakpoints_info (char *bnum_exp, int from_tty)
{
int bnum = -1;
/* ARGSUSED */
static void
-maintenance_info_breakpoints (bnum_exp, from_tty)
- char *bnum_exp;
- int from_tty;
+maintenance_info_breakpoints (char *bnum_exp, int from_tty)
{
int bnum = -1;
/* Print a message describing any breakpoints set at PC. */
static void
-describe_other_breakpoints (pc, section)
- CORE_ADDR pc;
- asection *section;
+describe_other_breakpoints (CORE_ADDR pc, asection *section)
{
register int others = 0;
register struct breakpoint *b;
for the `break' command with no arguments. */
void
-set_default_breakpoint (valid, addr, symtab, line)
- int valid;
- CORE_ADDR addr;
- struct symtab *symtab;
- int line;
+set_default_breakpoint (int valid, CORE_ADDR addr, struct symtab *symtab,
+ int line)
{
default_breakpoint_valid = valid;
default_breakpoint_address = addr;
the official one, and the rest as duplicates. */
static void
-check_duplicates (address, section)
- CORE_ADDR address;
- asection *section;
+check_duplicates (CORE_ADDR address, asection *section)
{
register struct breakpoint *b;
register int count = 0;
your arguments BEFORE calling this routine! */
struct breakpoint *
-set_raw_breakpoint (sal)
- struct symtab_and_line sal;
+set_raw_breakpoint (struct symtab_and_line sal)
{
register struct breakpoint *b, *b1;
#ifdef GET_LONGJMP_TARGET
static void
-create_longjmp_breakpoint (func_name)
- char *func_name;
+create_longjmp_breakpoint (char *func_name)
{
struct symtab_and_line sal;
struct breakpoint *b;
set_longjmp_resume_breakpoint() to figure out where we are going. */
void
-enable_longjmp_breakpoint ()
+enable_longjmp_breakpoint (void)
{
register struct breakpoint *b;
}
void
-disable_longjmp_breakpoint ()
+disable_longjmp_breakpoint (void)
{
register struct breakpoint *b;
}
struct breakpoint *
-create_thread_event_breakpoint (address)
- CORE_ADDR address;
+create_thread_event_breakpoint (CORE_ADDR address)
{
struct breakpoint *b;
struct symtab_and_line sal;
#ifdef SOLIB_ADD
void
-remove_solib_event_breakpoints ()
+remove_solib_event_breakpoints (void)
{
register struct breakpoint *b, *temp;
}
struct breakpoint *
-create_solib_event_breakpoint (address)
- CORE_ADDR address;
+create_solib_event_breakpoint (CORE_ADDR address)
{
struct breakpoint *b;
struct symtab_and_line sal;
apply to enabled breakpoints, disabled ones can just stay disabled. */
void
-disable_breakpoints_in_shlibs (silent)
- int silent;
+disable_breakpoints_in_shlibs (int silent)
{
struct breakpoint *b;
int disabled_shlib_breaks = 0;
/* Try to reenable any breakpoints in shared libraries. */
void
-re_enable_breakpoints_in_shlibs ()
+re_enable_breakpoints_in_shlibs (void)
{
struct breakpoint *b;
#endif
static void
-solib_load_unload_1 (hookname, tempflag, dll_pathname, cond_string, bp_kind)
- char *hookname;
- int tempflag;
- char *dll_pathname;
- char *cond_string;
- enum bptype bp_kind;
+solib_load_unload_1 (char *hookname, int tempflag, char *dll_pathname,
+ char *cond_string, enum bptype bp_kind)
{
struct breakpoint *b;
struct symtabs_and_lines sals;
}
void
-create_solib_load_event_breakpoint (hookname, tempflag,
- dll_pathname, cond_string)
- char *hookname;
- int tempflag;
- char *dll_pathname;
- char *cond_string;
+create_solib_load_event_breakpoint (char *hookname, int tempflag,
+ char *dll_pathname, char *cond_string)
{
solib_load_unload_1 (hookname, tempflag, dll_pathname,
cond_string, bp_catch_load);
}
void
-create_solib_unload_event_breakpoint (hookname, tempflag,
- dll_pathname, cond_string)
- char *hookname;
- int tempflag;
- char *dll_pathname;
- char *cond_string;
+create_solib_unload_event_breakpoint (char *hookname, int tempflag,
+ char *dll_pathname, char *cond_string)
{
solib_load_unload_1 (hookname,tempflag, dll_pathname,
cond_string, bp_catch_unload);
}
static void
-create_fork_vfork_event_catchpoint (tempflag, cond_string, bp_kind)
- int tempflag;
- char *cond_string;
- enum bptype bp_kind;
+create_fork_vfork_event_catchpoint (int tempflag, char *cond_string,
+ enum bptype bp_kind)
{
struct symtab_and_line sal;
struct breakpoint *b;
}
void
-create_fork_event_catchpoint (tempflag, cond_string)
- int tempflag;
- char *cond_string;
+create_fork_event_catchpoint (int tempflag, char *cond_string)
{
create_fork_vfork_event_catchpoint (tempflag, cond_string, bp_catch_fork);
}
void
-create_vfork_event_catchpoint (tempflag, cond_string)
- int tempflag;
- char *cond_string;
+create_vfork_event_catchpoint (int tempflag, char *cond_string)
{
create_fork_vfork_event_catchpoint (tempflag, cond_string, bp_catch_vfork);
}
void
-create_exec_event_catchpoint (tempflag, cond_string)
- int tempflag;
- char *cond_string;
+create_exec_event_catchpoint (int tempflag, char *cond_string)
{
struct symtab_and_line sal;
struct breakpoint *b;
}
static int
-hw_breakpoint_used_count ()
+hw_breakpoint_used_count (void)
{
register struct breakpoint *b;
int i = 0;
}
static int
-hw_watchpoint_used_count (type, other_type_used)
- enum bptype type;
- int *other_type_used;
+hw_watchpoint_used_count (enum bptype type, int *other_type_used)
{
register struct breakpoint *b;
int i = 0;
that gets deleted automatically... */
void
-set_longjmp_resume_breakpoint (pc, frame)
- CORE_ADDR pc;
- struct frame_info *frame;
+set_longjmp_resume_breakpoint (CORE_ADDR pc, struct frame_info *frame)
{
register struct breakpoint *b;
}
void
-disable_watchpoints_before_interactive_call_start ()
+disable_watchpoints_before_interactive_call_start (void)
{
struct breakpoint *b;
}
void
-enable_watchpoints_after_interactive_call_stop ()
+enable_watchpoints_after_interactive_call_stop (void)
{
struct breakpoint *b;
Restrict it to frame FRAME if FRAME is nonzero. */
struct breakpoint *
-set_momentary_breakpoint (sal, frame, type)
- struct symtab_and_line sal;
- struct frame_info *frame;
- enum bptype type;
+set_momentary_breakpoint (struct symtab_and_line sal, struct frame_info *frame,
+ enum bptype type)
{
register struct breakpoint *b;
b = set_raw_breakpoint (sal);
/* Tell the user we have just set a breakpoint B. */
static void
-mention (b)
- struct breakpoint *b;
+mention (struct breakpoint *b)
{
int say_where = 0;
#ifdef UI_OUT
second bit : 0 normal breakpoint, 1 hardware breakpoint. */
static void
-break_command_1 (arg, flag, from_tty)
- char *arg;
- int flag, from_tty;
+break_command_1 (char *arg, int flag, int from_tty)
{
int tempflag, hardwareflag;
struct symtabs_and_lines sals;
static void
-break_at_finish_at_depth_command_1 (arg, flag, from_tty)
- char *arg;
- int flag;
- int from_tty;
+break_at_finish_at_depth_command_1 (char *arg, int flag, int from_tty)
{
struct frame_info *frame;
CORE_ADDR low, high, selected_pc = 0;
static void
-break_at_finish_command_1 (arg, flag, from_tty)
- char *arg;
- int flag;
- int from_tty;
+break_at_finish_command_1 (char *arg, int flag, int from_tty)
{
char *addr_string, *break_string, *beg_addr_string;
CORE_ADDR low, high;
/* Helper function for break_command_1 and disassemble_command. */
void
-resolve_sal_pc (sal)
- struct symtab_and_line *sal;
+resolve_sal_pc (struct symtab_and_line *sal)
{
CORE_ADDR pc;
}
void
-break_command (arg, from_tty)
- char *arg;
- int from_tty;
+break_command (char *arg, int from_tty)
{
break_command_1 (arg, 0, from_tty);
}
static void
-break_at_finish_command (arg, from_tty)
- char *arg;
- int from_tty;
+break_at_finish_command (char *arg, int from_tty)
{
break_at_finish_command_1 (arg, 0, from_tty);
}
static void
-break_at_finish_at_depth_command (arg, from_tty)
- char *arg;
- int from_tty;
+break_at_finish_at_depth_command (char *arg, int from_tty)
{
break_at_finish_at_depth_command_1 (arg, 0, from_tty);
}
void
-tbreak_command (arg, from_tty)
- char *arg;
- int from_tty;
+tbreak_command (char *arg, int from_tty)
{
break_command_1 (arg, BP_TEMPFLAG, from_tty);
}
static void
-tbreak_at_finish_command (arg, from_tty)
- char *arg;
- int from_tty;
+tbreak_at_finish_command (char *arg, int from_tty)
{
break_at_finish_command_1 (arg, BP_TEMPFLAG, from_tty);
}
static void
-hbreak_command (arg, from_tty)
- char *arg;
- int from_tty;
+hbreak_command (char *arg, int from_tty)
{
break_command_1 (arg, BP_HARDWAREFLAG, from_tty);
}
static void
-thbreak_command (arg, from_tty)
- char *arg;
- int from_tty;
+thbreak_command (char *arg, int from_tty)
{
break_command_1 (arg, (BP_TEMPFLAG | BP_HARDWAREFLAG), from_tty);
}
static void
-stop_command (arg, from_tty)
- char *arg;
- int from_tty;
+stop_command (char *arg, int from_tty)
{
printf_filtered ("Specify the type of breakpoint to set.\n\
Usage: stop in <function | address>\n\
}
static void
-stopin_command (arg, from_tty)
- char *arg;
- int from_tty;
+stopin_command (char *arg, int from_tty)
{
int badInput = 0;
}
static void
-stopat_command (arg, from_tty)
- char *arg;
- int from_tty;
+stopat_command (char *arg, int from_tty)
{
int badInput = 0;
hw_read: watch read,
hw_access: watch access (read or write) */
static void
-watch_command_1 (arg, accessflag, from_tty)
- char *arg;
- int accessflag;
- int from_tty;
+watch_command_1 (char *arg, int accessflag, int from_tty)
{
struct breakpoint *b;
struct symtab_and_line sal;
#endif
static int
-can_use_hardware_watchpoint (v)
- struct value *v;
+can_use_hardware_watchpoint (struct value *v)
{
int found_memory_cnt = 0;
struct value *head = v;
#ifdef UI_OUT
void
-watch_command_wrapper (arg, from_tty)
- char *arg;
- int from_tty;
+watch_command_wrapper (char *arg, int from_tty)
{
watch_command (arg, from_tty);
}
#endif
static void
-watch_command (arg, from_tty)
- char *arg;
- int from_tty;
+watch_command (char *arg, int from_tty)
{
watch_command_1 (arg, hw_write, from_tty);
}
#ifdef UI_OUT
void
-rwatch_command_wrapper (arg, from_tty)
- char *arg;
- int from_tty;
+rwatch_command_wrapper (char *arg, int from_tty)
{
rwatch_command (arg, from_tty);
}
#endif
static void
-rwatch_command (arg, from_tty)
- char *arg;
- int from_tty;
+rwatch_command (char *arg, int from_tty)
{
watch_command_1 (arg, hw_read, from_tty);
}
#ifdef UI_OUT
void
-awatch_command_wrapper (arg, from_tty)
- char *arg;
- int from_tty;
+awatch_command_wrapper (char *arg, int from_tty)
{
awatch_command (arg, from_tty);
}
#endif
static void
-awatch_command (arg, from_tty)
- char *arg;
- int from_tty;
+awatch_command (char *arg, int from_tty)
{
watch_command_1 (arg, hw_access, from_tty);
}
/* ARGSUSED */
void
-until_break_command (arg, from_tty)
- char *arg;
- int from_tty;
+until_break_command (char *arg, int from_tty)
{
struct symtabs_and_lines sals;
struct symtab_and_line sal;
/* These aren't used; I don't konw what they were for. */
/* Set a breakpoint at the catch clause for NAME. */
static int
-catch_breakpoint (name)
- char *name;
+catch_breakpoint (char *name)
{
}
static int
-disable_catch_breakpoint ()
+disable_catch_breakpoint (void)
{
}
static int
-delete_catch_breakpoint ()
+delete_catch_breakpoint (void)
{
}
static int
-enable_catch_breakpoint ()
+enable_catch_breakpoint (void)
{
}
#endif /* 0 */
/* This shares a lot of code with `print_frame_label_vars' from stack.c. */
static struct symtabs_and_lines
-get_catch_sals (this_level_only)
- int this_level_only;
+get_catch_sals (int this_level_only)
{
register struct blockvector *bl;
register struct block *block;
}
static void
-ep_skip_leading_whitespace (s)
- char **s;
+ep_skip_leading_whitespace (char **s)
{
if ((s == NULL) || (*s == NULL))
return;
the token is returned. Else, NULL is returned. */
static char *
-ep_find_event_name_end (arg)
- char *arg;
+ep_find_event_name_end (char *arg)
{
char *s = arg;
char *event_name_end = NULL;
if clause in the arg string. */
static char *
-ep_parse_optional_if_clause (arg)
- char **arg;
+ep_parse_optional_if_clause (char **arg)
{
char *cond_string;
Note that clients needing to preserve the returned filename for
future access should copy it to their own buffers. */
static char *
-ep_parse_optional_filename (arg)
- char **arg;
+ep_parse_optional_filename (char **arg)
{
static char filename[1024];
char *arg_p = *arg;
char *arg, int tempflag, int from_tty);
static void
-catch_fork_command_1 (fork_kind, arg, tempflag, from_tty)
- catch_fork_kind fork_kind;
- char *arg;
- int tempflag;
- int from_tty;
+catch_fork_command_1 (catch_fork_kind fork_kind, char *arg, int tempflag,
+ int from_tty)
{
char *cond_string = NULL;
#if defined(CHILD_INSERT_EXEC_CATCHPOINT)
static void
-catch_exec_command_1 (arg, tempflag, from_tty)
- char *arg;
- int tempflag;
- int from_tty;
+catch_exec_command_1 (char *arg, int tempflag, int from_tty)
{
char *cond_string = NULL;
#if defined(SOLIB_ADD)
static void
-catch_load_command_1 (arg, tempflag, from_tty)
- char *arg;
- int tempflag;
- int from_tty;
+catch_load_command_1 (char *arg, int tempflag, int from_tty)
{
char *dll_pathname = NULL;
char *cond_string = NULL;
}
static void
-catch_unload_command_1 (arg, tempflag, from_tty)
- char *arg;
- int tempflag;
- int from_tty;
+catch_unload_command_1 (char *arg, int tempflag, int from_tty)
{
char *dll_pathname = NULL;
char *cond_string = NULL;
exception event callback */
static void
-create_exception_catchpoint (tempflag, cond_string, ex_event, sal)
- int tempflag;
- char *cond_string;
- enum exception_event_kind ex_event;
- struct symtab_and_line *sal;
+create_exception_catchpoint (int tempflag, char *cond_string,
+ enum exception_event_kind ex_event,
+ struct symtab_and_line *sal)
{
struct breakpoint *b;
int thread = -1; /* All threads. */
/* Deal with "catch catch" and "catch throw" commands */
static void
-catch_exception_command_1 (ex_event, arg, tempflag, from_tty)
- enum exception_event_kind ex_event;
- char *arg;
- int tempflag;
- int from_tty;
+catch_exception_command_1 (enum exception_event_kind ex_event, char *arg,
+ int tempflag, int from_tty)
{
char *cond_string = NULL;
struct symtab_and_line *sal = NULL;
inside a catch_errors */
static int
-cover_target_enable_exception_callback (arg)
- PTR arg;
+cover_target_enable_exception_callback (PTR arg)
{
args_for_catchpoint_enable *args = arg;
struct symtab_and_line *sal;
static void
-handle_gnu_4_16_catch_command (arg, tempflag, from_tty)
- char *arg;
- int tempflag;
- int from_tty;
+handle_gnu_4_16_catch_command (char *arg, int tempflag, int from_tty)
{
/* First, translate ARG into something we can deal with in terms
of breakpoints. */
/* This creates a temporary internal breakpoint
just to placate infrun */
static struct breakpoint *
-create_temp_exception_breakpoint (pc)
- CORE_ADDR pc;
+create_temp_exception_breakpoint (CORE_ADDR pc)
{
struct symtab_and_line sal;
struct breakpoint *b;
#endif
static void
-catch_command_1 (arg, tempflag, from_tty)
- char *arg;
- int tempflag;
- int from_tty;
+catch_command_1 (char *arg, int tempflag, int from_tty)
{
/* The first argument may be an event name, such as "start" or "load".
/* Used by the gui, could be made a worker for other things. */
struct breakpoint *
-set_breakpoint_sal (sal)
- struct symtab_and_line sal;
+set_breakpoint_sal (struct symtab_and_line sal)
{
struct breakpoint *b;
b = set_raw_breakpoint (sal);
/* These aren't used; I don't know what they were for. */
/* Disable breakpoints on all catch clauses described in ARGS. */
static void
-disable_catch (args)
- char *args;
+disable_catch (char *args)
{
/* Map the disable command to catch clauses described in ARGS. */
}
/* Enable breakpoints on all catch clauses described in ARGS. */
static void
-enable_catch (args)
- char *args;
+enable_catch (char *args)
{
/* Map the disable command to catch clauses described in ARGS. */
}
/* Delete breakpoints on all catch clauses in the active scope. */
static void
-delete_catch (args)
- char *args;
+delete_catch (char *args)
{
/* Map the delete command to catch clauses described in ARGS. */
}
#endif /* 0 */
static void
-catch_command (arg, from_tty)
- char *arg;
- int from_tty;
+catch_command (char *arg, int from_tty)
{
catch_command_1 (arg, 0, from_tty);
}
\f
static void
-tcatch_command (arg, from_tty)
- char *arg;
- int from_tty;
+tcatch_command (char *arg, int from_tty)
{
catch_command_1 (arg, 1, from_tty);
}
static void
-clear_command (arg, from_tty)
- char *arg;
- int from_tty;
+clear_command (char *arg, int from_tty)
{
register struct breakpoint *b, *b1;
int default_match;
This is called after any breakpoint is hit, or after errors. */
void
-breakpoint_auto_delete (bs)
- bpstat bs;
+breakpoint_auto_delete (bpstat bs)
{
struct breakpoint *b, *temp;
structures. */
void
-delete_breakpoint (bpt)
- struct breakpoint *bpt;
+delete_breakpoint (struct breakpoint *bpt)
{
register struct breakpoint *b;
register bpstat bs;
}
void
-delete_command (arg, from_tty)
- char *arg;
- int from_tty;
+delete_command (char *arg, int from_tty)
{
struct breakpoint *b, *temp;
Unused in this case. */
static int
-breakpoint_re_set_one (bint)
- PTR bint;
+breakpoint_re_set_one (PTR bint)
{
/* get past catch_errs */
struct breakpoint *b = (struct breakpoint *) bint;
/* Re-set all breakpoints after symbols have been re-loaded. */
void
-breakpoint_re_set ()
+breakpoint_re_set (void)
{
struct breakpoint *b, *temp;
enum language save_language;
- If the breakpoint is for all threads, leave it as-is.
- Else, reset it to the current thread for inferior_pid. */
void
-breakpoint_re_set_thread (b)
- struct breakpoint *b;
+breakpoint_re_set_thread (struct breakpoint *b)
{
if (b->thread != -1)
{
}
void
-set_ignore_count (bptnum, count, from_tty)
- int bptnum, count, from_tty;
+set_ignore_count (int bptnum, int count, int from_tty)
{
register struct breakpoint *b;
/* Clear the ignore counts of all breakpoints. */
void
-breakpoint_clear_ignore_counts ()
+breakpoint_clear_ignore_counts (void)
{
struct breakpoint *b;
/* Command to set ignore-count of breakpoint N to COUNT. */
static void
-ignore_command (args, from_tty)
- char *args;
- int from_tty;
+ignore_command (char *args, int from_tty)
{
char *p = args;
register int num;
}
void
-disable_breakpoint (bpt)
- struct breakpoint *bpt;
+disable_breakpoint (struct breakpoint *bpt)
{
/* Never disable a watchpoint scope breakpoint; we want to
hit them when we leave scope so we can delete both the
/* ARGSUSED */
static void
-disable_command (args, from_tty)
- char *args;
- int from_tty;
+disable_command (char *args, int from_tty)
{
register struct breakpoint *bpt;
if (args == 0)
}
static void
-do_enable_breakpoint (bpt, disposition)
- struct breakpoint *bpt;
- enum bpdisp disposition;
+do_enable_breakpoint (struct breakpoint *bpt, enum bpdisp disposition)
{
struct frame_info *save_selected_frame = NULL;
int save_selected_frame_level = -1;
}
void
-enable_breakpoint (bpt)
- struct breakpoint *bpt;
+enable_breakpoint (struct breakpoint *bpt)
{
do_enable_breakpoint (bpt, bpt->disposition);
}
/* ARGSUSED */
static void
-enable_command (args, from_tty)
- char *args;
- int from_tty;
+enable_command (char *args, int from_tty)
{
register struct breakpoint *bpt;
if (args == 0)
}
static void
-enable_once_breakpoint (bpt)
- struct breakpoint *bpt;
+enable_once_breakpoint (struct breakpoint *bpt)
{
do_enable_breakpoint (bpt, disable);
}
/* ARGSUSED */
static void
-enable_once_command (args, from_tty)
- char *args;
- int from_tty;
+enable_once_command (char *args, int from_tty)
{
map_breakpoint_numbers (args, enable_once_breakpoint);
}
static void
-enable_delete_breakpoint (bpt)
- struct breakpoint *bpt;
+enable_delete_breakpoint (struct breakpoint *bpt)
{
do_enable_breakpoint (bpt, del);
}
/* ARGSUSED */
static void
-enable_delete_command (args, from_tty)
- char *args;
- int from_tty;
+enable_delete_command (char *args, int from_tty)
{
map_breakpoint_numbers (args, enable_delete_breakpoint);
}
/* Use default_breakpoint_'s, or nothing if they aren't valid. */
struct symtabs_and_lines
-decode_line_spec_1 (string, funfirstline)
- char *string;
- int funfirstline;
+decode_line_spec_1 (char *string, int funfirstline)
{
struct symtabs_and_lines sals;
if (string == 0)
}
\f
void
-_initialize_breakpoint ()
+_initialize_breakpoint (void)
{
struct cmd_list_element *c;
corresponding to a psymtab. */
void
-buildsym_init ()
+buildsym_init (void)
{
free_pendings = NULL;
file_symbols = NULL;
file, e.g. a shared library). */
void
-buildsym_new_init ()
+buildsym_new_init (void)
{
buildsym_init ();
}
characters and strings is language specific. */
static void
-c_emit_char (c, stream, quoter)
- register int c;
- struct ui_file *stream;
- int quoter;
+c_emit_char (register int c, struct ui_file *stream, int quoter)
{
c &= 0xFF; /* Avoid sign bit follies */
}
void
-c_printchar (c, stream)
- int c;
- struct ui_file *stream;
+c_printchar (int c, struct ui_file *stream)
{
fputc_filtered ('\'', stream);
LA_EMIT_CHAR (c, stream, '\'');
printing LENGTH characters, or if FORCE_ELLIPSES. */
void
-c_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+c_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
register unsigned int i;
unsigned int things_printed = 0;
debugging information supplied by the compiler. fnf@cygnus.com */
struct type *
-c_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+c_create_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type *type = NULL;
};
void
-_initialize_c_language ()
+_initialize_c_language (void)
{
add_language (&c_language_defn);
add_language (&cplus_language_defn);
NEW is the new name for a type TYPE. */
void
-c_typedef_print (type, new, stream)
- struct type *type;
- struct symbol *new;
- struct ui_file *stream;
+c_typedef_print (struct type *type, struct symbol *new, struct ui_file *stream)
{
CHECK_TYPEDEF (type);
switch (current_language->la_language)
/* LEVEL is the depth to indent lines by. */
void
-c_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+c_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
register enum type_code code;
int demangled_args;
derivation via protected inheritance, so gdb can print it out */
static void
-cp_type_print_derivation_info (stream, type)
- struct ui_file *stream;
- struct type *type;
+cp_type_print_derivation_info (struct ui_file *stream, struct type *type)
{
char *name;
int i;
/* Print the C++ method arguments ARGS to the file STREAM. */
static void
-cp_type_print_method_args (args, prefix, varstring, staticp, stream)
- struct type **args;
- char *prefix;
- char *varstring;
- int staticp;
- struct ui_file *stream;
+cp_type_print_method_args (struct type **args, char *prefix, char *varstring,
+ int staticp, struct ui_file *stream)
{
int i;
SHOW is always zero on recursive calls. */
void
-c_type_print_varspec_prefix (type, stream, show, passed_a_ptr)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
+c_type_print_varspec_prefix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr)
{
char *name;
if (type == 0)
NEED_SPACE = 1 indicates an initial white space is needed */
static void
-c_type_print_cv_qualifier (type, stream, need_pre_space, need_post_space)
- struct type *type;
- struct ui_file *stream;
- int need_pre_space;
- int need_post_space;
+c_type_print_cv_qualifier (struct type *type, struct ui_file *stream,
+ int need_pre_space, int need_post_space)
{
int flag = 0;
static void
-c_type_print_args (type, stream)
- struct type *type;
- struct ui_file *stream;
+c_type_print_args (struct type *type, struct ui_file *stream)
{
int i;
struct type **args;
Args work like c_type_print_varspec_prefix. */
void
-c_type_print_varspec_suffix (type, stream, show, passed_a_ptr, demangled_args)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
- int demangled_args;
+c_type_print_varspec_suffix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr, int demangled_args)
{
if (type == 0)
return;
We increase it for some recursive calls. */
void
-c_type_print_base (type, stream, show, level)
- struct type *type;
- struct ui_file *stream;
- int show;
- int level;
+c_type_print_base (struct type *type, struct ui_file *stream, int show,
+ int level)
{
register int i;
register int len;
The PRETTY parameter controls prettyprinting. */
int
-c_val_print (type, valaddr, embedded_offset, address, stream, format, deref_ref, recurse,
- pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+c_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
register unsigned int i = 0; /* Number of characters printed */
unsigned len;
}
\f
int
-c_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+c_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
struct type *type = VALUE_TYPE (val);
struct type *real_type;
/*int current_token, lookahead_token; */
INLINE static enum ch_terminal
-PEEK_TOKEN ()
+PEEK_TOKEN (void)
{
if (terminal_buffer[0] == TOKEN_NOT_READ)
{
#define PEEK_TOKEN1() peek_token_(1)
#define PEEK_TOKEN2() peek_token_(2)
static enum ch_terminal
-peek_token_ (i)
- int i;
+peek_token_ (int i)
{
if (i > MAX_LOOK_AHEAD)
internal_error ("ch-exp.c - too much lookahead");
#if 0
static void
-pushback_token (code, node)
- enum ch_terminal code;
- YYSTYPE node;
+pushback_token (enum ch_terminal code, YYSTYPE node)
{
int i;
if (terminal_buffer[MAX_LOOK_AHEAD] != TOKEN_NOT_READ)
#endif
static void
-forward_token_ ()
+forward_token_ (void)
{
int i;
for (i = 0; i < MAX_LOOK_AHEAD; i++)
if it isn't TOKEN, the parser is broken. */
static void
-require (token)
- enum ch_terminal token;
+require (enum ch_terminal token)
{
if (PEEK_TOKEN () != token)
{
}
static int
-check_token (token)
- enum ch_terminal token;
+check_token (enum ch_terminal token)
{
if (PEEK_TOKEN () != token)
return 0;
else return 1.
*/
static int
-expect (token, message)
- enum ch_terminal token;
- char *message;
+expect (enum ch_terminal token, char *message)
{
if (PEEK_TOKEN () != token)
{
}
static tree
-parse_simple_name_string ()
+parse_simple_name_string (void)
{
int token = PEEK_TOKEN ();
tree name;
}
static tree
-parse_name_string ()
+parse_name_string (void)
{
tree name = parse_opt_name_string (0);
if (name)
Returns if pass 2: a decl or value for identifier. */
static tree
-parse_name ()
+parse_name (void)
{
tree name = parse_name_string ();
if (pass == 1 || ignoring)
#if 0
static void
-pushback_paren_expr (expr)
- tree expr;
+pushback_paren_expr (tree expr)
{
if (pass == 1 && !ignoring)
expr = build1 (PAREN_EXPR, NULL_TREE, expr);
/* Matches: <case label> */
static void
-parse_case_label ()
+parse_case_label (void)
{
if (check_token (ELSE))
error ("ELSE in tuples labels not implemented");
}
static int
-parse_opt_untyped_expr ()
+parse_opt_untyped_expr (void)
{
switch (PEEK_TOKEN ())
{
}
static void
-parse_unary_call ()
+parse_unary_call (void)
{
FORWARD_TOKEN ();
expect ('(', NULL);
#if 0
static struct type *
-parse_mode_call ()
+parse_mode_call (void)
{
struct type *type;
FORWARD_TOKEN ();
#endif
static struct type *
-parse_mode_or_normal_call ()
+parse_mode_or_normal_call (void)
{
struct type *type;
FORWARD_TOKEN ();
Assume we have parsed the function, and are at the '('. */
static void
-parse_call ()
+parse_call (void)
{
int arg_count;
require ('(');
}
static void
-parse_named_record_element ()
+parse_named_record_element (void)
{
struct stoken label;
char buf[256];
/* Returns one or more TREE_LIST nodes, in reverse order. */
static void
-parse_tuple_element (type)
- struct type *type;
+parse_tuple_element (struct type *type)
{
if (PEEK_TOKEN () == DOT_FIELD_NAME)
{
/* Matches: a COMMA-separated list of tuple elements.
Returns a list (of TREE_LIST nodes). */
static void
-parse_opt_element_list (type)
- struct type *type;
+parse_opt_element_list (struct type *type)
{
arglist_len = 0;
if (PEEK_TOKEN () == ']')
If modename is non-NULL it prefixed the tuple. */
static void
-parse_tuple (mode)
- struct type *mode;
+parse_tuple (struct type *mode)
{
struct type *type;
if (mode)
}
static void
-parse_primval ()
+parse_primval (void)
{
struct type *type;
enum exp_opcode op;
}
static void
-parse_operand6 ()
+parse_operand6 (void)
{
if (check_token (RECEIVE))
{
}
static void
-parse_operand5 ()
+parse_operand5 (void)
{
enum exp_opcode op;
/* We are supposed to be looking for a <string repetition operator>,
}
static void
-parse_operand4 ()
+parse_operand4 (void)
{
enum exp_opcode op;
parse_operand5 ();
}
static void
-parse_operand3 ()
+parse_operand3 (void)
{
enum exp_opcode op;
parse_operand4 ();
}
static void
-parse_operand2 ()
+parse_operand2 (void)
{
enum exp_opcode op;
parse_operand3 ();
}
static void
-parse_operand1 ()
+parse_operand1 (void)
{
enum exp_opcode op;
parse_operand2 ();
}
static void
-parse_operand0 ()
+parse_operand0 (void)
{
enum exp_opcode op;
parse_operand1 ();
}
static void
-parse_expr ()
+parse_expr (void)
{
parse_operand0 ();
if (check_token (GDB_ASSIGNMENT))
}
static void
-parse_then_alternative ()
+parse_then_alternative (void)
{
expect (THEN, "missing 'THEN' in 'IF' expression");
parse_expr ();
}
static void
-parse_else_alternative ()
+parse_else_alternative (void)
{
if (check_token (ELSIF))
parse_if_expression_body ();
/* Matches: <boolean expression> <then alternative> <else alternative> */
static void
-parse_if_expression_body ()
+parse_if_expression_body (void)
{
parse_expr ();
parse_then_alternative ();
}
static void
-parse_if_expression ()
+parse_if_expression (void)
{
require (IF);
parse_if_expression_body ();
You should call convert() to fix up the <untyped_expr>. */
static void
-parse_untyped_expr ()
+parse_untyped_expr (void)
{
switch (PEEK_TOKEN ())
{
}
int
-chill_parse ()
+chill_parse (void)
{
terminal_buffer[0] = TOKEN_NOT_READ;
if (PEEK_TOKEN () == TYPENAME && PEEK_TOKEN1 () == END_TOKEN)
on demand. */
static void
-growbuf_by_size (count)
- int count;
+growbuf_by_size (int count)
{
int growby;
in symbol table lookups. If not successful, returns NULL. */
static char *
-match_simple_name_string ()
+match_simple_name_string (void)
{
char *tokptr = lexptr;
digits we have encountered. */
static int
-decode_integer_value (base, tokptrptr, ivalptr)
- int base;
- char **tokptrptr;
- LONGEST *ivalptr;
+decode_integer_value (int base, char **tokptrptr, LONGEST *ivalptr)
{
char *tokptr = *tokptrptr;
int temp;
}
static int
-decode_integer_literal (valptr, tokptrptr)
- LONGEST *valptr;
- char **tokptrptr;
+decode_integer_literal (LONGEST *valptr, char **tokptrptr)
{
char *tokptr = *tokptrptr;
int base = 0;
legal floating point value. */
static enum ch_terminal
-match_float_literal ()
+match_float_literal (void)
{
char *tokptr = lexptr;
char *buf;
a string, it is simply doubled (I.E. "this""is""one""string") */
static enum ch_terminal
-match_string_literal ()
+match_string_literal (void)
{
char *tokptr = lexptr;
int in_ctrlseq = 0;
*/
static enum ch_terminal
-match_character_literal ()
+match_character_literal (void)
{
char *tokptr = lexptr;
LONGEST ival = 0;
in any integer literal. */
static enum ch_terminal
-match_integer_literal ()
+match_integer_literal (void)
{
char *tokptr = lexptr;
LONGEST ival;
in any bit-string literal. */
static enum ch_terminal
-match_bitstring_literal ()
+match_bitstring_literal (void)
{
register char *tokptr = lexptr;
int bitoffset = 0;
operators used are compatible. */
static enum ch_terminal
-ch_lex ()
+ch_lex (void)
{
unsigned int i;
enum ch_terminal token;
}
static void
-write_lower_upper_value (opcode, type)
- enum exp_opcode opcode; /* Either UNOP_LOWER or UNOP_UPPER */
- struct type *type;
+write_lower_upper_value (enum exp_opcode opcode, /* Either UNOP_LOWER or UNOP_UPPER */
+ struct type *type)
{
if (type == NULL)
write_exp_elt_opcode (opcode);
}
void
-chill_error (msg)
- char *msg;
+chill_error (char *msg)
{
/* Never used. */
}
characters to derive the demangled form. */
char *
-chill_demangle (mangled)
- const char *mangled;
+chill_demangle (const char *mangled)
{
const char *joiner = NULL;
char *demangled;
}
static void
-chill_printchar (c, stream)
- register int c;
- struct ui_file *stream;
+chill_printchar (register int c, struct ui_file *stream)
{
c &= 0xFF; /* Avoid sign bit follies */
*/
static void
-chill_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+chill_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
register unsigned int i;
unsigned int things_printed = 0;
}
static struct type *
-chill_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+chill_create_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type *type = NULL;
*RESULT_TYPE is the appropriate type for the result. */
LONGEST
-type_lower_upper (op, type, result_type)
- enum exp_opcode op; /* Either UNOP_LOWER or UNOP_UPPER */
- struct type *type;
- struct type **result_type;
+type_lower_upper (enum exp_opcode op, /* Either UNOP_LOWER or UNOP_UPPER */
+ struct type *type, struct type **result_type)
{
LONGEST low, high;
*result_type = type;
}
static value_ptr
-value_chill_length (val)
- value_ptr val;
+value_chill_length (value_ptr val)
{
LONGEST tmp;
struct type *type = VALUE_TYPE (val);
}
static value_ptr
-value_chill_card (val)
- value_ptr val;
+value_chill_card (value_ptr val)
{
LONGEST tmp = 0;
struct type *type = VALUE_TYPE (val);
}
static value_ptr
-value_chill_max_min (op, val)
- enum exp_opcode op;
- value_ptr val;
+value_chill_max_min (enum exp_opcode op, value_ptr val)
{
LONGEST tmp = 0;
struct type *type = VALUE_TYPE (val);
}
static value_ptr
-evaluate_subexp_chill (expect_type, exp, pos, noside)
- struct type *expect_type;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_chill (struct type *expect_type,
+ register struct expression *exp, register int *pos,
+ enum noside noside)
{
int pc = *pos;
struct type *type;
/* Initialization for Chill */
void
-_initialize_chill_language ()
+_initialize_chill_language (void)
{
builtin_type_chill_bool =
init_type (TYPE_CODE_BOOL, TARGET_CHAR_BIT / TARGET_CHAR_BIT,
static void chill_type_print_base (struct type *, struct ui_file *, int, int);
void
-chill_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+chill_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
if (varstring != NULL && *varstring != '\0')
{
We increase it for some recursive calls. */
static void
-chill_type_print_base (type, stream, show, level)
- struct type *type;
- struct ui_file *stream;
- int show;
- int level;
+chill_type_print_base (struct type *type, struct ui_file *stream, int show,
+ int level)
{
register int len;
register int i;
decimal integer values. */
static void
-chill_print_type_scalar (type, val, stream)
- struct type *type;
- LONGEST val;
- struct ui_file *stream;
+chill_print_type_scalar (struct type *type, LONGEST val, struct ui_file *stream)
{
switch (TYPE_CODE (type))
{
element indexes (in Chill syntax). */
static void
-chill_val_print_array_elements (type, valaddr, address, stream,
- format, deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+chill_val_print_array_elements (struct type *type, char *valaddr,
+ CORE_ADDR address, struct ui_file *stream,
+ int format, int deref_ref, int recurse,
+ enum val_prettyprint pretty)
{
unsigned int i = 0;
unsigned int things_printed = 0;
The PRETTY parameter controls prettyprinting. */
int
-chill_val_print (type, valaddr, embedded_offset, address,
- stream, format, deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+chill_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
LONGEST val;
unsigned int i = 0; /* Number of characters printed. */
should not print, or zero if called from top level. */
static void
-chill_print_value_fields (type, valaddr, stream, format, recurse, pretty,
- dont_print)
- struct type *type;
- char *valaddr;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
- struct type **dont_print;
+chill_print_value_fields (struct type *type, char *valaddr,
+ struct ui_file *stream, int format, int recurse,
+ enum val_prettyprint pretty, struct type **dont_print)
{
int i, len;
int fields_seen = 0;
}
\f
int
-chill_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+chill_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
struct type *type = VALUE_TYPE (val);
struct type *real_type = check_typedef (type);
/* Mark beginning of a table */
void
-cli_table_begin (uiout, nbrofcols, tblid)
- struct ui_out *uiout;
- int nbrofcols;
- char *tblid;
+cli_table_begin (struct ui_out *uiout, int nbrofcols, char *tblid)
{
}
/* Mark beginning of a table body */
void
-cli_table_body (uiout)
- struct ui_out *uiout;
+cli_table_body (struct ui_out *uiout)
{
/* first, close the table header line */
cli_text (uiout, "\n");
/* Mark end of a table */
void
-cli_table_end (uiout)
- struct ui_out *uiout;
+cli_table_end (struct ui_out *uiout)
{
}
/* Specify table header */
void
-cli_table_header (uiout, width, alignment, colhdr)
- struct ui_out *uiout;
- int width;
- enum ui_align alignment;
- char *colhdr;
+cli_table_header (struct ui_out *uiout, int width, enum ui_align alignment,
+ char *colhdr)
{
cli_field_string (uiout, 0, width, alignment, 0, colhdr);
}
/* Mark beginning of a list */
void
-cli_list_begin (uiout, list_flag, lstid)
- struct ui_out *uiout;
- int list_flag;
- char *lstid;
+cli_list_begin (struct ui_out *uiout, int list_flag, char *lstid)
{
}
/* Mark end of a list */
void
-cli_list_end (uiout, list_flag)
- struct ui_out *uiout;
- int list_flag;
+cli_list_end (struct ui_out *uiout, int list_flag)
{
}
/* output an int field */
void
-cli_field_int (uiout, fldno, width, alignment, fldname, value)
- struct ui_out *uiout;
- int fldno;
- int width;
- enum ui_align alignment;
- char *fldname;
- int value;
+cli_field_int (struct ui_out *uiout, int fldno, int width,
+ enum ui_align alignment, char *fldname, int value)
{
char buffer[20]; /* FIXME: how many chars long a %d can become? */
/* used to ommit a field */
void
-cli_field_skip (uiout, fldno, width, alignment, fldname)
- struct ui_out *uiout;
- int fldno;
- int width;
- enum ui_align alignment;
- char *fldname;
+cli_field_skip (struct ui_out *uiout, int fldno, int width,
+ enum ui_align alignment, char *fldname)
{
cli_field_string (uiout, fldno, width, alignment, fldname, "");
}
}
void
-cli_spaces (uiout, numspaces)
- struct ui_out *uiout;
- int numspaces;
+cli_spaces (struct ui_out *uiout, int numspaces)
{
struct ui_out_data *data = ui_out_data (uiout);
print_spaces_filtered (numspaces, data->stream);
}
void
-cli_text (uiout, string)
- struct ui_out *uiout;
- char *string;
+cli_text (struct ui_out *uiout, char *string)
{
struct ui_out_data *data = ui_out_data (uiout);
fputs_filtered (string, data->stream);
}
void
-cli_wrap_hint (uiout, identstring)
- struct ui_out *uiout;
- char *identstring;
+cli_wrap_hint (struct ui_out *uiout, char *identstring)
{
wrap_here (identstring);
}
void
-cli_flush (uiout)
- struct ui_out *uiout;
+cli_flush (struct ui_out *uiout)
{
struct ui_out_data *data = ui_out_data (uiout);
gdb_flush (data->stream);
/* access to ui_out format private members */
static void
-field_separator ()
+field_separator (void)
{
struct ui_out_data *data = ui_out_data (uiout);
fputc_filtered (' ', data->stream);
/* standard gdb initialization hook */
void
-_initialize_cli_out ()
+_initialize_cli_out (void)
{
/* nothing needs to be done */
}
*/
void
-coff_solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+coff_solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
asection *libsect;
*/
void
-coff_solib_create_inferior_hook ()
+coff_solib_create_inferior_hook (void)
{
coff_solib_add ((char *) 0, 0, (struct target_ops *) 0);
}
-kingdon). */
static void
-coff_locate_sections (abfd, sectp, csip)
- bfd *abfd;
- asection *sectp;
- PTR csip;
+coff_locate_sections (bfd *abfd, asection *sectp, PTR csip)
{
register struct coff_symfile_info *csi;
const char *name;
static void find_targ_sec (bfd *, asection *, void *);
static void
-find_targ_sec (abfd, sect, obj)
- bfd *abfd;
- asection *sect;
- PTR obj;
+find_targ_sec (bfd *abfd, asection *sect, PTR obj)
{
struct find_targ_sec_arg *args = (struct find_targ_sec_arg *) obj;
if (sect->target_index == args->targ_index)
/* Return the section number (SECT_OFF_*) that CS points to. */
static int
-cs_to_section (cs, objfile)
- struct coff_symbol *cs;
- struct objfile *objfile;
+cs_to_section (struct coff_symbol *cs, struct objfile *objfile)
{
asection *sect = NULL;
struct find_targ_sec_arg args;
static CORE_ADDR cs_section_address (struct coff_symbol *, bfd *);
static CORE_ADDR
-cs_section_address (cs, abfd)
- struct coff_symbol *cs;
- bfd *abfd;
+cs_section_address (struct coff_symbol *cs, bfd *abfd)
{
asection *sect = NULL;
struct find_targ_sec_arg args;
or for associating a new type with the index. */
static struct type **
-coff_lookup_type (index)
- register int index;
+coff_lookup_type (register int index)
{
if (index >= type_vector_length)
{
This can create an empty (zeroed) type object. */
static struct type *
-coff_alloc_type (index)
- int index;
+coff_alloc_type (int index)
{
register struct type **type_addr = coff_lookup_type (index);
register struct type *type = *type_addr;
it indicates the start of data for one original source file. */
static void
-coff_start_symtab (name)
- char *name;
+coff_start_symtab (char *name)
{
start_symtab (
/* We fill in the filename later. start_symtab puts
text address for the file, and SIZE is the number of bytes of text. */
static void
-complete_symtab (name, start_addr, size)
- char *name;
- CORE_ADDR start_addr;
- unsigned int size;
+complete_symtab (char *name, CORE_ADDR start_addr, unsigned int size)
{
if (last_source_file != NULL)
free (last_source_file);
struct symtab for that file and put it in the list of all such. */
static void
-coff_end_symtab (objfile)
- struct objfile *objfile;
+coff_end_symtab (struct objfile *objfile)
{
struct symtab *symtab;
}
\f
static void
-record_minimal_symbol (name, address, type, objfile)
- char *name;
- CORE_ADDR address;
- enum minimal_symbol_type type;
- struct objfile *objfile;
+record_minimal_symbol (char *name, CORE_ADDR address,
+ enum minimal_symbol_type type, struct objfile *objfile)
{
/* We don't want TDESC entry points in the minimal symbol table */
if (name[0] == '@')
The ultimate result is a new symtab (or, FIXME, eventually a psymtab). */
static void
-coff_symfile_init (objfile)
- struct objfile *objfile;
+coff_symfile_init (struct objfile *objfile)
{
/* Allocate struct to keep track of stab reading. */
objfile->sym_stab_info = (struct dbx_symfile_info *)
/* ARGSUSED */
static void
-find_linenos (abfd, asect, vpinfo)
- bfd *abfd;
- sec_ptr asect;
- PTR vpinfo;
+find_linenos (bfd *abfd, sec_ptr asect, PTR vpinfo)
{
struct coff_symfile_info *info;
int size, count;
/* ARGSUSED */
static void
-coff_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+coff_symfile_read (struct objfile *objfile, int mainline)
{
struct coff_symfile_info *info;
struct dbx_symfile_info *dbxinfo;
}
static void
-coff_new_init (ignore)
- struct objfile *ignore;
+coff_new_init (struct objfile *ignore)
{
}
objfile struct from the global list of known objfiles. */
static void
-coff_symfile_finish (objfile)
- struct objfile *objfile;
+coff_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_private != NULL)
{
We read them one at a time using read_one_sym (). */
static void
-coff_symtab_read (symtab_offset, nsyms, objfile)
- long symtab_offset;
- unsigned int nsyms;
- struct objfile *objfile;
+coff_symtab_read (long symtab_offset, unsigned int nsyms,
+ struct objfile *objfile)
{
register struct context_stack *new;
struct coff_symbol coff_symbol;
in internal_auxent form, and skip any other auxents. */
static void
-read_one_sym (cs, sym, aux)
- register struct coff_symbol *cs;
- register struct internal_syment *sym;
- register union internal_auxent *aux;
+read_one_sym (register struct coff_symbol *cs,
+ register struct internal_syment *sym,
+ register union internal_auxent *aux)
{
int i;
static char *stringtab = NULL;
static int
-init_stringtab (abfd, offset)
- bfd *abfd;
- long offset;
+init_stringtab (bfd *abfd, long offset)
{
long length;
int val;
}
static void
-free_stringtab ()
+free_stringtab (void)
{
if (stringtab)
free (stringtab);
}
static char *
-getsymname (symbol_entry)
- struct internal_syment *symbol_entry;
+getsymname (struct internal_syment *symbol_entry)
{
static char buffer[SYMNMLEN + 1];
char *result;
is only good for temporary use. */
static char *
-coff_getfilename (aux_entry)
- union internal_auxent *aux_entry;
+coff_getfilename (union internal_auxent *aux_entry)
{
static char buffer[BUFSIZ];
register char *temp;
them into GDB's data structures. */
static int
-init_lineno (abfd, offset, size)
- bfd *abfd;
- long offset;
- int size;
+init_lineno (bfd *abfd, long offset, int size)
{
int val;
}
static void
-free_linetab ()
+free_linetab (void)
{
if (linetab)
free (linetab);
#endif
static void
-enter_linenos (file_offset, first_line, last_line, objfile)
- long file_offset;
- register int first_line;
- register int last_line;
- struct objfile *objfile;
+enter_linenos (long file_offset, register int first_line,
+ register int last_line, struct objfile *objfile)
{
register char *rawptr;
struct internal_lineno lptr;
}
\f
static void
-patch_type (type, real_type)
- struct type *type;
- struct type *real_type;
+patch_type (struct type *type, struct type *real_type)
{
register struct type *target = TYPE_TARGET_TYPE (type);
register struct type *real_target = TYPE_TARGET_TYPE (real_type);
so that they can be used to print out opaque data structures properly. */
static void
-patch_opaque_types (s)
- struct symtab *s;
+patch_opaque_types (struct symtab *s)
{
register struct block *b;
register int i;
}
\f
static struct symbol *
-process_coff_symbol (cs, aux, objfile)
- register struct coff_symbol *cs;
- register union internal_auxent *aux;
- struct objfile *objfile;
+process_coff_symbol (register struct coff_symbol *cs,
+ register union internal_auxent *aux,
+ struct objfile *objfile)
{
register struct symbol *sym
= (struct symbol *) obstack_alloc (&objfile->symbol_obstack,
/* Decode a coff type specifier; return the type that is meant. */
static struct type *
-decode_type (cs, c_type, aux)
- register struct coff_symbol *cs;
- unsigned int c_type;
- register union internal_auxent *aux;
+decode_type (register struct coff_symbol *cs, unsigned int c_type,
+ register union internal_auxent *aux)
{
register struct type *type = 0;
unsigned int new_c_type;
return the type that the function returns. */
static struct type *
-decode_function_type (cs, c_type, aux)
- register struct coff_symbol *cs;
- unsigned int c_type;
- register union internal_auxent *aux;
+decode_function_type (register struct coff_symbol *cs, unsigned int c_type,
+ register union internal_auxent *aux)
{
if (aux->x_sym.x_tagndx.l == 0)
cs->c_naux = 0; /* auxent refers to function, not base type */
/* basic C types */
static struct type *
-decode_base_type (cs, c_type, aux)
- register struct coff_symbol *cs;
- unsigned int c_type;
- register union internal_auxent *aux;
+decode_base_type (register struct coff_symbol *cs, unsigned int c_type,
+ register union internal_auxent *aux)
{
struct type *type;
object describing the type. */
static struct type *
-coff_read_struct_type (index, length, lastsym)
- int index;
- int length;
- int lastsym;
+coff_read_struct_type (int index, int length, int lastsym)
{
struct nextfield
{
/* ARGSUSED */
static struct type *
-coff_read_enum_type (index, length, lastsym)
- int index;
- int length;
- int lastsym;
+coff_read_enum_type (int index, int length, int lastsym)
{
register struct symbol *sym;
register struct type *type;
};
void
-_initialize_coffread ()
+_initialize_coffread (void)
{
add_symtab_fns (&coff_sym_fns);
}
Returns a pointer to the deprecated command. */
struct cmd_list_element *
-deprecate_cmd (cmd, replacement)
- struct cmd_list_element *cmd;
- char *replacement;
+deprecate_cmd (struct cmd_list_element *cmd, char *replacement)
{
cmd->flags |= (CMD_DEPRECATED | DEPRECATED_WARN_USER);
#endif
struct cmd_list_element *
-add_alias_cmd (name, oldname, class, abbrev_flag, list)
- char *name;
- char *oldname;
- enum command_class class;
- int abbrev_flag;
- struct cmd_list_element **list;
+add_alias_cmd (char *name, char *oldname, enum command_class class,
+ int abbrev_flag, struct cmd_list_element **list)
{
/* Must do this since lookup_cmd tries to side-effect its first arg */
char *copied_name;
/* This is an empty "cfunc". */
void
-not_just_help_class_command (args, from_tty)
- char *args;
- int from_tty;
+not_just_help_class_command (char *args, int from_tty)
{
}
static void empty_sfunc (char *, int, struct cmd_list_element *);
static void
-empty_sfunc (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+empty_sfunc (char *args, int from_tty, struct cmd_list_element *c)
{
}
command to LIST and return a pointer to the added command (not
necessarily the head of LIST). */
struct cmd_list_element *
-add_show_from_set (setcmd, list)
- struct cmd_list_element *setcmd;
- struct cmd_list_element **list;
+add_show_from_set (struct cmd_list_element *setcmd,
+ struct cmd_list_element **list)
{
struct cmd_list_element *showcmd =
(struct cmd_list_element *) xmalloc (sizeof (struct cmd_list_element));
/* Remove the command named NAME from the command list. */
void
-delete_cmd (name, list)
- char *name;
- struct cmd_list_element **list;
+delete_cmd (char *name, struct cmd_list_element **list)
{
register struct cmd_list_element *c;
struct cmd_list_element *p;
*/
void
-help_cmd (command, stream)
- char *command;
- struct ui_file *stream;
+help_cmd (char *command, struct ui_file *stream)
{
struct cmd_list_element *c;
extern struct cmd_list_element *cmdlist;
* If you call this routine with a class >= 0, it recurses.
*/
void
-help_list (list, cmdtype, class, stream)
- struct cmd_list_element *list;
- char *cmdtype;
- enum command_class class;
- struct ui_file *stream;
+help_list (struct cmd_list_element *list, char *cmdtype,
+ enum command_class class, struct ui_file *stream)
{
int len;
char *cmdtype1, *cmdtype2;
/* Print only the first line of STR on STREAM. */
static void
-print_doc_line (stream, str)
- struct ui_file *stream;
- char *str;
+print_doc_line (struct ui_file *stream, char *str)
{
static char *line_buffer = 0;
static int line_size;
* is at the low level, not the high-level).
*/
void
-help_cmd_list (list, class, prefix, recurse, stream)
- struct cmd_list_element *list;
- enum command_class class;
- char *prefix;
- int recurse;
- struct ui_file *stream;
+help_cmd_list (struct cmd_list_element *list, enum command_class class,
+ char *prefix, int recurse, struct ui_file *stream)
{
register struct cmd_list_element *c;
found in nfound */
static struct cmd_list_element *
-find_cmd (command, len, clist, ignore_help_classes, nfound)
- char *command;
- int len;
- struct cmd_list_element *clist;
- int ignore_help_classes;
- int *nfound;
+find_cmd (char *command, int len, struct cmd_list_element *clist,
+ int ignore_help_classes, int *nfound)
{
struct cmd_list_element *found, *c;
the struct cmd_list_element is NULL). */
struct cmd_list_element *
-lookup_cmd_1 (text, clist, result_list, ignore_help_classes)
- char **text;
- struct cmd_list_element *clist, **result_list;
- int ignore_help_classes;
+lookup_cmd_1 (char **text, struct cmd_list_element *clist,
+ struct cmd_list_element **result_list, int ignore_help_classes)
{
char *p, *command;
int len, tmp, nfound;
/* All this hair to move the space to the front of cmdtype */
static void
-undef_cmd_error (cmdtype, q)
- char *cmdtype, *q;
+undef_cmd_error (char *cmdtype, char *q)
{
error ("Undefined %scommand: \"%s\". Try \"help%s%.*s\".",
cmdtype,
the function field of the struct cmd_list_element is 0). */
struct cmd_list_element *
-lookup_cmd (line, list, cmdtype, allow_unknown, ignore_help_classes)
- char **line;
- struct cmd_list_element *list;
- char *cmdtype;
- int allow_unknown;
- int ignore_help_classes;
+lookup_cmd (char **line, struct cmd_list_element *list, char *cmdtype,
+ int allow_unknown, int ignore_help_classes)
{
struct cmd_list_element *last_list = 0;
struct cmd_list_element *c =
CMDTYPE precedes the word "command" in the error message. */
struct cmd_list_element *
-lookup_cmd (line, list, cmdtype, allow_unknown)
- char **line;
- struct cmd_list_element *list;
- char *cmdtype;
- int allow_unknown;
+lookup_cmd (char **line, struct cmd_list_element *list, char *cmdtype,
+ int allow_unknown)
{
register char *p;
register struct cmd_list_element *c, *found;
"oobar"; if WORD is "baz/foo", return "baz/foobar". */
char **
-complete_on_cmdlist (list, text, word)
- struct cmd_list_element *list;
- char *text;
- char *word;
+complete_on_cmdlist (struct cmd_list_element *list, char *text, char *word)
{
struct cmd_list_element *ptr;
char **matchlist;
}
static int
-parse_binary_operation (arg)
- char *arg;
+parse_binary_operation (char *arg)
{
int length;
directly by the user (i.e. these are just like any other
command). C is the command list element for the command. */
void
-do_setshow_command (arg, from_tty, c)
- char *arg;
- int from_tty;
- struct cmd_list_element *c;
+do_setshow_command (char *arg, int from_tty, struct cmd_list_element *c)
{
if (c->type == set_cmd)
{
/* Show all the settings in a list of show commands. */
void
-cmd_show_list (list, from_tty, prefix)
- struct cmd_list_element *list;
- int from_tty;
- char *prefix;
+cmd_show_list (struct cmd_list_element *list, int from_tty, char *prefix)
{
#ifdef UI_OUT
ui_out_list_begin (uiout, "showlist");
/* ARGSUSED */
static void
-shell_escape (arg, from_tty)
- char *arg;
- int from_tty;
+shell_escape (char *arg, int from_tty)
{
#ifdef CANT_FORK
/* If ARG is NULL, they want an inferior shell, but `system' just
}
static void
-make_command (arg, from_tty)
- char *arg;
- int from_tty;
+make_command (char *arg, int from_tty)
{
char *p;
}
static void
-show_user_1 (c, stream)
- struct cmd_list_element *c;
- struct ui_file *stream;
+show_user_1 (struct cmd_list_element *c, struct ui_file *stream)
{
register struct command_line *cmdlines;
/* ARGSUSED */
static void
-show_user (args, from_tty)
- char *args;
- int from_tty;
+show_user (char *args, int from_tty)
{
struct cmd_list_element *c;
extern struct cmd_list_element *cmdlist;
}
void
-_initialize_command ()
+_initialize_command (void)
{
add_com ("shell", class_support, shell_escape,
"Execute the rest of the line as a shell command. \n\
context for the user to figure it out. */
void
-clear_complaints (sym_reading, noisy)
- int sym_reading;
- int noisy;
+clear_complaints (int sym_reading, int noisy)
{
struct complaint *p;
}
void
-_initialize_complaints ()
+_initialize_complaints (void)
{
add_show_from_set
(add_set_cmd ("complaints", class_support, var_zinteger,
extern int immediate_quit;
static void
-show_copying_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_copying_command (char *ignore, int from_tty)
{
immediate_quit++;
printf_filtered (" GNU GENERAL PUBLIC LICENSE\n");
}
static void
-show_warranty_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_warranty_command (char *ignore, int from_tty)
{
immediate_quit++;
printf_filtered (" NO WARRANTY\n");
}
void
-_initialize_copying ()
+_initialize_copying (void)
{
add_cmd ("copying", no_class, show_copying_command,
"Conditions for redistributing copies of GDB.",
*/
static void
-fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR reg_addr;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR reg_addr)
{
int regno;
CORE_ADDR addr;
BLOCKEND is the address of the end of the user structure. */
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
};
void
-_initialize_core_aout ()
+_initialize_core_aout (void)
{
add_core_fns (&aout_core_fns);
}
};
void
-_initialize_core_regset ()
+_initialize_core_regset (void)
{
add_core_fns (®set_core_fns);
}
};
void
-_initialize_core_solaris ()
+_initialize_core_solaris (void)
{
add_core_fns (&solaris_core_fns);
}
/* Backward compatability with old way of specifying core files. */
void
-core_file_command (filename, from_tty)
- char *filename;
- int from_tty;
+core_file_command (char *filename, int from_tty)
{
struct target_ops *t;
* this function will call all of the hook functions. */
static void
-call_extra_exec_file_hooks (filename)
- char *filename;
+call_extra_exec_file_hooks (char *filename)
{
int i;
be reopened. */
void
-close_exec_file ()
+close_exec_file (void)
{
#if 0 /* FIXME */
if (exec_bfd)
}
void
-reopen_exec_file ()
+reopen_exec_file (void)
{
#if 0 /* FIXME */
if (exec_bfd)
print a warning if they don't go together. */
void
-validate_files ()
+validate_files (void)
{
if (exec_bfd && core_bfd)
{
otherwise return 0 in that case. */
char *
-get_exec_file (err)
- int err;
+get_exec_file (int err)
{
if (exec_bfd)
return bfd_get_filename (exec_bfd);
/* Report a memory error with error(). */
void
-memory_error (status, memaddr)
- int status;
- CORE_ADDR memaddr;
+memory_error (int status, CORE_ADDR memaddr)
{
struct ui_file *tmp_stream = mem_fileopen ();
make_cleanup_ui_file_delete (tmp_stream);
/* Same as target_read_memory, but report an error if can't read. */
void
-read_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int status;
status = target_read_memory (memaddr, myaddr, len);
/* Like target_read_memory, but slightly different parameters. */
int
-dis_asm_read_memory (memaddr, myaddr, len, info)
- bfd_vma memaddr;
- bfd_byte *myaddr;
- unsigned int len;
- disassemble_info *info;
+dis_asm_read_memory (bfd_vma memaddr, bfd_byte *myaddr, unsigned int len,
+ disassemble_info *info)
{
return target_read_memory (memaddr, (char *) myaddr, len);
}
/* Like memory_error with slightly different parameters. */
void
-dis_asm_memory_error (status, memaddr, info)
- int status;
- bfd_vma memaddr;
- disassemble_info *info;
+dis_asm_memory_error (int status, bfd_vma memaddr, disassemble_info *info)
{
memory_error (status, memaddr);
}
/* Like print_address with slightly different parameters. */
void
-dis_asm_print_address (addr, info)
- bfd_vma addr;
- struct disassemble_info *info;
+dis_asm_print_address (bfd_vma addr, struct disassemble_info *info)
{
print_address (addr, info->stream);
}
/* Same as target_write_memory, but report an error if can't write. */
void
-write_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int status;
/* Read an integer from debugged memory, given address and number of bytes. */
LONGEST
-read_memory_integer (memaddr, len)
- CORE_ADDR memaddr;
- int len;
+read_memory_integer (CORE_ADDR memaddr, int len)
{
char buf[sizeof (LONGEST)];
}
ULONGEST
-read_memory_unsigned_integer (memaddr, len)
- CORE_ADDR memaddr;
- int len;
+read_memory_unsigned_integer (CORE_ADDR memaddr, int len)
{
char buf[sizeof (ULONGEST)];
}
void
-read_memory_string (memaddr, buffer, max_len)
- CORE_ADDR memaddr;
- char *buffer;
- int max_len;
+read_memory_string (CORE_ADDR memaddr, char *buffer, int max_len)
{
register char *cp;
register int i;
static void set_gnutarget_command (char *, int, struct cmd_list_element *);
static void
-set_gnutarget_command (ignore, from_tty, c)
- char *ignore;
- int from_tty;
- struct cmd_list_element *c;
+set_gnutarget_command (char *ignore, int from_tty, struct cmd_list_element *c)
{
if (STREQ (gnutarget_string, "auto"))
gnutarget = NULL;
/* Set the gnutarget. */
void
-set_gnutarget (newtarget)
- char *newtarget;
+set_gnutarget (char *newtarget)
{
if (gnutarget_string != NULL)
free (gnutarget_string);
}
void
-_initialize_core ()
+_initialize_core (void)
{
struct cmd_list_element *c;
c = add_cmd ("core-file", class_files, core_file_command,
handle. */
void
-add_core_fns (cf)
- struct core_fns *cf;
+add_core_fns (struct core_fns *cf)
{
cf->next = core_file_fns;
core_file_fns = cf;
reading the core file. */
int
-default_core_sniffer (our_fns, abfd)
- struct core_fns *our_fns;
- bfd *abfd;
+default_core_sniffer (struct core_fns *our_fns, bfd *abfd)
{
int result;
selected. */
static struct core_fns *
-sniff_core_bfd (abfd)
- bfd *abfd;
+sniff_core_bfd (bfd *abfd)
{
struct core_fns *cf;
struct core_fns *yummy = NULL;
core file handler that recognizes it. */
int
-default_check_format (abfd)
- bfd *abfd;
+default_check_format (bfd *abfd)
{
return (0);
}
/* Attempt to recognize core file formats that BFD rejects. */
static boolean
-gdb_check_format (abfd)
- bfd *abfd;
+gdb_check_format (bfd *abfd)
{
struct core_fns *cf;
/* ARGSUSED */
static void
-core_close (quitting)
- int quitting;
+core_close (int quitting)
{
char *name;
is really an int * which points to from_tty. */
static int
-solib_add_stub (from_ttyp)
- PTR from_ttyp;
+solib_add_stub (PTR from_ttyp)
{
SOLIB_ADD (NULL, *(int *) from_ttyp, ¤t_target);
re_enable_breakpoints_in_shlibs ();
list of threads in a core file. */
static void
-add_to_thread_list (abfd, asect, reg_sect_arg)
- bfd *abfd;
- asection *asect;
- PTR reg_sect_arg;
+add_to_thread_list (bfd *abfd, asection *asect, PTR reg_sect_arg)
{
int thread_id;
asection *reg_sect = (asection *) reg_sect_arg;
/* This routine opens and sets up the core file bfd. */
static void
-core_open (filename, from_tty)
- char *filename;
- int from_tty;
+core_open (char *filename, int from_tty)
{
const char *p;
int siggy;
}
static void
-core_detach (args, from_tty)
- char *args;
- int from_tty;
+core_detach (char *args, int from_tty)
{
if (args)
error ("Too many arguments");
/* ARGSUSED */
static void
-get_core_registers (regno)
- int regno;
+get_core_registers (int regno)
{
int status;
}
static char *
-core_file_to_sym_file (core)
- char *core;
+core_file_to_sym_file (char *core)
{
CONST char *failing_command;
char *p;
}
static void
-core_files_info (t)
- struct target_ops *t;
+core_files_info (struct target_ops *t)
{
print_section_info (t, core_bfd);
}
`gdb internal error' (since generic_mourn calls breakpoint_init_inferior). */
static int
-ignore (addr, contents)
- CORE_ADDR addr;
- char *contents;
+ignore (CORE_ADDR addr, char *contents)
{
return 0;
}
behaviour.
*/
static int
-core_file_thread_alive (tid)
- int tid;
+core_file_thread_alive (int tid)
{
return 1;
}
/* Fill in core_ops with its defined operations and properties. */
static void
-init_core_ops ()
+init_core_ops (void)
{
core_ops.to_shortname = "core";
core_ops.to_longname = "Local core dump file";
int coreops_suppress_target;
void
-_initialize_corelow ()
+_initialize_corelow (void)
{
init_core_ops ();
void
-cp_print_class_method (valaddr, type, stream)
- char *valaddr;
- struct type *type;
- struct ui_file *stream;
+cp_print_class_method (char *valaddr, struct type *type, struct ui_file *stream)
{
struct type *domain;
struct fn_field *f = NULL;
"pointer to virtual function". */
int
-cp_is_vtbl_ptr_type (type)
- struct type *type;
+cp_is_vtbl_ptr_type (struct type *type)
{
char *typename = type_name_no_tag (type);
"pointer to virtual function table". */
int
-cp_is_vtbl_member (type)
- struct type *type;
+cp_is_vtbl_member (struct type *type)
{
if (TYPE_CODE (type) == TYPE_CODE_PTR)
{
should not print, or zero if called from top level. */
void
-cp_print_value_fields (type, real_type, valaddr, offset, address, stream, format, recurse, pretty,
- dont_print_vb, dont_print_statmem)
- struct type *type;
- struct type *real_type;
- char *valaddr;
- int offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
- struct type **dont_print_vb;
- int dont_print_statmem;
+cp_print_value_fields (struct type *type, struct type *real_type, char *valaddr,
+ int offset, CORE_ADDR address, struct ui_file *stream,
+ int format, int recurse, enum val_prettyprint pretty,
+ struct type **dont_print_vb, int dont_print_statmem)
{
int i, len, n_baseclasses;
struct obstack tmp_obstack;
baseclasses. */
static void
-cp_print_value (type, real_type, valaddr, offset, address, stream, format, recurse, pretty,
- dont_print_vb)
- struct type *type;
- struct type *real_type;
- char *valaddr;
- int offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
- struct type **dont_print_vb;
+cp_print_value (struct type *type, struct type *real_type, char *valaddr,
+ int offset, CORE_ADDR address, struct ui_file *stream,
+ int format, int recurse, enum val_prettyprint pretty,
+ struct type **dont_print_vb)
{
struct obstack tmp_obstack;
struct type **last_dont_print
have the same meanings as in c_val_print. */
static void
-cp_print_static_field (type, val, stream, format, recurse, pretty)
- struct type *type;
- value_ptr val;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
+cp_print_static_field (struct type *type, value_ptr val, struct ui_file *stream,
+ int format, int recurse, enum val_prettyprint pretty)
{
if (TYPE_CODE (type) == TYPE_CODE_STRUCT)
{
}
void
-cp_print_class_member (valaddr, domain, stream, prefix)
- char *valaddr;
- struct type *domain;
- struct ui_file *stream;
- char *prefix;
+cp_print_class_member (char *valaddr, struct type *domain,
+ struct ui_file *stream, char *prefix)
{
/* VAL is a byte offset into the structure type DOMAIN.
static void
-cp_print_hpacc_virtual_table_entries (type, vfuncs, v, stream, format, recurse, pretty)
- struct type *type;
- int *vfuncs;
- value_ptr v;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
+cp_print_hpacc_virtual_table_entries (struct type *type, int *vfuncs,
+ value_ptr v, struct ui_file *stream,
+ int format, int recurse,
+ enum val_prettyprint pretty)
{
int fn, oi;
void
-_initialize_cp_valprint ()
+_initialize_cp_valprint (void)
{
add_show_from_set
(add_set_cmd ("static-members", class_support, var_boolean,
static void cpu32bug_open (char *args, int from_tty);
static void
-cpu32bug_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+cpu32bug_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
}; /* init_cpu32bug_cmds */
static void
-cpu32bug_open (args, from_tty)
- char *args;
- int from_tty;
+cpu32bug_open (char *args, int from_tty)
{
monitor_open (args, &cpu32bug_cmds, from_tty);
}
void
-_initialize_cpu32bug_rom ()
+_initialize_cpu32bug_rom (void)
{
init_cpu32bug_cmds ();
init_monitor_ops (&cpu32bug_ops);
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
/* blockend is the address of the end of the user structure */
-m88k_register_u_addr (blockend, regnum)
- int blockend, regnum;
+m88k_register_u_addr (int blockend, int regnum)
{
struct USER u;
int ustart = blockend - sizeof (struct USER);
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = (greg_t *) gregsetp;
#endif
void
-add_shared_symbol_files ()
+add_shared_symbol_files (void)
{
void *desc;
struct link_map *ld_map, *lm, lms;
#include <sys/regset.h>
unsigned int
-m88k_harris_core_register_addr (regno, reg_ptr)
- int regno, reg_ptr;
+m88k_harris_core_register_addr (int regno, int reg_ptr)
{
unsigned int word_offset;
#endif /* _ES_MP */
void
-_initialize_m88k_nat ()
+_initialize_m88k_nat (void)
{
#ifdef _ES_MP
/* Enable 88110 support, as we don't support the 88100 under ES/MP. */
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
char *from;
registers. */
int
-d10v_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+d10v_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 8);
}
unsigned char *
-d10v_breakpoint_from_pc (pcptr, lenptr)
- CORE_ADDR *pcptr;
- int *lenptr;
+d10v_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
{
static unsigned char breakpoint[] =
{0x2f, 0x90, 0x5e, 0x00};
register REG_NR. */
int
-d10v_register_byte (reg_nr)
- int reg_nr;
+d10v_register_byte (int reg_nr)
{
if (reg_nr < A0_REGNUM)
return (reg_nr * 2);
register REG_NR. */
int
-d10v_register_raw_size (reg_nr)
- int reg_nr;
+d10v_register_raw_size (int reg_nr)
{
if (reg_nr < A0_REGNUM)
return 2;
for register N. */
int
-d10v_register_virtual_size (reg_nr)
- int reg_nr;
+d10v_register_virtual_size (int reg_nr)
{
return TYPE_LENGTH (REGISTER_VIRTUAL_TYPE (reg_nr));
}
of data in register N. */
struct type *
-d10v_register_virtual_type (reg_nr)
- int reg_nr;
+d10v_register_virtual_type (int reg_nr)
{
if (reg_nr >= A0_REGNUM
&& reg_nr < (A0_REGNUM + NR_A_REGS))
/* convert $pc and $sp to/from virtual addresses */
int
-d10v_register_convertible (nr)
- int nr;
+d10v_register_convertible (int nr)
{
return ((nr) == PC_REGNUM || (nr) == SP_REGNUM);
}
void
-d10v_register_convert_to_virtual (regnum, type, from, to)
- int regnum;
- struct type *type;
- char *from;
- char *to;
+d10v_register_convert_to_virtual (int regnum, struct type *type, char *from,
+ char *to)
{
ULONGEST x = extract_unsigned_integer (from, REGISTER_RAW_SIZE (regnum));
if (regnum == PC_REGNUM)
}
void
-d10v_register_convert_to_raw (type, regnum, from, to)
- struct type *type;
- int regnum;
- char *from;
- char *to;
+d10v_register_convert_to_raw (struct type *type, int regnum, char *from,
+ char *to)
{
ULONGEST x = extract_unsigned_integer (from, TYPE_LENGTH (type));
x &= 0x3ffff;
CORE_ADDR
-d10v_make_daddr (x)
- CORE_ADDR x;
+d10v_make_daddr (CORE_ADDR x)
{
return ((x) | DMEM_START);
}
CORE_ADDR
-d10v_make_iaddr (x)
- CORE_ADDR x;
+d10v_make_iaddr (CORE_ADDR x)
{
return (((x) << 2) | IMEM_START);
}
int
-d10v_daddr_p (x)
- CORE_ADDR x;
+d10v_daddr_p (CORE_ADDR x)
{
return (((x) & 0x3000000) == DMEM_START);
}
int
-d10v_iaddr_p (x)
- CORE_ADDR x;
+d10v_iaddr_p (CORE_ADDR x)
{
return (((x) & 0x3000000) == IMEM_START);
}
CORE_ADDR
-d10v_convert_iaddr_to_raw (x)
- CORE_ADDR x;
+d10v_convert_iaddr_to_raw (CORE_ADDR x)
{
return (((x) >> 2) & 0xffff);
}
CORE_ADDR
-d10v_convert_daddr_to_raw (x)
- CORE_ADDR x;
+d10v_convert_daddr_to_raw (CORE_ADDR x)
{
return ((x) & 0xffff);
}
register. */
void
-d10v_store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+d10v_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
write_register (ARG1_REGNUM, (addr));
}
Things always get returned in RET1_REGNUM, RET2_REGNUM, ... */
void
-d10v_store_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+d10v_store_return_value (struct type *type, char *valbuf)
{
write_register_bytes (REGISTER_BYTE (RET1_REGNUM),
valbuf,
as a CORE_ADDR (or an expression that can be used as one). */
CORE_ADDR
-d10v_extract_struct_value_address (regbuf)
- char *regbuf;
+d10v_extract_struct_value_address (char *regbuf)
{
return (extract_address ((regbuf) + REGISTER_BYTE (ARG1_REGNUM),
REGISTER_RAW_SIZE (ARG1_REGNUM))
}
CORE_ADDR
-d10v_frame_saved_pc (frame)
- struct frame_info *frame;
+d10v_frame_saved_pc (struct frame_info *frame)
{
return ((frame)->extra_info->return_pc);
}
CORE_ADDR
-d10v_frame_args_address (fi)
- struct frame_info *fi;
+d10v_frame_args_address (struct frame_info *fi)
{
return (fi)->frame;
}
CORE_ADDR
-d10v_frame_locals_address (fi)
- struct frame_info *fi;
+d10v_frame_locals_address (struct frame_info *fi)
{
return (fi)->frame;
}
the stack and that may not be written yet. */
CORE_ADDR
-d10v_saved_pc_after_call (frame)
- struct frame_info *frame;
+d10v_saved_pc_after_call (struct frame_info *frame)
{
return ((read_register (LR_REGNUM) << 2)
| IMEM_START);
registers. */
void
-d10v_pop_frame ()
+d10v_pop_frame (void)
{
generic_pop_current_frame (do_d10v_pop_frame);
}
static void
-do_d10v_pop_frame (fi)
- struct frame_info *fi;
+do_d10v_pop_frame (struct frame_info *fi)
{
CORE_ADDR fp;
int regnum;
}
static int
-check_prologue (op)
- unsigned short op;
+check_prologue (unsigned short op)
{
/* st rn, @-sp */
if ((op & 0x7E1F) == 0x6C1F)
}
CORE_ADDR
-d10v_skip_prologue (pc)
- CORE_ADDR pc;
+d10v_skip_prologue (CORE_ADDR pc)
{
unsigned long op;
unsigned short op1, op2;
*/
CORE_ADDR
-d10v_frame_chain (fi)
- struct frame_info *fi;
+d10v_frame_chain (struct frame_info *fi)
{
d10v_frame_init_saved_regs (fi);
static int next_addr, uses_frame;
static int
-prologue_find_regs (op, fi, addr)
- unsigned short op;
- struct frame_info *fi;
- CORE_ADDR addr;
+prologue_find_regs (unsigned short op, struct frame_info *fi, CORE_ADDR addr)
{
int n;
for it IS the sp for the next frame. */
void
-d10v_frame_init_saved_regs (fi)
- struct frame_info *fi;
+d10v_frame_init_saved_regs (struct frame_info *fi)
{
CORE_ADDR fp, pc;
unsigned long op;
}
void
-d10v_init_extra_frame_info (fromleaf, fi)
- int fromleaf;
- struct frame_info *fi;
+d10v_init_extra_frame_info (int fromleaf, struct frame_info *fi)
{
fi->extra_info = (struct frame_extra_info *)
frame_obstack_alloc (sizeof (struct frame_extra_info));
}
static void
-show_regs (args, from_tty)
- char *args;
- int from_tty;
+show_regs (char *args, int from_tty)
{
int a;
printf_filtered ("PC=%04lx (0x%lx) PSW=%04lx RPT_S=%04lx RPT_E=%04lx RPT_C=%04lx\n",
}
CORE_ADDR
-d10v_read_pc (pid)
- int pid;
+d10v_read_pc (int pid)
{
int save_pid;
CORE_ADDR pc;
}
void
-d10v_write_pc (val, pid)
- CORE_ADDR val;
- int pid;
+d10v_write_pc (CORE_ADDR val, int pid)
{
int save_pid;
}
CORE_ADDR
-d10v_read_sp ()
+d10v_read_sp (void)
{
return (D10V_MAKE_DADDR (read_register (SP_REGNUM)));
}
void
-d10v_write_sp (val)
- CORE_ADDR val;
+d10v_write_sp (CORE_ADDR val)
{
write_register (SP_REGNUM, D10V_CONVERT_DADDR_TO_RAW (val));
}
void
-d10v_write_fp (val)
- CORE_ADDR val;
+d10v_write_fp (CORE_ADDR val)
{
write_register (FP_REGNUM, D10V_CONVERT_DADDR_TO_RAW (val));
}
CORE_ADDR
-d10v_read_fp ()
+d10v_read_fp (void)
{
return (D10V_MAKE_DADDR (read_register (FP_REGNUM)));
}
Needed for targets where we don't actually execute a JSR/BSR instruction */
CORE_ADDR
-d10v_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+d10v_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
write_register (LR_REGNUM, D10V_CONVERT_IADDR_TO_RAW (CALL_DUMMY_ADDRESS ()));
return sp;
static struct stack_item *push_stack_item (struct stack_item *prev,
void *contents, int len);
static struct stack_item *
-push_stack_item (prev, contents, len)
- struct stack_item *prev;
- void *contents;
- int len;
+push_stack_item (struct stack_item *prev, void *contents, int len)
{
struct stack_item *si;
si = xmalloc (sizeof (struct stack_item));
static struct stack_item *pop_stack_item (struct stack_item *si);
static struct stack_item *
-pop_stack_item (si)
- struct stack_item *si;
+pop_stack_item (struct stack_item *si)
{
struct stack_item *dead = si;
si = si->prev;
CORE_ADDR
-d10v_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+d10v_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int i;
int regnum = ARG1_REGNUM;
trace_data;
static void
-trace_command (args, from_tty)
- char *args;
- int from_tty;
+trace_command (char *args, int from_tty)
{
/* Clear the host-side trace buffer, allocating space if needed. */
trace_data.size = 0;
}
static void
-untrace_command (args, from_tty)
- char *args;
- int from_tty;
+untrace_command (char *args, int from_tty)
{
tracing = 0;
}
static void
-trace_info (args, from_tty)
- char *args;
- int from_tty;
+trace_info (char *args, int from_tty)
{
int i;
on STREAM. Returns length of the instruction, in bytes. */
static int
-print_insn (memaddr, stream)
- CORE_ADDR memaddr;
- struct ui_file *stream;
+print_insn (CORE_ADDR memaddr, struct ui_file *stream)
{
/* If there's no disassembler, something is very wrong. */
if (tm_print_insn == NULL)
}
static void
-d10v_eva_prepare_to_trace ()
+d10v_eva_prepare_to_trace (void)
{
if (!tracing)
return;
more useful for display. */
static void
-d10v_eva_get_trace_data ()
+d10v_eva_get_trace_data (void)
{
int count, i, j, oldsize;
int trace_addr, trace_seg, trace_cnt, next_cnt;
}
static void
-tdisassemble_command (arg, from_tty)
- char *arg;
- int from_tty;
+tdisassemble_command (char *arg, int from_tty)
{
int i, count;
CORE_ADDR low, high;
}
static void
-display_trace (low, high)
- int low, high;
+display_trace (int low, int high)
{
int i, count, trace_show_source, first, suppress;
CORE_ADDR next_address;
static gdbarch_init_ftype d10v_gdbarch_init;
static struct gdbarch *
-d10v_gdbarch_init (info, arches)
- struct gdbarch_info info;
- struct gdbarch_list *arches;
+d10v_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
{
static LONGEST d10v_call_dummy_words[] =
{0};
extern void (*target_wait_loop_hook) (void);
void
-_initialize_d10v_tdep ()
+_initialize_d10v_tdep (void)
{
register_gdbarch_init (bfd_arch_d10v, d10v_gdbarch_init);
registers. */
void
-d30v_pop_frame ()
+d30v_pop_frame (void)
{
struct frame_info *frame = get_current_frame ();
CORE_ADDR fp;
}
static int
-check_prologue (op)
- unsigned long op;
+check_prologue (unsigned long op)
{
/* add sp,sp,imm -- observed */
if ((op & OP_MASK_ALL_BUT_IMM) == OP_ADD_SP_IMM)
}
CORE_ADDR
-d30v_skip_prologue (pc)
- CORE_ADDR pc;
+d30v_skip_prologue (CORE_ADDR pc)
{
unsigned long op[2];
unsigned long opl, opr; /* left / right sub operations */
*/
CORE_ADDR
-d30v_frame_chain (frame)
- struct frame_info *frame;
+d30v_frame_chain (struct frame_info *frame)
{
struct frame_saved_regs fsr;
static int frame_size;
static int
-prologue_find_regs (op, fsr, addr)
- unsigned long op;
- struct frame_saved_regs *fsr;
- CORE_ADDR addr;
+prologue_find_regs (unsigned long op, struct frame_saved_regs *fsr,
+ CORE_ADDR addr)
{
int n;
int offset;
ways in the stack frame. sp is even more special: the address we
return for it IS the sp for the next frame. */
void
-d30v_frame_find_saved_regs (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+d30v_frame_find_saved_regs (struct frame_info *fi, struct frame_saved_regs *fsr)
{
CORE_ADDR fp, pc;
unsigned long opl, opr;
}
void
-d30v_frame_find_saved_regs_offsets (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+d30v_frame_find_saved_regs_offsets (struct frame_info *fi,
+ struct frame_saved_regs *fsr)
{
CORE_ADDR fp, pc;
unsigned long opl, opr;
}
void
-d30v_init_extra_frame_info (fromleaf, fi)
- int fromleaf;
- struct frame_info *fi;
+d30v_init_extra_frame_info (int fromleaf, struct frame_info *fi)
{
struct frame_saved_regs dummy;
}
void
-d30v_init_frame_pc (fromleaf, prev)
- int fromleaf;
- struct frame_info *prev;
+d30v_init_frame_pc (int fromleaf, struct frame_info *prev)
{
/* default value, put here so we can breakpoint on it and
see if the default value is really the right thing to use */
static void d30v_print_register (int regnum, int tabular);
static void
-d30v_print_register (regnum, tabular)
- int regnum;
- int tabular;
+d30v_print_register (int regnum, int tabular)
{
if (regnum < A0_REGNUM)
{
}
static void
-d30v_print_flags ()
+d30v_print_flags (void)
{
long psw = read_register (PSW_REGNUM);
printf_filtered ("flags #1");
}
static void
-print_flags_command (args, from_tty)
- char *args;
- int from_tty;
+print_flags_command (char *args, int from_tty)
{
d30v_print_flags ();
}
void
-d30v_do_registers_info (regnum, fpregs)
- int regnum;
- int fpregs;
+d30v_do_registers_info (int regnum, int fpregs)
{
long long num1, num2;
long psw;
}
CORE_ADDR
-d30v_fix_call_dummy (dummyname, start_sp, fun, nargs, args, type, gcc_p)
- char *dummyname;
- CORE_ADDR start_sp;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+d30v_fix_call_dummy (char *dummyname, CORE_ADDR start_sp, CORE_ADDR fun,
+ int nargs, value_ptr *args, struct type *type, int gcc_p)
{
int regnum;
CORE_ADDR sp;
}
static void
-d30v_pop_dummy_frame (fi)
- struct frame_info *fi;
+d30v_pop_dummy_frame (struct frame_info *fi)
{
CORE_ADDR sp = fi->dummy;
int regnum;
CORE_ADDR
-d30v_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+d30v_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int i, len, index = 0, regnum = 2;
char buffer[4], *contents;
/* restored. */
CORE_ADDR
-d30v_call_dummy_address ()
+d30v_call_dummy_address (void)
{
CORE_ADDR entry;
struct minimal_symbol *sym;
trace_data;
static void
-trace_command (args, from_tty)
- char *args;
- int from_tty;
+trace_command (char *args, int from_tty)
{
/* Clear the host-side trace buffer, allocating space if needed. */
trace_data.size = 0;
}
static void
-untrace_command (args, from_tty)
- char *args;
- int from_tty;
+untrace_command (char *args, int from_tty)
{
tracing = 0;
}
static void
-trace_info (args, from_tty)
- char *args;
- int from_tty;
+trace_info (char *args, int from_tty)
{
int i;
on STREAM. Returns length of the instruction, in bytes. */
static int
-print_insn (memaddr, stream)
- CORE_ADDR memaddr;
- struct ui_file *stream;
+print_insn (CORE_ADDR memaddr, struct ui_file *stream)
{
/* If there's no disassembler, something is very wrong. */
if (tm_print_insn == NULL)
}
void
-d30v_eva_prepare_to_trace ()
+d30v_eva_prepare_to_trace (void)
{
if (!tracing)
return;
more useful for display. */
void
-d30v_eva_get_trace_data ()
+d30v_eva_get_trace_data (void)
{
int count, i, j, oldsize;
int trace_addr, trace_seg, trace_cnt, next_cnt;
}
static void
-tdisassemble_command (arg, from_tty)
- char *arg;
- int from_tty;
+tdisassemble_command (char *arg, int from_tty)
{
int i, count;
CORE_ADDR low, high;
}
static void
-display_trace (low, high)
- int low, high;
+display_trace (int low, int high)
{
int i, count, trace_show_source, first, suppress;
CORE_ADDR next_address;
extern void (*target_wait_loop_hook) (void);
void
-_initialize_d30v_tdep ()
+_initialize_d30v_tdep (void)
{
tm_print_insn = print_insn_d30v;
static void dbug_open (char *args, int from_tty);
static void
-dbug_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+dbug_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
} /* init_debug_ops */
static void
-dbug_open (args, from_tty)
- char *args;
- int from_tty;
+dbug_open (char *args, int from_tty)
{
monitor_open (args, &dbug_cmds, from_tty);
}
void
-_initialize_dbug_rom ()
+_initialize_dbug_rom (void)
{
init_dbug_cmds ();
init_monitor_ops (&dbug_ops);
/* Free up old header file tables */
static void
-free_header_files ()
+free_header_files (void)
{
if (this_object_header_files)
{
/* Allocate new header file tables */
static void
-init_header_files ()
+init_header_files (void)
{
n_allocated_this_object_header_files = 10;
this_object_header_files = (int *) xmalloc (10 * sizeof (int));
at the next successive FILENUM. */
static void
-add_this_object_header_file (i)
- int i;
+add_this_object_header_file (int i)
{
if (n_this_object_header_files == n_allocated_this_object_header_files)
{
symbol tables for the same header file. */
static void
-add_old_header_file (name, instance)
- char *name;
- int instance;
+add_old_header_file (char *name, int instance)
{
register struct header_file *p = HEADER_FILES (current_objfile);
register int i;
so we record the file when its "begin" is seen and ignore the "end". */
static void
-add_new_header_file (name, instance)
- char *name;
- int instance;
+add_new_header_file (char *name, int instance)
{
register int i;
register struct header_file *hfile;
#if 0
static struct type **
-explicit_lookup_type (real_filenum, index)
- int real_filenum, index;
+explicit_lookup_type (int real_filenum, int index)
{
register struct header_file *f = &HEADER_FILES (current_objfile)[real_filenum];
#endif
\f
static void
-record_minimal_symbol (name, address, type, objfile)
- char *name;
- CORE_ADDR address;
- int type;
- struct objfile *objfile;
+record_minimal_symbol (char *name, CORE_ADDR address, int type,
+ struct objfile *objfile)
{
enum minimal_symbol_type ms_type;
int section;
file, e.g. a shared library). */
static void
-dbx_new_init (ignore)
- struct objfile *ignore;
+dbx_new_init (struct objfile *ignore)
{
stabsread_new_init ();
buildsym_new_init ();
#define DBX_STRINGTAB_SIZE_SIZE sizeof(long) /* FIXME */
static void
-dbx_symfile_init (objfile)
- struct objfile *objfile;
+dbx_symfile_init (struct objfile *objfile)
{
int val;
bfd *sym_bfd = objfile->obfd;
objfile struct from the global list of known objfiles. */
static void
-dbx_symfile_finish (objfile)
- struct objfile *objfile;
+dbx_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_stab_info != NULL)
{
/* Call deferred funtions in CONT_LIST. */
static void
-process_now (objfile)
- struct objfile *objfile;
+process_now (struct objfile *objfile)
{
int i;
int save_symbuf_idx;
(into the string table) but this does no harm. */
static void
-fill_symbuf (sym_bfd)
- bfd *sym_bfd;
+fill_symbuf (bfd *sym_bfd)
{
unsigned int count;
int nbytes;
call this function to get the continuation. */
static char *
-dbx_next_symbol_text (objfile)
- struct objfile *objfile;
+dbx_next_symbol_text (struct objfile *objfile)
{
struct internal_nlist nlist;
allocated. */
static void
-init_bincl_list (number, objfile)
- int number;
- struct objfile *objfile;
+init_bincl_list (int number, struct objfile *objfile)
{
bincls_allocated = number;
next_bincl = bincl_list = (struct header_file_location *)
/* Add a bincl to the list. */
static void
-add_bincl_to_list (pst, name, instance)
- struct partial_symtab *pst;
- char *name;
- int instance;
+add_bincl_to_list (struct partial_symtab *pst, char *name, int instance)
{
if (next_bincl >= bincl_list + bincls_allocated)
{
with that header_file_location. */
static struct partial_symtab *
-find_corresponding_bincl_psymtab (name, instance)
- char *name;
- int instance;
+find_corresponding_bincl_psymtab (char *name, int instance)
{
struct header_file_location *bincl;
/* Free the storage allocated for the bincl list. */
static void
-free_bincl_list (objfile)
- struct objfile *objfile;
+free_bincl_list (struct objfile *objfile)
{
mfree (objfile->md, (PTR) bincl_list);
bincls_allocated = 0;
add them to the minimal symbol table. */
static void
-read_dbx_dynamic_symtab (objfile)
- struct objfile *objfile;
+read_dbx_dynamic_symtab (struct objfile *objfile)
{
bfd *abfd = objfile->obfd;
struct cleanup *back_to;
debugging information is available. */
static void
-read_dbx_symtab (objfile)
- struct objfile *objfile;
+read_dbx_symtab (struct objfile *objfile)
{
register struct external_nlist *bufp = 0; /* =0 avoids gcc -Wall glitch */
struct internal_nlist nlist;
static struct partial_symtab *
-start_psymtab (objfile, filename, textlow, ldsymoff, global_syms, static_syms)
- struct objfile *objfile;
- char *filename;
- CORE_ADDR textlow;
- int ldsymoff;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+start_psymtab (struct objfile *objfile, char *filename, CORE_ADDR textlow,
+ int ldsymoff, struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
struct partial_symtab *result =
start_psymtab_common (objfile, objfile->section_offsets,
FIXME: List variables and peculiarities of same. */
struct partial_symtab *
-end_psymtab (pst, include_list, num_includes, capping_symbol_offset,
- capping_text, dependency_list, number_dependencies, textlow_not_set)
- struct partial_symtab *pst;
- char **include_list;
- int num_includes;
- int capping_symbol_offset;
- CORE_ADDR capping_text;
- struct partial_symtab **dependency_list;
- int number_dependencies;
- int textlow_not_set;
+end_psymtab (struct partial_symtab *pst, char **include_list, int num_includes,
+ int capping_symbol_offset, CORE_ADDR capping_text,
+ struct partial_symtab **dependency_list, int number_dependencies,
+ int textlow_not_set)
{
int i;
struct objfile *objfile = pst->objfile;
}
\f
static void
-dbx_psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+dbx_psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct cleanup *old_chain;
int i;
Be verbose about it if the user wants that. */
static void
-dbx_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+dbx_psymtab_to_symtab (struct partial_symtab *pst)
{
bfd *sym_bfd;
/* Read in a defined section of a specific object file's symbols. */
static void
-read_ofile_symtab (pst)
- struct partial_symtab *pst;
+read_ofile_symtab (struct partial_symtab *pst)
{
register char *namestring;
register struct external_nlist *bufp;
It is used in end_symtab. */
void
-process_one_symbol (type, desc, valu, name, section_offsets, objfile)
- int type, desc;
- CORE_ADDR valu;
- char *name;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
+process_one_symbol (int type, int desc, CORE_ADDR valu, char *name,
+ struct section_offsets *section_offsets,
+ struct objfile *objfile)
{
#ifdef SUN_FIXED_LBRAC_BUG
/* If SUN_FIXED_LBRAC_BUG is defined, then it tells us whether we need
adjusted for coff details. */
void
-coffstab_build_psymtabs (objfile, mainline,
- textaddr, textsize, stabsects,
- stabstroffset, stabstrsize)
- struct objfile *objfile;
- int mainline;
- CORE_ADDR textaddr;
- unsigned int textsize;
- struct stab_section_list *stabsects;
- file_ptr stabstroffset;
- unsigned int stabstrsize;
+coffstab_build_psymtabs (struct objfile *objfile, int mainline,
+ CORE_ADDR textaddr, unsigned int textsize,
+ struct stab_section_list *stabsects,
+ file_ptr stabstroffset, unsigned int stabstrsize)
{
int val;
bfd *sym_bfd = objfile->obfd;
adjusted for elf details. */
void
-elfstab_build_psymtabs (objfile, mainline,
- staboffset, stabsize,
- stabstroffset, stabstrsize)
- struct objfile *objfile;
- int mainline;
- file_ptr staboffset;
- unsigned int stabsize;
- file_ptr stabstroffset;
- unsigned int stabstrsize;
+elfstab_build_psymtabs (struct objfile *objfile, int mainline,
+ file_ptr staboffset, unsigned int stabsize,
+ file_ptr stabstroffset, unsigned int stabstrsize)
{
int val;
bfd *sym_bfd = objfile->obfd;
This routine is mostly copied from dbx_symfile_init and dbx_symfile_read. */
void
-stabsect_build_psymtabs (objfile, mainline, stab_name,
- stabstr_name, text_name)
- struct objfile *objfile;
- int mainline;
- char *stab_name;
- char *stabstr_name;
- char *text_name;
+stabsect_build_psymtabs (struct objfile *objfile, int mainline, char *stab_name,
+ char *stabstr_name, char *text_name)
{
int val;
bfd *sym_bfd = objfile->obfd;
};
void
-_initialize_dbxread ()
+_initialize_dbxread (void)
{
add_symtab_fns (&aout_sym_fns);
}
/* Free all the data cache blocks, thus discarding all cached data. */
void
-dcache_flush (dcache)
- DCACHE *dcache;
+dcache_flush (DCACHE *dcache)
{
int i;
dcache->valid_head = 0;
containing it. */
static struct dcache_block *
-dcache_hit (dcache, addr)
- DCACHE *dcache;
- CORE_ADDR addr;
+dcache_hit (DCACHE *dcache, CORE_ADDR addr)
{
register struct dcache_block *db;
be written is. */
static int
-dcache_write_line (dcache, db)
- DCACHE *dcache;
- register struct dcache_block *db;
+dcache_write_line (DCACHE *dcache, register struct dcache_block *db)
{
int s;
int e;
list...). */
static struct dcache_block *
-dcache_alloc (dcache)
- DCACHE *dcache;
+dcache_alloc (DCACHE *dcache)
{
register struct dcache_block *db;
Returns 0 on error. */
static int
-dcache_peek_byte (dcache, addr, ptr)
- DCACHE *dcache;
- CORE_ADDR addr;
- char *ptr;
+dcache_peek_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr)
{
register struct dcache_block *db = dcache_hit (dcache, addr);
int ok = 1;
/* Writeback any dirty lines to the remote. */
static int
-dcache_writeback (dcache)
- DCACHE *dcache;
+dcache_writeback (DCACHE *dcache)
{
struct dcache_block *db;
*/
static int
-dcache_poke_byte (dcache, addr, ptr)
- DCACHE *dcache;
- CORE_ADDR addr;
- char *ptr;
+dcache_poke_byte (DCACHE *dcache, CORE_ADDR addr, char *ptr)
{
register struct dcache_block *db = dcache_hit (dcache, addr);
/* Initialize the data cache. */
DCACHE *
-dcache_init (reading, writing)
- memxferfunc reading;
- memxferfunc writing;
+dcache_init (memxferfunc reading, memxferfunc writing)
{
int csize = sizeof (struct dcache_block) * DCACHE_SIZE;
DCACHE *dcache;
This routine is indended to be called by remote_xfer_ functions. */
int
-dcache_xfer_memory (dcache, memaddr, myaddr, len, should_write)
- DCACHE *dcache;
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int should_write;
+dcache_xfer_memory (DCACHE *dcache, CORE_ADDR memaddr, char *myaddr, int len,
+ int should_write)
{
int i;
}
static void
-dcache_info (exp, tty)
- char *exp;
- int tty;
+dcache_info (char *exp, int tty)
{
struct dcache_block *p;
}
void
-_initialize_dcache ()
+_initialize_dcache (void)
{
add_show_from_set
(add_set_cmd ("remotecache", class_support, var_boolean,
BLOCKEND is the address of the end of the user structure. */
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
static int sysv68reg[] =
{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, -1, 15, 16};
/* Read the value of the u area from the kernel. */
void
-_initialize_delta68_nat ()
+_initialize_delta68_nat (void)
{
struct nlist nl[2];
}
}
-clear_insn_cache ()
+clear_insn_cache (void)
{
#ifdef MCT_TEXT /* in sys/signal.h on sysV68 R3V7.1 */
memctl (0, 4096, MCT_TEXT);
#endif
}
-kernel_u_size ()
+kernel_u_size (void)
{
return sizeof (struct user);
}
a malloc'd string, even if it is a null-string. */
static void
-set_demangling_command (ignore, from_tty, c)
- char *ignore;
- int from_tty;
- struct cmd_list_element *c;
+set_demangling_command (char *ignore, int from_tty, struct cmd_list_element *c)
{
const struct demangler *dem;
/* Fake a "set demangle-style" command. */
void
-set_demangling_style (style)
- char *style;
+set_demangling_style (char *style)
{
if (current_demangling_style_string != NULL)
{
{CPLUS_MARKER, '.', '$', '\0'};
int
-is_cplus_marker (c)
- int c;
+is_cplus_marker (int c)
{
return c && strchr (cplus_markers, c) != NULL;
}
void
-_initialize_demangler ()
+_initialize_demangler (void)
{
struct cmd_list_element *set, *show;
static void dink32_open (char *args, int from_tty);
static void
-dink32_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+dink32_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno = 0;
}
static void
-dink32_load (monops, filename, from_tty)
- struct monitor_ops *monops;
- char *filename;
- int from_tty;
+dink32_load (struct monitor_ops *monops, char *filename, int from_tty)
{
extern int inferior_pid;
static struct monitor_ops dink32_cmds;
static void
-dink32_open (args, from_tty)
- char *args;
- int from_tty;
+dink32_open (char *args, int from_tty)
{
monitor_open (args, &dink32_cmds, from_tty);
}
void
-_initialize_dink32_rom ()
+_initialize_dink32_rom (void)
{
dink32_cmds.flags = MO_HEX_PREFIX | MO_GETMEM_NEEDS_RANGE | MO_FILL_USES_ADDR | MO_HANDLE_NL | MO_32_REGS_PAIRED | MO_SETREG_INTERACTIVE | MO_SETMEM_INTERACTIVE | MO_GETMEM_16_BOUNDARY | MO_CLR_BREAK_1_BASED | MO_SREC_ACK | MO_SREC_ACK_ROTATE;
dink32_cmds.init = dink32_inits;
*/
int
-dpx2_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+dpx2_register_u_addr (int blockend, int regnum)
{
if (regnum < FP0_REGNUM)
return (blockend + 4 * regmap[regnum]);
CORE_ADDR kernel_u_addr;
void
-_initialize_dpx2_nat ()
+_initialize_dpx2_nat (void)
{
struct utsname uts;
*/
static int
-make_srec (srec, targ_addr, abfd, sect, sectoff, maxrecsize, flags)
- char *srec;
- CORE_ADDR targ_addr;
- bfd *abfd;
- asection *sect;
- int sectoff;
- int *maxrecsize;
- int flags;
+make_srec (char *srec, CORE_ADDR targ_addr, bfd *abfd, asection *sect,
+ int sectoff, int *maxrecsize, int flags)
{
unsigned char checksum;
int tmp;
/* FIXME: Use record_line instead. */
static void
-dst_record_line (line, pc)
- int line;
- CORE_ADDR pc;
+dst_record_line (int line, CORE_ADDR pc)
{
struct linetable_entry *e;
/* Make sure line vector is big enough. */
/* FIXME: use start_symtab, like coffread.c now does. */
static void
-dst_start_symtab ()
+dst_start_symtab (void)
{
/* Initialize the source file line number information for this file. */
text address for the file, and SIZE is the number of bytes of text. */
static void
-complete_symtab (name, start_addr, size)
- char *name;
- CORE_ADDR start_addr;
- unsigned int size;
+complete_symtab (char *name, CORE_ADDR start_addr, unsigned int size)
{
last_source_file = savestring (name, strlen (name));
cur_src_start_addr = start_addr;
/* FIXME: Use end_symtab, like coffread.c now does. */
static void
-dst_end_symtab (objfile)
- struct objfile *objfile;
+dst_end_symtab (struct objfile *objfile)
{
register struct symtab *symtab;
register struct blockvector *blockvector;
The ultimate result is a new symtab (or, FIXME, eventually a psymtab). */
static void
-dst_symfile_init (objfile)
- struct objfile *objfile;
+dst_symfile_init (struct objfile *objfile)
{
asection *section;
bfd *abfd = objfile->obfd;
/* ARGSUSED */
static void
-find_dst_sections (abfd, asect, vpinfo)
- bfd *abfd;
- sec_ptr asect;
- PTR vpinfo;
+find_dst_sections (bfd *abfd, sec_ptr asect, PTR vpinfo)
{
int size, count;
long base;
/* ARGSUSED */
static void
-dst_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+dst_symfile_read (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
char *name = bfd_get_filename (abfd);
}
static void
-dst_new_init (ignore)
- struct objfile *ignore;
+dst_new_init (struct objfile *ignore)
{
/* Nothin' to do */
}
objfile struct from the global list of known objfiles. */
static void
-dst_symfile_finish (objfile)
- struct objfile *objfile;
+dst_symfile_finish (struct objfile *objfile)
{
/* Nothing to do */
}
* this is what was really intended.
*/
static int
-get_dst_line (buffer, pc)
- signed char **buffer;
- long *pc;
+get_dst_line (signed char **buffer, long *pc)
{
static last_pc = 0;
static long last_line = 0;
}
static void
-enter_all_lines (buffer, address)
- char *buffer;
- long address;
+enter_all_lines (char *buffer, long address)
{
if (buffer)
while (get_dst_line (&buffer, &address));
}
static int
-get_dst_entry (buffer, ret_entry)
- char *buffer;
- dst_rec_ptr_t *ret_entry;
+get_dst_entry (char *buffer, dst_rec_ptr_t *ret_entry)
{
int size;
dst_rec_ptr_t entry;
}
static int
-next_dst_entry (buffer, entry, table)
- char **buffer;
- dst_rec_ptr_t *entry;
- dst_sec *table;
+next_dst_entry (char **buffer, dst_rec_ptr_t *entry, dst_sec *table)
{
if (*buffer - table->buffer >= table->size)
{
static dst_rec_ptr_t section_table = NULL;
char *
-get_sec_ref (ref)
- dst_sect_ref_t *ref;
+get_sec_ref (dst_sect_ref_t *ref)
{
dst_sec *section = NULL;
long offset;
}
CORE_ADDR
-dst_sym_addr (ref)
- dst_sect_ref_t *ref;
+dst_sym_addr (dst_sect_ref_t *ref)
{
if (!section_table || !ref->sect_index)
return 0;
}
static struct type *
-create_new_type (objfile)
- struct objfile *objfile;
+create_new_type (struct objfile *objfile)
{
struct type *type;
}
static struct symbol *
-create_new_symbol (objfile, name)
- struct objfile *objfile;
- char *name;
+create_new_symbol (struct objfile *objfile, char *name)
{
struct symbol *sym = (struct symbol *)
obstack_alloc (&objfile->symbol_obstack, sizeof (struct symbol));
static struct type *decode_dst_type (struct objfile *, dst_rec_ptr_t);
static struct type *
-decode_type_desc (objfile, type_desc, base)
- struct objfile *objfile;
- dst_type_t *type_desc;
- dst_rec_ptr_t base;
+decode_type_desc (struct objfile *objfile, dst_type_t *type_desc,
+ dst_rec_ptr_t base)
{
struct type *type;
dst_rec_ptr_t entry;
static struct structure_list *struct_list = NULL;
static struct type *
-find_dst_structure (name)
- char *name;
+find_dst_structure (char *name)
{
struct structure_list *element;
static struct type *
-decode_dst_structure (objfile, entry, code, version)
- struct objfile *objfile;
- dst_rec_ptr_t entry;
- int code;
- int version;
+decode_dst_structure (struct objfile *objfile, dst_rec_ptr_t entry, int code,
+ int version)
{
struct type *type, *child_type;
char *struct_name;
}
static struct type *
-decode_dst_type (objfile, entry)
- struct objfile *objfile;
- dst_rec_ptr_t entry;
+decode_dst_type (struct objfile *objfile, dst_rec_ptr_t entry)
{
struct type *child_type, *type, *range_type, *index_type;
static int total_globals = 0;
static void
-decode_dst_locstring (locstr, sym)
- char *locstr;
- struct symbol *sym;
+decode_dst_locstring (char *locstr, struct symbol *sym)
{
dst_loc_entry_t *entry, *next_entry;
CORE_ADDR temp;
}
static struct symbol_list *
-process_dst_symbols (objfile, entry, name, nsyms_ret)
- struct objfile *objfile;
- dst_rec_ptr_t entry;
- char *name;
- int *nsyms_ret;
+process_dst_symbols (struct objfile *objfile, dst_rec_ptr_t entry, char *name,
+ int *nsyms_ret)
{
struct symbol_list *list = NULL, *element;
struct symbol *sym;
static struct symbol *
-process_dst_function (objfile, entry, name, address)
- struct objfile *objfile;
- dst_rec_ptr_t entry;
- char *name;
- CORE_ADDR address;
+process_dst_function (struct objfile *objfile, dst_rec_ptr_t entry, char *name,
+ CORE_ADDR address)
{
struct symbol *sym;
struct type *type, *ftype;
}
static struct block *
-process_dst_block (objfile, entry)
- struct objfile *objfile;
- dst_rec_ptr_t entry;
+process_dst_block (struct objfile *objfile, dst_rec_ptr_t entry)
{
struct block *block;
struct symbol *function = NULL;
static void
-read_dst_symtab (objfile)
- struct objfile *objfile;
+read_dst_symtab (struct objfile *objfile)
{
char *buffer;
dst_rec_ptr_t entry, file_table, root_block;
external (unswapped) format in memory; we'll swap them as we enter
them into GDB's data structures. */
static int
-init_one_section (chan, secinfo)
- int chan;
- dst_sec *secinfo;
+init_one_section (int chan, dst_sec *secinfo)
{
if (secinfo->size == 0
|| lseek (chan, secinfo->position, 0) == -1
}
static int
-init_dst_sections (chan)
- int chan;
+init_dst_sections (int chan)
{
if (!init_one_section (chan, &blocks_info) ||
};
void
-_initialize_dstread ()
+_initialize_dstread (void)
{
add_symtab_fns (&dst_sym_fns);
}
the hex value before passing it to monitor_supply_register. */
static void
-r3900_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+r3900_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno = -1;
int i;
you modify it. */
static void
-fetch_bad_vaddr ()
+fetch_bad_vaddr (void)
{
char buf[20];
combined binary value. */
static unsigned long
-fetch_fields (bf)
- struct bit_field *bf;
+fetch_fields (struct bit_field *bf)
{
char buf[20];
unsigned long val = 0;
static void
-fetch_bitmapped_register (regno, bf)
- int regno;
- struct bit_field *bf;
+fetch_bitmapped_register (int regno, struct bit_field *bf)
{
unsigned long val;
unsigned char regbuf[MAX_REGISTER_RAW_SIZE];
a very unusual fashion by the monitor, and must be handled specially. */
static void
-r3900_fetch_registers (regno)
- int regno;
+r3900_fetch_registers (int regno)
{
switch (regno)
{
/* Write the new value of the bitmapped register to the monitor. */
static void
-store_bitmapped_register (regno, bf)
- int regno;
- struct bit_field *bf;
+store_bitmapped_register (int regno, struct bit_field *bf)
{
unsigned long oldval, newval;
static void
-r3900_store_registers (regno)
- int regno;
+r3900_store_registers (int regno)
{
switch (regno)
{
/* Write a 4-byte integer to the buffer in big-endian order. */
static void
-write_long (buf, n)
- char *buf;
- long n;
+write_long (char *buf, long n)
{
buf[0] = (n >> 24) & 0xff;
buf[1] = (n >> 16) & 0xff;
/* Write a 4-byte integer to the buffer in little-endian order. */
static void
-write_long_le (buf, n)
- char *buf;
- long n;
+write_long_le (char *buf, long n)
{
buf[0] = n & 0xff;
buf[1] = (n >> 8) & 0xff;
character in hexadecimal; otherwise, print it in ASCII. */
static int
-debug_readchar (hex)
- int hex;
+debug_readchar (int hex)
{
char buf[10];
int c = monitor_readchar ();
print the sent buffer in hex. */
static void
-debug_write (buf, buflen)
- unsigned char *buf;
- int buflen;
+debug_write (unsigned char *buf, int buflen)
{
char s[10];
*/
static void
-ignore_packet ()
+ignore_packet (void)
{
int c;
int len;
*/
static void
-send_packet (type, buf, buflen, seq)
- char type;
- unsigned char *buf;
- int buflen, seq;
+send_packet (char type, unsigned char *buf, int buflen, int seq)
{
unsigned char hdr[4];
int len = buflen;
*/
static void
-process_read_request (buf, buflen)
- unsigned char *buf;
- int buflen;
+process_read_request (unsigned char *buf, int buflen)
{
unsigned char len[4];
int i, chunk;
/* Count loadable sections (helper function for r3900_load). */
static void
-count_section (abfd, s, section_count)
- bfd *abfd;
- asection *s;
- unsigned int *section_count;
+count_section (bfd *abfd, asection *s, unsigned int *section_count)
{
if (s->flags & SEC_LOAD && bfd_section_size (abfd, s) != 0)
(*section_count)++;
*/
static void
-load_section (abfd, s, data_count)
- bfd *abfd;
- asection *s;
- unsigned int *data_count;
+load_section (bfd *abfd, asection *s, unsigned int *data_count)
{
if (s->flags & SEC_LOAD)
{
*/
static void
-r3900_load (filename, from_tty)
- char *filename;
- int from_tty;
+r3900_load (char *filename, int from_tty)
{
bfd *abfd;
unsigned int data_count = 0;
static struct monitor_ops r3900_cmds;
static void
-r3900_open (args, from_tty)
- char *args;
- int from_tty;
+r3900_open (char *args, int from_tty)
{
char buf[64];
int i;
}
void
-_initialize_r3900_rom ()
+_initialize_r3900_rom (void)
{
r3900_cmds.flags = MO_NO_ECHO_ON_OPEN |
MO_ADDR_BITS_REMOVE |
information and return true if we have enough to do something. */
int
-dwarf2_has_info (abfd)
- bfd *abfd;
+dwarf2_has_info (bfd *abfd)
{
dwarf_info_offset = dwarf_abbrev_offset = dwarf_line_offset = 0;
bfd_map_over_sections (abfd, dwarf2_locate_sections, NULL);
in. */
static void
-dwarf2_locate_sections (ignore_abfd, sectp, ignore_ptr)
- bfd *ignore_abfd;
- asection *sectp;
- PTR ignore_ptr;
+dwarf2_locate_sections (bfd *ignore_abfd, asection *sectp, PTR ignore_ptr)
{
if (STREQ (sectp->name, INFO_SECTION))
{
/* Build a partial symbol table. */
void
-dwarf2_build_psymtabs (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+dwarf2_build_psymtabs (struct objfile *objfile, int mainline)
{
/* We definitely need the .debug_info and .debug_abbrev sections */
.debug_pubnames and .debug_aranges sections. */
static void
-dwarf2_build_psymtabs_easy (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+dwarf2_build_psymtabs_easy (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
char *aranges_buffer, *pubnames_buffer;
.debug_info and .debug_abbrev sections. */
static void
-dwarf2_build_psymtabs_hard (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+dwarf2_build_psymtabs_hard (struct objfile *objfile, int mainline)
{
/* Instead of reading this into a big buffer, we should probably use
mmap() on architectures that support it. (FIXME) */
/* Expand this partial symbol table into a full symbol table. */
static void
-dwarf2_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+dwarf2_psymtab_to_symtab (struct partial_symtab *pst)
{
/* FIXME: This is barely more than a stub. */
if (pst != NULL)
}
static void
-psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct objfile *objfile = pst->objfile;
bfd *abfd = objfile->obfd;
Return 1 if the attributes are present and valid, otherwise, return 0. */
static int
-dwarf2_get_pc_bounds (die, lowpc, highpc, objfile)
- struct die_info *die;
- CORE_ADDR *lowpc;
- CORE_ADDR *highpc;
- struct objfile *objfile;
+dwarf2_get_pc_bounds (struct die_info *die, CORE_ADDR *lowpc, CORE_ADDR *highpc,
+ struct objfile *objfile)
{
struct attribute *attr;
CORE_ADDR low;
/* Create the vector of fields, and attach it to the type. */
static void
-dwarf2_attach_fields_to_type (fip, type, objfile)
- struct field_info *fip;
- struct type *type;
- struct objfile *objfile;
+dwarf2_attach_fields_to_type (struct field_info *fip, struct type *type,
+ struct objfile *objfile)
{
int nfields = fip->nfields;
/* Create the vector of member function fields, and attach it to the type. */
static void
-dwarf2_attach_fn_fields_to_type (fip, type, objfile)
- struct field_info *fip;
- struct type *type;
- struct objfile *objfile;
+dwarf2_attach_fn_fields_to_type (struct field_info *fip, struct type *type,
+ struct objfile *objfile)
{
struct fnfieldlist *flp;
int total_length = 0;
attribute to reference it. */
static void
-read_tag_string_type (die, objfile)
- struct die_info *die;
- struct objfile *objfile;
+read_tag_string_type (struct die_info *die, struct objfile *objfile)
{
struct type *type, *range_type, *index_type, *char_type;
struct attribute *attr;
it in the TYPE field of the die. */
static void
-read_base_type (die, objfile)
- struct die_info *die;
- struct objfile *objfile;
+read_base_type (struct die_info *die, struct objfile *objfile)
{
struct type *type;
struct attribute *attr;
/* Free a linked list of dies. */
static void
-free_die_list (dies)
- struct die_info *dies;
+free_die_list (struct die_info *dies)
{
struct die_info *die, *next;
object file specified by OBJFILE into the psymbol_obstack and return it. */
static char *
-dwarf2_read_section (objfile, offset, size)
- struct objfile *objfile;
- file_ptr offset;
- unsigned int size;
+dwarf2_read_section (struct objfile *objfile, file_ptr offset,
+ unsigned int size)
{
bfd *abfd = objfile->obfd;
char *buf;
in a hash table. */
static void
-dwarf2_read_abbrevs (abfd, offset)
- bfd *abfd;
- unsigned int offset;
+dwarf2_read_abbrevs (bfd *abfd, unsigned int offset)
{
char *abbrev_ptr;
struct abbrev_info *cur_abbrev;
/* ARGSUSED */
static void
-dwarf2_empty_abbrev_table (ignore)
- PTR ignore;
+dwarf2_empty_abbrev_table (PTR ignore)
{
int i;
struct abbrev_info *abbrev, *next;
/* Lookup an abbrev_info structure in the abbrev hash table. */
static struct abbrev_info *
-dwarf2_lookup_abbrev (number)
- unsigned int number;
+dwarf2_lookup_abbrev (unsigned int number)
{
unsigned int hash_number;
struct abbrev_info *abbrev;
/* read dwarf information from a buffer */
static unsigned int
-read_1_byte (abfd, buf)
- bfd *abfd;
- char *buf;
+read_1_byte (bfd *abfd, char *buf)
{
return bfd_get_8 (abfd, (bfd_byte *) buf);
}
static int
-read_1_signed_byte (abfd, buf)
- bfd *abfd;
- char *buf;
+read_1_signed_byte (bfd *abfd, char *buf)
{
return bfd_get_signed_8 (abfd, (bfd_byte *) buf);
}
static unsigned int
-read_2_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_2_bytes (bfd *abfd, char *buf)
{
return bfd_get_16 (abfd, (bfd_byte *) buf);
}
static int
-read_2_signed_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_2_signed_bytes (bfd *abfd, char *buf)
{
return bfd_get_signed_16 (abfd, (bfd_byte *) buf);
}
static unsigned int
-read_4_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_4_bytes (bfd *abfd, char *buf)
{
return bfd_get_32 (abfd, (bfd_byte *) buf);
}
static int
-read_4_signed_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_4_signed_bytes (bfd *abfd, char *buf)
{
return bfd_get_signed_32 (abfd, (bfd_byte *) buf);
}
static unsigned long
-read_8_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_8_bytes (bfd *abfd, char *buf)
{
return bfd_get_64 (abfd, (bfd_byte *) buf);
}
}
static char *
-read_n_bytes (abfd, buf, size)
- bfd *abfd;
- char *buf;
- unsigned int size;
+read_n_bytes (bfd *abfd, char *buf, unsigned int size)
{
/* If the size of a host char is 8 bits, we can return a pointer
to the buffer, otherwise we have to copy the data to a buffer
}
static char *
-read_string (abfd, buf, bytes_read_ptr)
- bfd *abfd;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_string (bfd *abfd, char *buf, unsigned int *bytes_read_ptr)
{
/* If the size of a host char is 8 bits, we can return a pointer
to the string, otherwise we have to copy the string to a buffer
}
static unsigned long
-read_unsigned_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_unsigned_leb128 (bfd *abfd, char *buf, unsigned int *bytes_read_ptr)
{
unsigned long result;
unsigned int num_read;
}
static long
-read_signed_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_signed_leb128 (bfd *abfd, char *buf, unsigned int *bytes_read_ptr)
{
long result;
int i, shift, size, num_read;
}
static void
-set_cu_language (lang)
- unsigned int lang;
+set_cu_language (unsigned int lang)
{
switch (lang)
{
/* Return the named attribute or NULL if not there. */
static struct attribute *
-dwarf_attr (die, name)
- struct die_info *die;
- unsigned int name;
+dwarf_attr (struct die_info *die, unsigned int name)
{
unsigned int i;
struct attribute *spec = NULL;
subfile, so that `break /srcdir/list0.c:1' works as expected. */
static void
-dwarf2_start_subfile (filename, dirname)
- char *filename;
- char *dirname;
+dwarf2_start_subfile (char *filename, char *dirname)
{
/* If the filename isn't absolute, try to match an existing subfile
with the full pathname. */
#if 0
static struct type *
-type_at_offset (offset, objfile)
- unsigned int offset;
- struct objfile *objfile;
+type_at_offset (unsigned int offset, struct objfile *objfile)
{
struct die_info *die;
struct type *type;
}
static struct type *
-dwarf_base_type (encoding, size, objfile)
- int encoding;
- int size;
- struct objfile *objfile;
+dwarf_base_type (int encoding, int size, struct objfile *objfile)
{
/* FIXME - this should not produce a new (struct type *)
every time. It should cache base types. */
#if 0
struct die_info *
-copy_die (old_die)
- struct die_info *old_die;
+copy_die (struct die_info *old_die)
{
struct die_info *new_die;
int i, num_attrs;
/* Return sibling of die, NULL if no sibling. */
struct die_info *
-sibling_die (die)
- struct die_info *die;
+sibling_die (struct die_info *die)
{
int nesting_level = 0;
/* Get linkage name of a die, return NULL if not found. */
static char *
-dwarf2_linkage_name (die)
- struct die_info *die;
+dwarf2_linkage_name (struct die_info *die)
{
struct attribute *attr;
/* Convert a DIE tag into its string name. */
static char *
-dwarf_tag_name (tag)
- register unsigned tag;
+dwarf_tag_name (register unsigned tag)
{
switch (tag)
{
/* Convert a DWARF attribute code into its string name. */
static char *
-dwarf_attr_name (attr)
- register unsigned attr;
+dwarf_attr_name (register unsigned attr)
{
switch (attr)
{
/* Convert a DWARF value form code into its string name. */
static char *
-dwarf_form_name (form)
- register unsigned form;
+dwarf_form_name (register unsigned form)
{
switch (form)
{
/* Convert a DWARF stack opcode into its string name. */
static char *
-dwarf_stack_op_name (op)
- register unsigned op;
+dwarf_stack_op_name (register unsigned op)
{
switch (op)
{
}
static char *
-dwarf_bool_name (mybool)
- unsigned mybool;
+dwarf_bool_name (unsigned mybool)
{
if (mybool)
return "TRUE";
/* Convert a DWARF type code into its string name. */
static char *
-dwarf_type_encoding_name (enc)
- register unsigned enc;
+dwarf_type_encoding_name (register unsigned enc)
{
switch (enc)
{
#if 0
static char *
-dwarf_cfi_name (cfi_opc)
- register unsigned cfi_opc;
+dwarf_cfi_name (register unsigned cfi_opc)
{
switch (cfi_opc)
{
#endif
void
-dump_die (die)
- struct die_info *die;
+dump_die (struct die_info *die)
{
unsigned int i;
}
void
-dump_die_list (die)
- struct die_info *die;
+dump_die_list (struct die_info *die)
{
while (die)
{
}
void
-store_in_ref_table (offset, die)
- unsigned int offset;
- struct die_info *die;
+store_in_ref_table (unsigned int offset, struct die_info *die)
{
int h;
struct die_info *old;
static void
-dwarf2_empty_hash_tables ()
+dwarf2_empty_hash_tables (void)
{
memset (die_ref_table, 0, sizeof (die_ref_table));
memset (dwarf2_cached_types, 0, sizeof(dwarf2_cached_types));
}
static unsigned int
-dwarf2_get_ref_die_offset (attr)
- struct attribute *attr;
+dwarf2_get_ref_die_offset (struct attribute *attr)
{
unsigned int result = 0;
}
struct die_info *
-follow_die_ref (offset)
- unsigned int offset;
+follow_die_ref (unsigned int offset)
{
struct die_info *die;
int h;
}
static struct type *
-dwarf2_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+dwarf2_fundamental_type (struct objfile *objfile, int typeid)
{
if (typeid < 0 || typeid >= FT_NUM_MEMBERS)
{
/* ARGSUSED */
static void
-dwarf2_free_tmp_obstack (ignore)
- PTR ignore;
+dwarf2_free_tmp_obstack (PTR ignore)
{
obstack_free (&dwarf2_tmp_obstack, NULL);
}
static struct dwarf_block *
-dwarf_alloc_block ()
+dwarf_alloc_block (void)
{
struct dwarf_block *blk;
}
static struct abbrev_info *
-dwarf_alloc_abbrev ()
+dwarf_alloc_abbrev (void)
{
struct abbrev_info *abbrev;
}
static struct die_info *
-dwarf_alloc_die ()
+dwarf_alloc_die (void)
{
struct die_info *die;
*/
static struct type *
-dwarf_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+dwarf_fundamental_type (struct objfile *objfile, int typeid)
{
if (typeid < 0 || typeid >= FT_NUM_MEMBERS)
{
*/
static void
-set_cu_language (dip)
- struct dieinfo *dip;
+set_cu_language (struct dieinfo *dip)
{
switch (dip->at_language)
{
*/
void
-dwarf_build_psymtabs (objfile, mainline, dbfoff, dbfsize,
- lnoffset, lnsize)
- struct objfile *objfile;
- int mainline;
- file_ptr dbfoff;
- unsigned int dbfsize;
- file_ptr lnoffset;
- unsigned int lnsize;
+dwarf_build_psymtabs (struct objfile *objfile, int mainline, file_ptr dbfoff,
+ unsigned int dbfsize, file_ptr lnoffset,
+ unsigned int lnsize)
{
bfd *abfd = objfile->obfd;
struct cleanup *back_to;
*/
static void
-read_lexical_block_scope (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+read_lexical_block_scope (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
register struct context_stack *new;
*/
static struct type *
-lookup_utype (die_ref)
- DIE_REF die_ref;
+lookup_utype (DIE_REF die_ref)
{
struct type *type = NULL;
int utypeidx;
*/
static struct type *
-alloc_utype (die_ref, utypep)
- DIE_REF die_ref;
- struct type *utypep;
+alloc_utype (DIE_REF die_ref, struct type *utypep)
{
struct type **typep;
int utypeidx;
*/
static void
-free_utypes (dummy)
- PTR dummy;
+free_utypes (PTR dummy)
{
free (utypes);
utypes = NULL;
*/
static struct type *
-decode_die_type (dip)
- struct dieinfo *dip;
+decode_die_type (struct dieinfo *dip)
{
struct type *type = NULL;
*/
static struct type *
-struct_type (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+struct_type (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
struct type *type;
struct nextfield
*/
static void
-read_structure_scope (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+read_structure_scope (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
struct type *type;
struct symbol *sym;
*/
static struct type *
-decode_array_element_type (scan)
- char *scan;
+decode_array_element_type (char *scan)
{
struct type *typep;
DIE_REF die_ref;
*/
static struct type *
-decode_subscript_data_item (scan, end)
- char *scan;
- char *end;
+decode_subscript_data_item (char *scan, char *end)
{
struct type *typep = NULL; /* Array type we are building */
struct type *nexttype; /* Type of each element (may be array) */
*/
static void
-dwarf_read_array_type (dip)
- struct dieinfo *dip;
+dwarf_read_array_type (struct dieinfo *dip)
{
struct type *type;
struct type *utype;
*/
static void
-read_tag_pointer_type (dip)
- struct dieinfo *dip;
+read_tag_pointer_type (struct dieinfo *dip)
{
struct type *type;
struct type *utype;
*/
static void
-read_tag_string_type (dip)
- struct dieinfo *dip;
+read_tag_string_type (struct dieinfo *dip)
{
struct type *utype;
struct type *indextype;
*/
static void
-read_subroutine_type (dip, thisdie, enddie)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
+read_subroutine_type (struct dieinfo *dip, char *thisdie, char *enddie)
{
struct type *type; /* Type that this function returns */
struct type *ftype; /* Function that returns above type */
*/
static void
-read_enumeration (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+read_enumeration (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
struct type *type;
struct symbol *sym;
*/
static struct type *
-enum_type (dip, objfile)
- struct dieinfo *dip;
- struct objfile *objfile;
+enum_type (struct dieinfo *dip, struct objfile *objfile)
{
struct type *type;
struct nextfield
*/
static void
-read_func_scope (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+read_func_scope (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
register struct context_stack *new;
*/
static void
-handle_producer (producer)
- char *producer;
+handle_producer (char *producer)
{
/* If this compilation unit was compiled with g++ or gcc, then set the
*/
static void
-read_file_scope (dip, thisdie, enddie, objfile)
- struct dieinfo *dip;
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+read_file_scope (struct dieinfo *dip, char *thisdie, char *enddie,
+ struct objfile *objfile)
{
struct cleanup *back_to;
struct symtab *symtab;
*/
static void
-process_dies (thisdie, enddie, objfile)
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+process_dies (char *thisdie, char *enddie, struct objfile *objfile)
{
char *nextdie;
struct dieinfo di;
*/
static void
-decode_line_numbers (linetable)
- char *linetable;
+decode_line_numbers (char *linetable)
{
char *tblscan;
char *tblend;
*/
static int
-locval (dip)
- struct dieinfo *dip;
+locval (struct dieinfo *dip)
{
unsigned short nbytes;
unsigned short locsize;
*/
static void
-read_ofile_symtab (pst)
- struct partial_symtab *pst;
+read_ofile_symtab (struct partial_symtab *pst)
{
struct cleanup *back_to;
unsigned long lnsize;
*/
static void
-psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+psymtab_to_symtab_1 (struct partial_symtab *pst)
{
int i;
struct cleanup *old_chain;
*/
static void
-dwarf_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+dwarf_psymtab_to_symtab (struct partial_symtab *pst)
{
if (pst != NULL)
*/
static void
-add_enum_psymbol (dip, objfile)
- struct dieinfo *dip;
- struct objfile *objfile;
+add_enum_psymbol (struct dieinfo *dip, struct objfile *objfile)
{
char *scan;
char *listend;
*/
static void
-add_partial_symbol (dip, objfile)
- struct dieinfo *dip;
- struct objfile *objfile;
+add_partial_symbol (struct dieinfo *dip, struct objfile *objfile)
{
switch (dip->die_tag)
{
static void
-scan_partial_symbols (thisdie, enddie, objfile)
- char *thisdie;
- char *enddie;
- struct objfile *objfile;
+scan_partial_symbols (char *thisdie, char *enddie, struct objfile *objfile)
{
char *nextdie;
char *temp;
*/
static void
-scan_compilation_units (thisdie, enddie, dbfoff, lnoffset, objfile)
- char *thisdie;
- char *enddie;
- file_ptr dbfoff;
- file_ptr lnoffset;
- struct objfile *objfile;
+scan_compilation_units (char *thisdie, char *enddie, file_ptr dbfoff,
+ file_ptr lnoffset, struct objfile *objfile)
{
char *nextdie;
struct dieinfo di;
*/
static struct symbol *
-new_symbol (dip, objfile)
- struct dieinfo *dip;
- struct objfile *objfile;
+new_symbol (struct dieinfo *dip, struct objfile *objfile)
{
struct symbol *sym = NULL;
*/
static void
-synthesize_typedef (dip, objfile, type)
- struct dieinfo *dip;
- struct objfile *objfile;
- struct type *type;
+synthesize_typedef (struct dieinfo *dip, struct objfile *objfile,
+ struct type *type)
{
struct symbol *sym = NULL;
*/
static struct type *
-decode_mod_fund_type (typedata)
- char *typedata;
+decode_mod_fund_type (char *typedata)
{
struct type *typep = NULL;
unsigned short modcount;
*/
static struct type *
-decode_mod_u_d_type (typedata)
- char *typedata;
+decode_mod_u_d_type (char *typedata)
{
struct type *typep = NULL;
unsigned short modcount;
*/
static struct type *
-decode_modified_type (modifiers, modcount, mtype)
- char *modifiers;
- unsigned int modcount;
- int mtype;
+decode_modified_type (char *modifiers, unsigned int modcount, int mtype)
{
struct type *typep = NULL;
unsigned short fundtype;
*/
static struct type *
-decode_fund_type (fundtype)
- unsigned int fundtype;
+decode_fund_type (unsigned int fundtype)
{
struct type *typep = NULL;
*/
static char *
-create_name (name, obstackp)
- char *name;
- struct obstack *obstackp;
+create_name (char *name, struct obstack *obstackp)
{
int length;
char *newname;
*/
static void
-basicdieinfo (dip, diep, objfile)
- struct dieinfo *dip;
- char *diep;
- struct objfile *objfile;
+basicdieinfo (struct dieinfo *dip, char *diep, struct objfile *objfile)
{
curdie = dip;
memset (dip, 0, sizeof (struct dieinfo));
*/
static void
-completedieinfo (dip, objfile)
- struct dieinfo *dip;
- struct objfile *objfile;
+completedieinfo (struct dieinfo *dip, struct objfile *objfile)
{
char *diep; /* Current pointer into raw DIE data */
char *end; /* Terminate DIE scan here */
*/
static CORE_ADDR
-target_to_host (from, nbytes, signextend, objfile)
- char *from;
- int nbytes;
- int signextend; /* FIXME: Unused */
- struct objfile *objfile;
+target_to_host (char *from, int nbytes, int signextend, /* FIXME: Unused */
+ struct objfile *objfile)
{
CORE_ADDR rtnval;
*/
static int
-attribute_size (attr)
- unsigned int attr;
+attribute_size (unsigned int attr)
{
int nbytes; /* Size of next data for this attribute */
unsigned short form; /* Form of the attribute */
-kingdon). */
static void
-elf_locate_sections (ignore_abfd, sectp, eip)
- bfd *ignore_abfd;
- asection *sectp;
- PTR eip;
+elf_locate_sections (bfd *ignore_abfd, asection *sectp, PTR eip)
{
register struct elfinfo *ei;
#if 0 /* Currently unused */
char *
-elf_interpreter (abfd)
- bfd *abfd;
+elf_interpreter (bfd *abfd)
{
sec_ptr interp_sec;
unsigned size;
#endif
static struct minimal_symbol *
-record_minimal_symbol_and_info (name, address, ms_type, info, bfd_section,
- objfile)
- char *name;
- CORE_ADDR address;
- enum minimal_symbol_type ms_type;
- char *info; /* FIXME, is this really char *? */
- asection *bfd_section;
- struct objfile *objfile;
+record_minimal_symbol_and_info (char *name, CORE_ADDR address,
+ enum minimal_symbol_type ms_type, char *info, /* FIXME, is this really char *? */
+ asection *bfd_section, struct objfile *objfile)
{
int section;
*/
static void
-elf_symtab_read (objfile, dynamic)
- struct objfile *objfile;
- int dynamic;
+elf_symtab_read (struct objfile *objfile, int dynamic)
{
long storage_needed;
asymbol *sym;
capability even for files compiled without -g. */
static void
-elf_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+elf_symfile_read (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
struct elfinfo ei;
stab_section_info's, that might be dangling from it. */
static void
-free_elfinfo (objp)
- PTR objp;
+free_elfinfo (PTR objp)
{
struct objfile *objfile = (struct objfile *) objp;
struct dbx_symfile_info *dbxinfo = objfile->sym_stab_info;
We reinitialize buildsym, since we may be reading stabs from an ELF file. */
static void
-elf_new_init (ignore)
- struct objfile *ignore;
+elf_new_init (struct objfile *ignore)
{
stabsread_new_init ();
buildsym_new_init ();
objfile struct from the global list of known objfiles. */
static void
-elf_symfile_finish (objfile)
- struct objfile *objfile;
+elf_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_stab_info != NULL)
{
just a stub. */
static void
-elf_symfile_init (objfile)
- struct objfile *objfile;
+elf_symfile_init (struct objfile *objfile)
{
/* ELF objects may be reordered, so set OBJF_REORDERED. If we
find this causes a significant slowdown in gdb then we could
with wierd names. Go get 'em when needed. */
void
-elfstab_offset_sections (objfile, pst)
- struct objfile *objfile;
- struct partial_symtab *pst;
+elfstab_offset_sections (struct objfile *objfile, struct partial_symtab *pst)
{
char *filename = pst->filename;
struct dbx_symfile_info *dbx = objfile->sym_stab_info;
};
void
-_initialize_elfread ()
+_initialize_elfread (void)
{
add_symtab_fns (&elf_sym_fns);
}
/* Return a new environment object. */
struct environ *
-make_environ ()
+make_environ (void)
{
register struct environ *e;
/* Free an environment and all the strings in it. */
void
-free_environ (e)
- register struct environ *e;
+free_environ (register struct environ *e)
{
register char **vector = e->vector;
that all strings in these environments are safe to free. */
void
-init_environ (e)
- register struct environ *e;
+init_environ (register struct environ *e)
{
extern char **environ;
register int i;
This is used to get something to pass to execve. */
char **
-environ_vector (e)
- struct environ *e;
+environ_vector (struct environ *e)
{
return e->vector;
}
/* Return the value in environment E of variable VAR. */
char *
-get_in_environ (e, var)
- const struct environ *e;
- const char *var;
+get_in_environ (const struct environ *e, const char *var)
{
register int len = strlen (var);
register char **vector = e->vector;
/* Store the value in E of VAR as VALUE. */
void
-set_in_environ (e, var, value)
- struct environ *e;
- const char *var;
- const char *value;
+set_in_environ (struct environ *e, const char *var, const char *value)
{
register int i;
register int len = strlen (var);
/* Remove the setting for variable VAR from environment E. */
void
-unset_in_environ (e, var)
- struct environ *e;
- char *var;
+unset_in_environ (struct environ *e, char *var)
{
register int len = strlen (var);
register char **vector = e->vector;
inline
#endif
static value_ptr
-evaluate_subexp (expect_type, exp, pos, noside)
- struct type *expect_type;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp (struct type *expect_type, register struct expression *exp,
+ register int *pos, enum noside noside)
{
return (*exp->language_defn->evaluate_exp) (expect_type, exp, pos, noside);
}
and return the result as a number. */
CORE_ADDR
-parse_and_eval_address (exp)
- char *exp;
+parse_and_eval_address (char *exp)
{
struct expression *expr = parse_expression (exp);
register CORE_ADDR addr;
and advanced that variable across the characters parsed. */
CORE_ADDR
-parse_and_eval_address_1 (expptr)
- char **expptr;
+parse_and_eval_address_1 (char **expptr)
{
struct expression *expr = parse_exp_1 (expptr, (struct block *) 0, 0);
register CORE_ADDR addr;
}
value_ptr
-parse_and_eval (exp)
- char *exp;
+parse_and_eval (char *exp)
{
struct expression *expr = parse_expression (exp);
register value_ptr val;
EXPP is advanced to point to the comma. */
value_ptr
-parse_to_comma_and_eval (expp)
- char **expp;
+parse_to_comma_and_eval (char **expp)
{
struct expression *expr = parse_exp_1 (expp, (struct block *) 0, 1);
register value_ptr val;
See expression.h for info on the format of an expression. */
value_ptr
-evaluate_expression (exp)
- struct expression *exp;
+evaluate_expression (struct expression *exp)
{
int pc = 0;
return evaluate_subexp (NULL_TYPE, exp, &pc, EVAL_NORMAL);
and getting a value whose type alone is correct. */
value_ptr
-evaluate_type (exp)
- struct expression *exp;
+evaluate_type (struct expression *exp)
{
int pc = 0;
return evaluate_subexp (NULL_TYPE, exp, &pc, EVAL_AVOID_SIDE_EFFECTS);
returning the label. Otherwise, does nothing and returns NULL. */
static char *
-get_label (exp, pos)
- register struct expression *exp;
- int *pos;
+get_label (register struct expression *exp, int *pos)
{
if (exp->elts[*pos].opcode == OP_LABELED)
{
(in C/C++) for structure types. */
static value_ptr
-evaluate_struct_tuple (struct_val, exp, pos, noside, nargs)
- value_ptr struct_val;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
- int nargs;
+evaluate_struct_tuple (value_ptr struct_val, register struct expression *exp,
+ register int *pos, enum noside noside, int nargs)
{
struct type *struct_type = check_typedef (VALUE_TYPE (struct_val));
struct type *substruct_type = struct_type;
Returns last index value. */
static LONGEST
-init_array_element (array, element, exp, pos, noside, low_bound, high_bound)
- value_ptr array, element;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
- LONGEST low_bound, high_bound;
+init_array_element (value_ptr array, value_ptr element,
+ register struct expression *exp, register int *pos,
+ enum noside noside, LONGEST low_bound, LONGEST high_bound)
{
LONGEST index;
int element_size = TYPE_LENGTH (VALUE_TYPE (element));
}
value_ptr
-evaluate_subexp_standard (expect_type, exp, pos, noside)
- struct type *expect_type;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_standard (struct type *expect_type,
+ register struct expression *exp, register int *pos,
+ enum noside noside)
{
enum exp_opcode op;
int tem, tem2, tem3;
then only the type of the result need be correct. */
static value_ptr
-evaluate_subexp_for_address (exp, pos, noside)
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_for_address (register struct expression *exp, register int *pos,
+ enum noside noside)
{
enum exp_opcode op;
register int pc;
*/
value_ptr
-evaluate_subexp_with_coercion (exp, pos, noside)
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_with_coercion (register struct expression *exp,
+ register int *pos, enum noside noside)
{
register enum exp_opcode op;
register int pc;
Advance *POS over the subexpression. */
static value_ptr
-evaluate_subexp_for_sizeof (exp, pos)
- register struct expression *exp;
- register int *pos;
+evaluate_subexp_for_sizeof (register struct expression *exp, register int *pos)
{
enum exp_opcode op;
register int pc;
/* Parse a type expression in the string [P..P+LENGTH). */
struct type *
-parse_and_eval_type (p, length)
- char *p;
- int length;
+parse_and_eval_type (char *p, int length)
{
char *tmp = (char *) alloca (length + 4);
struct expression *expr;
}
int
-calc_f77_array_dims (array_type)
- struct type *array_type;
+calc_f77_array_dims (struct type *array_type)
{
int ndimen = 1;
struct type *tmp_type;
/* Tell the event loop what to do if SIGHUP is received.
See event-signal.c. */
static void
-handle_sighup (sig)
- int sig;
+handle_sighup (int sig)
{
mark_async_signal_handler_wrapper (sighup_token);
signal (sig, handle_sighup);
/* ARGSUSED */
static void
-exec_close (quitting)
- int quitting;
+exec_close (int quitting)
{
int need_symtab_cleanup = 0;
struct vmap *vp, *nxt;
we're supplying the exec pathname late for good reason.) */
void
-exec_file_attach (args, from_tty)
- char *args;
- int from_tty;
+exec_file_attach (char *args, int from_tty)
{
char **argv;
char *filename;
which can take multiple args. */
void
-exec_file_command (args, from_tty)
- char *args;
- int from_tty;
+exec_file_command (char *args, int from_tty)
{
target_preopen (from_tty);
exec_file_attach (args, from_tty);
command was added? */
static void
-file_command (arg, from_tty)
- char *arg;
- int from_tty;
+file_command (char *arg, int from_tty)
{
/* FIXME, if we lose on reading the symbol file, we should revert
the exec file, but that's rough. */
we cast it back to its proper type. */
static void
-add_to_section_table (abfd, asect, table_pp_char)
- bfd *abfd;
- sec_ptr asect;
- PTR table_pp_char;
+add_to_section_table (bfd *abfd, sec_ptr asect, PTR table_pp_char)
{
struct section_table **table_pp = (struct section_table **) table_pp_char;
flagword aflag;
Returns 0 if OK, 1 on error. */
int
-build_section_table (some_bfd, start, end)
- bfd *some_bfd;
- struct section_table **start, **end;
+build_section_table (bfd *some_bfd, struct section_table **start,
+ struct section_table **end)
{
unsigned count;
}
\f
static void
-bfdsec_to_vmap (abfd, sect, arg3)
- bfd *abfd;
- sec_ptr sect;
- PTR arg3;
+bfdsec_to_vmap (bfd *abfd, sec_ptr sect, PTR arg3)
{
struct vmap_and_bfd *vmap_bfd = (struct vmap_and_bfd *) arg3;
struct vmap *vp;
Return the new vmap. */
struct vmap *
-map_vmap (abfd, arch)
- bfd *abfd;
- bfd *arch;
+map_vmap (bfd *abfd, bfd *arch)
{
struct vmap_and_bfd vmap_bfd;
struct vmap *vp, **vpp;
we just tail-call it with more arguments to select between them. */
int
-xfer_memory (memaddr, myaddr, len, write, target)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
- struct target_ops *target;
+xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int write,
+ struct target_ops *target)
{
boolean res;
struct section_table *p;
\f
void
-print_section_info (t, abfd)
- struct target_ops *t;
- bfd *abfd;
+print_section_info (struct target_ops *t, bfd *abfd)
{
struct section_table *p;
}
static void
-exec_files_info (t)
- struct target_ops *t;
+exec_files_info (struct target_ops *t)
{
print_section_info (t, exec_bfd);
in the exec objfile. */
void
-exec_set_section_offsets (text_off, data_off, bss_off)
- bfd_signed_vma text_off;
- bfd_signed_vma data_off;
- bfd_signed_vma bss_off;
+exec_set_section_offsets (bfd_signed_vma text_off, bfd_signed_vma data_off,
+ bfd_signed_vma bss_off)
{
struct section_table *sect;
}
static void
-set_section_command (args, from_tty)
- char *args;
- int from_tty;
+set_section_command (char *args, int from_tty)
{
struct section_table *p;
char *secname;
breakpoint_init_inferior). */
static int
-ignore (addr, contents)
- CORE_ADDR addr;
- char *contents;
+ignore (CORE_ADDR addr, char *contents)
{
return 0;
}
defined. */
void
-init_exec_ops ()
+init_exec_ops (void)
{
exec_ops.to_shortname = "exec";
exec_ops.to_longname = "Local exec file";
}
void
-_initialize_exec ()
+_initialize_exec (void)
{
struct cmd_list_element *c;
enum precedence);
void
-print_expression (exp, stream)
- struct expression *exp;
- struct ui_file *stream;
+print_expression (struct expression *exp, struct ui_file *stream)
{
int pc = 0;
print_subexp (exp, &pc, stream, PREC_NULL);
parentheses are needed here. */
static void
-print_subexp (exp, pos, stream, prec)
- register struct expression *exp;
- register int *pos;
- struct ui_file *stream;
- enum precedence prec;
+print_subexp (register struct expression *exp, register int *pos,
+ struct ui_file *stream, enum precedence prec)
{
register unsigned tem;
register const struct op_print *op_print_tab;
a string. NULL indicates that the opcode was not found in the
current language table. */
char *
-op_string (op)
- enum exp_opcode op;
+op_string (enum exp_opcode op)
{
int tem;
register const struct op_print *op_print_tab;
static char *op_name (int opcode);
static char *
-op_name (opcode)
- int opcode;
+op_name (int opcode)
{
switch (opcode)
{
}
void
-dump_prefix_expression (exp, stream, note)
- struct expression *exp;
- struct ui_file *stream;
- char *note;
+dump_prefix_expression (struct expression *exp, struct ui_file *stream,
+ char *note)
{
int elt;
char *opcode_name;
int elt);
static int
-dump_subexp (exp, stream, elt)
- struct expression *exp;
- struct ui_file *stream;
- int elt;
+dump_subexp (struct expression *exp, struct ui_file *stream, int elt)
{
static int indent = 0;
int i;
}
void
-dump_postfix_expression (exp, stream, note)
- struct expression *exp;
- struct ui_file *stream;
- char *note;
+dump_postfix_expression (struct expression *exp, struct ui_file *stream,
+ char *note)
{
int elt;
be replaced with a true F77 version. */
static void
-f_emit_char (c, stream, quoter)
- register int c;
- struct ui_file *stream;
- int quoter;
+f_emit_char (register int c, struct ui_file *stream, int quoter)
{
c &= 0xFF; /* Avoid sign bit follies */
be replaced with a true F77version. */
static void
-f_printchar (c, stream)
- int c;
- struct ui_file *stream;
+f_printchar (int c, struct ui_file *stream)
{
fputs_filtered ("'", stream);
LA_EMIT_CHAR (c, stream, '\'');
be replaced with a true F77 version. */
static void
-f_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+f_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
register unsigned int i;
unsigned int things_printed = 0;
by an experienced F77 programmer. */
static struct type *
-f_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+f_create_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type *type = NULL;
};
void
-_initialize_f_language ()
+_initialize_f_language (void)
{
builtin_type_f_void =
init_type (TYPE_CODE_VOID, 1,
#if 0
static SAVED_BF_PTR
-allocate_saved_bf_node ()
+allocate_saved_bf_node (void)
{
SAVED_BF_PTR new;
}
static SAVED_FUNCTION *
-allocate_saved_function_node ()
+allocate_saved_function_node (void)
{
SAVED_FUNCTION *new;
}
static SAVED_F77_COMMON_PTR
-allocate_saved_f77_common_node ()
+allocate_saved_f77_common_node (void)
{
SAVED_F77_COMMON_PTR new;
}
static COMMON_ENTRY_PTR
-allocate_common_entry_node ()
+allocate_common_entry_node (void)
{
COMMON_ENTRY_PTR new;
the global common block chain */
static void
-add_common_block (name, offset, secnum, func_stab)
- char *name;
- CORE_ADDR offset;
- int secnum;
- char *func_stab;
+add_common_block (char *name, CORE_ADDR offset, int secnum, char *func_stab)
{
SAVED_F77_COMMON_PTR tmp;
char *c, *local_copy_func_stab;
#if 0
static void
-add_common_entry (entry_sym_ptr)
- struct symbol *entry_sym_ptr;
+add_common_entry (struct symbol *entry_sym_ptr)
{
COMMON_ENTRY_PTR tmp;
#if 0
static SAVED_F77_COMMON_PTR
-find_first_common_named (name)
- char *name;
+find_first_common_named (char *name)
{
SAVED_F77_COMMON_PTR tmp;
that belongs to function funcname */
SAVED_F77_COMMON_PTR
-find_common_for_function (name, funcname)
- char *name;
- char *funcname;
+find_common_for_function (char *name, char *funcname)
{
SAVED_F77_COMMON_PTR tmp;
"name." */
static void
-patch_common_entries (blk, offset, secnum)
- SAVED_F77_COMMON_PTR blk;
- CORE_ADDR offset;
- int secnum;
+patch_common_entries (SAVED_F77_COMMON_PTR blk, CORE_ADDR offset, int secnum)
{
COMMON_ENTRY_PTR entry;
(which is where common data lives). */
static void
-patch_all_commons_by_name (name, offset, secnum)
- char *name;
- CORE_ADDR offset;
- int secnum;
+patch_all_commons_by_name (char *name, CORE_ADDR offset, int secnum)
{
SAVED_F77_COMMON_PTR tmp;
#if 0
static void
-clear_bf_list ()
+clear_bf_list (void)
{
SAVED_BF_PTR tmp = saved_bf_list;
#if 0
static long
-get_bf_for_fcn (the_function)
- long the_function;
+get_bf_for_fcn (long the_function)
{
SAVED_BF_PTR tmp;
int nprobes = 0;
static SAVED_FUNCTION_PTR saved_function_list_end = NULL;
static void
-clear_function_list ()
+clear_function_list (void)
{
SAVED_FUNCTION_PTR tmp = saved_function_list;
SAVED_FUNCTION_PTR next = NULL;
/* LEVEL is the depth to indent lines by. */
void
-f_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+f_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
register enum type_code code;
int demangled_args;
SHOW is always zero on recursive calls. */
void
-f_type_print_varspec_prefix (type, stream, show, passed_a_ptr)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
+f_type_print_varspec_prefix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr)
{
if (type == 0)
return;
#if 0 /* Currently unused */
static void
-f_type_print_args (type, stream)
- struct type *type;
- struct ui_file *stream;
+f_type_print_args (struct type *type, struct ui_file *stream)
{
int i;
struct type **args;
Args work like c_type_print_varspec_prefix. */
static void
-f_type_print_varspec_suffix (type, stream, show, passed_a_ptr, demangled_args)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
- int demangled_args;
+f_type_print_varspec_suffix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr, int demangled_args)
{
int upper_bound, lower_bound;
int lower_bound_was_default = 0;
}
static void
-print_equivalent_f77_float_type (type, stream)
- struct type *type;
- struct ui_file *stream;
+print_equivalent_f77_float_type (struct type *type, struct ui_file *stream)
{
/* Override type name "float" and make it the
appropriate real. XLC stupidly outputs -12 as a type
We increase it for some recursive calls. */
void
-f_type_print_base (type, stream, show, level)
- struct type *type;
- struct ui_file *stream;
- int show;
- int level;
+f_type_print_base (struct type *type, struct ui_file *stream, int show,
+ int level)
{
int retcode;
int upper_bound;
#define F77_DIM_OFFSET(n) (f77_array_offset_tbl[n][0])
int
-f77_get_dynamic_lowerbound (type, lower_bound)
- struct type *type;
- int *lower_bound;
+f77_get_dynamic_lowerbound (struct type *type, int *lower_bound)
{
CORE_ADDR current_frame_addr;
CORE_ADDR ptr_to_lower_bound;
}
int
-f77_get_dynamic_upperbound (type, upper_bound)
- struct type *type;
- int *upper_bound;
+f77_get_dynamic_upperbound (struct type *type, int *upper_bound)
{
CORE_ADDR current_frame_addr = 0;
CORE_ADDR ptr_to_upper_bound;
/* Obtain F77 adjustable array dimensions */
static void
-f77_get_dynamic_length_of_aggregate (type)
- struct type *type;
+f77_get_dynamic_length_of_aggregate (struct type *type)
{
int upper_bound = -1;
int lower_bound = 1;
type "type". */
static void
-f77_create_arrayprint_offset_tbl (type, stream)
- struct type *type;
- struct ui_file *stream;
+f77_create_arrayprint_offset_tbl (struct type *type, struct ui_file *stream)
{
struct type *tmp_type;
int eltlen;
the superior. Address == the address in the inferior. */
static void
-f77_print_array_1 (nss, ndimensions, type, valaddr, address,
- stream, format, deref_ref, recurse, pretty)
- int nss;
- int ndimensions;
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+f77_print_array_1 (int nss, int ndimensions, struct type *type, char *valaddr,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
int i;
stuff and then immediately call f77_print_array_1() */
static void
-f77_print_array (type, valaddr, address, stream, format, deref_ref, recurse,
- pretty)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+f77_print_array (struct type *type, char *valaddr, CORE_ADDR address,
+ struct ui_file *stream, int format, int deref_ref, int recurse,
+ enum val_prettyprint pretty)
{
int ndimensions;
The PRETTY parameter controls prettyprinting. */
int
-f_val_print (type, valaddr, embedded_offset, address, stream, format, deref_ref, recurse,
- pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+f_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
register unsigned int i = 0; /* Number of characters printed */
struct type *elttype;
}
static void
-list_all_visible_commons (funname)
- char *funname;
+list_all_visible_commons (char *funname)
{
SAVED_F77_COMMON_PTR tmp;
given name */
static void
-info_common_command (comname, from_tty)
- char *comname;
- int from_tty;
+info_common_command (char *comname, int from_tty)
{
SAVED_F77_COMMON_PTR the_common;
COMMON_ENTRY_PTR entry;
#if 0
static int
-there_is_a_visible_common_named (comname)
- char *comname;
+there_is_a_visible_common_named (char *comname)
{
SAVED_F77_COMMON_PTR the_common;
struct frame_info *fi;
#endif
void
-_initialize_f_valprint ()
+_initialize_f_valprint (void)
{
add_info ("common", info_common_command,
"Print out the values contained in a Fortran COMMON block.");
Caller will check return value or die! */
value_ptr
-value_of_register (regnum)
- int regnum;
+value_of_register (int regnum)
{
CORE_ADDR addr;
int optim;
up caring what frame it is being evaluated relative to? SYM must
be non-NULL. */
int
-symbol_read_needs_frame (sym)
- struct symbol *sym;
+symbol_read_needs_frame (struct symbol *sym)
{
switch (SYMBOL_CLASS (sym))
{
If FRAME is NULL, use the selected_frame. */
value_ptr
-read_var_value (var, frame)
- register struct symbol *var;
- struct frame_info *frame;
+read_var_value (register struct symbol *var, struct frame_info *frame)
{
register value_ptr v;
struct type *type = SYMBOL_TYPE (var);
Caller will check return value or die! */
value_ptr
-value_from_register (type, regnum, frame)
- struct type *type;
- int regnum;
- struct frame_info *frame;
+value_from_register (struct type *type, int regnum, struct frame_info *frame)
{
char raw_buffer[MAX_REGISTER_RAW_SIZE];
CORE_ADDR addr;
address. */
value_ptr
-locate_var_value (var, frame)
- register struct symbol *var;
- struct frame_info *frame;
+locate_var_value (register struct symbol *var, struct frame_info *frame)
{
CORE_ADDR addr = 0;
struct type *type = SYMBOL_TYPE (var);
* the four arguments "a", "b", "c", "d".
*/
static void
-breakup_args (
- scratch,
- argv)
- char *scratch;
- char **argv;
+breakup_args (char *scratch, char **argv)
{
char *cp = scratch;
clone will set it TRUE.
*/
void
-clone_and_follow_inferior (child_pid, followed_child)
- int child_pid;
- int *followed_child;
+clone_and_follow_inferior (int child_pid, int *followed_child)
{
extern int auto_solib_add;
/* Accept NTRAPS traps from the inferior. */
void
-startup_inferior (ntraps)
- int ntraps;
+startup_inferior (int ntraps)
{
int pending_execs = ntraps;
int terminal_initted;
/* An expression that tells us whether the function invocation represented
by FI does not have a frame on the stack associated with it. */
int
-fr30_frameless_function_invocation (fi)
- struct frame_info *fi;
+fr30_frameless_function_invocation (struct frame_info *fi)
{
int frameless;
CORE_ADDR func_start, after_prologue;
command, or the call dummy breakpoint gets hit. */
void
-fr30_pop_frame ()
+fr30_pop_frame (void)
{
struct frame_info *frame = get_current_frame ();
int regnum;
*/
CORE_ADDR
-fr30_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+fr30_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int argreg;
int argnum;
void _initialize_fr30_tdep (void);
void
-_initialize_fr30_tdep ()
+_initialize_fr30_tdep (void)
{
extern int print_insn_fr30 (bfd_vma, disassemble_info *);
tm_print_insn = print_insn_fr30;
static struct frame_info prologue_cache;
static int
-check_prologue_cache (fi)
- struct frame_info *fi;
+check_prologue_cache (struct frame_info *fi)
{
int i;
*/
static void
-save_prologue_cache (fi)
- struct frame_info *fi;
+save_prologue_cache (struct frame_info *fi)
{
int i;
be determined till after we have scanned the prologue. */
static void
-fr30_scan_prologue (fi)
- struct frame_info *fi;
+fr30_scan_prologue (struct frame_info *fi)
{
int sp_offset, fp_offset;
CORE_ADDR prologue_start, prologue_end, current_pc;
pointer just prior to calling the target function (see run_stack_dummy). */
void
-fr30_init_extra_frame_info (fi)
- struct frame_info *fi;
+fr30_init_extra_frame_info (struct frame_info *fi)
{
int reg;
frame. */
CORE_ADDR
-fr30_find_callers_reg (fi, regnum)
- struct frame_info *fi;
- int regnum;
+fr30_find_callers_reg (struct frame_info *fi, int regnum)
{
for (; fi; fi = fi->next)
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
CORE_ADDR
-fr30_frame_chain (fi)
- struct frame_info *fi;
+fr30_frame_chain (struct frame_info *fi)
{
CORE_ADDR fn_start, callers_pc, fp;
struct frame_info caller_fi;
will be found. */
CORE_ADDR
-fr30_frame_saved_pc (fi)
- struct frame_info *fi;
+fr30_frame_saved_pc (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
*/
int
-fr30_fix_call_dummy (dummy, sp, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR sp;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+fr30_fix_call_dummy (char *dummy, CORE_ADDR sp, CORE_ADDR fun, int nargs,
+ value_ptr *args, struct type *type, int gcc_p)
{
long offset24;
data-pointer. */
void *
-gdbarch_data (data)
- struct gdbarch_data *data;
+gdbarch_data (struct gdbarch_data *data)
{
if (data->index >= current_gdbarch->nr_data)
internal_error ("gdbarch_data: request for non-existant data.");
extern void _initialize_gdbarch (void);
void
-_initialize_gdbarch ()
+_initialize_gdbarch (void)
{
struct cmd_list_element *c;
Then return to command level. */
void
-perror_with_name (string)
- char *string;
+perror_with_name (char *string)
{
#ifndef STDC_HEADERS
extern int sys_nerr;
}
static void
-sync_error (fp, desc, expect, got)
- FILE *fp;
- char *desc;
- int expect;
- int got;
+sync_error (FILE *fp, char *desc, int expect, int got)
{
fprintf (stderr, "\n%s\n", desc);
fprintf (stderr, "At logfile offset %ld, expected '0x%x' got '0x%x'\n",
}
void
-remote_close ()
+remote_close (void)
{
close (remote_desc);
}
NAME is the filename used for communication. */
void
-remote_open (name)
- char *name;
+remote_open (char *name)
{
extern char *strchr ();
}
static int
-tohex (ch)
- int ch;
+tohex (int ch)
{
if (ch >= '0' && ch <= '9')
{
}
static int
-logchar (fp)
- FILE *fp;
+logchar (FILE *fp)
{
int ch;
int ch2;
blank) up until a \n is read from fp (which is not matched) */
void
-expect (fp)
- FILE *fp;
+expect (FILE *fp)
{
int fromlog;
unsigned char fromgdb;
\n is read from fp (which is discarded and not sent to gdb). */
void
-play (fp)
- FILE *fp;
+play (FILE *fp)
{
int fromlog;
char ch;
ENV is the environment vector to pass. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
union wait w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PT_STEP : PT_CONTINUE, inferior_pid, 1, signal, 0);
#endif
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
register unsigned int regaddr;
char buf[MAX_REGISTER_RAW_SIZE];
/* Fetch all registers, or just one, from the child process. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno == -1 || regno == 0)
for (regno = 0; regno < NUM_REGS; regno++)
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
/* Copy LEN bytes from inferior's memory starting at MEMADDR
to debugger memory starting at MYADDR. */
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
}
ENV is the environment vector to pass. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
union wait w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PTRACE_SINGLESTEP : PTRACE_CONT, inferior_pid, 1, signal);
int i386_register_byte[MAX_NUM_REGS];
static void
-initialize_arch ()
+initialize_arch (void)
{
/* Initialize the table saying where each register starts in the
register file. */
};
int
-i386_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+i386_register_u_addr (int blockend, int regnum)
{
#if 0
/* this will be needed if fp registers are reinstated */
}
#elif defined(TARGET_M68K)
static void
-initialize_arch ()
+initialize_arch (void)
{
return;
}
is stored. */
int
-m68k_linux_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+m68k_linux_register_u_addr (int blockend, int regnum)
{
return (blockend + 4 * regmap[regnum]);
}
}
static void
-initialize_arch ()
+initialize_arch (void)
{
return;
}
#endif
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
CORE_ADDR regaddr;
register int i;
/* Fetch all registers, or just one, from the child process. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno == -1 || regno == 0)
for (regno = 0; regno < NUM_REGS - NUM_FREGS; regno++)
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
CORE_ADDR regaddr;
int i;
to debugger memory starting at MYADDR. */
void
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
initialize_arch ();
}
ALLARGS is a vector of program-name and args. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
/* Arggh. Apparently pthread_kill only works for threads within
the process that calls pthread_kill.
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
union wait w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PTRACE_SINGLESTEP_ONE : PTRACE_CONT,
It also handles knows where to find the I & L regs on the stack. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
#if 0
int whatregs = 0;
this point. */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
#if 0
int whatregs = 0;
saved context block. */
static unsigned long
-lynx_registers_addr ()
+lynx_registers_addr (void)
{
CORE_ADDR stblock;
int ecpoff = offsetof (st_t, ecp);
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (ignored)
- int ignored;
+fetch_inferior_registers (int ignored)
{
int regno;
unsigned long reg;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (ignored)
- int ignored;
+store_inferior_registers (int ignored)
{
int regno;
unsigned long reg;
to debugger memory starting at MYADDR. */
void
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
}
int i386_register_byte[MAX_NUM_REGS];
static void
-initialize_arch()
+initialize_arch (void)
{
/* Initialize the table saying where each register starts in the
register file. */
#ifdef __powerpc__
static void
-initialize_arch()
+initialize_arch (void)
{
}
#endif /* !__powerpc__ */
ENV is the environment vector to pass. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
int w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PT_STEP : PT_CONTINUE, inferior_pid,
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (ignored)
- int ignored;
+fetch_inferior_registers (int ignored)
{
struct reg inferior_registers;
struct env387 inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (ignored)
- int ignored;
+store_inferior_registers (int ignored)
{
struct reg inferior_registers;
struct env387 inferior_fp_registers;
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
/* Copy LEN bytes from inferior's memory starting at MEMADDR
to debugger memory starting at MYADDR. */
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
initialize_arch ();
}
does not support loading itself. */
static void
-generic_load (loadfile_bfd)
- bfd *loadfile_bfd;
+generic_load (bfd *loadfile_bfd)
{
asection *s;
}
int
-create_inferior (program, argv)
- char *program;
- char **argv;
+create_inferior (char *program, char **argv)
{
bfd *abfd;
int pid = 0;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
sim_close (gdbsim_desc, 0);
default_callback.shutdown (&default_callback);
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
sim_fetch_register (gdbsim_desc, regno, ®isters[REGISTER_BYTE (regno)],
REGISTER_RAW_SIZE (regno));
/* Fetch all registers, or just one, from the child process. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno == -1 || regno == 0)
for (regno = 0; regno < NUM_REGS /*-NUM_FREGS*/ ; regno++)
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
if (regno == -1)
{
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int sigrc;
enum sim_stop reason;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signo)
- int step;
- int signo;
+myresume (int step, int signo)
{
/* Should be using target_signal_to_host() or signal numbers in target.h
to convert GDB signal number to target signal number. */
to debugger memory starting at MYADDR. */
void
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
sim_read (gdbsim_desc, memaddr, myaddr, len);
}
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
sim_write (gdbsim_desc, memaddr, myaddr, len); /* should check for error. FIXME!! */
return 0;
}
void
-initialize_low ()
+initialize_low (void)
{
}
ENV is the environment vector to pass. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
union wait w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PTRACE_SINGLESTEP : PTRACE_CONT, inferior_pid, 1, signal);
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (ignored)
- int ignored;
+fetch_inferior_registers (int ignored)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (ignored)
- int ignored;
+store_inferior_registers (int ignored)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
/* Copy LEN bytes from inferior's memory starting at MEMADDR
to debugger memory starting at MYADDR. */
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
}
ENV is the environment vector to pass. */
int
-create_inferior (program, allargs)
- char *program;
- char **allargs;
+create_inferior (char *program, char **allargs)
{
int pid;
/* Kill the inferior process. Make us have no inferior. */
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
/* Return nonzero if the given thread is still alive. */
int
-mythread_alive (pid)
- int pid;
+mythread_alive (int pid)
{
return 1;
}
/* Wait for process, returns status */
unsigned char
-mywait (status)
- char *status;
+mywait (char *status)
{
int pid;
union wait w;
If SIGNAL is nonzero, give it that signal. */
void
-myresume (step, signal)
- int step;
- int signal;
+myresume (int step, int signal)
{
errno = 0;
ptrace (step ? PTRACE_SINGLESTEP : PTRACE_CONT, inferior_pid, 1, signal);
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (ignored)
- int ignored;
+fetch_inferior_registers (int ignored)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (ignored)
- int ignored;
+store_inferior_registers (int ignored)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
/* Copy LEN bytes from inferior's memory starting at MEMADDR
to debugger memory starting at MYADDR. */
-read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
returns the value of errno. */
int
-write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
register int i;
/* Round starting address down to longword boundary. */
}
\f
void
-initialize_low ()
+initialize_low (void)
{
}
NAME is the filename used for communication. */
void
-remote_open (name)
- char *name;
+remote_open (char *name)
{
int save_fcntl_flags;
}
void
-remote_close ()
+remote_close (void)
{
close (remote_desc);
}
/* Convert hex digit A to a number. */
static int
-fromhex (a)
- int a;
+fromhex (int a)
{
if (a >= '0' && a <= '9')
return a - '0';
/* Convert number NIB to a hex digit. */
static int
-tohex (nib)
- int nib;
+tohex (int nib)
{
if (nib < 10)
return '0' + nib;
The data of the packet is in BUF. Returns >= 0 on success, -1 otherwise. */
int
-putpkt (buf)
- char *buf;
+putpkt (char *buf)
{
int i;
unsigned char csum = 0;
will cause us to send a SIGINT to the child. */
static void
-input_interrupt ()
+input_interrupt (void)
{
int cc;
char c;
}
void
-enable_async_io ()
+enable_async_io (void)
{
signal (SIGIO, input_interrupt);
}
void
-disable_async_io ()
+disable_async_io (void)
{
signal (SIGIO, SIG_IGN);
}
/* Returns next char from remote GDB. -1 if error. */
static int
-readchar ()
+readchar (void)
{
static char buf[BUFSIZ];
static int bufcnt = 0;
and store it in BUF. Returns length of packet, or negative if error. */
int
-getpkt (buf)
- char *buf;
+getpkt (char *buf)
{
char *bp;
unsigned char csum, c1, c2;
}
void
-write_ok (buf)
- char *buf;
+write_ok (char *buf)
{
buf[0] = 'O';
buf[1] = 'K';
}
void
-write_enn (buf)
- char *buf;
+write_enn (char *buf)
{
buf[0] = 'E';
buf[1] = 'N';
}
void
-convert_int_to_ascii (from, to, n)
- char *from, *to;
- int n;
+convert_int_to_ascii (char *from, char *to, int n)
{
int nib;
char ch;
void
-convert_ascii_to_int (from, to, n)
- char *from, *to;
- int n;
+convert_ascii_to_int (char *from, char *to, int n)
{
int nib1, nib2;
while (n--)
}
static char *
-outreg (regno, buf)
- int regno;
- char *buf;
+outreg (int regno, char *buf)
{
int regsize = REGISTER_RAW_SIZE (regno);
}
void
-prepare_resume_reply (buf, status, signo)
- char *buf;
- char status;
- unsigned char signo;
+prepare_resume_reply (char *buf, char status, unsigned char signo)
{
int nib;
}
void
-decode_m_packet (from, mem_addr_ptr, len_ptr)
- char *from;
- CORE_ADDR *mem_addr_ptr;
- unsigned int *len_ptr;
+decode_m_packet (char *from, CORE_ADDR *mem_addr_ptr, unsigned int *len_ptr)
{
int i = 0, j = 0;
char ch;
}
void
-decode_M_packet (from, mem_addr_ptr, len_ptr, to)
- char *from, *to;
- CORE_ADDR *mem_addr_ptr;
- unsigned int *len_ptr;
+decode_M_packet (char *from, CORE_ADDR *mem_addr_ptr, unsigned int *len_ptr,
+ char *to)
{
int i = 0;
char ch;
Then return to command level. */
void
-perror_with_name (string)
- char *string;
+perror_with_name (char *string)
{
#ifndef STDC_HEADERS
extern int sys_nerr;
in that objfile's type_obstack. */
struct type *
-alloc_type (objfile)
- struct objfile *objfile;
+alloc_type (struct objfile *objfile)
{
register struct type *type;
We allocate new memory if needed. */
struct type *
-make_pointer_type (type, typeptr)
- struct type *type;
- struct type **typeptr;
+make_pointer_type (struct type *type, struct type **typeptr)
{
register struct type *ntype; /* New type */
struct objfile *objfile;
May need to construct such a type if this is the first use. */
struct type *
-lookup_pointer_type (type)
- struct type *type;
+lookup_pointer_type (struct type *type)
{
return make_pointer_type (type, (struct type **) 0);
}
We allocate new memory if needed. */
struct type *
-make_reference_type (type, typeptr)
- struct type *type;
- struct type **typeptr;
+make_reference_type (struct type *type, struct type **typeptr)
{
register struct type *ntype; /* New type */
struct objfile *objfile;
/* Same as above, but caller doesn't care about memory allocation details. */
struct type *
-lookup_reference_type (type)
- struct type *type;
+lookup_reference_type (struct type *type)
{
return make_reference_type (type, (struct type **) 0);
}
We allocate new memory if needed. */
struct type *
-make_function_type (type, typeptr)
- struct type *type;
- struct type **typeptr;
+make_function_type (struct type *type, struct type **typeptr)
{
register struct type *ntype; /* New type */
struct objfile *objfile;
May need to construct such a type if this is the first use. */
struct type *
-lookup_function_type (type)
- struct type *type;
+lookup_function_type (struct type *type)
{
return make_function_type (type, (struct type **) 0);
}
We allocate new memory if needed. */
struct type *
-make_cv_type (cnst, voltl, type, typeptr)
- int cnst;
- int voltl;
- struct type *type;
- struct type **typeptr;
+make_cv_type (int cnst, int voltl, struct type *type, struct type **typeptr)
{
register struct type *ntype; /* New type */
register struct type *tmp_type = type; /* tmp type */
of the aggregate that the member belongs to. */
struct type *
-lookup_member_type (type, domain)
- struct type *type;
- struct type *domain;
+lookup_member_type (struct type *type, struct type *domain)
{
register struct type *mtype;
This always returns a fresh type. */
struct type *
-allocate_stub_method (type)
- struct type *type;
+allocate_stub_method (struct type *type)
{
struct type *mtype;
sure it is TYPE_CODE_UNDEF before we bash it into a range type? */
struct type *
-create_range_type (result_type, index_type, low_bound, high_bound)
- struct type *result_type;
- struct type *index_type;
- int low_bound;
- int high_bound;
+create_range_type (struct type *result_type, struct type *index_type,
+ int low_bound, int high_bound)
{
if (result_type == NULL)
{
will fit in LONGEST), or -1 otherwise. */
int
-get_discrete_bounds (type, lowp, highp)
- struct type *type;
- LONGEST *lowp, *highp;
+get_discrete_bounds (struct type *type, LONGEST *lowp, LONGEST *highp)
{
CHECK_TYPEDEF (type);
switch (TYPE_CODE (type))
sure it is TYPE_CODE_UNDEF before we bash it into an array type? */
struct type *
-create_array_type (result_type, element_type, range_type)
- struct type *result_type;
- struct type *element_type;
- struct type *range_type;
+create_array_type (struct type *result_type, struct type *element_type,
+ struct type *range_type)
{
LONGEST low_bound, high_bound;
sure it is TYPE_CODE_UNDEF before we bash it into a string type? */
struct type *
-create_string_type (result_type, range_type)
- struct type *result_type;
- struct type *range_type;
+create_string_type (struct type *result_type, struct type *range_type)
{
result_type = create_array_type (result_type,
*current_language->string_char_type,
}
struct type *
-create_set_type (result_type, domain_type)
- struct type *result_type;
- struct type *domain_type;
+create_set_type (struct type *result_type, struct type *domain_type)
{
LONGEST low_bound, high_bound, bit_length;
if (result_type == NULL)
allocated. */
void
-smash_to_member_type (type, domain, to_type)
- struct type *type;
- struct type *domain;
- struct type *to_type;
+smash_to_member_type (struct type *type, struct type *domain,
+ struct type *to_type)
{
struct objfile *objfile;
allocated. */
void
-smash_to_method_type (type, domain, to_type, args)
- struct type *type;
- struct type *domain;
- struct type *to_type;
- struct type **args;
+smash_to_method_type (struct type *type, struct type *domain,
+ struct type *to_type, struct type **args)
{
struct objfile *objfile;
"union ", or "enum ". If the type has a NULL name, return NULL. */
char *
-type_name_no_tag (type)
- register const struct type *type;
+type_name_no_tag (register const struct type *type)
{
if (TYPE_TAG_NAME (type) != NULL)
return TYPE_TAG_NAME (type);
Return zero if NAME is not a primitive type. */
struct type *
-lookup_primitive_typename (name)
- char *name;
+lookup_primitive_typename (char *name)
{
struct type **const *p;
If NOERR is nonzero, return zero if NAME is not suitably defined. */
struct type *
-lookup_typename (name, block, noerr)
- char *name;
- struct block *block;
- int noerr;
+lookup_typename (char *name, struct block *block, int noerr)
{
register struct symbol *sym;
register struct type *tmp;
}
struct type *
-lookup_unsigned_typename (name)
- char *name;
+lookup_unsigned_typename (char *name)
{
char *uns = alloca (strlen (name) + 10);
}
struct type *
-lookup_signed_typename (name)
- char *name;
+lookup_signed_typename (char *name)
{
struct type *t;
char *uns = alloca (strlen (name) + 8);
visible in lexical block BLOCK. */
struct type *
-lookup_struct (name, block)
- char *name;
- struct block *block;
+lookup_struct (char *name, struct block *block)
{
register struct symbol *sym;
visible in lexical block BLOCK. */
struct type *
-lookup_union (name, block)
- char *name;
- struct block *block;
+lookup_union (char *name, struct block *block)
{
register struct symbol *sym;
struct type *t;
visible in lexical block BLOCK. */
struct type *
-lookup_enum (name, block)
- char *name;
- struct block *block;
+lookup_enum (char *name, struct block *block)
{
register struct symbol *sym;
visible in lexical block BLOCK. */
struct type *
-lookup_template_type (name, type, block)
- char *name;
- struct type *type;
- struct block *block;
+lookup_template_type (char *name, struct type *type, struct block *block)
{
struct symbol *sym;
char *nam = (char *) alloca (strlen (name) + strlen (type->name) + 4);
If NAME is the name of a baseclass type, return that type. */
struct type *
-lookup_struct_elt_type (type, name, noerr)
- struct type *type;
- char *name;
- int noerr;
+lookup_struct_elt_type (struct type *type, char *name, int noerr)
{
int i;
will remain NULL. */
void
-fill_in_vptr_fieldno (type)
- struct type *type;
+fill_in_vptr_fieldno (struct type *type)
{
CHECK_TYPEDEF (type);
Return 1 if the destructor was found, otherwise, return 0. */
int
-get_destructor_fn_field (t, method_indexp, field_indexp)
- struct type *t;
- int *method_indexp;
- int *field_indexp;
+get_destructor_fn_field (struct type *t, int *method_indexp, int *field_indexp)
{
int i;
{"stub type has NULL name", 0, 0};
struct type *
-check_typedef (type)
- register struct type *type;
+check_typedef (register struct type *type)
{
struct type *orig_type = type;
while (TYPE_CODE (type) == TYPE_CODE_TYPEDEF)
#define ADD_EXTRA(c) { pextras->str[pextras->len++]=c; }
static void
-add_name (pextras, n)
- struct extra *pextras;
- char *n;
+add_name (struct extra *pextras, char *n)
{
int nlen;
}
static void
-add_mangled_type (pextras, t)
- struct extra *pextras;
- struct type *t;
+add_mangled_type (struct extra *pextras, struct type *t)
{
enum type_code tcode;
int tlen, tflags;
#if 0
void
-cfront_mangle_name (type, i, j)
- struct type *type;
- int i;
- int j;
+cfront_mangle_name (struct type *type, int i, int j)
{
struct fn_field *f;
char *mangled_name = gdb_mangle_name (type, i, j);
the space required for them. */
void
-check_stub_method (type, method_id, signature_id)
- struct type *type;
- int method_id;
- int signature_id;
+check_stub_method (struct type *type, int method_id, int signature_id)
{
struct fn_field *f;
char *mangled_name = gdb_mangle_name (type, method_id, signature_id);
const struct cplus_struct_type cplus_struct_default;
void
-allocate_cplus_struct_type (type)
- struct type *type;
+allocate_cplus_struct_type (struct type *type)
{
if (!HAVE_CPLUS_STRUCT (type))
{
in particular, where init_type is called with a NULL value for NAME). */
struct type *
-init_type (code, length, flags, name, objfile)
- enum type_code code;
- int length;
- int flags;
- char *name;
- struct objfile *objfile;
+init_type (enum type_code code, int length, int flags, char *name,
+ struct objfile *objfile)
{
register struct type *type;
struct type *
-lookup_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+lookup_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type **typep;
register int nbytes;
}
int
-can_dereference (t)
- struct type *t;
+can_dereference (struct type *t)
{
/* FIXME: Should we return true for references as well as pointers? */
CHECK_TYPEDEF (t);
}
int
-is_integral_type (t)
- struct type *t;
+is_integral_type (struct type *t)
{
CHECK_TYPEDEF (t);
return
Return true if TYPE is such a Chill varying type. */
int
-chill_varying_type (type)
- struct type *type;
+chill_varying_type (struct type *type)
{
if (TYPE_CODE (type) != TYPE_CODE_STRUCT
|| TYPE_NFIELDS (type) != 2
the ancestor relationship even if they're identical */
int
-is_ancestor (base, dclass)
- struct type *base;
- struct type *dclass;
+is_ancestor (struct type *base, struct type *dclass)
{
int i;
runtime models. Return 1 => Yes, 0 => No. */
int
-has_vtable (dclass)
- struct type *dclass;
+has_vtable (struct type *dclass)
{
/* In the HP ANSI C++ runtime model, a class has a vtable only if it
has virtual functions or virtual bases. */
and may not work with other runtime models. */
struct type *
-primary_base_class (dclass)
- struct type *dclass;
+primary_base_class (struct type *dclass)
{
/* In HP ANSI C++'s runtime model, a "primary base class" of a class
is the first directly inherited, non-virtual base class that
copies the items out in reverse order. */
static void
-virtual_base_list_aux (dclass)
- struct type *dclass;
+virtual_base_list_aux (struct type *dclass)
{
struct vbase *tmp_vbase;
register int i;
and then copies the result into an array to save space. */
struct type **
-virtual_base_list (dclass)
- struct type *dclass;
+virtual_base_list (struct type *dclass)
{
register struct vbase *tmp_vbase;
register struct vbase *tmp_vbase_2;
/* Return the length of the virtual base list of the type DCLASS. */
int
-virtual_base_list_length (dclass)
- struct type *dclass;
+virtual_base_list_length (struct type *dclass)
{
register int i;
register struct vbase *tmp_vbase;
primary base, recursively). */
int
-virtual_base_list_length_skip_primaries (dclass)
- struct type *dclass;
+virtual_base_list_length_skip_primaries (struct type *dclass)
{
register int i;
register struct vbase *tmp_vbase;
indicates "not found" or a problem. */
int
-virtual_base_index (base, dclass)
- struct type *base;
- struct type *dclass;
+virtual_base_index (struct type *base, struct type *dclass)
{
register struct type *vbase;
register int i;
found" or a problem. */
int
-virtual_base_index_skip_primaries (base, dclass)
- struct type *base;
- struct type *dclass;
+virtual_base_index_skip_primaries (struct type *base, struct type *dclass)
{
register struct type *vbase;
register int i, j;
* Position returned is 0-based. */
int
-class_index_in_primary_list (dclass)
- struct type *dclass;
+class_index_in_primary_list (struct type *dclass)
{
struct type *pbc; /* primary base class */
*/
int
-count_virtual_fns (dclass)
- struct type *dclass;
+count_virtual_fns (struct type *dclass)
{
int fn, oi; /* function and overloaded instance indices */
int vfuncs; /* count to return */
* 3 => A is worse than B */
int
-compare_badness (a, b)
- struct badness_vector *a;
- struct badness_vector *b;
+compare_badness (struct badness_vector *a, struct badness_vector *b)
{
int i;
int tmp;
* Return a pointer to a badness vector. This has NARGS + 1 entries. */
struct badness_vector *
-rank_function (parms, nparms, args, nargs)
- struct type **parms;
- int nparms;
- struct type **args;
- int nargs;
+rank_function (struct type **parms, int nparms, struct type **args, int nargs)
{
int i;
struct badness_vector *bv;
* Generally the "bad" conversions are all uniformly assigned a 100 */
int
-rank_one_type (parm, arg)
- struct type *parm;
- struct type *arg;
+rank_one_type (struct type *parm, struct type *arg)
{
/* Identical type pointers */
/* However, this still doesn't catch all cases of same type for arg
/* End of functions for overload resolution */
static void
-print_bit_vector (bits, nbits)
- B_TYPE *bits;
- int nbits;
+print_bit_vector (B_TYPE *bits, int nbits)
{
int bitno;
include it since we may get into a infinitely recursive situation. */
static void
-print_arg_types (args, spaces)
- struct type **args;
- int spaces;
+print_arg_types (struct type **args, int spaces)
{
if (args != NULL)
{
}
static void
-dump_fn_fieldlists (type, spaces)
- struct type *type;
- int spaces;
+dump_fn_fieldlists (struct type *type, int spaces)
{
int method_idx;
int overload_idx;
}
static void
-print_cplus_stuff (type, spaces)
- struct type *type;
- int spaces;
+print_cplus_stuff (struct type *type, int spaces)
{
printfi_filtered (spaces, "n_baseclasses %d\n",
TYPE_N_BASECLASSES (type));
static struct obstack dont_print_type_obstack;
void
-recursive_dump_type (type, spaces)
- struct type *type;
- int spaces;
+recursive_dump_type (struct type *type, int spaces)
{
int idx;
static void build_gdbtypes (void);
static void
-build_gdbtypes ()
+build_gdbtypes (void)
{
builtin_type_void =
init_type (TYPE_CODE_VOID, 1,
extern void _initialize_gdbtypes (void);
void
-_initialize_gdbtypes ()
+_initialize_gdbtypes (void)
{
struct cmd_list_element *c;
build_gdbtypes ();
\f
struct inf *
-make_inf ()
+make_inf (void)
{
struct inf *inf = malloc (sizeof (struct inf));
\f
static void
-gnu_kill_inferior ()
+gnu_kill_inferior (void)
{
struct proc *task = current_inferior->task;
if (task)
/* Clean up after the inferior dies. */
static void
-gnu_mourn_inferior ()
+gnu_mourn_inferior (void)
{
inf_debug (current_inferior, "rip");
inf_detach (current_inferior);
/* Set INFERIOR_PID to the first thread available in the child, if any. */
static int
-inf_pick_first_thread ()
+inf_pick_first_thread (void)
{
if (current_inferior->task && current_inferior->threads)
/* The first thread. */
}
static struct inf *
-cur_inf ()
+cur_inf (void)
{
if (!current_inferior)
current_inferior = make_inf ();
}
static void
-gnu_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+gnu_create_inferior (char *exec_file, char *allargs, char **env)
{
struct inf *inf = cur_inf ();
/* Mark our target-struct as eligible for stray "run" and "attach"
commands. */
static int
-gnu_can_run ()
+gnu_can_run (void)
{
return 1;
}
/* Attach to process PID, then initialize for debugging it
and wait for the trace-trap that results from attaching. */
static void
-gnu_attach (args, from_tty)
- char *args;
- int from_tty;
+gnu_attach (char *args, int from_tty)
{
int pid;
char *exec_file;
previously attached. It *might* work if the program was
started via fork. */
static void
-gnu_detach (args, from_tty)
- char *args;
- int from_tty;
+gnu_detach (char *args, int from_tty)
{
if (from_tty)
{
\f
static void
-gnu_terminal_init_inferior ()
+gnu_terminal_init_inferior (void)
{
assert (current_inferior);
terminal_init_inferior_with_pgrp (current_inferior->pid);
that registers contains all the registers from the program being
debugged. */
static void
-gnu_prepare_to_store ()
+gnu_prepare_to_store (void)
{
#ifdef CHILD_PREPARE_TO_STORE
CHILD_PREPARE_TO_STORE ();
}
static void
-gnu_open (arg, from_tty)
- char *arg;
- int from_tty;
+gnu_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a Unix child process.");
}
static void
-gnu_stop ()
+gnu_stop (void)
{
error ("to_stop target function not implemented");
}
static char *
-gnu_pid_to_exec_file ()
+gnu_pid_to_exec_file (void)
{
error ("to_pid_to_exec_file target function not implemented");
return NULL;
gdb's address space. Return 0 on failure; number of bytes read
otherwise. */
int
-gnu_read_inferior (task, addr, myaddr, length)
- task_t task;
- CORE_ADDR addr;
- char *myaddr;
- int length;
+gnu_read_inferior (task_t task, CORE_ADDR addr, char *myaddr, int length)
{
error_t err;
vm_address_t low_address = (vm_address_t) trunc_page (addr);
/* Write gdb's LEN bytes from MYADDR and copy it to ADDR in inferior
task's address space. */
int
-gnu_write_inferior (task, addr, myaddr, length)
- task_t task;
- CORE_ADDR addr;
- char *myaddr;
- int length;
+gnu_write_inferior (task_t task, CORE_ADDR addr, char *myaddr, int length)
{
error_t err = 0;
vm_address_t low_address = (vm_address_t) trunc_page (addr);
/* Returns the alive thread named by INFERIOR_PID, or signals an error. */
static struct proc *
-cur_thread ()
+cur_thread (void)
{
struct inf *inf = cur_inf ();
struct proc *thread = inf_tid_to_thread (inf, inferior_pid);
/* Returns the current inferior, but signals an error if it has no task. */
static struct inf *
-active_inf ()
+active_inf (void)
{
struct inf *inf = cur_inf ();
if (!inf->task)
end up looping in mysterious Bpt traps */
void
-flush_inferior_icache (pc, amount)
- CORE_ADDR pc;
+flush_inferior_icache (CORE_ADDR pc, int amount)
{
vm_machine_attribute_val_t flush = MATTR_VAL_ICACHE_FLUSH;
error_t ret;
void h8300_frame_find_saved_regs ();
CORE_ADDR
-h8300_skip_prologue (start_pc)
- CORE_ADDR start_pc;
+h8300_skip_prologue (CORE_ADDR start_pc)
{
short int w;
int adjust = 0;
}
int
-gdb_print_insn_h8300 (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_h8300 (bfd_vma memaddr, disassemble_info *info)
{
if (h8300smode)
return print_insn_h8300s (memaddr, info);
the function prologue to determine the caller's sp value, and return it. */
CORE_ADDR
-h8300_frame_chain (thisframe)
- struct frame_info *thisframe;
+h8300_frame_chain (struct frame_info *thisframe)
{
if (PC_IN_CALL_DUMMY (thisframe->pc, thisframe->frame, thisframe->frame))
{ /* initialize the from_pc now */
fairly expensive. */
void
-h8300_frame_find_saved_regs (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+h8300_frame_find_saved_regs (struct frame_info *fi,
+ struct frame_saved_regs *fsr)
{
register struct frame_saved_regs *cache_fsr;
CORE_ADDR ip;
of the instruction. */
CORE_ADDR
-NEXT_PROLOGUE_INSN (addr, lim, pword1)
- CORE_ADDR addr;
- CORE_ADDR lim;
- INSN_WORD *pword1;
+NEXT_PROLOGUE_INSN (CORE_ADDR addr, CORE_ADDR lim, INSN_WORD *pword1)
{
char buf[2];
if (addr < lim + 8)
to reflect the offsets of the arg pointer and the locals pointer. */
static CORE_ADDR
-examine_prologue (ip, limit, after_prolog_fp, fsr, fi)
- register CORE_ADDR ip;
- register CORE_ADDR limit;
- CORE_ADDR after_prolog_fp;
- struct frame_saved_regs *fsr;
- struct frame_info *fi;
+examine_prologue (register CORE_ADDR ip, register CORE_ADDR limit,
+ CORE_ADDR after_prolog_fp, struct frame_saved_regs *fsr,
+ struct frame_info *fi)
{
register CORE_ADDR next_ip;
int r;
}
void
-h8300_init_extra_frame_info (fromleaf, fi)
- int fromleaf;
- struct frame_info *fi;
+h8300_init_extra_frame_info (int fromleaf, struct frame_info *fi)
{
fi->fsr = 0; /* Not yet allocated */
fi->args_pointer = 0; /* Unknown */
just use the register SRP_REGNUM itself. */
CORE_ADDR
-h8300_frame_saved_pc (frame)
- struct frame_info *frame;
+h8300_frame_saved_pc (struct frame_info *frame)
{
if (PC_IN_CALL_DUMMY (frame->pc, frame->frame, frame->frame))
return generic_read_register_dummy (frame->pc, frame->frame, PC_REGNUM);
}
CORE_ADDR
-frame_locals_address (fi)
- struct frame_info *fi;
+frame_locals_address (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return (CORE_ADDR) 0; /* Not sure what else to do... */
described by FI. Returns 0 if the address is unknown. */
CORE_ADDR
-frame_args_address (fi)
- struct frame_info *fi;
+frame_args_address (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return (CORE_ADDR) 0; /* Not sure what else to do... */
the other arguments passed in via registers R0 to R2. */
CORE_ADDR
-h8300_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- struct value **args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+h8300_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int stack_align, stack_alloc, stack_offset;
int wordsize;
a JSR/BSR instruction. */
CORE_ADDR
-h8300_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+h8300_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
unsigned char buf[4];
int wordsize;
call_function_by_hand after the dummy_frame is finished. */
void
-h8300_pop_frame ()
+h8300_pop_frame (void)
{
unsigned regnum;
struct frame_saved_regs fsr;
Copy that into VALBUF. Be sure to account for CPU type. */
void
-h8300_extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+h8300_extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
int wordsize, len;
Primarily used by the RETURN command. */
void
-h8300_store_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+h8300_store_return_value (struct type *type, char *valbuf)
{
int wordsize, len, regval;
struct cmd_list_element *setmemorylist;
static void
-set_register_names ()
+set_register_names (void)
{
if (h8300hmode != 0)
h8300_register_names = h8300h_register_names;
}
static void
-h8300_command (args, from_tty)
+h8300_command (int args, int from_tty)
{
extern int h8300hmode;
h8300hmode = 0;
}
static void
-h8300h_command (args, from_tty)
+h8300h_command (int args, int from_tty)
{
extern int h8300hmode;
h8300hmode = 1;
}
static void
-h8300s_command (args, from_tty)
+h8300s_command (int args, int from_tty)
{
extern int h8300smode;
extern int h8300hmode;
static void
-set_machine (args, from_tty)
- char *args;
- int from_tty;
+set_machine (char *args, int from_tty)
{
printf_unfiltered ("\"set machine\" must be followed by h8300, h8300h");
printf_unfiltered ("or h8300s");
to be 16 or 32 bits as appropriate for the machine. */
static void
-set_machine_hook (filename)
- char *filename;
+set_machine_hook (char *filename)
{
if (bfd_get_mach (exec_bfd) == bfd_mach_h8300s)
{
}
void
-_initialize_h8300m ()
+_initialize_h8300m (void)
{
add_prefix_cmd ("machine", no_class, set_machine,
"set the machine type",
void
-print_register_hook (regno)
+print_register_hook (int regno)
{
if (regno == 8)
{
}
void
-_initialize_h8300_tdep ()
+_initialize_h8300_tdep (void)
{
tm_print_insn = gdb_print_insn_h8300;
}
int minimum_mode = 1;
CORE_ADDR
-h8500_skip_prologue (start_pc)
- CORE_ADDR start_pc;
+h8500_skip_prologue (CORE_ADDR start_pc)
{
short int w;
}
CORE_ADDR
-h8500_addr_bits_remove (addr)
- CORE_ADDR addr;
+h8500_addr_bits_remove (CORE_ADDR addr)
{
return ((addr) & 0xffffff);
}
the function prologue to determine the caller's sp value, and return it. */
CORE_ADDR
-h8500_frame_chain (thisframe)
- struct frame_info *thisframe;
+h8500_frame_chain (struct frame_info *thisframe)
{
if (!inside_entry_file (thisframe->pc))
return (read_memory_integer (FRAME_FP (thisframe), PTR_SIZE));
of the instruction. */
CORE_ADDR
-NEXT_PROLOGUE_INSN (addr, lim, pword1)
- CORE_ADDR addr;
- CORE_ADDR lim;
- char *pword1;
+NEXT_PROLOGUE_INSN (CORE_ADDR addr, CORE_ADDR lim, char *pword1)
{
if (addr < lim + 8)
{
/* Return the saved PC from this frame. */
CORE_ADDR
-frame_saved_pc (frame)
- struct frame_info *frame;
+frame_saved_pc (struct frame_info *frame)
{
return read_memory_integer (FRAME_FP (frame) + 2, PTR_SIZE);
}
void
-h8500_pop_frame ()
+h8500_pop_frame (void)
{
unsigned regnum;
struct frame_saved_regs fsr;
}
void
-print_register_hook (regno)
- int regno;
+print_register_hook (int regno)
{
if (regno == CCR_REGNUM)
{
}
int
-h8500_register_size (regno)
- int regno;
+h8500_register_size (int regno)
{
switch (regno)
{
}
struct type *
-h8500_register_virtual_type (regno)
- int regno;
+h8500_register_virtual_type (int regno)
{
switch (regno)
{
the address we return for it IS the sp for the next frame. */
void
-frame_find_saved_regs (frame_info, frame_saved_regs)
- struct frame_info *frame_info;
- struct frame_saved_regs *frame_saved_regs;
+frame_find_saved_regs (struct frame_info *frame_info,
+ struct frame_saved_regs *frame_saved_regs)
{
register int regnum;
register int regmask;
}
CORE_ADDR
-saved_pc_after_call ()
+saved_pc_after_call (void)
{
int x;
int a = read_register (SP_REGNUM);
}
void
-h8500_set_pointer_size (newsize)
- int newsize;
+h8500_set_pointer_size (int newsize)
{
static int oldsize = 0;
}
static void
-big_command ()
+big_command (void)
{
h8500_set_pointer_size (32);
code_size = 4;
}
static void
-medium_command ()
+medium_command (void)
{
h8500_set_pointer_size (32);
code_size = 4;
}
static void
-compact_command ()
+compact_command (void)
{
h8500_set_pointer_size (32);
code_size = 2;
}
static void
-small_command ()
+small_command (void)
{
h8500_set_pointer_size (16);
code_size = 2;
static struct cmd_list_element *setmemorylist;
static void
-set_memory (args, from_tty)
- char *args;
- int from_tty;
+set_memory (char *args, int from_tty)
{
printf_unfiltered ("\"set memory\" must be followed by the name of a memory subcommand.\n");
help_list (setmemorylist, "set memory ", -1, gdb_stdout);
/* See if variable name is ppc or pr[0-7] */
int
-h8500_is_trapped_internalvar (name)
- char *name;
+h8500_is_trapped_internalvar (char *name)
{
if (name[0] != 'p')
return 0;
}
value_ptr
-h8500_value_of_trapped_internalvar (var)
- struct internalvar *var;
+h8500_value_of_trapped_internalvar (struct internalvar *var)
{
LONGEST regval;
unsigned char regbuf[4];
}
void
-h8500_set_trapped_internalvar (var, newval, bitpos, bitsize, offset)
- struct internalvar *var;
- int offset, bitpos, bitsize;
- value_ptr newval;
+h8500_set_trapped_internalvar (struct internalvar *var, value_ptr newval,
+ int bitpos, int bitsize, int offset)
{
char *page_regnum, *regnum;
char expression[100];
}
CORE_ADDR
-h8500_read_sp ()
+h8500_read_sp (void)
{
return read_register (PR7_REGNUM);
}
void
-h8500_write_sp (v)
- CORE_ADDR v;
+h8500_write_sp (CORE_ADDR v)
{
write_register (PR7_REGNUM, v);
}
CORE_ADDR
-h8500_read_pc (pid)
- int pid;
+h8500_read_pc (int pid)
{
return read_register (PC_REGNUM);
}
void
-h8500_write_pc (v, pid)
- CORE_ADDR v;
- int pid;
+h8500_write_pc (CORE_ADDR v, int pid)
{
write_register (PC_REGNUM, v);
}
CORE_ADDR
-h8500_read_fp ()
+h8500_read_fp (void)
{
return read_register (PR6_REGNUM);
}
void
-h8500_write_fp (v)
- CORE_ADDR v;
+h8500_write_fp (CORE_ADDR v)
{
write_register (PR6_REGNUM, v);
}
void
-_initialize_h8500_tdep ()
+_initialize_h8500_tdep (void)
{
tm_print_insn = print_insn_h8500;
/* check for the existance of a file, given its full pathname */
int
-file_exists (filename)
- char *filename;
+file_exists (char *filename)
{
if (filename)
return (access (filename, F_OK) == 0);
/* Translate from the "hp_language" enumeration in hp-symtab.h
used in the debug info to gdb's generic enumeration in defs.h. */
static enum language
-trans_lang (in_lang)
- enum hp_language in_lang;
+trans_lang (enum hp_language in_lang)
{
if (in_lang == HP_LANGUAGE_C)
return language_c;
Return value: 1 if ok, 0 if not */
int
-hpread_call_pxdb (file_name)
- char *file_name;
+hpread_call_pxdb (char *file_name)
{
char *p;
int status;
and the file therefore needs to be re-loaded. Otherwise
return 0. */
int
-hpread_pxdb_needed (sym_bfd)
- bfd *sym_bfd;
+hpread_pxdb_needed (bfd *sym_bfd)
{
asection *pinfo_section, *debug_section, *header_section;
unsigned int do_pxdb;
If so, call pxdb. */
void
-do_pxdb (sym_bfd)
- bfd *sym_bfd;
+do_pxdb (bfd *sym_bfd)
{
/* The following code is HP-specific. The "right" way of
doing this is unknown, but we bet would involve a target-
/* Set up psymtab symbol index stuff */
static void
-init_pst_syms ()
+init_pst_syms (void)
{
pst_syms_count = 0;
pst_syms_size = 20;
/* Clean up psymtab symbol index stuff */
static void
-clear_pst_syms ()
+clear_pst_syms (void)
{
pst_syms_count = 0;
pst_syms_size = 0;
/* Add information about latest psymtab to symbol index table */
static void
-record_pst_syms (start_sym, end_sym)
- int start_sym;
- int end_sym;
+record_pst_syms (int start_sym, int end_sym)
{
if (++pst_syms_count > pst_syms_size)
{
Return 0 => not found */
static int
-find_next_pst_start (index)
- int index;
+find_next_pst_start (int index)
{
int i;
Return 0 => not found */
static int
-find_next_file_isym (index, qFD, curr_fd, pxdb_header_p)
- int index;
- quick_file_entry *qFD;
- int curr_fd;
- PXDB_header_ptr pxdb_header_p;
+find_next_file_isym (int index, quick_file_entry *qFD, int curr_fd,
+ PXDB_header_ptr pxdb_header_p)
{
while (VALID_CURR_FILE)
{
Return 0 => not found */
static int
-find_next_proc_isym (index, qPD, curr_pd, pxdb_header_p)
- int index;
- quick_procedure_entry *qPD;
- int curr_pd;
- PXDB_header_ptr pxdb_header_p;
+find_next_proc_isym (int index, quick_procedure_entry *qPD, int curr_pd,
+ PXDB_header_ptr pxdb_header_p)
{
while (VALID_CURR_PROC)
{
Return 0 => not found */
static int
-find_next_module_isym (index, qMD, curr_md, pxdb_header_p)
- int index;
- quick_module_entry *qMD;
- int curr_md;
- PXDB_header_ptr pxdb_header_p;
+find_next_module_isym (int index, quick_module_entry *qMD, int curr_md,
+ PXDB_header_ptr pxdb_header_p)
{
while (VALID_CURR_MODULE)
{
/* Get appropriate header, based on pxdb type.
Return value: 1 if ok, 0 if not */
int
-hpread_get_header (objfile, pxdb_header_p)
- struct objfile *objfile;
- PXDB_header_ptr pxdb_header_p;
+hpread_get_header (struct objfile *objfile, PXDB_header_ptr pxdb_header_p)
{
asection *pinfo_section, *debug_section, *header_section;
FIXME, there should be a cleaner peephole into the BFD environment
here. */
void
-hpread_symfile_init (objfile)
- struct objfile *objfile;
+hpread_symfile_init (struct objfile *objfile)
{
asection *vt_section, *slt_section, *lntt_section, *gntt_section;
opposed to a shared lib or dynamically loaded file). */
void
-hpread_build_psymtabs (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+hpread_build_psymtabs (struct objfile *objfile, int mainline)
{
#ifdef DUMPING
objfile struct from the global list of known objfiles. */
void
-hpread_symfile_finish (objfile)
- struct objfile *objfile;
+hpread_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_private != NULL)
{
/* Various small functions to get entries in the debug symbol sections. */
union dnttentry *
-hpread_get_lntt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_lntt (int index, struct objfile *objfile)
{
return (union dnttentry *)
&(LNTT (objfile)[(index * sizeof (struct dntt_type_block))]);
}
static union dnttentry *
-hpread_get_gntt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_gntt (int index, struct objfile *objfile)
{
return (union dnttentry *)
&(GNTT (objfile)[(index * sizeof (struct dntt_type_block))]);
}
union sltentry *
-hpread_get_slt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_slt (int index, struct objfile *objfile)
{
return (union sltentry *) &(SLT (objfile)[index * sizeof (union sltentry)]);
}
the existance of DNTT_TYPE_FUNCTION symbols. */
static unsigned long
-hpread_get_textlow (global, index, objfile, symcount)
- int global;
- int index;
- struct objfile *objfile;
- int symcount;
+hpread_get_textlow (int global, int index, struct objfile *objfile,
+ int symcount)
{
union dnttentry *dn_bufp;
struct minimal_symbol *msymbol;
(normal). */
static struct partial_symtab *
-hpread_start_psymtab (objfile,
- filename, textlow, ldsymoff, global_syms, static_syms)
- struct objfile *objfile;
- char *filename;
- CORE_ADDR textlow;
- int ldsymoff;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+hpread_start_psymtab (struct objfile *objfile, char *filename,
+ CORE_ADDR textlow, int ldsymoff,
+ struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
int offset = ANOFFSET (objfile->section_offsets, SECT_OFF_TEXT (objfile));
extern void hpread_psymtab_to_symtab ();
FIXME: List variables and peculiarities of same. */
static struct partial_symtab *
-hpread_end_psymtab (pst, include_list, num_includes, capping_symbol_offset,
- capping_text, dependency_list, number_dependencies)
- struct partial_symtab *pst;
- char **include_list;
- int num_includes;
- int capping_symbol_offset;
- CORE_ADDR capping_text;
- struct partial_symtab **dependency_list;
- int number_dependencies;
+hpread_end_psymtab (struct partial_symtab *pst, char **include_list,
+ int num_includes, int capping_symbol_offset,
+ CORE_ADDR capping_text,
+ struct partial_symtab **dependency_list,
+ int number_dependencies)
{
int i;
struct objfile *objfile = pst->objfile;
/* Get the nesting depth for the source line identified by INDEX. */
static unsigned long
-hpread_get_scope_start (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_scope_start (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
/* Get the source line number the the line identified by INDEX. */
static unsigned long
-hpread_get_line (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_line (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
/* Find the code address associated with a given sltpointer */
static CORE_ADDR
-hpread_get_location (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_location (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
int i;
*/
int
-hpread_has_name (kind)
- enum dntt_entry_type kind;
+hpread_has_name (enum dntt_entry_type kind)
{
switch (kind)
{
table. */
static void
-hpread_psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+hpread_psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct cleanup *old_chain;
int i;
Be verbose about it if the user wants that. */
void
-hpread_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+hpread_psymtab_to_symtab (struct partial_symtab *pst)
{
/* Get out quick if given junk. */
if (!pst)
SECTION_OFFSETS are the relocation offsets which get added to each symbol. */
static struct symtab *
-hpread_expand_symtab (objfile, sym_offset, sym_size, text_offset, text_size,
- section_offsets, filename)
- struct objfile *objfile;
- int sym_offset;
- int sym_size;
- CORE_ADDR text_offset;
- int text_size;
- struct section_offsets *section_offsets;
- char *filename;
+hpread_expand_symtab (struct objfile *objfile, int sym_offset, int sym_size,
+ CORE_ADDR text_offset, int text_size,
+ struct section_offsets *section_offsets, char *filename)
{
char *namestring;
union dnttentry *dn_bufp;
/* Convert basic types from HP debug format into GDB internal format. */
static int
-hpread_type_translate (typep)
- dnttpointer typep;
+hpread_type_translate (dnttpointer typep)
{
if (!typep.dntti.immediate)
{
*/
static struct type **
-hpread_lookup_type (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_lookup_type (dnttpointer hp_type, struct objfile *objfile)
{
unsigned old_len;
int index = hp_type.dnttp.index;
have it lying around. */
static struct type *
-hpread_alloc_type (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_alloc_type (dnttpointer hp_type, struct objfile *objfile)
{
struct type **type_addr;
/* Read a native enumerated type and return it in GDB internal form. */
static struct type *
-hpread_read_enum_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_enum_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
struct pending **symlist, *osyms, *syms;
/* Read and internalize a native function debug symbol. */
static struct type *
-hpread_read_function_type (hp_type, dn_bufp, objfile, newblock)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
- int newblock;
+hpread_read_function_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile, int newblock)
{
struct type *type, *type1;
struct pending *syms;
* volatile, please leave it this way.
*/
static struct type *
-hpread_read_doc_function_type (hp_type, dn_bufp, objfile, newblock)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
- int newblock;
+hpread_read_doc_function_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile, int newblock)
{
struct type *type, *type1;
struct pending *syms;
*/
static struct type *
-hpread_read_struct_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_struct_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
/* The data members get linked together into a list of struct nextfield's */
struct nextfield
Void return */
static void
-fix_static_member_physnames (type, class_name, objfile)
- struct type *type;
- char *class_name;
- struct objfile *objfile;
+fix_static_member_physnames (struct type *type, char *class_name,
+ struct objfile *objfile)
{
int i;
* Void return. */
static void
-fixup_class_method_type (class, method, objfile)
- struct type *class;
- struct type *method;
- struct objfile *objfile;
+fixup_class_method_type (struct type *class, struct type *method,
+ struct objfile *objfile)
{
int i, j, k;
* This is called from hpread_type_lookup().
*/
static struct type *
-hpread_get_nth_template_arg (objfile, n)
- struct objfile *objfile;
- int n;
+hpread_get_nth_template_arg (struct objfile *objfile, int n)
{
if (current_template != NULL)
return TYPE_TEMPLATE_ARG (current_template, n).type;
/* Read in and internalize a TEMPL_ARG (template arg) symbol. */
static struct type *
-hpread_read_templ_arg_type (hp_type, dn_bufp, objfile, name)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
- char *name;
+hpread_read_templ_arg_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile, char *name)
{
struct type *type;
/* Read in and internalize a set debug symbol. */
static struct type *
-hpread_read_set_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_set_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
/* Read in and internalize an array debug symbol. */
static struct type *
-hpread_read_array_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_array_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
/* Read in and internalize a subrange debug symbol. */
static struct type *
-hpread_read_subrange_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_subrange_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
* a struct/class type, etc).
*/
static struct type *
-hpread_type_lookup (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_type_lookup (dnttpointer hp_type, struct objfile *objfile)
{
union dnttentry *dn_bufp;
struct type *tmp_type;
}
static sltpointer
-hpread_record_lines (subfile, s_idx, e_idx, objfile, offset)
- struct subfile *subfile;
- sltpointer s_idx, e_idx;
- struct objfile *objfile;
- CORE_ADDR offset;
+hpread_record_lines (struct subfile *subfile, sltpointer s_idx,
+ sltpointer e_idx, struct objfile *objfile,
+ CORE_ADDR offset)
{
union sltentry *sl_bufp;
* If "f" is not a member function, return NULL.
*/
char *
-class_of (functype)
- struct type *functype;
+class_of (struct type *functype)
{
struct type *first_param_type;
char *first_param_name;
*/
static void
-hpread_process_one_debug_symbol (dn_bufp, name, section_offsets, objfile,
- text_offset, text_size, filename,
- index, at_module_boundary_p
-)
- union dnttentry *dn_bufp;
- char *name;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
- CORE_ADDR text_offset;
- int text_size;
- char *filename;
- int index;
- int *at_module_boundary_p;
+hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
+ struct section_offsets *section_offsets,
+ struct objfile *objfile, CORE_ADDR text_offset,
+ int text_size, char *filename, int index,
+ int *at_module_boundary_p)
{
unsigned long desc;
int type;
static int
-hpread_get_scope_depth (dn_bufp, objfile, report_nested)
- union dnttentry *dn_bufp;
- struct objfile *objfile;
- int report_nested;
+hpread_get_scope_depth (union dnttentry *dn_bufp, struct objfile *objfile,
+ int report_nested)
{
register int index;
register union dnttentry *dn_tmp;
enclosing structure instead of relative to the union itself. */
static void
-hpread_adjust_bitoffsets (type, bits)
- struct type *type;
- int bits;
+hpread_adjust_bitoffsets (struct type *type, int bits)
{
register int i;
is a dnttpointer for the new field after all the skipped ones */
static dnttpointer
-hpread_get_next_skip_over_anon_unions (skip_fields, field, fieldp, objfile)
- int skip_fields;
- dnttpointer field;
- union dnttentry **fieldp;
- struct objfile *objfile;
+hpread_get_next_skip_over_anon_unions (int skip_fields, dnttpointer field,
+ union dnttentry **fieldp,
+ struct objfile *objfile)
{
struct type *anon_type;
register int i;
/* read the value of the u area from the hp-ux kernel */
void
-_initialize_hp300ux_nat ()
+_initialize_hp300ux_nat (void)
{
#ifndef HPUX_VERSION_5
nlist ("/hp-ux", nl);
- kernel_u_addr)
static void
-fetch_inferior_register (regno, regaddr)
- register int regno;
- register unsigned int regaddr;
+fetch_inferior_register (register int regno, register unsigned int regaddr)
{
#ifndef HPUX_VERSION_5
if (regno == PS_REGNUM)
}
static void
-store_inferior_register_1 (regno, regaddr, val)
- int regno;
- unsigned int regaddr;
- int val;
+store_inferior_register_1 (int regno, unsigned int regaddr, int val)
{
errno = 0;
ptrace (PT_WUAREA, inferior_pid, (PTRACE_ARG3_TYPE) regaddr, val, 0);
}
static void
-store_inferior_register (regno, regaddr)
- register int regno;
- register unsigned int regaddr;
+store_inferior_register (register int regno, register unsigned int regaddr)
{
#ifndef HPUX_VERSION_5
if (regno == PS_REGNUM)
}
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct user u;
register unsigned int ar0_offset;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- register int regno;
+store_inferior_registers (register int regno)
{
struct user u;
register unsigned int ar0_offset;
}
int
-getpagesize ()
+getpagesize (void)
{
return 4096;
}
/* Should call_function allocate stack space for a struct return? */
int
-hppa_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+hppa_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 2 * REGISTER_SIZE);
}
value. */
static int
-sign_extend (val, bits)
- unsigned val, bits;
+sign_extend (unsigned val, unsigned bits)
{
return (int) (val >> (bits - 1) ? (-1 << bits) | val : val);
}
/* For many immediate values the sign bit is the low bit! */
static int
-low_sign_extend (val, bits)
- unsigned val, bits;
+low_sign_extend (unsigned val, unsigned bits)
{
return (int) ((val & 0x1 ? (-1 << (bits - 1)) : 0) | val >> 1);
}
/* extract the immediate field from a ld{bhw}s instruction */
static int
-extract_5_load (word)
- unsigned word;
+extract_5_load (unsigned word)
{
return low_sign_extend (word >> 16 & MASK_5, 5);
}
/* extract the immediate field from a break instruction */
static unsigned
-extract_5r_store (word)
- unsigned word;
+extract_5r_store (unsigned word)
{
return (word & MASK_5);
}
/* extract the immediate field from a {sr}sm instruction */
static unsigned
-extract_5R_store (word)
- unsigned word;
+extract_5R_store (unsigned word)
{
return (word >> 16 & MASK_5);
}
/* extract a 14 bit immediate field */
static int
-extract_14 (word)
- unsigned word;
+extract_14 (unsigned word)
{
return low_sign_extend (word & MASK_14, 14);
}
/* deposit a 14 bit constant in a word */
static unsigned
-deposit_14 (opnd, word)
- int opnd;
- unsigned word;
+deposit_14 (int opnd, unsigned word)
{
unsigned sign = (opnd < 0 ? 1 : 0);
/* extract a 21 bit constant */
static int
-extract_21 (word)
- unsigned word;
+extract_21 (unsigned word)
{
int val;
the low 21 bits of opnd are relevant */
static unsigned
-deposit_21 (opnd, word)
- unsigned opnd, word;
+deposit_21 (unsigned opnd, unsigned word)
{
unsigned val = 0;
19 bit signed value. */
static int
-extract_17 (word)
- unsigned word;
+extract_17 (unsigned word)
{
return sign_extend (GET_FIELD (word, 19, 28) |
GET_FIELD (word, 29, 29) << 10 |
larger than the first, and zero if they are equal. */
static int
-compare_unwind_entries (arg1, arg2)
- const void *arg1;
- const void *arg2;
+compare_unwind_entries (const void *arg1, const void *arg2)
{
const struct unwind_table_entry *a = arg1;
const struct unwind_table_entry *b = arg2;
}
static void
-internalize_unwinds (objfile, table, section, entries, size, text_offset)
- struct objfile *objfile;
- struct unwind_table_entry *table;
- asection *section;
- unsigned int entries, size;
- CORE_ADDR text_offset;
+internalize_unwinds (struct objfile *objfile, struct unwind_table_entry *table,
+ asection *section, unsigned int entries, unsigned int size,
+ CORE_ADDR text_offset)
{
/* We will read the unwind entries into temporary memory, then
fill in the actual unwind table. */
gets freed when the objfile is destroyed. */
static void
-read_unwind_info (objfile)
- struct objfile *objfile;
+read_unwind_info (struct objfile *objfile)
{
asection *unwind_sec, *stub_unwind_sec;
unsigned unwind_size, stub_unwind_size, total_size;
search of the unwind tables, we depend upon them to be sorted. */
struct unwind_table_entry *
-find_unwind_entry (pc)
- CORE_ADDR pc;
+find_unwind_entry (CORE_ADDR pc)
{
int first, middle, last;
struct objfile *objfile;
bizarre way in which someone (?) decided they wanted to handle
frame pointerless code in GDB. */
int
-hpread_adjust_stack_address (func_addr)
- CORE_ADDR func_addr;
+hpread_adjust_stack_address (CORE_ADDR func_addr)
{
struct unwind_table_entry *u;
kind. */
static int
-pc_in_interrupt_handler (pc)
- CORE_ADDR pc;
+pc_in_interrupt_handler (CORE_ADDR pc)
{
struct unwind_table_entry *u;
struct minimal_symbol *msym_us;
?!? Need to handle stubs which appear in PA64 code. */
static int
-pc_in_linker_stub (pc)
- CORE_ADDR pc;
+pc_in_linker_stub (CORE_ADDR pc)
{
int found_magic_instruction = 0;
int i;
}
static int
-find_return_regnum (pc)
- CORE_ADDR pc;
+find_return_regnum (CORE_ADDR pc)
{
struct unwind_table_entry *u;
/* Return size of frame, or -1 if we should use a frame pointer. */
static int
-find_proc_framesize (pc)
- CORE_ADDR pc;
+find_proc_framesize (CORE_ADDR pc)
{
struct unwind_table_entry *u;
struct minimal_symbol *msym_us;
static int rp_saved (CORE_ADDR);
static int
-rp_saved (pc)
- CORE_ADDR pc;
+rp_saved (CORE_ADDR pc)
{
struct unwind_table_entry *u;
}
\f
int
-frameless_function_invocation (frame)
- struct frame_info *frame;
+frameless_function_invocation (struct frame_info *frame)
{
struct unwind_table_entry *u;
}
CORE_ADDR
-saved_pc_after_call (frame)
- struct frame_info *frame;
+saved_pc_after_call (struct frame_info *frame)
{
int ret_regnum;
CORE_ADDR pc;
}
\f
CORE_ADDR
-hppa_frame_saved_pc (frame)
- struct frame_info *frame;
+hppa_frame_saved_pc (struct frame_info *frame)
{
CORE_ADDR pc = get_frame_pc (frame);
struct unwind_table_entry *u;
in a system call. */
void
-init_extra_frame_info (fromleaf, frame)
- int fromleaf;
- struct frame_info *frame;
+init_extra_frame_info (int fromleaf, struct frame_info *frame)
{
int flags;
int framesize;
a frame pointer calls code without a frame pointer. */
CORE_ADDR
-frame_chain (frame)
- struct frame_info *frame;
+frame_chain (struct frame_info *frame)
{
int my_framesize, caller_framesize;
struct unwind_table_entry *u;
was compiled with gcc. */
int
-hppa_frame_chain_valid (chain, thisframe)
- CORE_ADDR chain;
- struct frame_info *thisframe;
+hppa_frame_chain_valid (CORE_ADDR chain, struct frame_info *thisframe)
{
struct minimal_symbol *msym_us;
struct minimal_symbol *msym_start;
to be aligned to a 64-byte boundary. */
void
-push_dummy_frame (inf_status)
- struct inferior_status *inf_status;
+push_dummy_frame (struct inferior_status *inf_status)
{
CORE_ADDR sp, pc, pcspace;
register int regnum;
}
static void
-find_dummy_frame_regs (frame, frame_saved_regs)
- struct frame_info *frame;
- struct frame_saved_regs *frame_saved_regs;
+find_dummy_frame_regs (struct frame_info *frame,
+ struct frame_saved_regs *frame_saved_regs)
{
CORE_ADDR fp = frame->frame;
int i;
}
void
-hppa_pop_frame ()
+hppa_pop_frame (void)
{
register struct frame_info *frame = get_current_frame ();
register CORE_ADDR fp, npc, target_pc;
queue space registers. */
static int
-restore_pc_queue (fsr)
- struct frame_saved_regs *fsr;
+restore_pc_queue (struct frame_saved_regs *fsr)
{
CORE_ADDR pc = read_pc ();
CORE_ADDR new_pc = read_memory_integer (fsr->regs[PCOQ_HEAD_REGNUM],
to the callee, so we do that too. */
CORE_ADDR
-hppa_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+hppa_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
/* array of arguments' offsets */
int *offset = (int *) alloca (nargs * sizeof (int));
arguments into registers as needed by the ABI. */
CORE_ADDR
-hppa_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+hppa_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
/* array of arguments' offsets */
int *offset = (int *) alloca (nargs * sizeof (int));
gets the value from the stack rather than from the buffer where all the
registers were saved when the function called completed. */
value_ptr
-hppa_value_returned_from_stack (valtype, addr)
- register struct type *valtype;
- CORE_ADDR addr;
+hppa_value_returned_from_stack (register struct type *valtype, CORE_ADDR addr)
{
register value_ptr val;
man entry for shl_findsym */
CORE_ADDR
-find_stub_with_shl_get (function, handle)
- struct minimal_symbol *function;
- CORE_ADDR handle;
+find_stub_with_shl_get (struct minimal_symbol *function, CORE_ADDR handle)
{
struct symbol *get_sym, *symbol2;
struct minimal_symbol *buff_minsym, *msymbol;
Please contact Jeff Law (law@cygnus.com) before changing this code. */
CORE_ADDR
-hppa_fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR pc;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+hppa_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
+ value_ptr *args, struct type *type, int gcc_p)
{
CORE_ADDR dyncall_addr;
struct minimal_symbol *msymbol;
We'll return zero in that case, rather than attempting to read it
and cause a warning. */
CORE_ADDR
-target_read_fp (pid)
- int pid;
+target_read_fp (int pid)
{
int flags = read_register (FLAGS_REGNUM);
bits. */
CORE_ADDR
-target_read_pc (pid)
- int pid;
+target_read_pc (int pid)
{
int flags = read_register_pid (FLAGS_REGNUM, pid);
PC value into %r31. */
void
-target_write_pc (v, pid)
- CORE_ADDR v;
- int pid;
+target_write_pc (CORE_ADDR v, int pid)
{
int flags = read_register_pid (FLAGS_REGNUM, pid);
alignment required by their fields. */
static int
-hppa_alignof (type)
- struct type *type;
+hppa_alignof (struct type *type)
{
int max_align, align, i;
CHECK_TYPEDEF (type);
/* Print the register regnum, or all registers if regnum is -1 */
void
-pa_do_registers_info (regnum, fpregs)
- int regnum;
- int fpregs;
+pa_do_registers_info (int regnum, int fpregs)
{
char raw_regs[REGISTER_BYTES];
int i;
/********** new function ********************/
void
-pa_do_strcat_registers_info (regnum, fpregs, stream, precision)
- int regnum;
- int fpregs;
- struct ui_file *stream;
- enum precision_type precision;
+pa_do_strcat_registers_info (int regnum, int fpregs, struct ui_file *stream,
+ enum precision_type precision)
{
char raw_regs[REGISTER_BYTES];
int i;
Note that reg_val is really expected to be an array of longs,
with two elements. */
static void
-pa_register_look_aside (raw_regs, regnum, raw_val)
- char *raw_regs;
- int regnum;
- long *raw_val;
+pa_register_look_aside (char *raw_regs, int regnum, long *raw_val)
{
static int know_which = 0; /* False */
/* "Info all-reg" command */
static void
-pa_print_registers (raw_regs, regnum, fpregs)
- char *raw_regs;
- int regnum;
- int fpregs;
+pa_print_registers (char *raw_regs, int regnum, int fpregs)
{
int i, j;
/* Alas, we are compiled so that "long long" is 32 bits */
/************* new function ******************/
static void
-pa_strcat_registers (raw_regs, regnum, fpregs, stream)
- char *raw_regs;
- int regnum;
- int fpregs;
- struct ui_file *stream;
+pa_strcat_registers (char *raw_regs, int regnum, int fpregs,
+ struct ui_file *stream)
{
int i, j;
long raw_val[2]; /* Alas, we are compiled so that "long long" is 32 bits */
}
static void
-pa_print_fp_reg (i)
- int i;
+pa_print_fp_reg (int i)
{
char raw_buffer[MAX_REGISTER_RAW_SIZE];
char virtual_buffer[MAX_REGISTER_VIRTUAL_SIZE];
/*************** new function ***********************/
static void
-pa_strcat_fp_reg (i, stream, precision)
- int i;
- struct ui_file *stream;
- enum precision_type precision;
+pa_strcat_fp_reg (int i, struct ui_file *stream, enum precision_type precision)
{
char raw_buffer[MAX_REGISTER_RAW_SIZE];
char virtual_buffer[MAX_REGISTER_VIRTUAL_SIZE];
just shared library trampolines (import, export). */
int
-in_solib_call_trampoline (pc, name)
- CORE_ADDR pc;
- char *name;
+in_solib_call_trampoline (CORE_ADDR pc, char *name)
{
struct minimal_symbol *minsym;
struct unwind_table_entry *u;
just shared library trampolines (import, export). */
int
-in_solib_return_trampoline (pc, name)
- CORE_ADDR pc;
- char *name;
+in_solib_return_trampoline (CORE_ADDR pc, char *name)
{
struct unwind_table_entry *u;
used in dynamic executables. */
CORE_ADDR
-skip_trampoline_code (pc, name)
- CORE_ADDR pc;
- char *name;
+skip_trampoline_code (CORE_ADDR pc, char *name)
{
long orig_pc = pc;
long prev_inst, curr_inst, loc;
This only handles instructions commonly found in prologues. */
static int
-prologue_inst_adjust_sp (inst)
- unsigned long inst;
+prologue_inst_adjust_sp (unsigned long inst)
{
/* This must persist across calls. */
static int save_high21;
/* Return nonzero if INST is a branch of some kind, else return zero. */
static int
-is_branch (inst)
- unsigned long inst;
+is_branch (unsigned long inst)
{
switch (inst >> 26)
{
zero it INST does not save a GR. */
static int
-inst_saves_gr (inst)
- unsigned long inst;
+inst_saves_gr (unsigned long inst)
{
/* Does it look like a stw? */
if ((inst >> 26) == 0x1a || (inst >> 26) == 0x1b
FIXME: What about argument stores with the HP compiler in ANSI mode? */
static int
-inst_saves_fr (inst)
- unsigned long inst;
+inst_saves_fr (unsigned long inst)
{
/* is this an FSTD ? */
if ((inst & 0xfc00dfc0) == 0x2c001200)
CORE_ADDR
-skip_prologue_hard_way (pc)
- CORE_ADDR pc;
+skip_prologue_hard_way (CORE_ADDR pc)
{
char buf[4];
CORE_ADDR orig_pc = pc;
we can determine it from the debug symbols. Else return zero. */
static CORE_ADDR
-after_prologue (pc)
- CORE_ADDR pc;
+after_prologue (CORE_ADDR pc)
{
struct symtab_and_line sal;
CORE_ADDR func_addr, func_end;
stuff some day. */
CORE_ADDR
-hppa_skip_prologue (pc)
- CORE_ADDR pc;
+hppa_skip_prologue (CORE_ADDR pc)
{
unsigned long inst;
int offset;
the address we return for it IS the sp for the next frame. */
void
-hppa_frame_find_saved_regs (frame_info, frame_saved_regs)
- struct frame_info *frame_info;
- struct frame_saved_regs *frame_saved_regs;
+hppa_frame_find_saved_regs (struct frame_info *frame_info,
+ struct frame_saved_regs *frame_saved_regs)
{
CORE_ADDR pc;
struct unwind_table_entry *u;
0 => success
1 => failure */
int
-setup_d_pid_in_inferior ()
+setup_d_pid_in_inferior (void)
{
CORE_ADDR anaddr;
struct minimal_symbol *msymbol;
1 => success */
static int
-initialize_hp_cxx_exception_support ()
+initialize_hp_cxx_exception_support (void)
{
struct symtabs_and_lines sals;
struct cleanup *old_chain;
address was found. */
struct symtab_and_line *
-child_enable_exception_callback (kind, enable)
- enum exception_event_kind kind;
- int enable;
+child_enable_exception_callback (enum exception_event_kind kind, int enable)
{
char buf[4];
and where it will be caught. More information may be reported
in the future */
struct exception_event_record *
-child_get_current_exception_event ()
+child_get_current_exception_event (void)
{
CORE_ADDR event_kind;
CORE_ADDR throw_addr;
}
static void
-unwind_command (exp, from_tty)
- char *exp;
- int from_tty;
+unwind_command (char *exp, int from_tty)
{
CORE_ADDR address;
struct unwind_table_entry *u;
here, that's what counts, as core gdb is the one which is
putting the BPT instruction in and taking it out. */
int
-hppa_prepare_to_proceed ()
+hppa_prepare_to_proceed (void)
{
pid_t old_thread;
pid_t current_thread;
#endif /* PREPARE_TO_PROCEED */
void
-hppa_skip_permanent_breakpoint ()
+hppa_skip_permanent_breakpoint (void)
{
/* To step over a breakpoint instruction on the PA takes some
fiddling with the instruction address queue.
}
void
-_initialize_hppa_tdep ()
+_initialize_hppa_tdep (void)
{
tm_print_insn = print_insn_hppa;
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
register unsigned int regaddr;
char buf[MAX_REGISTER_RAW_SIZE];
/* Fetch all registers, or just one, from the child process. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno == -1)
for (regno = 0; regno < NUM_REGS; regno++)
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
#define PT_PROT 21
int
-hppa_set_watchpoint (addr, len, flag)
- int addr, len, flag;
+hppa_set_watchpoint (int addr, int len, int flag)
{
int pt_args[3];
pt_args[0] = addr;
static void fetch_register (int);
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno == -1)
for (regno = 0; regno < NUM_REGS; regno++)
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
/* Fetch a register's value from the process's U area. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
char buf[MAX_REGISTER_RAW_SIZE];
unsigned int addr, len, offset;
void
-child_post_follow_inferior_by_clone ()
+child_post_follow_inferior_by_clone (void)
{
int status;
void
-child_post_follow_vfork (parent_pid, followed_parent, child_pid, followed_child)
- int parent_pid;
- int followed_parent;
- int child_pid;
- int followed_child;
+child_post_follow_vfork (int parent_pid, int followed_parent, int child_pid,
+ int followed_child)
{
/* Are we a debugger that followed the parent of a vfork? If so,
then recall that the child's vfork event was delivered to us
/* Format a process id, given PID. Be sure to terminate
this with a null--it's going to be printed via a "%s". */
char *
-child_pid_to_str (pid)
- pid_t pid;
+child_pid_to_str (pid_t pid)
{
/* Static because address returned */
static char buf[30];
Note: This is a core-gdb tid, not the actual system tid.
See infttrace.c for details. */
char *
-hppa_tid_to_str (tid)
- pid_t tid;
+hppa_tid_to_str (pid_t tid)
{
/* Static because address returned */
static char buf[30];
child_acknowledge_created_inferior.) */
int
-parent_attach_all (pid, addr, data)
- int pid;
- PTRACE_ARG3_TYPE addr;
- int data;
+parent_attach_all (int pid, PTRACE_ARG3_TYPE addr, int data)
{
int pt_status = 0;
#endif
int
-hppa_require_attach (pid)
- int pid;
+hppa_require_attach (int pid)
{
int pt_status;
CORE_ADDR pc;
}
int
-hppa_require_detach (pid, signal)
- int pid;
- int signal;
+hppa_require_detach (int pid, int signal)
{
errno = 0;
call_ptrace (PT_DETACH, pid, (PTRACE_ARG3_TYPE) 1, signal);
dummy versions, which perform no useful work. */
void
-hppa_enable_page_protection_events (pid)
- int pid;
+hppa_enable_page_protection_events (int pid)
{
}
void
-hppa_disable_page_protection_events (pid)
- int pid;
+hppa_disable_page_protection_events (int pid)
{
}
int
-hppa_insert_hw_watchpoint (pid, start, len, type)
- int pid;
- CORE_ADDR start;
- LONGEST len;
- int type;
+hppa_insert_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len, int type)
{
error ("Hardware watchpoints not implemented on this platform.");
}
int
-hppa_remove_hw_watchpoint (pid, start, len, type)
- int pid;
- CORE_ADDR start;
- LONGEST len;
- enum bptype type;
+hppa_remove_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len,
+ enum bptype type)
{
error ("Hardware watchpoints not implemented on this platform.");
}
int
-hppa_can_use_hw_watchpoint (type, cnt, ot)
- enum bptype type;
- int cnt;
- enum bptype ot;
+hppa_can_use_hw_watchpoint (enum bptype type, int cnt, enum bptype ot)
{
return 0;
}
int
-hppa_range_profitable_for_hw_watchpoint (pid, start, len)
- int pid;
- CORE_ADDR start;
- LONGEST len;
+hppa_range_profitable_for_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len)
{
error ("Hardware watchpoints not implemented on this platform.");
}
char *
-hppa_pid_or_tid_to_str (id)
- pid_t id;
+hppa_pid_or_tid_to_str (pid_t id)
{
/* In the ptrace world, there are only processes. */
return child_pid_to_str (id);
hppa-tdep.c. */
pid_t
-hppa_switched_threads (pid)
- pid_t pid;
+hppa_switched_threads (pid_t pid)
{
return (pid_t) 0;
}
void
-hppa_ensure_vforking_parent_remains_stopped (pid)
- int pid;
+hppa_ensure_vforking_parent_remains_stopped (int pid)
{
/* This assumes that the vforked parent is presently stopped, and
that the vforked child has just delivered its first exec event.
}
int
-hppa_resume_execd_vforking_child_to_get_parent_vfork ()
+hppa_resume_execd_vforking_child_to_get_parent_vfork (void)
{
return 1; /* Yes, the child must be resumed. */
}
void
-require_notification_of_events (pid)
- int pid;
+require_notification_of_events (int pid)
{
#if defined(PT_SET_EVENT_MASK)
int pt_status;
}
void
-require_notification_of_exec_events (pid)
- int pid;
+require_notification_of_exec_events (int pid)
{
#if defined(PT_SET_EVENT_MASK)
int pt_status;
ID of the child process, after the debugger has forked. */
void
-child_acknowledge_created_inferior (pid)
- int pid;
+child_acknowledge_created_inferior (int pid)
{
/* We need a memory home for a constant. */
int tc_magic_parent = PT_VERSION;
}
void
-child_post_startup_inferior (pid)
- int pid;
+child_post_startup_inferior (int pid)
{
require_notification_of_events (pid);
}
void
-child_post_attach (pid)
- int pid;
+child_post_attach (int pid)
{
require_notification_of_events (pid);
}
int
-child_insert_fork_catchpoint (pid)
- int pid;
+child_insert_fork_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_remove_fork_catchpoint (pid)
- int pid;
+child_remove_fork_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_insert_vfork_catchpoint (pid)
- int pid;
+child_insert_vfork_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_remove_vfork_catchpoint (pid)
- int pid;
+child_remove_vfork_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_has_forked (pid, childpid)
- int pid;
- int *childpid;
+child_has_forked (int pid, int *childpid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_GET_PROCESS_STATE)
}
int
-child_has_vforked (pid, childpid)
- int pid;
- int *childpid;
+child_has_vforked (int pid, int *childpid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_GET_PROCESS_STATE)
}
int
-child_can_follow_vfork_prior_to_exec ()
+child_can_follow_vfork_prior_to_exec (void)
{
/* ptrace doesn't allow this. */
return 0;
}
int
-child_insert_exec_catchpoint (pid)
- int pid;
+child_insert_exec_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_remove_exec_catchpoint (pid)
- int pid;
+child_remove_exec_catchpoint (int pid)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_SET_EVENT_MASK)
}
int
-child_has_execd (pid, execd_pathname)
- int pid;
- char **execd_pathname;
+child_has_execd (int pid, char **execd_pathname)
{
/* This request is only available on HPUX 10.0 and later. */
#if !defined(PT_GET_PROCESS_STATE)
}
int
-child_reported_exec_events_per_exec_call ()
+child_reported_exec_events_per_exec_call (void)
{
return 2; /* ptrace reports the event twice per call. */
}
int
-child_has_syscall_event (pid, kind, syscall_id)
- int pid;
- enum target_waitkind *kind;
- int *syscall_id;
+child_has_syscall_event (int pid, enum target_waitkind *kind, int *syscall_id)
{
/* This request is only available on HPUX 10.30 and later, via
the ttrace interface. */
}
char *
-child_pid_to_exec_file (pid)
- int pid;
+child_pid_to_exec_file (int pid)
{
static char exec_file_buffer[1024];
int pt_status;
}
void
-pre_fork_inferior ()
+pre_fork_inferior (void)
{
int status;
return "TRUE". */
int
-child_thread_alive (pid)
- int pid;
+child_thread_alive (int pid)
{
return 1;
}
*/
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
* On mach3 all registers are always saved in one call.
*/
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
FIXME, there should be a cleaner peephole into the BFD environment here. */
void
-hpread_symfile_init (objfile)
- struct objfile *objfile;
+hpread_symfile_init (struct objfile *objfile)
{
asection *vt_section, *slt_section, *lntt_section, *gntt_section;
table (as opposed to a shared lib or dynamically loaded file). */
void
-hpread_build_psymtabs (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+hpread_build_psymtabs (struct objfile *objfile, int mainline)
{
char *namestring;
int past_first_source_file = 0;
objfile struct from the global list of known objfiles. */
void
-hpread_symfile_finish (objfile)
- struct objfile *objfile;
+hpread_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_private != NULL)
{
/* Various small functions to get entries in the debug symbol sections. */
static union dnttentry *
-hpread_get_lntt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_lntt (int index, struct objfile *objfile)
{
return (union dnttentry *)
&(LNTT (objfile)[(index * sizeof (struct dntt_type_block))]);
}
static union dnttentry *
-hpread_get_gntt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_gntt (int index, struct objfile *objfile)
{
return (union dnttentry *)
&(GNTT (objfile)[(index * sizeof (struct dntt_type_block))]);
}
static union sltentry *
-hpread_get_slt (index, objfile)
- int index;
- struct objfile *objfile;
+hpread_get_slt (int index, struct objfile *objfile)
{
return (union sltentry *) &(SLT (objfile)[index * sizeof (union sltentry)]);
}
the existance of DNTT_TYPE_FUNCTION symbols. */
static unsigned long
-hpread_get_textlow (global, index, objfile)
- int global;
- int index;
- struct objfile *objfile;
+hpread_get_textlow (int global, int index, struct objfile *objfile)
{
union dnttentry *dn_bufp;
struct minimal_symbol *msymbol;
/* Get the nesting depth for the source line identified by INDEX. */
static unsigned long
-hpread_get_depth (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_depth (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
/* Get the source line number the the line identified by INDEX. */
static unsigned long
-hpread_get_line (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_line (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
}
static CORE_ADDR
-hpread_get_location (index, objfile)
- sltpointer index;
- struct objfile *objfile;
+hpread_get_location (sltpointer index, struct objfile *objfile)
{
union sltentry *sl_bufp;
int i;
it, else return 0. */
static int
-hpread_has_name (kind)
- enum dntt_entry_type kind;
+hpread_has_name (enum dntt_entry_type kind)
{
switch (kind)
{
(normal). */
static struct partial_symtab *
-hpread_start_psymtab (objfile, filename, textlow, ldsymoff, global_syms,
- static_syms)
- struct objfile *objfile;
- char *filename;
- CORE_ADDR textlow;
- int ldsymoff;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+hpread_start_psymtab (struct objfile *objfile, char *filename,
+ CORE_ADDR textlow, int ldsymoff,
+ struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
struct partial_symtab *result =
start_psymtab_common (objfile, section_offsets,
FIXME: List variables and peculiarities of same. */
static struct partial_symtab *
-hpread_end_psymtab (pst, include_list, num_includes, capping_symbol_offset,
- capping_text, dependency_list, number_dependencies)
- struct partial_symtab *pst;
- char **include_list;
- int num_includes;
- int capping_symbol_offset;
- CORE_ADDR capping_text;
- struct partial_symtab **dependency_list;
- int number_dependencies;
+hpread_end_psymtab (struct partial_symtab *pst, char **include_list,
+ int num_includes, int capping_symbol_offset,
+ CORE_ADDR capping_text,
+ struct partial_symtab **dependency_list,
+ int number_dependencies)
{
int i;
struct objfile *objfile = pst->objfile;
table. */
static void
-hpread_psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+hpread_psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct cleanup *old_chain;
int i;
Be verbose about it if the user wants that. */
static void
-hpread_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+hpread_psymtab_to_symtab (struct partial_symtab *pst)
{
/* Get out quick if given junk. */
if (!pst)
SECTION_OFFSETS are the relocation offsets which get added to each symbol. */
static struct symtab *
-hpread_expand_symtab (objfile, sym_offset, sym_size, text_offset, text_size,
- section_offsets, filename)
- struct objfile *objfile;
- int sym_offset;
- int sym_size;
- CORE_ADDR text_offset;
- int text_size;
- struct section_offsets *section_offsets;
- char *filename;
+hpread_expand_symtab (struct objfile *objfile, int sym_offset, int sym_size,
+ CORE_ADDR text_offset, int text_size,
+ struct section_offsets *section_offsets, char *filename)
{
char *namestring;
union dnttentry *dn_bufp;
/* Convert basic types from HP debug format into GDB internal format. */
static int
-hpread_type_translate (typep)
- dnttpointer typep;
+hpread_type_translate (dnttpointer typep)
{
if (!typep.dntti.immediate)
abort ();
/* Return the type associated with the index found in HP_TYPE. */
static struct type **
-hpread_lookup_type (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_lookup_type (dnttpointer hp_type, struct objfile *objfile)
{
unsigned old_len;
int index = hp_type.dnttp.index;
have it lying around. */
static struct type *
-hpread_alloc_type (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_alloc_type (dnttpointer hp_type, struct objfile *objfile)
{
struct type **type_addr;
/* Read a native enumerated type and return it in GDB internal form. */
static struct type *
-hpread_read_enum_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_enum_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
struct pending **symlist, *osyms, *syms;
/* Read and internalize a native function debug symbol. */
static struct type *
-hpread_read_function_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_function_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type, *type1;
struct pending **symlist, *osyms, *syms;
/* Read in and internalize a structure definition. */
static struct type *
-hpread_read_struct_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_struct_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct nextfield
{
/* Read in and internalize a set debug symbol. */
static struct type *
-hpread_read_set_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_set_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
/* Read in and internalize an array debug symbol. */
static struct type *
-hpread_read_array_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_array_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
union dnttentry save;
/* Read in and internalize a subrange debug symbol. */
static struct type *
-hpread_read_subrange_type (hp_type, dn_bufp, objfile)
- dnttpointer hp_type;
- union dnttentry *dn_bufp;
- struct objfile *objfile;
+hpread_read_subrange_type (dnttpointer hp_type, union dnttentry *dn_bufp,
+ struct objfile *objfile)
{
struct type *type;
}
static struct type *
-hpread_type_lookup (hp_type, objfile)
- dnttpointer hp_type;
- struct objfile *objfile;
+hpread_type_lookup (dnttpointer hp_type, struct objfile *objfile)
{
union dnttentry *dn_bufp;
}
static sltpointer
-hpread_record_lines (subfile, s_idx, e_idx, objfile, offset)
- struct subfile *subfile;
- sltpointer s_idx, e_idx;
- struct objfile *objfile;
- CORE_ADDR offset;
+hpread_record_lines (struct subfile *subfile, sltpointer s_idx,
+ sltpointer e_idx, struct objfile *objfile,
+ CORE_ADDR offset)
{
union sltentry *sl_bufp;
/* Internalize one native debug symbol. */
static void
-hpread_process_one_debug_symbol (dn_bufp, name, section_offsets, objfile,
- text_offset, text_size, filename, index)
- union dnttentry *dn_bufp;
- char *name;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
- CORE_ADDR text_offset;
- int text_size;
- char *filename;
- int index;
+hpread_process_one_debug_symbol (union dnttentry *dn_bufp, char *name,
+ struct section_offsets *section_offsets,
+ struct objfile *objfile, CORE_ADDR text_offset,
+ int text_size, char *filename, int index)
{
unsigned long desc;
int type;
static struct cleanup *
-save_inferior_pid ()
+save_inferior_pid (void)
{
return make_cleanup (restore_inferior_pid, inferior_pid);
}
static void
-restore_inferior_pid (pid)
- int pid;
+restore_inferior_pid (int pid)
{
inferior_pid = pid;
}
static cma__t_int_tcb cached_tcb;
static int
-find_active_thread ()
+find_active_thread (void)
{
static cma__t_int_tcb tcb;
CORE_ADDR tcb_ptr;
static cma__t_int_tcb *find_tcb (int thread);
static cma__t_int_tcb *
-find_tcb (thread)
- int thread;
+find_tcb (int thread)
{
cma__t_known_object queue_header;
cma__t_queue *queue_ptr;
/* ARGSUSED */
static void
-hpux_thread_open (arg, from_tty)
- char *arg;
- int from_tty;
+hpux_thread_open (char *arg, int from_tty)
{
child_ops.to_open (arg, from_tty);
}
and wait for the trace-trap that results from attaching. */
static void
-hpux_thread_attach (args, from_tty)
- char *args;
- int from_tty;
+hpux_thread_attach (char *args, int from_tty)
{
child_ops.to_attach (args, from_tty);
started via the normal ptrace (PTRACE_TRACEME). */
static void
-hpux_thread_detach (args, from_tty)
- char *args;
- int from_tty;
+hpux_thread_detach (char *args, int from_tty)
{
child_ops.to_detach (args, from_tty);
}
for procfs. */
static void
-hpux_thread_resume (pid, step, signo)
- int pid;
- int step;
- enum target_signal signo;
+hpux_thread_resume (int pid, int step, enum target_signal signo)
{
struct cleanup *old_chain;
to a LWP id, and vice versa on the way out. */
static int
-hpux_thread_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+hpux_thread_wait (int pid, struct target_waitstatus *ourstatus)
{
int rtnval;
struct cleanup *old_chain;
};
static void
-hpux_thread_fetch_registers (regno)
- int regno;
+hpux_thread_fetch_registers (int regno)
{
cma__t_int_tcb tcb, *tcb_ptr;
struct cleanup *old_chain;
}
static void
-hpux_thread_store_registers (regno)
- int regno;
+hpux_thread_store_registers (int regno)
{
cma__t_int_tcb tcb, *tcb_ptr;
struct cleanup *old_chain;
debugged. */
static void
-hpux_thread_prepare_to_store ()
+hpux_thread_prepare_to_store (void)
{
child_ops.to_prepare_to_store ();
}
/* Print status information about what we're accessing. */
static void
-hpux_thread_files_info (ignore)
- struct target_ops *ignore;
+hpux_thread_files_info (struct target_ops *ignore)
{
child_ops.to_files_info (ignore);
}
static void
-hpux_thread_kill_inferior ()
+hpux_thread_kill_inferior (void)
{
child_ops.to_kill ();
}
static void
-hpux_thread_notice_signals (pid)
- int pid;
+hpux_thread_notice_signals (int pid)
{
child_ops.to_notice_signals (pid);
}
/* Fork an inferior process, and start debugging it with /proc. */
static void
-hpux_thread_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+hpux_thread_create_inferior (char *exec_file, char *allargs, char **env)
{
child_ops.to_create_inferior (exec_file, allargs, env);
static void (*target_new_objfile_chain) (struct objfile *);
void
-hpux_thread_new_objfile (objfile)
- struct objfile *objfile;
+hpux_thread_new_objfile (struct objfile *objfile)
{
struct minimal_symbol *ms;
/* Clean up after the inferior dies. */
static void
-hpux_thread_mourn_inferior ()
+hpux_thread_mourn_inferior (void)
{
child_ops.to_mourn_inferior ();
}
/* Mark our target-struct as eligible for stray "run" and "attach" commands. */
static int
-hpux_thread_can_run ()
+hpux_thread_can_run (void)
{
return child_suppress_run;
}
static int
-hpux_thread_alive (pid)
- int pid;
+hpux_thread_alive (int pid)
{
return 1;
}
static void
-hpux_thread_stop ()
+hpux_thread_stop (void)
{
child_ops.to_stop ();
}
/* Convert a pid to printable form. */
char *
-hpux_pid_to_str (pid)
- int pid;
+hpux_pid_to_str (int pid)
{
static char buf[100];
}
\f
static void
-init_hpux_thread_ops ()
+init_hpux_thread_ops (void)
{
hpux_thread_ops.to_shortname = "hpux-threads";
hpux_thread_ops.to_longname = "HPUX threads and pthread.";
}
void
-_initialize_hpux_thread ()
+_initialize_hpux_thread (void)
{
init_hpux_thread_ops ();
add_target (&hpux_thread_ops);
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
/* This isn't really an address. But ptrace thinks of it as one. */
CORE_ADDR regaddr;
Otherwise, REGNO specifies which register (so we can save time). */
void
-old_fetch_inferior_registers (regno)
- int regno;
+old_fetch_inferior_registers (int regno)
{
if (regno >= 0)
{
/* Store one register. */
static void
-store_register (regno)
- int regno;
+store_register (int regno)
{
/* This isn't really an address. But ptrace thinks of it as one. */
CORE_ADDR regaddr;
Otherwise, REGNO specifies which register (so we can save time). */
void
-old_store_inferior_registers (regno)
- int regno;
+old_store_inferior_registers (int regno)
{
if (regno >= 0)
{
};
void
-_initialize_i386_linux_nat ()
+_initialize_i386_linux_nat (void)
{
add_core_fns (&linux_elf_core_fns);
}
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
static volatile int mem_err = 0;
void
-set_mem_err ()
+set_mem_err (void)
{
mem_err = 1;
}
to mem_fault, they won't get restored, so there better not be any
saved). */
int
-get_char (addr)
- char *addr;
+get_char (char *addr)
{
return *addr;
}
void
-set_char (addr, val)
- char *addr;
- int val;
+set_char (char *addr, int val)
{
*addr = val;
}
codestream_fill(0) : codestream_buf[codestream_off++])
static unsigned char
-codestream_fill (peek_flag)
- int peek_flag;
+codestream_fill (int peek_flag)
{
codestream_addr = codestream_next_addr;
codestream_next_addr += CODESTREAM_BUFSIZ;
}
static void
-codestream_seek (place)
- CORE_ADDR place;
+codestream_seek (CORE_ADDR place)
{
codestream_next_addr = place / CODESTREAM_BUFSIZ;
codestream_next_addr *= CODESTREAM_BUFSIZ;
}
static void
-codestream_read (buf, count)
- unsigned char *buf;
- int count;
+codestream_read (unsigned char *buf, int count)
{
unsigned char *p;
int i;
/* next instruction is a jump, move to target */
static void
-i386_follow_jump ()
+i386_follow_jump (void)
{
unsigned char buf[4];
long delta;
*/
static long
-i386_get_frame_setup (pc)
- CORE_ADDR pc;
+i386_get_frame_setup (CORE_ADDR pc)
{
unsigned char op;
Can return -1, meaning no way to tell. */
int
-i386_frame_num_args (fi)
- struct frame_info *fi;
+i386_frame_num_args (struct frame_info *fi)
{
#if 1
return -1;
*/
void
-i386_frame_init_saved_regs (fip)
- struct frame_info *fip;
+i386_frame_init_saved_regs (struct frame_info *fip)
{
long locals = -1;
unsigned char op;
/* return pc of first real instruction */
int
-i386_skip_prologue (pc)
- int pc;
+i386_skip_prologue (int pc)
{
unsigned char op;
int i;
}
void
-i386_push_dummy_frame ()
+i386_push_dummy_frame (void)
{
CORE_ADDR sp = read_register (SP_REGNUM);
int regnum;
}
void
-i386_pop_frame ()
+i386_pop_frame (void)
{
struct frame_info *frame = get_current_frame ();
CORE_ADDR fp;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR sp, jb_addr;
for all three variants of SVR4 sigtramps. */
CORE_ADDR
-i386v4_sigtramp_saved_pc (frame)
- struct frame_info *frame;
+i386v4_sigtramp_saved_pc (struct frame_info *frame)
{
CORE_ADDR saved_pc_offset = 4;
char *name = NULL;
it is done for C too. */
char *
-sunpro_static_transform_name (name)
- char *name;
+sunpro_static_transform_name (char *name)
{
char *p;
if (IS_STATIC_TRANSFORM_NAME (name))
/* Stuff for WIN32 PE style DLL's but is pretty generic really. */
CORE_ADDR
-skip_trampoline_code (pc, name)
- CORE_ADDR pc;
- char *name;
+skip_trampoline_code (CORE_ADDR pc, char *name)
{
if (pc && read_memory_unsigned_integer (pc, 2) == 0x25ff) /* jmp *(dest) */
{
}
static int
-gdb_print_insn_i386 (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_i386 (bfd_vma memaddr, disassemble_info *info)
{
if (disassembly_flavor == att_flavor)
return print_insn_i386_att (memaddr, info);
command, and does that. */
static void
-set_disassembly_flavor_sfunc (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_disassembly_flavor_sfunc (char *args, int from_tty,
+ struct cmd_list_element *c)
{
set_disassembly_flavor ();
}
static void
-set_disassembly_flavor ()
+set_disassembly_flavor (void)
{
if (disassembly_flavor == att_flavor)
set_architecture_from_arch_mach (bfd_arch_i386, bfd_mach_i386_i386);
void
-_initialize_i386_tdep ()
+_initialize_i386_tdep (void)
{
/* Initialize the table saying where each register starts in the
register file. */
*/
int
-i386_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+i386_register_u_addr (int blockend, int regnum)
{
#if 0
/* this will be needed if fp registers are reinstated */
};
static
-print_387_status (status, ep)
- unsigned short status;
- struct env387 *ep;
+print_387_status (unsigned short status, struct env387 *ep)
{
int i;
int bothstatus;
static struct env387 core_env387;
void
-i386_float_info ()
+i386_float_info (void)
{
struct env387 fps;
int fpsaved = 0;
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
char buf[MAX_REGISTER_RAW_SIZE];
if (regno < FP0_REGNUM)
}
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno < 0)
for (regno = 0; regno < NUM_REGS; regno++)
/* store one register */
static void
-store_register (regno)
- int regno;
+store_register (int regno)
{
char buf[80];
errno = 0;
If REGNO is -1, do this for all registers.
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
if (regno < 0)
for (regno = 0; regno < NUM_REGS; regno++)
};
void
-_initialize_core_i386aix ()
+_initialize_core_i386aix (void)
{
add_core_fns (&i386aix_core_fns);
}
#include "gdbcore.h" /* for registers_fetched() */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
}
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
};
void
-fetch_core_registers (core_reg_sect, core_reg_size, which, ignore)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR ignore;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR ignore)
{
struct md_core *core_reg = (struct md_core *) core_reg_sect;
place where ES is stored. */
int
-i386_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+i386_register_u_addr (int blockend, int regnum)
{
/* The following condition is a kludge to get at the proper register map
depending upon the state of pcb_flag.
};
static void
-print_387_status (status, ep)
- unsigned short status;
- struct env387 *ep;
+print_387_status (unsigned short status, struct env387 *ep)
{
int i;
int bothstatus;
}
}
-i386_float_info ()
+i386_float_info (void)
{
struct user u; /* just for address computations */
int i;
}
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
system calls use a different calling sequence. */
CORE_ADDR
-i386lynx_saved_pc_after_call (frame)
- struct frame_info *frame;
+i386lynx_saved_pc_after_call (struct frame_info *frame)
{
char opcode[7];
static const unsigned char call_inst[] =
*/
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
* On mach3 all registers are always saved in one call.
*/
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
*/
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
* Should move it to i387-tdep.c but you need to export struct env387
*/
private
-print_387_status (status, ep)
- unsigned short status;
- struct env387 *ep;
+print_387_status (unsigned short status, struct env387 *ep)
{
int i;
int bothstatus;
/* Mach 3 specific routines.
*/
private boolean_t
-get_i387_state (fstate)
- struct fpstate *fstate;
+get_i387_state (struct fpstate *fstate)
{
kern_return_t ret;
thread_state_data_t state;
}
private boolean_t
-get_i387_core_state (fstate)
- struct fpstate *fstate;
+get_i387_core_state (struct fpstate *fstate)
{
/* Not implemented yet. Core files do not contain float state. */
return FALSE;
* This is called by "info float" command
*/
void
-i386_mach3_float_info ()
+i386_mach3_float_info (void)
{
char buf[sizeof (struct fpstate) + 2 * sizeof (int)];
boolean_t valid = FALSE;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_state inferior_fp_registers;
};
void
-_initialize_core_i386mach ()
+_initialize_core_i386mach (void)
{
add_core_fns (&i386mach_core_fns);
}
};
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
struct env387 inferior_fpregisters;
}
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
struct env387 inferior_fpregisters;
};
static void
-fetch_core_registers (core_reg_sect, core_reg_size, which, ignore)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR ignore;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR ignore)
{
struct md_core *core_reg = (struct md_core *) core_reg_sect;
};
void
-_initialize_i386nbsd_nat ()
+_initialize_i386nbsd_nat (void)
{
add_core_fns (&i386nbsd_core_fns);
}
*/
int
-i386_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+i386_register_u_addr (int blockend, int regnum)
{
struct user u;
int fpstate;
}
\f
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
/* Insert a watchpoint. */
int
-i386_insert_watchpoint (pid, addr, len, rw)
- int pid;
- CORE_ADDR addr;
- int len;
- int rw;
+i386_insert_watchpoint (int pid, CORE_ADDR addr, int len, int rw)
{
return i386_insert_aligned_watchpoint (pid, addr, addr, len, rw);
}
static int
-i386_insert_aligned_watchpoint (pid, waddr, addr, len, rw)
- int pid;
- CORE_ADDR waddr;
- CORE_ADDR addr;
- int len;
- int rw;
+i386_insert_aligned_watchpoint (int pid, CORE_ADDR waddr, CORE_ADDR addr,
+ int len, int rw)
{
int i;
int read_write_bits, len_bits;
}
static int
-i386_insert_nonaligned_watchpoint (pid, waddr, addr, len, rw)
- int pid;
- CORE_ADDR waddr;
- CORE_ADDR addr;
- int len;
- int rw;
+i386_insert_nonaligned_watchpoint (int pid, CORE_ADDR waddr, CORE_ADDR addr,
+ int len, int rw)
{
int align;
int size;
/* Remove a watchpoint. */
int
-i386_remove_watchpoint (pid, addr, len)
- int pid;
- CORE_ADDR addr;
- int len;
+i386_remove_watchpoint (int pid, CORE_ADDR addr, int len)
{
int i;
int register_number;
/* Check if stopped by a watchpoint. */
CORE_ADDR
-i386_stopped_by_watchpoint (pid)
- int pid;
+i386_stopped_by_watchpoint (int pid)
{
int i;
int status;
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = (greg_t *) gregsetp;
};
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
int regi;
them all. */
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
void double_to_i387 (char *from, char *to);
void
-i387_to_double (from, to)
- char *from;
- char *to;
+i387_to_double (char *from, char *to)
{
floatformat_to_double (&floatformat_i387_ext, from, (double *) to);
}
void
-double_to_i387 (from, to)
- char *from;
- char *to;
+double_to_i387 (char *from, char *to)
{
floatformat_from_double (&floatformat_i387_ext, (double *) from, to);
}
static void print_387_status_bits (unsigned int status);
static void
-print_387_control_bits (control)
- unsigned int control;
+print_387_control_bits (unsigned int control)
{
switch ((control >> 8) & 3)
{
}
void
-print_387_control_word (control)
- unsigned int control;
+print_387_control_word (unsigned int control)
{
printf_filtered ("control %s:", local_hex_string(control & 0xffff));
print_387_control_bits (control);
}
static void
-print_387_status_bits (status)
- unsigned int status;
+print_387_status_bits (unsigned int status)
{
printf_unfiltered (" flags %d%d%d%d; ",
(status & 0x4000) != 0,
}
void
-print_387_status_word (status)
- unsigned int status;
+print_387_status_word (unsigned int status)
{
printf_filtered ("status %s:", local_hex_string (status & 0xffff));
print_387_status_bits (status);
If it's more than 16 bytes long, g13 pointed to it on entry. */
int
-i960_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+i960_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 16);
}
This routine must be called as part of gdb initialization. */
static void
-check_host ()
+check_host (void)
{
int i;
(((addr) < (lim)) ? next_insn (addr, pword1, pword2) : 0)
static CORE_ADDR
-examine_prologue (ip, limit, frame_addr, fsr)
- register CORE_ADDR ip;
- register CORE_ADDR limit;
- CORE_ADDR frame_addr;
- struct frame_saved_regs *fsr;
+examine_prologue (register CORE_ADDR ip, register CORE_ADDR limit,
+ CORE_ADDR frame_addr, struct frame_saved_regs *fsr)
{
register CORE_ADDR next_ip;
register int src, dst;
fairly expensive. */
void
-frame_find_saved_regs (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+frame_find_saved_regs (struct frame_info *fi, struct frame_saved_regs *fsr)
{
register CORE_ADDR next_addr;
register CORE_ADDR *saved_regs;
described by FI. Returns 0 if the address is unknown. */
CORE_ADDR
-frame_args_address (fi, must_be_correct)
- struct frame_info *fi;
+frame_args_address (struct frame_info *fi, int must_be_correct)
{
struct frame_saved_regs fsr;
CORE_ADDR ap;
described by FI. Returns 0 if the address is unknown. */
CORE_ADDR
-frame_struct_result_address (fi)
- struct frame_info *fi;
+frame_struct_result_address (struct frame_info *fi)
{
struct frame_saved_regs fsr;
CORE_ADDR ap;
unless the function is a leaf procedure. */
CORE_ADDR
-saved_pc_after_call (frame)
- struct frame_info *frame;
+saved_pc_after_call (struct frame_info *frame)
{
CORE_ADDR saved_pc;
corresponds. */
enum target_signal
-i960_fault_to_signal (fault)
- int fault;
+i960_fault_to_signal (int fault)
{
switch (fault)
{
'pword2'. */
static CORE_ADDR
-next_insn (memaddr, pword1, pword2)
- unsigned int *pword1, *pword2;
- CORE_ADDR memaddr;
+next_insn (CORE_ADDR memaddr, unsigned int *pword1, unsigned int *pword2)
{
int len;
char buf[8];
they display this frame. */
int
-mon960_frame_chain_valid (chain, curframe)
- CORE_ADDR chain;
- struct frame_info *curframe;
+mon960_frame_chain_valid (CORE_ADDR chain, struct frame_info *curframe)
{
struct symbol *sym;
struct minimal_symbol *msymbol;
void
-_initialize_i960_tdep ()
+_initialize_i960_tdep (void)
{
check_host ();
};
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
}
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
int regi;
greg_t *regp = (greg_t *) gregsetp;
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
greg_t *regp = (greg_t *) gregsetp;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
char *from;
them all. */
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *to;
/* We don't really want to use this, but remote.c needs to call it in order
to figure out if Z-packets are supported or not. Oh, well. */
unsigned char *
-ia64_breakpoint_from_pc (pcptr, lenptr)
- CORE_ADDR *pcptr;
- int *lenptr;
+ia64_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
{
static unsigned char breakpoint[] =
{ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
of a command. If it has, it removes it and returns 1. Otherwise it
does nothing and returns 0. */
static int
-strip_bg_char (args)
- char **args;
+strip_bg_char (char **args)
{
char *p = NULL;
/* ARGSUSED */
void
-tty_command (file, from_tty)
- char *file;
- int from_tty;
+tty_command (char *file, int from_tty)
{
if (file == 0)
error_no_arg ("terminal name for running target process");
}
static void
-run_command (args, from_tty)
- char *args;
- int from_tty;
+run_command (char *args, int from_tty)
{
char *exec_file;
static void
-run_no_args_command (args, from_tty)
- char *args;
- int from_tty;
+run_no_args_command (char *args, int from_tty)
{
execute_command ("set args", from_tty);
run_command ((char *) NULL, from_tty);
\f
void
-continue_command (proc_count_exp, from_tty)
- char *proc_count_exp;
- int from_tty;
+continue_command (char *proc_count_exp, int from_tty)
{
int async_exec = 0;
ERROR_NO_INFERIOR;
/* ARGSUSED */
static void
-step_command (count_string, from_tty)
- char *count_string;
- int from_tty;
+step_command (char *count_string, int from_tty)
{
step_1 (0, 0, count_string);
}
/* ARGSUSED */
static void
-next_command (count_string, from_tty)
- char *count_string;
- int from_tty;
+next_command (char *count_string, int from_tty)
{
step_1 (1, 0, count_string);
}
/* ARGSUSED */
void
-stepi_command (count_string, from_tty)
- char *count_string;
- int from_tty;
+stepi_command (char *count_string, int from_tty)
{
step_1 (0, 1, count_string);
}
/* ARGSUSED */
void
-nexti_command (count_string, from_tty)
- char *count_string;
- int from_tty;
+nexti_command (char *count_string, int from_tty)
{
step_1 (1, 1, count_string);
}
}
static void
-step_1 (skip_subroutines, single_inst, count_string)
- int skip_subroutines;
- int single_inst;
- char *count_string;
+step_1 (int skip_subroutines, int single_inst, char *count_string)
{
register int count = 1;
struct frame_info *frame;
proceed(), via step_once(). Basically it is like step_once and
step_1_continuation are co-recursive. */
static void
-step_1_continuation (arg)
- struct continuation_arg *arg;
+step_1_continuation (struct continuation_arg *arg)
{
int count;
int skip_subroutines;
/* Continue program at specified address. */
static void
-jump_command (arg, from_tty)
- char *arg;
- int from_tty;
+jump_command (char *arg, int from_tty)
{
register CORE_ADDR addr;
struct symtabs_and_lines sals;
/* Go to line or address in current procedure */
static void
-go_command (line_no, from_tty)
- char *line_no;
- int from_tty;
+go_command (char *line_no, int from_tty)
{
if (line_no == (char *) NULL || !*line_no)
printf_filtered (GO_USAGE);
/* Continue program giving it specified signal. */
static void
-signal_command (signum_exp, from_tty)
- char *signum_exp;
- int from_tty;
+signal_command (char *signum_exp, int from_tty)
{
enum target_signal oursig;
pointed to by arg (which is really a bpstat *). */
static void
-breakpoint_auto_delete_contents (arg)
- PTR arg;
+breakpoint_auto_delete_contents (PTR arg)
{
breakpoint_auto_delete (*(bpstat *) arg);
}
will eventually be popped when we do hit the dummy end breakpoint). */
int
-run_stack_dummy (addr, buffer)
- CORE_ADDR addr;
- char *buffer;
+run_stack_dummy (CORE_ADDR addr, char *buffer)
{
struct cleanup *old_cleanups = make_cleanup (null_cleanup, 0);
int saved_async = 0;
/* ARGSUSED */
static void
-until_next_command (from_tty)
- int from_tty;
+until_next_command (int from_tty)
{
struct frame_info *frame;
CORE_ADDR pc;
}
static void
-until_command (arg, from_tty)
- char *arg;
- int from_tty;
+until_command (char *arg, int from_tty)
{
int async_exec = 0;
detects that the target has stopped. This function is called via the
cmd_continaution pointer. */
void
-finish_command_continuation (arg)
- struct continuation_arg *arg;
+finish_command_continuation (struct continuation_arg *arg)
{
register struct symbol *function;
struct breakpoint *breakpoint;
the selected frame will return to, then continue. */
static void
-finish_command (arg, from_tty)
- char *arg;
- int from_tty;
+finish_command (char *arg, int from_tty)
{
struct symtab_and_line sal;
register struct frame_info *frame;
\f
/* ARGSUSED */
static void
-program_info (args, from_tty)
- char *args;
- int from_tty;
+program_info (char *args, int from_tty)
{
bpstat bs = stop_bpstat;
int num = bpstat_num (&bs);
}
\f
static void
-environment_info (var, from_tty)
- char *var;
- int from_tty;
+environment_info (char *var, int from_tty)
{
if (var)
{
}
static void
-set_environment_command (arg, from_tty)
- char *arg;
- int from_tty;
+set_environment_command (char *arg, int from_tty)
{
register char *p, *val, *var;
int nullset = 0;
}
static void
-unset_environment_command (var, from_tty)
- char *var;
- int from_tty;
+unset_environment_command (char *var, int from_tty)
{
if (var == 0)
{
/* ARGSUSED */
static void
-path_info (args, from_tty)
- char *args;
- int from_tty;
+path_info (char *args, int from_tty)
{
puts_filtered ("Executable and object file path: ");
puts_filtered (get_in_environ (inferior_environ, path_var_name));
/* Add zero or more directories to the front of the execution path. */
static void
-path_command (dirname, from_tty)
- char *dirname;
- int from_tty;
+path_command (char *dirname, int from_tty)
{
char *exec_path;
char *env;
#define DO_REGISTERS_INFO(regnum, fp) do_registers_info(regnum, fp)
static void
-do_registers_info (regnum, fpregs)
- int regnum;
- int fpregs;
+do_registers_info (int regnum, int fpregs)
{
register int i;
int numregs = ARCH_NUM_REGS;
#endif /* no DO_REGISTERS_INFO. */
void
-registers_info (addr_exp, fpregs)
- char *addr_exp;
- int fpregs;
+registers_info (char *addr_exp, int fpregs)
{
int regnum, numregs;
register char *end;
}
void
-all_registers_info (addr_exp, from_tty)
- char *addr_exp;
- int from_tty;
+all_registers_info (char *addr_exp, int from_tty)
{
registers_info (addr_exp, 1);
}
void
-nofp_registers_info (addr_exp, from_tty)
- char *addr_exp;
- int from_tty;
+nofp_registers_info (char *addr_exp, int from_tty)
{
registers_info (addr_exp, 0);
}
and wait for the trace-trap that results from attaching. */
void
-attach_command (args, from_tty)
- char *args;
- int from_tty;
+attach_command (char *args, int from_tty)
{
#ifdef SOLIB_ADD
extern int auto_solib_add;
*/
static void
-detach_command (args, from_tty)
- char *args;
- int from_tty;
+detach_command (char *args, int from_tty)
{
dont_repeat (); /* Not for the faint of heart */
target_detach (args, from_tty);
the backgound. */
#ifdef UI_OUT
void
-interrupt_target_command_wrapper (args, from_tty)
- char *args;
- int from_tty;
+interrupt_target_command_wrapper (char *args, int from_tty)
{
interrupt_target_command (args, from_tty);
}
#endif
static void
-interrupt_target_command (args, from_tty)
- char *args;
- int from_tty;
+interrupt_target_command (char *args, int from_tty)
{
if (event_loop_p && target_can_async_p ())
{
/* ARGSUSED */
static void
-float_info (addr_exp, from_tty)
- char *addr_exp;
- int from_tty;
+float_info (char *addr_exp, int from_tty)
{
#ifdef FLOAT_INFO
FLOAT_INFO;
\f
/* ARGSUSED */
static void
-unset_command (args, from_tty)
- char *args;
- int from_tty;
+unset_command (char *args, int from_tty)
{
printf_filtered ("\"unset\" must be followed by the name of ");
printf_filtered ("an unset subcommand.\n");
}
void
-_initialize_infcmd ()
+_initialize_infcmd (void)
{
struct cmd_list_element *c;
/* Does GDB have a terminal (on stdin)? */
int
-gdb_has_a_terminal ()
+gdb_has_a_terminal (void)
{
switch (gdb_has_a_terminal_flag)
{
before we actually run the inferior. */
void
-terminal_init_inferior_with_pgrp (pgrp)
- int pgrp;
+terminal_init_inferior_with_pgrp (int pgrp)
{
if (gdb_has_a_terminal ())
{
}
void
-terminal_init_inferior ()
+terminal_init_inferior (void)
{
#ifdef PROCESS_GROUP_TYPE
/* This is for Lynx, and should be cleaned up by having Lynx be a separate
This is preparation for starting or resuming the inferior. */
void
-terminal_inferior ()
+terminal_inferior (void)
{
if (gdb_has_a_terminal () && terminal_is_ours
&& inferior_thisrun_terminal == 0)
should be called to get back to a normal state of affairs. */
void
-terminal_ours_for_output ()
+terminal_ours_for_output (void)
{
terminal_ours_1 (1);
}
so they can be restored properly later. */
void
-terminal_ours ()
+terminal_ours (void)
{
terminal_ours_1 (0);
}
flags. */
static void
-terminal_ours_1 (output_only)
- int output_only;
+terminal_ours_1 (int output_only)
{
/* Checking inferior_thisrun_terminal is necessary so that
if GDB is running in the background, it won't block trying
/* ARGSUSED */
void
-term_info (arg, from_tty)
- char *arg;
- int from_tty;
+term_info (char *arg, int from_tty)
{
target_terminal_info (arg, from_tty);
}
/* ARGSUSED */
void
-child_terminal_info (args, from_tty)
- char *args;
- int from_tty;
+child_terminal_info (char *args, int from_tty)
{
if (!gdb_has_a_terminal ())
{
the terminal specified in the NEW_TTY_PREFORK call. */
void
-new_tty_prefork (ttyname)
- char *ttyname;
+new_tty_prefork (char *ttyname)
{
/* Save the name for later, for determining whether we and the child
are sharing a tty. */
}
void
-new_tty ()
+new_tty (void)
{
register int tty;
/* ARGSUSED */
static void
-kill_command (arg, from_tty)
- char *arg;
- int from_tty;
+kill_command (char *arg, int from_tty)
{
/* FIXME: This should not really be inferior_pid (or target_has_execution).
It should be a distinct flag that indicates that a target is active, cuz
/* ARGSUSED */
static void
-pass_signal (signo)
- int signo;
+pass_signal (int signo)
{
#ifndef _WIN32
kill (PIDGET (inferior_pid), SIGINT);
static void (*osig) ();
void
-set_sigint_trap ()
+set_sigint_trap (void)
{
if (attach_flag || inferior_thisrun_terminal)
{
}
void
-clear_sigint_trap ()
+clear_sigint_trap (void)
{
if (attach_flag || inferior_thisrun_terminal)
{
static void (*old_sigio) ();
static void
-handle_sigio (signo)
- int signo;
+handle_sigio (int signo)
{
int numfds;
fd_set readfds;
static int old_fcntl_flags;
void
-set_sigio_trap ()
+set_sigio_trap (void)
{
if (target_activity_function)
{
}
void
-clear_sigio_trap ()
+clear_sigio_trap (void)
{
if (target_activity_function)
{
}
#else /* No SIGIO. */
void
-set_sigio_trap ()
+set_sigio_trap (void)
{
if (target_activity_function)
abort ();
}
void
-clear_sigio_trap ()
+clear_sigio_trap (void)
{
if (target_activity_function)
abort ();
calls setpgrp and a setpgrp which does nothing (any system with job control
will have one or the other). */
int
-gdb_setpgid ()
+gdb_setpgid (void)
{
int retval = 0;
}
void
-_initialize_inflow ()
+_initialize_inflow (void)
{
add_info ("terminal", term_info,
"Print inferior's saved terminal status.");
It exists so that all calls to ptrace are isolated in this
machine-dependent file. */
int
-call_ptrace (request, pid, addr, data)
- int request, pid;
- PTRACE_ARG3_TYPE addr;
- int data;
+call_ptrace (int request, int pid, PTRACE_ARG3_TYPE addr, int data)
{
int pt_status = 0;
hook before returning. */
int
-ptrace_wait (pid, status)
- int pid;
- int *status;
+ptrace_wait (int pid, int *status)
{
int wstate;
}
void
-kill_inferior ()
+kill_inferior (void)
{
int status;
If SIGNAL is nonzero, give it that signal. */
void
-child_resume (pid, step, signal)
- int pid;
- int step;
- enum target_signal signal;
+child_resume (int pid, int step, enum target_signal signal)
{
errno = 0;
#ifdef ATTACH_DETACH
/* Start debugging the process whose number is PID. */
int
-attach (pid)
- int pid;
+attach (int pid)
{
errno = 0;
ptrace (PT_ATTACH, pid, (PTRACE_ARG3_TYPE) 0, 0);
SIGNAL = 0 means just continue it. */
void
-detach (signal)
- int signal;
+detach (int signal)
{
errno = 0;
ptrace (PT_DETACH, inferior_pid, (PTRACE_ARG3_TYPE) 1, signal);
#endif /* KERNEL_U_ADDR_BSD. */
void
-_initialize_kernel_u_addr ()
+_initialize_kernel_u_addr (void)
{
#if defined (KERNEL_U_ADDR_BSD) && !defined (FETCH_INFERIOR_REGISTERS)
struct nlist names[2];
/* Fetch one register. */
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
/* This isn't really an address. But ptrace thinks of it as one. */
CORE_ADDR regaddr;
Otherwise, REGNO specifies which register (so we can save time). */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
if (regno >= 0)
{
/* Store one register. */
static void
-store_register (regno)
- int regno;
+store_register (int regno)
{
/* This isn't really an address. But ptrace thinks of it as one. */
CORE_ADDR regaddr;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
if (regno >= 0)
{
\f
static void
-udot_info (dummy1, dummy2)
- char *dummy1;
- int dummy2;
+udot_info (char *dummy1, int dummy2)
{
#if defined (KERNEL_U_SIZE)
int udot_off; /* Offset into user struct */
\f
void
-_initialize_infptrace ()
+_initialize_infptrace (void)
{
#if !defined (CHILD_XFER_MEMORY)
add_info ("udot", udot_info,
struct execution_control_state *async_ecs;
void
-fetch_inferior_event (client_data)
- void *client_data;
+fetch_inferior_event (void *client_data)
{
static struct cleanup *old_cleanups;
of error; store status through argument pointer OURSTATUS. */
static int
-child_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+child_wait (int pid, struct target_waitstatus *ourstatus)
{
int save_errno;
int status;
#if !defined(CHILD_POST_WAIT)
void
-child_post_wait (pid, wait_status)
- int pid;
- int wait_status;
+child_post_wait (int pid, int wait_status)
{
/* This version of Unix doesn't require a meaningful "post wait"
operation.
for now we're going to try and be compatable with the old thread
code. */
int
-child_thread_alive (pid)
- int pid;
+child_thread_alive (int pid)
{
return (kill (pid, 0) != -1);
}
#endif
static void
-child_attach_to_process (args, from_tty, after_fork)
- char *args;
- int from_tty;
- int after_fork;
+child_attach_to_process (char *args, int from_tty, int after_fork)
{
if (!args)
error_no_arg ("process-id to attach");
/* Attach to process PID, then initialize for debugging it. */
static void
-child_attach (args, from_tty)
- char *args;
- int from_tty;
+child_attach (char *args, int from_tty)
{
child_attach_to_process (args, from_tty, 0);
}
#if !defined(CHILD_POST_ATTACH)
void
-child_post_attach (pid)
- int pid;
+child_post_attach (int pid)
{
/* This version of Unix doesn't require a meaningful "post attach"
operation by a debugger. */
#endif
static void
-child_require_attach (args, from_tty)
- char *args;
- int from_tty;
+child_require_attach (char *args, int from_tty)
{
child_attach_to_process (args, from_tty, 1);
}
static void
-child_detach_from_process (pid, args, from_tty, after_fork)
- int pid;
- char *args;
- int from_tty;
- int after_fork;
+child_detach_from_process (int pid, char *args, int from_tty, int after_fork)
{
#ifdef ATTACH_DETACH
{
started via the normal ptrace (PTRACE_TRACEME). */
static void
-child_detach (args, from_tty)
- char *args;
- int from_tty;
+child_detach (char *args, int from_tty)
{
child_detach_from_process (inferior_pid, args, from_tty, 0);
inferior_pid = 0;
}
static void
-child_require_detach (pid, args, from_tty)
- int pid;
- char *args;
- int from_tty;
+child_require_detach (int pid, char *args, int from_tty)
{
child_detach_from_process (pid, args, from_tty, 1);
}
debugged. */
static void
-child_prepare_to_store ()
+child_prepare_to_store (void)
{
#ifdef CHILD_PREPARE_TO_STORE
CHILD_PREPARE_TO_STORE ();
/* Print status information about what we're accessing. */
static void
-child_files_info (ignore)
- struct target_ops *ignore;
+child_files_info (struct target_ops *ignore)
{
printf_unfiltered ("\tUsing the running image of %s %s.\n",
attach_flag ? "attached" : "child", target_pid_to_str (inferior_pid));
/* ARGSUSED */
static void
-child_open (arg, from_tty)
- char *arg;
- int from_tty;
+child_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a Unix child process.");
}
by its parent process. */
static void
-ptrace_me ()
+ptrace_me (void)
{
/* "Trace me, Dr. Memory!" */
call_ptrace (0, 0, (PTRACE_ARG3_TYPE) 0, 0);
the child process. */
static void
-ptrace_him (pid)
- int pid;
+ptrace_him (int pid)
{
push_target (&child_ops);
ENV is the environment vector to pass. Errors reported with error(). */
static void
-child_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+child_create_inferior (char *exec_file, char *allargs, char **env)
{
#ifdef HPUXHPPA
fork_inferior (exec_file, allargs, env, ptrace_me, ptrace_him, pre_fork_inferior, NULL);
#if !defined(CHILD_POST_STARTUP_INFERIOR)
void
-child_post_startup_inferior (pid)
- int pid;
+child_post_startup_inferior (int pid)
{
/* This version of Unix doesn't require a meaningful "post startup inferior"
operation by a debugger.
#if !defined(CHILD_ACKNOWLEDGE_CREATED_INFERIOR)
void
-child_acknowledge_created_inferior (pid)
- int pid;
+child_acknowledge_created_inferior (int pid)
{
/* This version of Unix doesn't require a meaningful "acknowledge created inferior"
operation by a debugger.
void
-child_clone_and_follow_inferior (child_pid, followed_child)
- int child_pid;
- int *followed_child;
+child_clone_and_follow_inferior (int child_pid, int *followed_child)
{
clone_and_follow_inferior (child_pid, followed_child);
#if !defined(CHILD_POST_FOLLOW_INFERIOR_BY_CLONE)
void
-child_post_follow_inferior_by_clone ()
+child_post_follow_inferior_by_clone (void)
{
/* This version of Unix doesn't require a meaningful "post follow inferior"
operation by a clone debugger.
#if !defined(CHILD_INSERT_FORK_CATCHPOINT)
int
-child_insert_fork_catchpoint (pid)
- int pid;
+child_insert_fork_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of fork events. */
return 0;
#if !defined(CHILD_REMOVE_FORK_CATCHPOINT)
int
-child_remove_fork_catchpoint (pid)
- int pid;
+child_remove_fork_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of fork events. */
return 0;
#if !defined(CHILD_INSERT_VFORK_CATCHPOINT)
int
-child_insert_vfork_catchpoint (pid)
- int pid;
+child_insert_vfork_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of vfork events. */
return 0;
#if !defined(CHILD_REMOVE_VFORK_CATCHPOINT)
int
-child_remove_vfork_catchpoint (pid)
- int pid;
+child_remove_vfork_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of vfork events. */
return 0;
#if !defined(CHILD_HAS_FORKED)
int
-child_has_forked (pid, child_pid)
- int pid;
- int *child_pid;
+child_has_forked (int pid, int *child_pid)
{
/* This version of Unix doesn't support notification of fork events. */
return 0;
#if !defined(CHILD_HAS_VFORKED)
int
-child_has_vforked (pid, child_pid)
- int pid;
- int *child_pid;
+child_has_vforked (int pid, int *child_pid)
{
/* This version of Unix doesn't support notification of vfork events.
*/
#if !defined(CHILD_CAN_FOLLOW_VFORK_PRIOR_TO_EXEC)
int
-child_can_follow_vfork_prior_to_exec ()
+child_can_follow_vfork_prior_to_exec (void)
{
/* This version of Unix doesn't support notification of vfork events.
However, if it did, it probably wouldn't allow vforks to be followed
#if !defined(CHILD_POST_FOLLOW_VFORK)
void
-child_post_follow_vfork (parent_pid, followed_parent, child_pid, followed_child)
- int parent_pid;
- int followed_parent;
- int child_pid;
- int followed_child;
+child_post_follow_vfork (int parent_pid, int followed_parent, int child_pid,
+ int followed_child)
{
/* This version of Unix doesn't require a meaningful "post follow vfork"
operation by a clone debugger.
#if !defined(CHILD_INSERT_EXEC_CATCHPOINT)
int
-child_insert_exec_catchpoint (pid)
- int pid;
+child_insert_exec_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of exec events. */
return 0;
#if !defined(CHILD_REMOVE_EXEC_CATCHPOINT)
int
-child_remove_exec_catchpoint (pid)
- int pid;
+child_remove_exec_catchpoint (int pid)
{
/* This version of Unix doesn't support notification of exec events. */
return 0;
#if !defined(CHILD_HAS_EXECD)
int
-child_has_execd (pid, execd_pathname)
- int pid;
- char **execd_pathname;
+child_has_execd (int pid, char **execd_pathname)
{
/* This version of Unix doesn't support notification of exec events.
*/
#if !defined(CHILD_REPORTED_EXEC_EVENTS_PER_EXEC_CALL)
int
-child_reported_exec_events_per_exec_call ()
+child_reported_exec_events_per_exec_call (void)
{
/* This version of Unix doesn't support notification of exec events.
*/
#if !defined(CHILD_HAS_SYSCALL_EVENT)
int
-child_has_syscall_event (pid, kind, syscall_id)
- int pid;
- enum target_waitkind *kind;
- int *syscall_id;
+child_has_syscall_event (int pid, enum target_waitkind *kind, int *syscall_id)
{
/* This version of Unix doesn't support notification of syscall events.
*/
#if !defined(CHILD_HAS_EXITED)
int
-child_has_exited (pid, wait_status, exit_status)
- int pid;
- int wait_status;
- int *exit_status;
+child_has_exited (int pid, int wait_status, int *exit_status)
{
if (WIFEXITED (wait_status))
{
static void
-child_mourn_inferior ()
+child_mourn_inferior (void)
{
unpush_target (&child_ops);
generic_mourn_inferior ();
}
static int
-child_can_run ()
+child_can_run (void)
{
/* This variable is controlled by modules that sit atop inftarg that may layer
their own process structure atop that provided here. hpux-thread.c does
killpg() instead of kill (-pgrp). */
static void
-child_stop ()
+child_stop (void)
{
extern pid_t inferior_process_group;
#if !defined(CHILD_ENABLE_EXCEPTION_CALLBACK)
struct symtab_and_line *
-child_enable_exception_callback (kind, enable)
- enum exception_event_kind kind;
- int enable;
+child_enable_exception_callback (enum exception_event_kind kind, int enable)
{
return (struct symtab_and_line *) NULL;
}
#if !defined(CHILD_GET_CURRENT_EXCEPTION_EVENT)
struct exception_event_record *
-child_get_current_exception_event ()
+child_get_current_exception_event (void)
{
return (struct exception_event_record *) NULL;
}
#if !defined(CHILD_PID_TO_EXEC_FILE)
char *
-child_pid_to_exec_file (pid)
- int pid;
+child_pid_to_exec_file (int pid)
{
/* This version of Unix doesn't support translation of a process ID
to the filename of the executable file.
#endif
char *
-child_core_file_to_sym_file (core)
- char *core;
+child_core_file_to_sym_file (char *core)
{
/* The target stratum for a running executable need not support
this operation.
#if !defined(CHILD_PID_TO_STR)
char *
-child_pid_to_str (pid)
- int pid;
+child_pid_to_str (int pid)
{
return normal_pid_to_str (pid);
}
#endif
static void
-init_child_ops ()
+init_child_ops (void)
{
child_ops.to_shortname = "child";
child_ops.to_longname = "Unix child process";
}
void
-_initialize_inftarg ()
+_initialize_inftarg (void)
{
#ifdef HAVE_OPTIONAL_PROC_FS
char procname[32];
*************************************************
*/
CORE_ADDR
-get_raw_pc (ttid)
- lwpid_t ttid;
+get_raw_pc (lwpid_t ttid)
{
unsigned long pc_val;
int offset;
}
static char *
-get_printable_name_of_stepping_mode (mode)
- stepping_mode_t mode;
+get_printable_name_of_stepping_mode (stepping_mode_t mode)
{
switch (mode)
{
* ttrace event being reported.
*/
char *
-get_printable_name_of_ttrace_event (event)
- ttevents_t event;
+get_printable_name_of_ttrace_event (ttevents_t event)
{
/* This enumeration is "gappy", so don't use a table. */
switch (event)
* name.
*/
char *
-get_printable_name_of_ttrace_request (request)
- ttreq_t request;
+get_printable_name_of_ttrace_request (ttreq_t request)
{
if (!IS_TTRACE_REQ (request))
return "?bad req?";
* name.
*/
static char *
-get_printable_name_of_process_state (process_state)
- process_state_t process_state;
+get_printable_name_of_process_state (process_state_t process_state)
{
switch (process_state)
{
/* Set a ttrace thread state to a safe, initial state.
*/
static void
-clear_ttstate_t (tts)
- ttstate_t *tts;
+clear_ttstate_t (ttstate_t *tts)
{
tts->tts_pid = 0;
tts->tts_lwpid = 0;
/* Copy ttrace thread state TTS_FROM into TTS_TO.
*/
static void
-copy_ttstate_t (tts_to, tts_from)
- ttstate_t *tts_to;
- ttstate_t *tts_from;
+copy_ttstate_t (ttstate_t *tts_to, ttstate_t *tts_from)
{
memcpy ((char *) tts_to, (char *) tts_from, sizeof (*tts_to));
}
/* Are there any live threads we know about?
*/
static int
-any_thread_records ()
+any_thread_records (void)
{
return (thread_head.count > 0);
}
/* Create, fill in and link in a thread descriptor.
*/
static thread_info *
-create_thread_info (pid, tid)
- int pid;
- lwpid_t tid;
+create_thread_info (int pid, lwpid_t tid)
{
thread_info *new_p;
thread_info *p;
/* Get rid of our thread info.
*/
static void
-clear_thread_info ()
+clear_thread_info (void)
{
thread_info *p;
thread_info *q;
/* Given a tid, find the thread block for it.
*/
static thread_info *
-find_thread_info (tid)
- lwpid_t tid;
+find_thread_info (lwpid_t tid)
{
thread_info *p;
* deleted threads. We do the map, but we don't like it.
*/
static lwpid_t
-map_from_gdb_tid (gdb_tid)
- lwpid_t gdb_tid;
+map_from_gdb_tid (lwpid_t gdb_tid)
{
thread_info *p;
* also need to consider deleted threads.
*/
static lwpid_t
-map_to_gdb_tid (real_tid)
- lwpid_t real_tid;
+map_to_gdb_tid (lwpid_t real_tid)
{
thread_info *p;
/* Do any threads have saved signals?
*/
static int
-saved_signals_exist ()
+saved_signals_exist (void)
{
thread_info *p;
/* Is this the tid for the zero-th thread?
*/
static int
-is_pseudo_thread (tid)
- lwpid_t tid;
+is_pseudo_thread (lwpid_t tid)
{
thread_info *p = find_thread_info (tid);
if (NULL == p || p->terminated)
/* Is this thread terminated?
*/
static int
-is_terminated (tid)
- lwpid_t tid;
+is_terminated (lwpid_t tid)
{
thread_info *p = find_thread_info (tid);
/* Is this pid a real PID or a TID?
*/
static int
-is_process_id (pid)
- int pid;
+is_process_id (int pid)
{
lwpid_t tid;
thread_info *tinfo;
/* Add a thread to our info. Prevent duplicate entries.
*/
static thread_info *
-add_tthread (pid, tid)
- int pid;
- lwpid_t tid;
+add_tthread (int pid, lwpid_t tid)
{
thread_info *p;
/* Notice that a thread was deleted.
*/
static void
-del_tthread (tid)
- lwpid_t tid;
+del_tthread (lwpid_t tid)
{
thread_info *p;
thread_info *chase;
/* Get the pid for this tid. (Has to be a real TID!).
*/
static int
-get_pid_for (tid)
- lwpid_t tid;
+get_pid_for (lwpid_t tid)
{
thread_info *p;
/* Note that this thread's current event has been handled.
*/
static void
-set_handled (pid, tid)
- int pid;
- lwpid_t tid;
+set_handled (int pid, lwpid_t tid)
{
thread_info *p;
/* Was this thread's current event handled?
*/
static int
-was_handled (tid)
- lwpid_t tid;
+was_handled (lwpid_t tid)
{
thread_info *p;
/* Set this thread to unhandled.
*/
static void
-clear_handled (tid)
- lwpid_t tid;
+clear_handled (lwpid_t tid)
{
thread_info *p;
/* Set all threads to unhandled.
*/
static void
-clear_all_handled ()
+clear_all_handled (void)
{
thread_info *p;
/* Set this thread to default stepping mode.
*/
static void
-clear_stepping_mode (tid)
- lwpid_t tid;
+clear_stepping_mode (lwpid_t tid)
{
thread_info *p;
/* Set all threads to do default continue on resume.
*/
static void
-clear_all_stepping_mode ()
+clear_all_stepping_mode (void)
{
thread_info *p;
/* Set all threads to unseen on this pass.
*/
static void
-set_all_unseen ()
+set_all_unseen (void)
{
thread_info *p;
/* debugging routine.
*/
static void
-print_tthread (p)
- thread_info *p;
+print_tthread (thread_info *p)
{
printf (" Thread pid %d, tid %d", p->pid, p->tid);
if (p->have_state)
}
static void
-print_tthreads ()
+print_tthreads (void)
{
thread_info *p;
/* Update the thread list based on the "seen" bits.
*/
static void
-update_thread_list ()
+update_thread_list (void)
{
thread_info *p;
thread_info *chase;
* No other "raw" calls to ttrace should exist in this module.
*/
static int
-call_real_ttrace (request, pid, tid, addr, data, addr2)
- ttreq_t request;
- pid_t pid;
- lwpid_t tid;
- TTRACE_ARG_TYPE addr, data, addr2;
+call_real_ttrace (ttreq_t request, pid_t pid, lwpid_t tid, TTRACE_ARG_TYPE addr,
+ TTRACE_ARG_TYPE data, TTRACE_ARG_TYPE addr2)
{
int tt_status;
* No "raw" calls to ttrace_wait should exist elsewhere.
*/
static int
-call_real_ttrace_wait (pid, tid, option, tsp, tsp_size)
- int pid;
- lwpid_t tid;
- ttwopt_t option;
- ttstate_t *tsp;
- size_t tsp_size;
+call_real_ttrace_wait (int pid, lwpid_t tid, ttwopt_t option, ttstate_t *tsp,
+ size_t tsp_size)
{
int ttw_status;
thread_info *tinfo = NULL;
to iterate over the IDs of all stopped threads of this process.
*/
static lwpid_t
-get_process_first_stopped_thread_id (pid, thread_state)
- int pid;
- ttstate_t *thread_state;
+get_process_first_stopped_thread_id (int pid, ttstate_t *thread_state)
{
int tt_status;
to iterate over the IDs of all stopped threads of this process.
*/
static lwpid_t
-get_process_next_stopped_thread_id (pid, thread_state)
- int pid;
- ttstate_t *thread_state;
+get_process_next_stopped_thread_id (int pid, ttstate_t *thread_state)
{
int tt_status;
NOTE: currently not called.
*/
static lwpid_t
-get_active_tid_of_pid (pid)
- int pid;
+get_active_tid_of_pid (int pid)
{
ttstate_t thread_state;
* operates upon all threads of a (i.e., the entire) process.
*/
int
-is_process_ttrace_request (tt_request)
- ttreq_t tt_request;
+is_process_ttrace_request (ttreq_t tt_request)
{
return IS_TTRACE_PROCREQ (tt_request);
}
* the equivalent process request for a one-thread process.
*/
static ttreq_t
-make_process_version (request)
- ttreq_t request;
+make_process_version (ttreq_t request)
{
if (!IS_TTRACE_REQ (request))
{
* reasons).
*/
static int
-call_ttrace (request, gdb_tid, addr, data, addr2)
- ttreq_t request;
- int gdb_tid;
- TTRACE_ARG_TYPE addr, data, addr2;
+call_ttrace (ttreq_t request, int gdb_tid, TTRACE_ARG_TYPE addr,
+ TTRACE_ARG_TYPE data, TTRACE_ARG_TYPE addr2)
{
lwpid_t real_tid;
int real_pid;
* very careful, and only call TT_PROC_STOP when you mean it!
*/
static void
-stop_all_threads_of_process (real_pid)
- pid_t real_pid;
+stop_all_threads_of_process (pid_t real_pid)
{
int ttw_status;
(((evt) == TTEVT_VFORK) && ((pid) == inferior_pid))
static int
-can_touch_threads_of_process (pid, stopping_event)
- int pid;
- ttevents_t stopping_event;
+can_touch_threads_of_process (int pid, ttevents_t stopping_event)
{
if (CHILD_VFORKED (stopping_event, pid))
{
* been stopped, undefined behaviour is guaranteed!
*/
static int
-select_stopped_thread_of_process (pid, tsp)
- int pid;
- ttstate_t *tsp;
+select_stopped_thread_of_process (int pid, ttstate_t *tsp)
{
lwpid_t candidate_tid, tid;
ttstate_t candidate_tstate, tstate;
/* Check our internal thread data against the real thing.
*/
static void
-check_thread_consistency (real_pid)
- pid_t real_pid;
+check_thread_consistency (pid_t real_pid)
{
int tid; /* really lwpid_t */
ttstate_t tstate;
* Return value is the status of the pseudo wait.
*/
static int
-call_ttrace_wait (pid, option, tsp, tsp_size)
- int pid;
- ttwopt_t option;
- ttstate_t *tsp;
- size_t tsp_size;
+call_ttrace_wait (int pid, ttwopt_t option, ttstate_t *tsp, size_t tsp_size)
{
/* This holds the actual, for-real, true process ID.
*/
#if defined(CHILD_REPORTED_EXEC_EVENTS_PER_EXEC_CALL)
int
-child_reported_exec_events_per_exec_call ()
+child_reported_exec_events_per_exec_call (void)
{
return 1; /* ttrace reports the event once per call. */
}
static void
-require_memory_page_dictionary ()
+require_memory_page_dictionary (void)
{
int i;
static void
-retire_memory_page_dictionary ()
+retire_memory_page_dictionary (void)
{
memory_page_dictionary.page_count = (LONGEST) - 1;
}
Returns the original permissions of the page.
*/
static int
-write_protect_page (pid, page_start)
- int pid;
- CORE_ADDR page_start;
+write_protect_page (int pid, CORE_ADDR page_start)
{
int tt_status;
int original_permissions;
(what we must assume are) its original permissions.
*/
static void
-unwrite_protect_page (pid, page_start, original_permissions)
- int pid;
- CORE_ADDR page_start;
- int original_permissions;
+unwrite_protect_page (int pid, CORE_ADDR page_start, int original_permissions)
{
int tt_status;
presently should be write-protected), write-protect it.
*/
void
-hppa_enable_page_protection_events (pid)
- int pid;
+hppa_enable_page_protection_events (int pid)
{
int bucket;
presently is or should be write-protected), un-write-protect it.
*/
void
-hppa_disable_page_protection_events (pid)
- int pid;
+hppa_disable_page_protection_events (int pid)
{
int bucket;
* Note: we could just scan our own thread list. FIXME!
*/
static int
-count_unhandled_events (real_pid, real_tid)
- int real_pid;
- lwpid_t real_tid;
+count_unhandled_events (int real_pid, lwpid_t real_tid)
{
ttstate_t tstate;
lwpid_t ttid;
* Note: used by core gdb and so uses the pseudo-pid (really tid).
*/
int
-ptrace_wait (pid, status)
- int pid;
- int *status;
+ptrace_wait (int pid, int *status)
{
ttstate_t tsp;
int ttwait_return;
child_acknowledge_created_inferior.)
*/
int
-parent_attach_all ()
+parent_attach_all (void)
{
int tt_status;
* have to be the common part of both.
*/
static void
-require_notification_of_events (real_pid)
- int real_pid;
+require_notification_of_events (int real_pid)
{
int tt_status;
ttevent_t notifiable_events;
}
static void
-require_notification_of_exec_events (real_pid)
- int real_pid;
+require_notification_of_exec_events (int real_pid)
{
int tt_status;
ttevent_t notifiable_events;
* ID of the child process, after the debugger has forked.
*/
void
-child_acknowledge_created_inferior (pid)
- int pid;
+child_acknowledge_created_inferior (int pid)
{
/* We need a memory home for a constant, to pass it to ttrace.
The value of the constant is arbitrary, so long as both
* calling require_notification_of_events.
*/
void
-child_post_startup_inferior (real_pid)
- int real_pid;
+child_post_startup_inferior (int real_pid)
{
require_notification_of_events (real_pid);
}
/* From here on, we should expect tids rather than pids.
*/
static void
-hppa_enable_catch_fork (tid)
- int tid;
+hppa_enable_catch_fork (int tid)
{
int tt_status;
ttevent_t ttrace_events;
static void
-hppa_disable_catch_fork (tid)
- int tid;
+hppa_disable_catch_fork (int tid)
{
int tt_status;
ttevent_t ttrace_events;
#if defined(CHILD_INSERT_FORK_CATCHPOINT)
int
-child_insert_fork_catchpoint (tid)
- int tid;
+child_insert_fork_catchpoint (int tid)
{
/* Enable reporting of fork events from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
#if defined(CHILD_REMOVE_FORK_CATCHPOINT)
int
-child_remove_fork_catchpoint (tid)
- int tid;
+child_remove_fork_catchpoint (int tid)
{
/* Disable reporting of fork events from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
static void
-hppa_enable_catch_vfork (tid)
- int tid;
+hppa_enable_catch_vfork (int tid)
{
int tt_status;
ttevent_t ttrace_events;
static void
-hppa_disable_catch_vfork (tid)
- int tid;
+hppa_disable_catch_vfork (int tid)
{
int tt_status;
ttevent_t ttrace_events;
#if defined(CHILD_INSERT_VFORK_CATCHPOINT)
int
-child_insert_vfork_catchpoint (tid)
- int tid;
+child_insert_vfork_catchpoint (int tid)
{
/* Enable reporting of vfork events from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
#if defined(CHILD_REMOVE_VFORK_CATCHPOINT)
int
-child_remove_vfork_catchpoint (tid)
- int tid;
+child_remove_vfork_catchpoint (int tid)
{
/* Disable reporting of vfork events from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
* start the mapping.
*/
int
-child_has_forked (tid, childpid)
- int tid;
- int *childpid;
+child_has_forked (int tid, int *childpid)
{
int tt_status;
ttstate_t ttrace_state;
/* See child_has_forked for pid discussion.
*/
int
-child_has_vforked (tid, childpid)
- int tid;
- int *childpid;
+child_has_vforked (int tid, int *childpid)
{
int tt_status;
ttstate_t ttrace_state;
#if defined(CHILD_CAN_FOLLOW_VFORK_PRIOR_TO_EXEC)
int
-child_can_follow_vfork_prior_to_exec ()
+child_can_follow_vfork_prior_to_exec (void)
{
/* ttrace does allow this.
#if defined(CHILD_INSERT_EXEC_CATCHPOINT)
int
-child_insert_exec_catchpoint (tid)
- int tid;
+child_insert_exec_catchpoint (int tid)
{
/* Enable reporting of exec events from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
#if defined(CHILD_REMOVE_EXEC_CATCHPOINT)
int
-child_remove_exec_catchpoint (tid)
- int tid;
+child_remove_exec_catchpoint (int tid)
{
/* Disable reporting of execevents from the kernel. */
/* ??rehrauer: For the moment, we're always enabling these events,
#if defined(CHILD_HAS_EXECD)
int
-child_has_execd (tid, execd_pathname)
- int tid;
- char **execd_pathname;
+child_has_execd (int tid, char **execd_pathname)
{
int tt_status;
ttstate_t ttrace_state;
#if defined(CHILD_HAS_SYSCALL_EVENT)
int
-child_has_syscall_event (pid, kind, syscall_id)
- int pid;
- enum target_waitkind *kind;
- int *syscall_id;
+child_has_syscall_event (int pid, enum target_waitkind *kind, int *syscall_id)
{
int tt_status;
ttstate_t ttrace_state;
* May need a FIXME for that reason.
*/
int
-child_thread_alive (gdb_tid)
- lwpid_t gdb_tid;
+child_thread_alive (lwpid_t gdb_tid)
{
lwpid_t tid;
undefined it this function fails.
*/
int
-read_from_register_save_state (tid, ss_offset, buf, sizeof_buf)
- int tid;
- TTRACE_ARG_TYPE ss_offset;
- char *buf;
- int sizeof_buf;
+read_from_register_save_state (int tid, TTRACE_ARG_TYPE ss_offset, char *buf,
+ int sizeof_buf)
{
int tt_status;
register_value_t register_value = 0;
are undefined it this function fails.
*/
int
-write_to_register_save_state (tid, ss_offset, buf, sizeof_buf)
- int tid;
- TTRACE_ARG_TYPE ss_offset;
- char *buf;
- int sizeof_buf;
+write_to_register_save_state (int tid, TTRACE_ARG_TYPE ss_offset, char *buf,
+ int sizeof_buf)
{
int tt_status;
register_value_t register_value = 0;
process-specific, ttrace equivalents.
*/
int
-call_ptrace (pt_request, gdb_tid, addr, data)
- int pt_request;
- int gdb_tid;
- PTRACE_ARG3_TYPE addr;
- int data;
+call_ptrace (int pt_request, int gdb_tid, PTRACE_ARG3_TYPE addr, int data)
{
ttreq_t tt_request;
TTRACE_ARG_TYPE tt_addr = (TTRACE_ARG_TYPE) addr;
/* Kill that pesky process!
*/
void
-kill_inferior ()
+kill_inferior (void)
{
int tid;
int wait_status;
/* Sanity check a thread about to be continued.
*/
static void
-thread_dropping_event_check (p)
- thread_info *p;
+thread_dropping_event_check (thread_info *p)
{
if (!p->handled)
{
* the one specified, which is to be stepped.
*/
static void
-threads_continue_all_but_one (gdb_tid, signal)
- lwpid_t gdb_tid;
- int signal;
+threads_continue_all_but_one (lwpid_t gdb_tid, int signal)
{
thread_info *p;
int thread_signal;
* This is done when a signal must be sent to any of the threads.
*/
static void
-threads_continue_all_with_signals (gdb_tid, signal)
- lwpid_t gdb_tid;
- int signal;
+threads_continue_all_with_signals (lwpid_t gdb_tid, int signal)
{
thread_info *p;
int thread_signal;
/* Step one thread only.
*/
static void
-thread_fake_step (tid, signal)
- lwpid_t tid;
- enum target_signal signal;
+thread_fake_step (lwpid_t tid, enum target_signal signal)
{
thread_info *p;
/* Continue one thread when a signal must be sent to it.
*/
static void
-threads_continue_one_with_signal (gdb_tid, signal)
- lwpid_t gdb_tid;
- int signal;
+threads_continue_one_with_signal (lwpid_t gdb_tid, int signal)
{
thread_info *p;
lwpid_t real_tid;
* | user command.
*/
void
-child_resume (gdb_tid, step, signal)
- lwpid_t gdb_tid;
- int step;
- enum target_signal signal;
+child_resume (lwpid_t gdb_tid, int step, enum target_signal signal)
{
int resume_all_threads;
lwpid_t tid;
*
*/
static void
-update_thread_state_after_attach (pid, kind_of_go)
- int pid;
- attach_continue_t kind_of_go;
+update_thread_state_after_attach (int pid, attach_continue_t kind_of_go)
{
int tt_status;
ttstate_t thread_state;
* (A _real_ pid).
*/
int
-attach (pid)
- int pid;
+attach (int pid)
{
int tt_status;
#if defined(CHILD_POST_ATTACH)
void
-child_post_attach (pid)
- int pid;
+child_post_attach (int pid)
{
#ifdef THREAD_DEBUG
if (debug_on)
SIGNAL = 0 means just continue it.
*/
void
-detach (signal)
- int signal;
+detach (int signal)
{
errno = 0;
call_ttrace (TT_PROC_DETACH,
#endif
void
-_initialize_kernel_u_addr ()
+_initialize_kernel_u_addr (void)
{
}
\f
static void
-udot_info ()
+udot_info (void)
{
int udot_off; /* Offset into user struct */
int udot_val; /* Value from user struct at udot_off */
/* TTrace version of "target_pid_to_exec_file"
*/
char *
-child_pid_to_exec_file (tid)
- int tid;
+child_pid_to_exec_file (int tid)
{
static char exec_file_buffer[1024];
int tt_status;
void
-pre_fork_inferior ()
+pre_fork_inferior (void)
{
int status;
* seems odd--it always fails in our test system.
*/
int
-hppa_require_attach (pid)
- int pid;
+hppa_require_attach (int pid)
{
int tt_status;
CORE_ADDR pc;
}
int
-hppa_require_detach (pid, signal)
- int pid;
- int signal;
+hppa_require_detach (int pid, int signal)
{
int tt_status;
the memory page dictionary.
*/
static int
-get_dictionary_bucket_of_page (page_start)
- CORE_ADDR page_start;
+get_dictionary_bucket_of_page (CORE_ADDR page_start)
{
int hash;
count of 0 (if the page was newly-added to the dictionary).
*/
static memory_page_t *
-get_dictionary_entry_of_page (pid, page_start)
- int pid;
- CORE_ADDR page_start;
+get_dictionary_entry_of_page (int pid, CORE_ADDR page_start)
{
int bucket;
memory_page_t *page = NULL;
static void
-remove_dictionary_entry_of_page (pid, page)
- int pid;
- memory_page_t *page;
+remove_dictionary_entry_of_page (int pid, memory_page_t *page)
{
/* Restore the page's original permissions. */
unwrite_protect_page (pid, page->page_start, page->original_permissions);
static void
-hppa_enable_syscall_events (pid)
- int pid;
+hppa_enable_syscall_events (int pid)
{
int tt_status;
ttevent_t ttrace_events;
static void
-hppa_disable_syscall_events (pid)
- int pid;
+hppa_disable_syscall_events (int pid)
{
int tt_status;
ttevent_t ttrace_events;
from the TYPE that is passed to hppa_remove_hw_watchpoint.)
*/
int
-hppa_insert_hw_watchpoint (pid, start, len, type)
- int pid;
- CORE_ADDR start;
- LONGEST len;
- int type;
+hppa_insert_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len, int type)
{
CORE_ADDR page_start;
int dictionary_was_empty;
watchpoints.
*/
int
-hppa_remove_hw_watchpoint (pid, start, len, type)
- int pid;
- CORE_ADDR start;
- LONGEST len;
- enum bptype type;
+hppa_remove_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len,
+ enum bptype type)
{
CORE_ADDR page_start;
int dictionary_is_empty;
hardware support.
*/
int
-hppa_can_use_hw_watchpoint (type, cnt, ot)
- enum bptype type;
- int cnt;
- enum bptype ot;
+hppa_can_use_hw_watchpoint (enum bptype type, int cnt, enum bptype ot)
{
return (type == bp_hardware_watchpoint);
}
on the address...
*/
int
-hppa_range_profitable_for_hw_watchpoint (pid, start, len)
- int pid;
- CORE_ADDR start;
- LONGEST len;
+hppa_range_profitable_for_hw_watchpoint (int pid, CORE_ADDR start, LONGEST len)
{
int range_is_stack_based;
int range_is_accessible;
char *
-hppa_pid_or_tid_to_str (id)
- pid_t id;
+hppa_pid_or_tid_to_str (pid_t id)
{
static char buf[100]; /* Static because address returned. */
* the old thread id, else return 0.
*/
pid_t
-hppa_switched_threads (gdb_pid)
- pid_t gdb_pid;
+hppa_switched_threads (pid_t gdb_pid)
{
if (gdb_pid == old_gdb_pid)
{
}
void
-hppa_ensure_vforking_parent_remains_stopped (pid)
- int pid;
+hppa_ensure_vforking_parent_remains_stopped (int pid)
{
/* Nothing to do when using ttrace. Only the ptrace-based implementation
must do real work.
int
-hppa_resume_execd_vforking_child_to_get_parent_vfork ()
+hppa_resume_execd_vforking_child_to_get_parent_vfork (void)
{
return 0; /* No, the parent vfork is available now. */
}
This is horribly gross and disgusting. */
int
-ttrace_write_reg_64 (gdb_tid, dest_addr, src_addr)
- int gdb_tid;
- CORE_ADDR dest_addr;
- CORE_ADDR src_addr;
+ttrace_write_reg_64 (int gdb_tid, CORE_ADDR dest_addr, CORE_ADDR src_addr)
{
pid_t pid;
lwpid_t tid;
}
void
-_initialize_infttrace ()
+_initialize_infttrace (void)
{
/* Initialize the ttrace-based hardware watchpoint implementation. */
memory_page_dictionary.page_count = (LONGEST) - 1;
*/
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) (gregsetp->gp_regs);
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = (greg_t *) (gregsetp->gp_regs);
*/
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
static char zerobuf[MAX_REGISTER_RAW_SIZE] =
}
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *from, *to;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR jb_addr;
};
void
-_initialize_core_irix4 ()
+_initialize_core_irix4 (void)
{
add_core_fns (&irix4_core_fns);
}
*/
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = &(*gregsetp)[0];
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = &(*gregsetp)[0];
*/
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
static char zerobuf[MAX_REGISTER_RAW_SIZE] =
}
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *from, *to;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR jb_addr;
*/
static CORE_ADDR
-locate_base ()
+locate_base (void)
{
struct minimal_symbol *msymbol;
CORE_ADDR address = 0;
*/
static struct link_map *
-first_link_map_member ()
+first_link_map_member (void)
{
struct obj_list *listp;
struct obj_list list_old;
*/
static struct link_map *
-next_link_map_member (so_list_ptr)
- struct so_list *so_list_ptr;
+next_link_map_member (struct so_list *so_list_ptr)
{
struct link_map *lm = &so_list_ptr->lm;
CORE_ADDR next_lladdr = lm->l_next;
*/
static void
-xfer_link_map_member (so_list_ptr, lm)
- struct so_list *so_list_ptr;
- struct link_map *lm;
+xfer_link_map_member (struct so_list *so_list_ptr, struct link_map *lm)
{
struct obj_list list_old;
CORE_ADDR lladdr = lm->l_lladdr;
*/
void
-solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
register struct so_list *so = NULL; /* link map state variable */
*/
static void
-info_sharedlibrary_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+info_sharedlibrary_command (char *ignore, int from_tty)
{
register struct so_list *so = NULL; /* link map state variable */
int header_done = 0;
*/
char *
-solib_address (address)
- CORE_ADDR address;
+solib_address (CORE_ADDR address)
{
register struct so_list *so = 0; /* link map state variable */
/* Called by free_all_symtabs */
void
-clear_solib ()
+clear_solib (void)
{
struct so_list *next;
char *bfd_filename;
*/
static int
-disable_break ()
+disable_break (void)
{
int status = 1;
*/
static int
-enable_break ()
+enable_break (void)
{
if (symfile_objfile != NULL
&& target_insert_breakpoint (symfile_objfile->ei.entry_point,
*/
void
-solib_create_inferior_hook ()
+solib_create_inferior_hook (void)
{
if (!enable_break ())
{
*/
static void
-sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
solib_add (args, from_tty, (struct target_ops *) 0);
}
void
-_initialize_solib ()
+_initialize_solib (void)
{
add_com ("sharedlibrary", class_files, sharedlibrary_command,
"Load shared object library symbols for files matching REGEXP.");
};
void
-_initialize_core_irix5 ()
+_initialize_core_irix5 (void)
{
add_core_fns (&irix5_core_fns);
}
static struct type *java_link_class_type (struct type *, value_ptr);
static struct objfile *
-get_dynamics_objfile ()
+get_dynamics_objfile (void)
{
if (dynamics_objfile == NULL)
{
static int class_symtab_space;
static struct symtab *
-get_java_class_symtab ()
+get_java_class_symtab (void)
{
if (class_symtab == NULL)
{
}
static void
-add_class_symtab_symbol (sym)
- struct symbol *sym;
+add_class_symtab_symbol (struct symbol *sym)
{
struct symtab *symtab = get_java_class_symtab ();
struct blockvector *bv = BLOCKVECTOR (symtab);
static struct symbol *add_class_symbol (struct type *type, CORE_ADDR addr);
static struct symbol *
-add_class_symbol (type, addr)
- struct type *type;
- CORE_ADDR addr;
+add_class_symbol (struct type *type, CORE_ADDR addr)
{
struct symbol *sym;
sym = (struct symbol *)
#endif
struct type *
-java_lookup_class (name)
- char *name;
+java_lookup_class (char *name)
{
struct symbol *sym;
sym = lookup_symbol (name, expression_context_block, STRUCT_NAMESPACE,
a name given by NAME (which has type Utf8Const*). */
char *
-get_java_utf8_name (obstack, name)
- struct obstack *obstack;
- value_ptr name;
+get_java_utf8_name (struct obstack *obstack, value_ptr name)
{
char *chrs;
value_ptr temp = name;
}
value_ptr
-java_class_from_object (obj_val)
- value_ptr obj_val;
+java_class_from_object (value_ptr obj_val)
{
/* This is all rather inefficient, since the offsets of vtable and
class are fixed. FIXME */
/* Check if CLASS_IS_PRIMITIVE(value of clas): */
static int
-java_class_is_primitive (clas)
- value_ptr clas;
+java_class_is_primitive (value_ptr clas)
{
value_ptr vtable = value_struct_elt (&clas, NULL, "vtable", NULL, "struct");
CORE_ADDR i = value_as_pointer (vtable);
/* Read a GCJ Class object, and generated a gdb (TYPE_CODE_STRUCT) type. */
struct type *
-type_from_class (clas)
- value_ptr clas;
+type_from_class (value_ptr clas)
{
struct type *type;
char *name;
/* Fill in class TYPE with data from the CLAS value. */
struct type *
-java_link_class_type (type, clas)
- struct type *type;
- value_ptr clas;
+java_link_class_type (struct type *type, value_ptr clas)
{
value_ptr temp;
char *unqualified_name;
static struct type *java_object_type;
struct type *
-get_java_object_type ()
+get_java_object_type (void)
{
if (java_object_type == NULL)
{
}
int
-get_java_object_header_size ()
+get_java_object_header_size (void)
{
struct type *objtype = get_java_object_type ();
if (objtype == NULL)
}
int
-is_object_type (type)
- struct type *type;
+is_object_type (struct type *type)
{
CHECK_TYPEDEF (type);
if (TYPE_CODE (type) == TYPE_CODE_PTR)
}
struct type *
-java_primitive_type (signature)
- int signature;
+java_primitive_type (int signature)
{
switch (signature)
{
return that type. Otherwise, return NULL. */
struct type *
-java_primitive_type_from_name (name, namelen)
- char *name;
- int namelen;
+java_primitive_type_from_name (char *name, int namelen)
{
switch (name[0])
{
signature string SIGNATURE. */
static int
-java_demangled_signature_length (signature)
- char *signature;
+java_demangled_signature_length (char *signature)
{
int array = 0;
for (; *signature == '['; signature++)
/* Demangle the Java type signature SIGNATURE, leaving the result in RESULT. */
static void
-java_demangled_signature_copy (result, signature)
- char *result;
- char *signature;
+java_demangled_signature_copy (char *result, char *signature)
{
int array = 0;
char *ptr;
as a freshly allocated copy. */
char *
-java_demangle_type_signature (signature)
- char *signature;
+java_demangle_type_signature (char *signature)
{
int length = java_demangled_signature_length (signature);
char *result = xmalloc (length + 1);
}
struct type *
-java_lookup_type (signature)
- char *signature;
+java_lookup_type (char *signature)
{
switch (signature[0])
{
If DIMS == 0, TYPE is returned. */
struct type *
-java_array_type (type, dims)
- struct type *type;
- int dims;
+java_array_type (struct type *type, int dims)
{
struct type *range_type;
/* Create a Java string in the inferior from a (Utf8) literal. */
static value_ptr
-java_value_string (ptr, len)
- char *ptr;
- int len;
+java_value_string (char *ptr, int len)
{
error ("not implemented - java_value_string"); /* FIXME */
}
characters and strings is language specific. */
static void
-java_emit_char (c, stream, quoter)
- int c;
- struct ui_file *stream;
- int quoter;
+java_emit_char (int c, struct ui_file *stream, int quoter)
{
switch (c)
{
}
static value_ptr
-evaluate_subexp_java (expect_type, exp, pos, noside)
- struct type *expect_type;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_java (struct type *expect_type, register struct expression *exp,
+ register int *pos, enum noside noside)
{
int pc = *pos;
int i;
}
static struct type *
-java_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+java_create_fundamental_type (struct objfile *objfile, int typeid)
{
switch (typeid)
{
};
void
-_initialize_java_language ()
+_initialize_java_language (void)
{
java_int_type = init_type (TYPE_CODE_INT, 4, 0, "int", NULL);
extern void java_rerun_cleanup (void);
void
-java_rerun_cleanup ()
+java_rerun_cleanup (void)
{
if (class_symtab != NULL)
{
int level);
static void
-java_type_print_derivation_info (stream, type)
- struct ui_file *stream;
- struct type *type;
+java_type_print_derivation_info (struct ui_file *stream, struct type *type)
{
char *name;
int i;
We increase it for some recursive calls. */
static void
-java_type_print_base (type, stream, show, level)
- struct type *type;
- struct ui_file *stream;
- int show;
- int level;
+java_type_print_base (struct type *type, struct ui_file *stream, int show,
+ int level)
{
register int i;
register int len;
int, int, int);
void
-java_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+java_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
int demangled_args;
int
-java_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+java_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
struct type *type;
CORE_ADDR address;
should not print, or zero if called from top level. */
static void
-java_print_value_fields (type, valaddr, address, stream,
- format, recurse, pretty)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
+java_print_value_fields (struct type *type, char *valaddr, CORE_ADDR address,
+ struct ui_file *stream, int format, int recurse,
+ enum val_prettyprint pretty)
{
int i, len, n_baseclasses;
The PRETTY parameter controls prettyprinting. */
int
-java_val_print (type, valaddr, embedded_offset, address, stream, format,
- deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+java_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
register unsigned int i = 0; /* Number of characters printed */
struct type *target_type;
char **environ;
-start ()
+start (void)
{
INIT_STACK (kdb_stack_beg, kdb_stack_end);
/* Close the connection. */
void
-cisco_kod_close ()
+cisco_kod_close (void)
{
}
/* Print a "bad packet" message. */
static void
-bad_packet ()
+bad_packet (void)
{
(*gdb_kod_display) ("Remote target returned malformed packet.\n");
}
}
void
-_initialize_kod ()
+_initialize_kod (void)
{
struct cmd_list_element *c;
/* Show command. Display a warning if the language set
does not match the frame. */
static void
-show_language_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_language_command (char *ignore, int from_tty)
{
enum language flang; /* The language of the current frame */
/* Set command. Change the current working language. */
static void
-set_language_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+set_language_command (char *ignore, int from_tty)
{
int i;
enum language flang;
/* Show command. Display a warning if the type setting does
not match the current language. */
static void
-show_type_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_type_command (char *ignore, int from_tty)
{
if (type_check != current_language->la_type_check)
printf_unfiltered (
/* Set command. Change the setting for type checking. */
static void
-set_type_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+set_type_command (char *ignore, int from_tty)
{
if (STREQ (type, "on"))
{
/* Show command. Display a warning if the range setting does
not match the current language. */
static void
-show_range_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_range_command (char *ignore, int from_tty)
{
if (range_check != current_language->la_range_check)
/* Set command. Change the setting for range checking. */
static void
-set_range_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+set_range_command (char *ignore, int from_tty)
{
if (STREQ (range, "on"))
{
If SHOW is non-zero, then print out the current language,
type and range checking status. */
static void
-set_type_range ()
+set_type_range (void)
{
if (range_mode == range_mode_auto)
/* Set current language to (enum language) LANG. Returns previous language. */
enum language
-set_language (lang)
- enum language lang;
+set_language (enum language lang)
{
int i;
enum language prev_language;
/* This page contains functions that update the global vars
language, type and range. */
static void
-set_lang_str ()
+set_lang_str (void)
{
char *prefix = "";
}
static void
-set_type_str ()
+set_type_str (void)
{
char *tmp = NULL, *prefix = "";
}
static void
-set_range_str ()
+set_range_str (void)
{
char *tmp, *pref = "";
type checking. If QUIETLY, print only what has changed. */
void
-language_info (quietly)
- int quietly;
+language_info (int quietly)
{
if (quietly && expected_language == current_language)
return;
#if 0 /* Currently unused */
struct type *
-binop_result_type (v1, v2)
- value_ptr v1, v2;
+binop_result_type (value_ptr v1, value_ptr v2)
{
int size, uns;
struct type *t1 = check_typedef (VALUE_TYPE (v1));
/* Returns the appropriate printf format for hexadecimal
numbers. */
char *
-local_hex_format_custom (pre)
- char *pre;
+local_hex_format_custom (char *pre)
{
static char form[50];
static string. Returns a pointer to this string. */
char *
-longest_raw_hex_string (num)
- LONGEST num;
+longest_raw_hex_string (LONGEST num)
{
static char res_longest_raw_hex_string[50];
long long ll = num; /* MERGEBUG ?? see below */
/* Converts a number to hexadecimal and stores it in a static
string. Returns a pointer to this string. */
char *
-local_hex_string (num)
- unsigned long num;
+local_hex_string (unsigned long num)
{
static char res[50];
/* Converts a LONGEST number to hexadecimal and stores it in a static
string. Returns a pointer to this string. */
char *
-longest_local_hex_string (num)
- LONGEST num;
+longest_local_hex_string (LONGEST num)
{
return longest_local_hex_string_custom (num, "l");
}
/* Converts a number to custom hexadecimal and stores it in a static
string. Returns a pointer to this string. */
char *
-local_hex_string_custom (num, pre)
- unsigned long num;
- char *pre;
+local_hex_string_custom (unsigned long num, char *pre)
{
static char res[50];
should end with "l", e.g. "08l" as with calls to local_hex_string_custom */
char *
-longest_local_hex_string_custom (num, width)
- LONGEST num;
- char *width;
+longest_local_hex_string_custom (LONGEST num, char *width)
{
#define RESULT_BUF_LEN 50
static char res2[RESULT_BUF_LEN];
/* Returns the appropriate printf format for octal
numbers. */
char *
-local_octal_format_custom (pre)
- char *pre;
+local_octal_format_custom (char *pre)
{
static char form[50];
/* Returns the appropriate printf format for decimal numbers. */
char *
-local_decimal_format_custom (pre)
- char *pre;
+local_decimal_format_custom (char *pre)
{
static char form[50];
both Modula-2 and for C. In the C case, TYPE_CODE_CHAR will never occur,
and thus will never cause the failure of the test. */
int
-simple_type (type)
- struct type *type;
+simple_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (TYPE_CODE (type))
properties of "greater than", "less than", etc, or for which the
operations "increment" or "decrement" make sense. */
int
-ordered_type (type)
- struct type *type;
+ordered_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (TYPE_CODE (type))
/* Returns non-zero if the two types are the same */
int
-same_type (arg1, arg2)
- struct type *arg1, *arg2;
+same_type (struct type *arg1, struct type *arg2)
{
CHECK_TYPEDEF (type);
if (structured_type (arg1) ? !structured_type (arg2) : structured_type (arg2))
/* Returns non-zero if the type is integral */
int
-integral_type (type)
- struct type *type;
+integral_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (current_language->la_language)
/* Returns non-zero if the value is numeric */
int
-numeric_type (type)
- struct type *type;
+numeric_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (TYPE_CODE (type))
/* Returns non-zero if the value is a character type */
int
-character_type (type)
- struct type *type;
+character_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (current_language->la_language)
/* Returns non-zero if the value is a string type */
int
-string_type (type)
- struct type *type;
+string_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (current_language->la_language)
/* Returns non-zero if the value is a boolean type */
int
-boolean_type (type)
- struct type *type;
+boolean_type (struct type *type)
{
CHECK_TYPEDEF (type);
if (TYPE_CODE (type) == TYPE_CODE_BOOL)
/* Returns non-zero if the value is a floating-point type */
int
-float_type (type)
- struct type *type;
+float_type (struct type *type)
{
CHECK_TYPEDEF (type);
return TYPE_CODE (type) == TYPE_CODE_FLT;
/* Returns non-zero if the value is a pointer type */
int
-pointer_type (type)
- struct type *type;
+pointer_type (struct type *type)
{
return TYPE_CODE (type) == TYPE_CODE_PTR ||
TYPE_CODE (type) == TYPE_CODE_REF;
/* Returns non-zero if the value is a structured type */
int
-structured_type (type)
- struct type *type;
+structured_type (struct type *type)
{
CHECK_TYPEDEF (type);
switch (current_language->la_language)
#endif
\f
struct type *
-lang_bool_type ()
+lang_bool_type (void)
{
struct symbol *sym;
struct type *type;
/* Returns non-zero if the value VAL represents a true value. */
int
-value_true (val)
- value_ptr val;
+value_true (value_ptr val)
{
/* It is possible that we should have some sort of error if a non-boolean
value is used in this context. Possibly dependent on some kind of
#if 0 /* Currently unused */
void
-binop_type_check (arg1, arg2, op)
- value_ptr arg1, arg2;
- int op;
+binop_type_check (value_ptr arg1, value_ptr arg2, int op)
{
struct type *t1, *t2;
this is an error and error () is called. Otherwise, it is
a warning and printf() is called. */
void
-op_error (fmt, op, fatal)
- char *fmt;
- enum exp_opcode op;
- int fatal;
+op_error (char *fmt, enum exp_opcode op, int fatal)
{
if (fatal)
error (fmt, op_string (op));
/* Return the language enum for a given language string. */
enum language
-language_enum (str)
- char *str;
+language_enum (char *str)
{
int i;
/* Return the language struct for a given language enum. */
const struct language_defn *
-language_def (lang)
- enum language lang;
+language_def (enum language lang)
{
int i;
/* Return the language as a string */
char *
-language_str (lang)
- enum language lang;
+language_str (enum language lang)
{
int i;
}
static void
-set_check (ignore, from_tty)
- char *ignore;
- int from_tty;
+set_check (char *ignore, int from_tty)
{
printf_unfiltered (
"\"set check\" must be followed by the name of a check subcommand.\n");
}
static void
-show_check (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_check (char *ignore, int from_tty)
{
cmd_show_list (showchecklist, from_tty, "");
}
/* Add a language to the set of known languages. */
void
-add_language (lang)
- const struct language_defn *lang;
+add_language (const struct language_defn *lang)
{
if (lang->la_magic != LANG_MAGIC)
{
/* Define the language that is no language. */
static int
-unk_lang_parser ()
+unk_lang_parser (void)
{
return 1;
}
static void
-unk_lang_error (msg)
- char *msg;
+unk_lang_error (char *msg)
{
error ("Attempted to parse an expression with unknown language");
}
static void
-unk_lang_emit_char (c, stream, quoter)
- register int c;
- struct ui_file *stream;
- int quoter;
+unk_lang_emit_char (register int c, struct ui_file *stream, int quoter)
{
error ("internal error - unimplemented function unk_lang_emit_char called.");
}
static void
-unk_lang_printchar (c, stream)
- register int c;
- struct ui_file *stream;
+unk_lang_printchar (register int c, struct ui_file *stream)
{
error ("internal error - unimplemented function unk_lang_printchar called.");
}
static void
-unk_lang_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+unk_lang_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
error ("internal error - unimplemented function unk_lang_printstr called.");
}
static struct type *
-unk_lang_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+unk_lang_create_fundamental_type (struct objfile *objfile, int typeid)
{
error ("internal error - unimplemented function unk_lang_create_fundamental_type called.");
}
static void
-unk_lang_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+unk_lang_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
error ("internal error - unimplemented function unk_lang_print_type called.");
}
static int
-unk_lang_val_print (type, valaddr, embedded_offset, address, stream, format, deref_ref,
- recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+unk_lang_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
error ("internal error - unimplemented function unk_lang_val_print called.");
}
static int
-unk_lang_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+unk_lang_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
error ("internal error - unimplemented function unk_lang_value_print called.");
}
/* Initialize the language routines */
void
-_initialize_language ()
+_initialize_language (void)
{
struct cmd_list_element *set, *show;
*/
static int
-init_thread_db_library ()
+init_thread_db_library (void)
{
void *dlhandle;
td_err_e ret;
*/
static char *
-thr_err_string (errcode)
- td_err_e errcode;
+thr_err_string (td_err_e errcode)
{
static char buf[50];
*/
static char *
-thr_state_string (statecode)
- td_thr_state_e statecode;
+thr_state_string (td_thr_state_e statecode)
{
static char buf[50];
#define THREADLIST_ALLOC 100 /* chunk size by which to expand table */
static threadinfo *
-insert_thread (tid, lid, state, type)
- int tid;
- int lid;
- td_thr_state_e state;
- td_thr_type_e type;
+insert_thread (int tid, int lid, td_thr_state_e state, td_thr_type_e type)
{
if (threadlist_top >= threadlist_max)
{
}
static void
-empty_threadlist ()
+empty_threadlist (void)
{
threadlist_top = 0;
}
static threadinfo *
-next_pending_event ()
+next_pending_event (void)
{
int i;
The thread-specific enabling is handled per-thread elsewhere. */
static void
-enable_thread_event_reporting (ta)
- td_thragent_t *ta;
+enable_thread_event_reporting (td_thragent_t *ta)
{
td_thr_events_t events;
td_notify_t notify;
The thread-specific enabling is handled per-thread elsewhere. */
static void
-disable_thread_event_reporting (ta)
- td_thragent_t *ta;
+disable_thread_event_reporting (td_thragent_t *ta)
{
td_thr_events_t events;
*/
static int
-thread_db_alive (pid)
- int pid;
+thread_db_alive (int pid)
{
if (is_thread (pid)) /* user-space (non-kernel) thread */
{
*/
static int /* lwpid_t or pid_t */
-get_lwp_from_thread_handle (th)
- td_thrhandle_t *th;
+get_lwp_from_thread_handle (td_thrhandle_t *th)
{
td_thrinfo_t ti;
td_err_e ret;
*/
static void
-thread_db_fetch_registers (regno)
- int regno;
+thread_db_fetch_registers (int regno)
{
td_thrhandle_t thandle;
gdb_prfpregset_t fpregset;
*/
static void
-thread_db_store_registers (regno)
- int regno;
+thread_db_store_registers (int regno)
{
td_thrhandle_t thandle;
gdb_prfpregset_t fpregset;
}
static void
-handle_new_thread (tid, lid, verbose)
- int tid; /* user thread id */
- int lid; /* kernel thread id */
- int verbose;
+handle_new_thread (int tid, /* user thread id */
+ int lid, /* kernel thread id */
+ int verbose)
{
int gdb_pid = BUILD_THREAD (tid, main_prochandle.pid);
int wait_pid, wait_status;
}
static void
-test_for_new_thread (tid, lid, verbose)
- int tid;
- int lid;
- int verbose;
+test_for_new_thread (int tid, int lid, int verbose)
{
if (!in_thread_list (BUILD_THREAD (tid, main_prochandle.pid)))
handle_new_thread (tid, lid, verbose);
*/
static int
-find_new_threads_callback (th, ignored)
- const td_thrhandle_t *th;
- void *ignored;
+find_new_threads_callback (const td_thrhandle_t *th, void *ignored)
{
td_thrinfo_t ti;
td_err_e ret;
*/
static void
-thread_db_find_new_threads ()
+thread_db_find_new_threads (void)
{
if (inferior_pid == -1) /* FIXME: still necessary? */
{
*/
static int
-resume_thread_callback (th, data)
- const td_thrhandle_t *th;
- void *data;
+resume_thread_callback (const td_thrhandle_t *th, void *data)
{
td_thrinfo_t ti;
td_err_e ret;
}
static int
-new_resume_thread_callback (thread, data)
- threadinfo *thread;
- void *data;
+new_resume_thread_callback (threadinfo *thread, void *data)
{
if (thread->lid != event_pid &&
thread->lid != main_prochandle.pid)
static int last_resume_signo;
static void
-thread_db_resume (pid, step, signo)
- int pid;
- int step;
- enum target_signal signo;
+thread_db_resume (int pid, int step, enum target_signal signo)
{
last_resume_pid = pid;
last_resume_step = step;
*/
static void
-wait_for_stop (pid)
- int pid;
+wait_for_stop (int pid)
{
int i;
int retpid;
}
static int
-new_wait_thread_callback (thread, data)
- threadinfo *thread;
- void *data;
+new_wait_thread_callback (threadinfo *thread, void *data)
{
/* don't wait on the event thread -- it's already stopped and waited.
Ditto the main thread. */
*/
static int
-kill_thread_callback (th, data)
- td_thrhandle_t *th;
- void *data;
+kill_thread_callback (td_thrhandle_t *th, void *data)
{
td_thrinfo_t ti;
td_err_e ret;
*/
static int
-detach_thread_callback (th, data)
- td_thrhandle_t *th;
- void *data;
+detach_thread_callback (td_thrhandle_t *th, void *data)
{
/* Called once per thread. */
td_thrinfo_t ti;
*/
static void
-thread_db_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+thread_db_create_inferior (char *exec_file, char *allargs, char **env)
{
thread_db_unpush_target ();
find_default_create_inferior (exec_file, allargs, env);
*/
void
-init_thread_db_ops ()
+init_thread_db_ops (void)
{
thread_db_ops.to_shortname = "multi-thread";
thread_db_ops.to_longname = "multi-threaded child process.";
void
-_initialize_thread_db ()
+_initialize_thread_db (void)
{
#ifdef HAVE_STDINT_H /* stub out entire module, leave initializer empty */
if (init_thread_db_library ())
#endif
/* Check to see if the given thread is alive. */
static int
-linuxthreads_thread_alive (pid)
- int pid;
+linuxthreads_thread_alive (int pid)
{
errno = 0;
return ptrace (PT_READ_U, pid, (PTRACE_ARG3_TYPE)0, 0) >= 0 || errno == 0;
our efforts to debug it, accept them with wait, but don't pass them
through to PID. Do pass all other signals through. */
static int
-linuxthreads_find_trap (pid, stop)
- int pid;
- int stop;
+linuxthreads_find_trap (int pid, int stop)
{
int i;
int rpid;
}
static void
-sigchld_handler (signo)
- int signo;
+sigchld_handler (int signo)
{
/* This handler is used to get an EINTR while doing waitpid()
when an event is received */
/* Have we already collected a wait status for PID in the
linuxthreads_wait bag? */
static int
-linuxthreads_pending_status (pid)
- int pid;
+linuxthreads_pending_status (int pid)
{
int i;
for (i = linuxthreads_wait_last; i >= 0; i--)
in OBJFILE, so we complain if it's required, but not there.
Return true iff things are okay. */
static int
-find_signal_var (sig, objfile)
- struct linuxthreads_signal *sig;
- struct objfile *objfile;
+find_signal_var (struct linuxthreads_signal *sig, struct objfile *objfile)
{
struct minimal_symbol *ms = lookup_minimal_symbol (sig->var, NULL, objfile);
}
static int
-find_all_signal_vars (objfile)
- struct objfile *objfile;
+find_all_signal_vars (struct objfile *objfile)
{
return ( find_signal_var (&linuxthreads_sig_restart, objfile)
&& find_signal_var (&linuxthreads_sig_cancel, objfile)
been initialized yet. If it has, tell GDB to pass that signal
through to the inferior silently. */
static void
-check_signal_number (sig)
- struct linuxthreads_signal *sig;
+check_signal_number (struct linuxthreads_signal *sig)
{
int num;
}
void
-check_all_signal_numbers ()
+check_all_signal_numbers (void)
{
/* If this isn't a LinuxThreads program, quit early. */
if (! linuxthreads_max)
talking to an executable that uses LinuxThreads, so we clear the
signal number and variable address too. */
static void
-restore_signal (sig)
- struct linuxthreads_signal *sig;
+restore_signal (struct linuxthreads_signal *sig)
{
if (! sig->signal)
return;
talking to an executable that uses LinuxThreads, so we clear the
signal number and variable address too. */
static void
-restore_all_signals ()
+restore_all_signals (void)
{
restore_signal (&linuxthreads_sig_restart);
restore_signal (&linuxthreads_sig_cancel);
This is the worker function for linuxthreads_insert_breakpoint,
which passes it to iterate_active_threads. */
static void
-insert_breakpoint (pid)
- int pid;
+insert_breakpoint (int pid)
{
int j;
breakpoint if the thread's PC is pointing at the breakpoint being
removed. */
static void
-remove_breakpoint (pid)
- int pid;
+remove_breakpoint (int pid)
{
int j;
/* Kill a thread */
static void
-kill_thread (pid)
- int pid;
+kill_thread (int pid)
{
if (in_thread_list (pid))
{
/* Resume a thread */
static void
-resume_thread (pid)
- int pid;
+resume_thread (int pid)
{
if (pid != inferior_pid
&& in_thread_list (pid)
/* Detach a thread */
static void
-detach_thread (pid)
- int pid;
+detach_thread (int pid)
{
if (in_thread_list (pid) && linuxthreads_thread_alive (pid))
{
/* Attach a thread */
void
-attach_thread (pid)
- int pid;
+attach_thread (int pid)
{
if (ptrace (PT_ATTACH, pid, (PTRACE_ARG3_TYPE) 0, 0) != 0)
perror_with_name ("attach_thread");
/* Stop a thread */
static void
-stop_thread (pid)
- int pid;
+stop_thread (int pid)
{
if (pid != inferior_pid)
{
/* Wait for a thread */
static void
-wait_thread (pid)
- int pid;
+wait_thread (int pid)
{
int status;
int rpid;
/* Walk through the linuxthreads handles in order to detect all
threads and stop them */
static void
-update_stop_threads (test_pid)
- int test_pid;
+update_stop_threads (int test_pid)
{
struct cleanup *old_chain = NULL;
static void (*target_new_objfile_chain) (struct objfile *);
void
-linuxthreads_new_objfile (objfile)
- struct objfile *objfile;
+linuxthreads_new_objfile (struct objfile *objfile)
{
struct minimal_symbol *ms;
return 1 otherwise 0. */
int
-linuxthreads_prepare_to_proceed (step)
- int step;
+linuxthreads_prepare_to_proceed (int step)
{
if (!linuxthreads_max
|| !linuxthreads_manager_pid
/* Convert a pid to printable form. */
char *
-linuxthreads_pid_to_str (pid)
- int pid;
+linuxthreads_pid_to_str (int pid)
{
static char buf[100];
and wait for the trace-trap that results from attaching. */
static void
-linuxthreads_attach (args, from_tty)
- char *args;
- int from_tty;
+linuxthreads_attach (char *args, int from_tty)
{
if (!args)
error_no_arg ("process-id to attach");
started via the normal ptrace (PTRACE_TRACEME). */
static void
-linuxthreads_detach (args, from_tty)
- char *args;
- int from_tty;
+linuxthreads_detach (char *args, int from_tty)
{
if (linuxthreads_max)
{
signal activated. */
static void
-linuxthreads_resume (pid, step, signo)
- int pid;
- int step;
- enum target_signal signo;
+linuxthreads_resume (int pid, int step, enum target_signal signo)
{
if (!linuxthreads_max || stop_soon_quietly || linuxthreads_manager_pid == 0)
{
/* Abstract out the child_wait functionality. */
int
-linux_child_wait (pid, rpid, status)
- int pid;
- int *rpid;
- int *status;
+linux_child_wait (int pid, int *rpid, int *status)
{
int save_errno;
to a LWP id, and vice versa on the way out. */
static int
-linuxthreads_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+linuxthreads_wait (int pid, struct target_waitstatus *ourstatus)
{
int status;
int rpid;
/* Fork an inferior process, and start debugging it with ptrace. */
static void
-linuxthreads_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+linuxthreads_create_inferior (char *exec_file, char *allargs, char **env)
{
if (!exec_file && !exec_bfd)
{
}
void
-linuxthreads_discard_global_state ()
+linuxthreads_discard_global_state (void)
{
linuxthreads_inferior_pid = 0;
linuxthreads_breakpoint_pid = 0;
/* Clean up after the inferior dies. */
static void
-linuxthreads_mourn_inferior ()
+linuxthreads_mourn_inferior (void)
{
if (linuxthreads_max)
{
/* Kill the inferior process */
static void
-linuxthreads_kill ()
+linuxthreads_kill (void)
{
int rpid;
int status;
/* Insert a breakpoint */
static int
-linuxthreads_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+linuxthreads_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (linuxthreads_max && linuxthreads_manager_pid != 0)
{
/* Remove a breakpoint */
static int
-linuxthreads_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+linuxthreads_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (linuxthreads_max && linuxthreads_manager_pid != 0)
{
/* Mark our target-struct as eligible for stray "run" and "attach" commands. */
static int
-linuxthreads_can_run ()
+linuxthreads_can_run (void)
{
return child_suppress_run;
}
\f
static void
-init_linuxthreads_ops ()
+init_linuxthreads_ops (void)
{
linuxthreads_ops.to_shortname = "linuxthreads";
linuxthreads_ops.to_longname = "LINUX threads and pthread.";
}
void
-_initialize_linuxthreads ()
+_initialize_linuxthreads (void)
{
struct sigaction sact;
sigset_t linuxthreads_wait_mask; /* sigset with SIGCHLD */
It also handles knows where to find the I & L regs on the stack. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
int whatregs = 0;
this point. */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
int whatregs = 0;
saved context block. */
static unsigned long
-registers_addr (pid)
- int pid;
+registers_addr (int pid)
{
CORE_ADDR stblock;
int ecpoff = offsetof (st_t, ecp);
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
int reglo, reghi;
int i;
#endif
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
int reglo, reghi;
int i;
of error; store status through argument pointer OURSTATUS. */
int
-child_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+child_wait (int pid, struct target_waitstatus *ourstatus)
{
int save_errno;
int thread;
/* Return nonzero if the given thread is still alive. */
int
-child_thread_alive (pid)
- int pid;
+child_thread_alive (int pid)
{
/* Arggh. Apparently pthread_kill only works for threads within
the process that calls pthread_kill.
If SIGNAL is nonzero, give it that signal. */
void
-child_resume (pid, step, signal)
- int pid;
- int step;
- enum target_signal signal;
+child_resume (int pid, int step, enum target_signal signal)
{
int func;
buffer. */
char *
-child_pid_to_str (pid)
- int pid;
+child_pid_to_str (int pid)
{
static char buf[40];
*/
static void
-fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR reg_addr;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR reg_addr)
{
struct st_entry s;
unsigned int regno;
};
void
-_initialize_core_lynx ()
+_initialize_core_lynx (void)
{
add_core_fns (&lynx_core_fns);
}
*/
static void
-m2_emit_char (c, stream, quoter)
- register int c;
- struct ui_file *stream;
- int quoter;
+m2_emit_char (register int c, struct ui_file *stream, int quoter)
{
c &= 0xFF; /* Avoid sign bit follies */
be replaced with a true Modula version. */
static void
-m2_printchar (c, stream)
- int c;
- struct ui_file *stream;
+m2_printchar (int c, struct ui_file *stream)
{
fputs_filtered ("'", stream);
LA_EMIT_CHAR (c, stream, '\'');
be replaced with a true Modula version. */
static void
-m2_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+m2_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
register unsigned int i;
unsigned int things_printed = 0;
by an experienced Modula programmer. */
static struct type *
-m2_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+m2_create_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type *type = NULL;
/* Initialization for Modula-2 */
void
-_initialize_m2_language ()
+_initialize_m2_language (void)
{
/* Modula-2 "pervasive" types. NOTE: these can be redefined!!! */
builtin_type_m2_int =
#include <errno.h>
void
-m2_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+m2_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
extern void c_print_type (struct type *, char *, struct ui_file *, int,
int);
/* FIXME: For now, just explicitly declare c_val_print and use it instead */
int
-m2_val_print (type, valaddr, embedded_offset, address,
- stream, format, deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+m2_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
extern int c_val_print (struct type *, char *, int, CORE_ADDR,
struct ui_file *, int, int, int,
/* "Temporary" debug stuff */
void
-xx_debug (fmt, a, b, c)
- char *fmt;
- int a, b, c;
+xx_debug (char *fmt, int a, int b, int c)
{
if (debug_level)
warning (fmt, a, b, c);
port_chain_t notify_chain = (port_chain_t) NULL;
port_chain_t
-port_chain_insert (list, name, type)
- port_chain_t list;
- mach_port_t name;
- int type;
+port_chain_insert (port_chain_t list, mach_port_t name, int type)
{
kern_return_t ret;
port_chain_t new;
}
port_chain_t
-port_chain_delete (list, elem)
- port_chain_t list;
- mach_port_t elem;
+port_chain_delete (port_chain_t list, mach_port_t elem)
{
if (list)
if (list->port == elem)
}
void
-port_chain_destroy (ostack)
- struct obstack *ostack;
+port_chain_destroy (struct obstack *ostack)
{
obstack_free (ostack, 0);
obstack_init (ostack);
}
port_chain_t
-port_chain_member (list, elem)
- port_chain_t list;
- mach_port_t elem;
+port_chain_member (port_chain_t list, mach_port_t elem)
{
while (list)
{
}
\f
int
-map_port_name_to_mid (name, type)
- mach_port_t name;
- int type;
+map_port_name_to_mid (mach_port_t name, int type)
{
port_chain_t elem;
\f
/* Guard for currently_waiting_for and singlestepped_thread_port */
static void
-discard_single_step (thread)
- thread_t thread;
+discard_single_step (thread_t thread)
{
currently_waiting_for = inferior_wait_port_set;
setup_single_step (thread, FALSE);
}
-setup_single_step (thread, start_step)
- thread_t thread;
- boolean_t start_step;
+setup_single_step (thread_t thread, boolean_t start_step)
{
kern_return_t ret;
}
\f
static
-request_notify (name, variant, type)
- mach_port_t name;
- mach_msg_id_t variant;
- int type;
+request_notify (mach_port_t name, mach_msg_id_t variant, int type)
{
kern_return_t ret;
mach_port_t previous_port_dummy = MACH_PORT_NULL;
notify_chain = port_chain_insert (notify_chain, name, type);
}
-reverse_msg_bits (msgp, type)
- mach_msg_header_t *msgp;
- int type;
+reverse_msg_bits (mach_msg_header_t *msgp, int type)
{
int rbits, lbits;
rbits = MACH_MSGH_BITS_REMOTE (msgp->msgh_bits);
/* Called from inferior after FORK but before EXEC */
static void
-m3_trace_me ()
+m3_trace_me (void)
{
kern_return_t ret;
*/
void
-intercept_exec_calls (exec_counter)
- int exec_counter;
+intercept_exec_calls (int exec_counter)
{
int terminal_initted = 0;
}
void
-consume_send_rights (thread_list, thread_count)
- thread_array_t thread_list;
- int thread_count;
+consume_send_rights (thread_array_t thread_list, int thread_count)
{
int index;
}
/* suspend/abort/resume a thread. */
-setup_thread (thread, what)
- mach_port_t thread;
- int what;
+setup_thread (mach_port_t thread, int what)
{
kern_return_t ret;
}
int
-map_slot_to_mid (slot, threads, thread_count)
- int slot;
- thread_array_t threads;
- int thread_count;
+map_slot_to_mid (int slot, thread_array_t threads, int thread_count)
{
kern_return_t ret;
int deallocate = 0;
}
static int
-parse_thread_id (arg, thread_count, slots)
- char *arg;
- int thread_count;
- int slots;
+parse_thread_id (char *arg, int thread_count, int slots)
{
kern_return_t ret;
int mid;
*
*/
kern_return_t
-select_thread (task, thread_id, flag)
- mach_port_t task;
- int thread_id;
- int flag;
+select_thread (mach_port_t task, int thread_id, int flag)
{
thread_array_t thread_list;
int thread_count;
* Return it's MID
*/
int
-switch_to_thread (new_thread)
- thread_t new_thread;
+switch_to_thread (thread_t new_thread)
{
thread_t saved_thread = current_thread;
int mid;
* Note that the registers are not yet valid in the inferior task.
*/
static int
-m3_trace_him (pid)
- int pid;
+m3_trace_him (int pid)
{
kern_return_t ret;
return pid;
}
-setup_exception_port ()
+setup_exception_port (void)
{
kern_return_t ret;
Returns the inferior_pid for rest of gdb.
Side effects: Set *OURSTATUS. */
int
-mach_really_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+mach_really_wait (int pid, struct target_waitstatus *ourstatus)
{
kern_return_t ret;
int w;
* This is called just before calling error() to return to command level
*/
void
-mach3_quit ()
+mach3_quit (void)
{
int mid;
kern_return_t ret;
* Called by REQUEST_QUIT() from utils.c(request_quit)
*/
void
-mach3_request_quit ()
+mach3_request_quit (void)
{
if (mach_really_waiting)
immediate_quit = 1;
* gdb to return to the command level like ^C had been typed from terminal.
*/
int
-gdb_message_server (InP)
- mach_msg_header_t *InP;
+gdb_message_server (mach_msg_header_t *InP)
{
kern_return_t ret;
int mid;
* External program "stop-gdb" implements this also.
*/
void
-stop_inferior_gdb ()
+stop_inferior_gdb (void)
{
kern_return_t ret;
* it is selected and the last exception was a breakpoint.
*/
int
-mach_thread_for_breakpoint (mid)
- int mid;
+mach_thread_for_breakpoint (int mid)
{
int cmid = map_port_name_to_mid (current_thread, MACH_TYPE_THREAD);
* slot index. (Since 0 is reserved))
*/
int
-mach_thread_parse_id (arg)
- char *arg;
+mach_thread_parse_id (char *arg)
{
int mid;
if (arg == 0)
#ifdef THREAD_OUTPUT_ID
char *
-mach_thread_output_id (mid)
- int mid;
+mach_thread_output_id (int mid)
{
static char foobar[20];
*
*/
-mach3_prepare_to_proceed (select_it)
- int select_it;
+mach3_prepare_to_proceed (int select_it)
{
if (stop_thread &&
stop_thread != current_thread &&
*/
kern_return_t
-catch_exception_raise (port, thread, task, exception, code, subcode)
- mach_port_t port;
- thread_t thread;
- task_t task;
- int exception, code, subcode;
+catch_exception_raise (mach_port_t port, thread_t thread, task_t task,
+ int exception, int code, int subcode)
{
kern_return_t ret;
boolean_t signal_thread;
}
\f
int
-port_valid (port, mask)
- mach_port_t port;
- int mask;
+port_valid (mach_port_t port, int mask)
{
kern_return_t ret;
mach_port_type_t type;
* Return 0 on failure; number of bytes read otherwise.
*/
int
-mach3_read_inferior (addr, myaddr, length)
- CORE_ADDR addr;
- char *myaddr;
- int length;
+mach3_read_inferior (CORE_ADDR addr, char *myaddr, int length)
{
kern_return_t ret;
vm_address_t low_address = (vm_address_t) trunc_page (addr);
* in gdb's address space.
*/
int
-mach3_write_inferior (addr, myaddr, length)
- CORE_ADDR addr;
- char *myaddr;
- int length;
+mach3_write_inferior (CORE_ADDR addr, char *myaddr, int length)
{
kern_return_t ret;
vm_address_t low_address = (vm_address_t) trunc_page (addr);
\f
static char *
-translate_state (state)
- int state;
+translate_state (int state)
{
switch (state)
{
}
static char *
-translate_cstate (state)
- int state;
+translate_cstate (int state)
{
switch (state)
{
/* type == MACH_MSG_TYPE_COPY_SEND || type == MACH_MSG_TYPE_MAKE_SEND */
mach_port_t /* no mach_port_name_t found in include files. */
-map_inferior_port_name (inferior_name, type)
- mach_port_t inferior_name;
- mach_msg_type_name_t type;
+map_inferior_port_name (mach_port_t inferior_name, mach_msg_type_name_t type)
{
kern_return_t ret;
mach_msg_type_name_t acquired;
static char buf[7];
static char *
-get_thread_name (one_cproc, id)
- gdb_thread_t one_cproc;
- int id;
+get_thread_name (gdb_thread_t one_cproc, int id)
{
if (one_cproc)
if (one_cproc->cthread == NULL)
* emulator stack below struct emul_stack_top stuff.
*/
CORE_ADDR
-fetch_usp_from_emulator_stack (sp)
- CORE_ADDR sp;
+fetch_usp_from_emulator_stack (CORE_ADDR sp)
{
CORE_ADDR stack_pointer;
/* Check if the emulator exists at task's address space.
*/
boolean_t
-have_emulator_p (task)
- task_t task;
+have_emulator_p (task_t task)
{
kern_return_t ret;
#ifndef EMUL_VECTOR_COUNT
/* Map cprocs to kernel threads and vice versa. */
void
-map_cprocs_to_kernel_threads (cprocs, mthreads, thread_count)
- gdb_thread_t cprocs;
- gdb_thread_t mthreads;
- int thread_count;
+map_cprocs_to_kernel_threads (gdb_thread_t cprocs, gdb_thread_t mthreads,
+ int thread_count)
{
int index;
gdb_thread_t scan;
#define TL_HEADER "\n@ MID Name KState CState Where\n"
void
-print_tl_address (stream, pc)
- struct ui_file *stream;
- CORE_ADDR pc;
+print_tl_address (struct ui_file *stream, CORE_ADDR pc)
{
if (!lookup_minimal_symbol_by_pc (pc))
fprintf_filtered (stream, local_hex_format (), pc);
/* Returns the address of variable NAME or 0 if not found */
CORE_ADDR
-lookup_address_of_variable (name)
- char *name;
+lookup_address_of_variable (char *name)
{
struct symbol *sym;
CORE_ADDR symaddr = 0;
}
static gdb_thread_t
-get_cprocs ()
+get_cprocs (void)
{
gdb_thread_t cproc_head;
gdb_thread_t cproc_copy;
#define FETCH_CPROC_STATE(mth) mach3_cproc_state (mth)
int
-mach3_cproc_state (mthread)
- gdb_thread_t mthread;
+mach3_cproc_state (gdb_thread_t mthread)
{
int context;
\f
void
-thread_list_command ()
+thread_list_command (void)
{
thread_basic_info_data_t ths;
int thread_count;
}
\f
void
-thread_select_command (args, from_tty)
- char *args;
- int from_tty;
+thread_select_command (char *args, int from_tty)
{
int mid;
thread_array_t thread_list;
MACH_TYPE_THREAD) : mid);
}
\f
-thread_trace (thread, set)
- mach_port_t thread;
- boolean_t set;
+thread_trace (mach_port_t thread, boolean_t set)
{
int flavor = TRACE_FLAVOR;
unsigned int stateCnt = TRACE_FLAVOR_SIZE;
This definitely includes breakpoints, for instance, or else we
end up looping in mysterious Bpt traps */
-flush_inferior_icache (pc, amount)
- CORE_ADDR pc;
+flush_inferior_icache (CORE_ADDR pc, int amount)
{
vm_machine_attribute_val_t flush = MATTR_VAL_ICACHE_FLUSH;
kern_return_t ret;
\f
static
-suspend_all_threads (from_tty)
- int from_tty;
+suspend_all_threads (int from_tty)
{
kern_return_t ret;
thread_array_t thread_list;
}
void
-thread_suspend_command (args, from_tty)
- char *args;
- int from_tty;
+thread_suspend_command (char *args, int from_tty)
{
kern_return_t ret;
int mid;
current_thread = saved_thread;
}
-resume_all_threads (from_tty)
- int from_tty;
+resume_all_threads (int from_tty)
{
kern_return_t ret;
thread_array_t thread_list;
}
void
-thread_resume_command (args, from_tty)
- char *args;
- int from_tty;
+thread_resume_command (char *args, int from_tty)
{
int mid;
mach_port_t saved_thread;
}
void
-thread_kill_command (args, from_tty)
- char *args;
- int from_tty;
+thread_kill_command (char *args, int from_tty)
{
int mid;
kern_return_t ret;
/* Task specific commands; add more if you like */
void
-task_resume_command (args, from_tty)
- char *args;
- int from_tty;
+task_resume_command (char *args, int from_tty)
{
kern_return_t ret;
task_basic_info_data_t ta_info;
void
-task_suspend_command (args, from_tty)
- char *args;
- int from_tty;
+task_suspend_command (char *args, int from_tty)
{
kern_return_t ret;
task_basic_info_data_t ta_info;
}
static char *
-get_size (bytes)
- int bytes;
+get_size (int bytes)
{
static char size[30];
int zz = bytes / 1024;
/* Does this require the target task to be suspended?? I don't think so. */
void
-task_info_command (args, from_tty)
- char *args;
- int from_tty;
+task_info_command (char *args, int from_tty)
{
int mid = -5;
mach_port_t task;
*/
static void
-exception_command (args, from_tty)
- char *args;
- int from_tty;
+exception_command (char *args, int from_tty)
{
char *scan = args;
int exception;
}
static void
-print_exception_info (exception)
- int exception;
+print_exception_info (int exception)
{
boolean_t forward = exception_map[exception].forward;
}
void
-exception_info (args, from_tty)
- char *args;
- int from_tty;
+exception_info (char *args, int from_tty)
{
int exception;
\f
/* Check for actions for mach exceptions.
*/
-mach3_exception_actions (w, force_print_only, who)
- WAITTYPE *w;
- boolean_t force_print_only;
- char *who;
+mach3_exception_actions (WAITTYPE *w, boolean_t force_print_only, char *who)
{
boolean_t force_print = FALSE;
}
}
\f
-setup_notify_port (create_new)
- int create_new;
+setup_notify_port (int create_new)
{
kern_return_t ret;
char registered_name[MAX_NAME_LEN];
void
-message_port_info (args, from_tty)
- char *args;
- int from_tty;
+message_port_info (char *args, int from_tty)
{
if (registered_name[0])
printf_filtered ("gdb's message port name: '%s'\n",
}
void
-gdb_register_port (name, port)
- char *name;
- mach_port_t port;
+gdb_register_port (char *name, mach_port_t port)
{
kern_return_t ret;
static int already_signed = 0;
/*ARGSUSED */
static void
-thread_command (arg, from_tty)
- char *arg;
- int from_tty;
+thread_command (char *arg, int from_tty)
{
printf_unfiltered ("\"thread\" must be followed by the name of a thread command.\n");
help_list (cmd_thread_list, "thread ", -1, gdb_stdout);
/*ARGSUSED */
static void
-task_command (arg, from_tty)
- char *arg;
- int from_tty;
+task_command (char *arg, int from_tty)
{
printf_unfiltered ("\"task\" must be followed by the name of a task command.\n");
help_list (cmd_task_list, "task ", -1, gdb_stdout);
}
-add_mach_specific_commands ()
+add_mach_specific_commands (void)
{
/* Thread handling commands */
}
kern_return_t
-do_mach_notify_dead_name (notify, name)
- mach_port_t notify;
- mach_port_t name;
+do_mach_notify_dead_name (mach_port_t notify, mach_port_t name)
{
kern_return_t kr = KERN_SUCCESS;
}
kern_return_t
-do_mach_notify_msg_accepted (notify, name)
- mach_port_t notify;
- mach_port_t name;
+do_mach_notify_msg_accepted (mach_port_t notify, mach_port_t name)
{
warning ("do_mach_notify_msg_accepted : notify %x, name %x",
notify, name);
}
kern_return_t
-do_mach_notify_no_senders (notify, mscount)
- mach_port_t notify;
- mach_port_mscount_t mscount;
+do_mach_notify_no_senders (mach_port_t notify, mach_port_mscount_t mscount)
{
warning ("do_mach_notify_no_senders : notify %x, mscount %x",
notify, mscount);
}
kern_return_t
-do_mach_notify_port_deleted (notify, name)
- mach_port_t notify;
- mach_port_t name;
+do_mach_notify_port_deleted (mach_port_t notify, mach_port_t name)
{
warning ("do_mach_notify_port_deleted : notify %x, name %x",
notify, name);
}
kern_return_t
-do_mach_notify_port_destroyed (notify, rights)
- mach_port_t notify;
- mach_port_t rights;
+do_mach_notify_port_destroyed (mach_port_t notify, mach_port_t rights)
{
warning ("do_mach_notify_port_destroyed : notify %x, rights %x",
notify, rights);
}
kern_return_t
-do_mach_notify_send_once (notify)
- mach_port_t notify;
+do_mach_notify_send_once (mach_port_t notify)
{
#ifdef DUMP_SYSCALL
/* MANY of these are generated. */
/* Kills the inferior. It's gone when you call this */
static void
-kill_inferior_fast ()
+kill_inferior_fast (void)
{
WAITTYPE w;
}
static void
-m3_kill_inferior ()
+m3_kill_inferior (void)
{
kill_inferior_fast ();
target_mourn_inferior ();
/* Clean up after the inferior dies. */
static void
-m3_mourn_inferior ()
+m3_mourn_inferior (void)
{
unpush_target (&m3_ops);
generic_mourn_inferior ();
/* Fork an inferior process, and start debugging it. */
static void
-m3_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+m3_create_inferior (char *exec_file, char *allargs, char **env)
{
fork_inferior (exec_file, allargs, env, m3_trace_me, m3_trace_him, NULL, NULL);
/* We are at the first instruction we care about. */
/* Mark our target-struct as eligible for stray "run" and "attach"
commands. */
static int
-m3_can_run ()
+m3_can_run (void)
{
return 1;
}
/* Mach 3.0 does not need ptrace for anything
* Make sure nobody uses it on mach.
*/
-ptrace (a, b, c, d)
- int a, b, c, d;
+ptrace (int a, int b, int c, int d)
{
error ("Lose, Lose! Somebody called ptrace\n");
}
If SIGNAL is nonzero, give it that signal. */
void
-m3_resume (pid, step, signal)
- int pid;
- int step;
- enum target_signal signal;
+m3_resume (int pid, int step, enum target_signal signal)
{
kern_return_t ret;
/* Start debugging the process with the given task */
void
-task_attach (tid)
- task_t tid;
+task_attach (task_t tid)
{
kern_return_t ret;
inferior_task = tid;
* (Someone must have killed it))
*/
void
-attach_to_thread ()
+attach_to_thread (void)
{
if (select_thread (inferior_task, 0, 1) != KERN_SUCCESS)
error ("Could not select any threads to attach to");
}
-mid_attach (mid)
- int mid;
+mid_attach (int mid)
{
kern_return_t ret;
* "atta pidself". Anyway, the latter is allowed by specifying a MID.
*/
static int
-m3_do_attach (pid)
- int pid;
+m3_do_attach (int pid)
{
kern_return_t ret;
and wait for the trace-trap that results from attaching. */
static void
-m3_attach (args, from_tty)
- char *args;
- int from_tty;
+m3_attach (char *args, int from_tty)
{
char *exec_file;
int pid;
}
\f
void
-deallocate_inferior_ports ()
+deallocate_inferior_ports (void)
{
kern_return_t ret;
thread_array_t thread_list;
SIGNAL = 0 means just continue it. */
static void
-m3_do_detach (signal)
- int signal;
+m3_do_detach (int signal)
{
kern_return_t ret;
started via fork. */
static void
-m3_detach (args, from_tty)
- char *args;
- int from_tty;
+m3_detach (char *args, int from_tty)
{
int siggnal = 0;
debugged. */
static void
-m3_prepare_to_store ()
+m3_prepare_to_store (void)
{
#ifdef CHILD_PREPARE_TO_STORE
CHILD_PREPARE_TO_STORE ();
/* Print status information about what we're accessing. */
static void
-m3_files_info (ignore)
- struct target_ops *ignore;
+m3_files_info (struct target_ops *ignore)
{
/* FIXME: should print MID and all that crap. */
printf_unfiltered ("\tUsing the running image of %s %s.\n",
}
static void
-m3_open (arg, from_tty)
- char *arg;
- int from_tty;
+m3_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a Unix child process.");
}
int bsd1_nnames = sizeof (bsd1_names) / sizeof (bsd1_names[0]);
char *
-name_str (name, buf)
-
- int name;
- char *buf;
-
+name_str (int name, char *buf)
{
switch (name)
{
}
char *
-id_str (id, buf)
-
- int id;
- char *buf;
-
+id_str (int id, char *buf)
{
char *p;
if (id >= 101000 && id < 101000 + bsd1_nnames)
return buf;
}
-print_msg (mp)
- mach_msg_header_t *mp;
+print_msg (mach_msg_header_t *mp)
{
char *fmt_x = "%20s : 0x%08x\n";
char *fmt_d = "%20s : %10d\n";
}
}
-print_data (p, size, number)
-
- char *p;
-
+print_data (char *p, int size, int number)
{
int *ip;
short *sp;
#endif /* DUMP_SYSCALL */
static void
-m3_stop ()
+m3_stop (void)
{
error ("to_stop target function not implemented");
}
static char *
-m3_pid_to_exec_file (pid)
- int pid;
+m3_pid_to_exec_file (int pid)
{
error ("to_pid_to_exec_file target function not implemented");
return NULL; /* To keep all compilers happy. */
}
static void
-init_m3_ops ()
+init_m3_ops (void)
{
m3_ops.to_shortname = "mach";
m3_ops.to_longname = "Mach child process";
}
void
-_initialize_m3_nat ()
+_initialize_m3_nat (void)
{
kern_return_t ret;
*/
static void
-m32r_load_section (abfd, s, data_count)
- bfd *abfd;
- asection *s;
- unsigned int *data_count;
+m32r_load_section (bfd *abfd, asection *s, unsigned int *data_count)
{
if (s->flags & SEC_LOAD)
{
}
static int
-m32r_load_1 (dummy)
- void *dummy;
+m32r_load_1 (void *dummy)
{
int data_count = 0;
*/
static void
-m32r_load (filename, from_tty)
- char *filename;
- int from_tty;
+m32r_load (char *filename, int from_tty)
{
extern int inferior_pid;
bfd *abfd;
}
static void
-m32r_load_gen (filename, from_tty)
- char *filename;
- int from_tty;
+m32r_load_gen (char *filename, int from_tty)
{
generic_load (filename, from_tty);
}
};
static void
-m32r_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+m32r_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
int num_regs = sizeof (m32r_regnames) / sizeof (m32r_regnames[0]);
} /* init_m32r_cmds */
static void
-m32r_open (args, from_tty)
- char *args;
- int from_tty;
+m32r_open (char *args, int from_tty)
{
monitor_open (args, &m32r_cmds, from_tty);
}
} /* init_mon2000_cmds */
static void
-mon2000_open (args, from_tty)
- char *args;
- int from_tty;
+mon2000_open (char *args, int from_tty)
{
monitor_open (args, &mon2000_cmds, from_tty);
}
Tell the BootOne monitor what it's ethernet IP address is. */
static void
-m32r_set_board_address (args, from_tty)
- char *args;
- int from_tty;
+m32r_set_board_address (char *args, int from_tty)
{
int resp_len;
char buf[1024];
Tell the BootOne monitor what gdb's ethernet IP address is. */
static void
-m32r_set_server_address (args, from_tty)
- char *args;
- int from_tty;
+m32r_set_server_address (char *args, int from_tty)
{
int resp_len;
char buf[1024];
Tell the BootOne monitor the default path for downloadable SREC files. */
static void
-m32r_set_download_path (args, from_tty)
- char *args;
- int from_tty;
+m32r_set_download_path (char *args, int from_tty)
{
int resp_len;
char buf[1024];
}
static void
-m32r_upload_command (args, from_tty)
- char *args;
- int from_tty;
+m32r_upload_command (char *args, int from_tty)
{
bfd *abfd;
asection *s;
#endif /* ! _MSC_VER */
void
-_initialize_m32r_rom ()
+_initialize_m32r_rom (void)
{
/* Initialize m32r RevC monitor target */
init_m32r_cmds ();
static unsigned long crc32_table[256] = {0, 0};
static unsigned long
-crc32 (buf, len, crc)
- unsigned char *buf;
- int len;
- unsigned long crc;
+crc32 (unsigned char *buf, int len, unsigned long crc)
{
if (! crc32_table[1])
{
}
static int
-hex(ch)
- unsigned char ch;
+hex (unsigned char ch)
{
if ((ch >= 'a') && (ch <= 'f')) return (ch-'a'+10);
if ((ch >= '0') && (ch <= '9')) return (ch-'0');
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
/* send the packet in buffer. */
static void
-putpacket(buffer)
- unsigned char *buffer;
+putpacket (unsigned char *buffer)
{
unsigned char checksum;
int count;
static void (*volatile mem_fault_routine)() = 0;
static void
-set_mem_err ()
+set_mem_err (void)
{
mem_err = 1;
}
whether there's anything connected to the expansion bus. */
static int
-mem_safe (addr)
- unsigned char *addr;
+mem_safe (unsigned char *addr)
{
#define BAD_RANGE_ONE_START ((unsigned char *) 0x600000)
#define BAD_RANGE_ONE_END ((unsigned char *) 0xa00000)
to mem_fault, they won't get restored, so there better not be any
saved). */
static int
-get_char (addr)
- unsigned char *addr;
+get_char (unsigned char *addr)
{
#if 1
if (mem_fault_routine && !mem_safe(addr))
}
static void
-set_char (addr, val)
- unsigned char *addr;
- unsigned char val;
+set_char (unsigned char *addr, unsigned char val)
{
#if 1
if (mem_fault_routine && !mem_safe (addr))
a fault; if zero treat a fault like any other fault in the stub. */
static unsigned char *
-mem2hex(mem, buf, count, may_fault)
- unsigned char* mem;
- unsigned char* buf;
- int count;
- int may_fault;
+mem2hex (unsigned char *mem, unsigned char *buf, int count, int may_fault)
{
int i;
unsigned char ch;
Return a pointer to the character AFTER the last byte written. */
static unsigned char*
-hex2mem(buf, mem, count, may_fault)
- unsigned char* buf;
- unsigned char* mem;
- int count;
- int may_fault;
+hex2mem (unsigned char *buf, unsigned char *mem, int count, int may_fault)
{
int i;
unsigned char ch;
COUNT is the total number of bytes to write into
memory. */
static unsigned char *
-bin2mem (buf, mem, count, may_fault)
- unsigned char *buf;
- unsigned char *mem;
- int count;
- int may_fault;
+bin2mem (unsigned char *buf, unsigned char *mem, int count, int may_fault)
{
int i;
unsigned char ch;
translate this number into a unix compatible signal value */
static int
-computeSignal(exceptionVector)
- int exceptionVector;
+computeSignal (int exceptionVector)
{
int sigval;
switch (exceptionVector) {
/* RETURN NUMBER OF CHARS PROCESSED */
/**********************************************/
static int
-hexToInt(ptr, intValue)
- unsigned char **ptr;
- int *intValue;
+hexToInt (unsigned char **ptr, int *intValue)
{
int numChars = 0;
int hexValue;
*/
static int
-isShortBranch(instr)
- unsigned char *instr;
+isShortBranch (unsigned char *instr)
{
unsigned char instr0 = instr[0] & 0x7F; /* mask off high bit */
}
static int
-isLongBranch(instr)
- unsigned char *instr;
+isLongBranch (unsigned char *instr)
{
if (instr[0] == 0xFC || instr[0] == 0xFD || /* BRA, BNC, BL, BC */
instr[0] == 0xFE || instr[0] == 0xFF) /* 24 bit relative */
((((int) addr & 2) || (((unsigned char *) addr)[0] & 0x80) == 0) ? 2 : 4)
static int
-isBranch(instr)
- unsigned char *instr;
+isBranch (unsigned char *instr)
{
if (INSTRUCTION_SIZE(instr) == 2)
return isShortBranch(instr);
}
static int
-willBranch(instr, branchCode)
- unsigned char *instr;
+willBranch (unsigned char *instr, int branchCode)
{
switch (branchCode)
{
}
static int
-branchDestination(instr, branchCode)
- unsigned char *instr;
+branchDestination (unsigned char *instr, int branchCode)
{
switch (branchCode) {
default:
}
static void
-branchSideEffects(instr, branchCode)
- unsigned char *instr;
- int branchCode;
+branchSideEffects (unsigned char *instr, int branchCode)
{
switch (branchCode)
{
just "continue continuing". */
static int
-finish_from_step()
+finish_from_step (void)
{
if (stepping.stepping) /* anything to do? */
{
but doing stash_registers in C isn't straightforward. */
static void
-cleanup_stash ()
+cleanup_stash (void)
{
psw = (struct PSWreg *) ®isters[PSW]; /* fields of PSW register */
psw->sm = psw->bsm; /* fix up pre-trap values of psw fields */
NUM is the trap/exception number. */
static void
-process_exception (num)
- int num;
+process_exception (int num)
{
cleanup_stash ();
asm volatile ("
/* this function is used to set up exception handlers for tracing and
breakpoints */
void
-set_debug_traps()
+set_debug_traps (void)
{
/* extern void remcomHandler(); */
int i;
#define BREAKPOINT() asm volatile (" trap #2");
void
-breakpoint()
+breakpoint (void)
{
if (initialized)
BREAKPOINT();
Returns: the char */
static int
-gdb_putchar(ch)
- int ch;
+gdb_putchar (int ch)
{
char buf[4];
Returns: number of bytes written */
static int
-gdb_write(data, len)
- char *data;
- int len;
+gdb_write (char *data, int len)
{
char *buf, *cpy;
int i;
Returns: the length of the string */
static int
-gdb_puts(str)
- char *str;
+gdb_puts (char *str)
{
return gdb_write(str, strlen(str));
}
will cause the optional second string to be inserted. */
static void
-gdb_error(format, parm)
- char * format;
- char * parm;
+gdb_error (char *format, char *parm)
{
char buf[400], *cpy;
int len;
Return nonzero if call_function should allocate stack space for a
struct return? */
int
-m32r_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+m32r_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 8);
}
an empty frame_saved_regs, so I guess that's better than total failure */
void
-m32r_frame_find_saved_regs (fi, regaddr)
- struct frame_info *fi;
- struct frame_saved_regs *regaddr;
+m32r_frame_find_saved_regs (struct frame_info *fi,
+ struct frame_saved_regs *regaddr)
{
memcpy (regaddr, &fi->fsr, sizeof (struct frame_saved_regs));
}
*/
static void
-decode_prologue (start_pc, scan_limit,
- pl_endptr, framelength,
- fi, fsr)
- CORE_ADDR start_pc;
- CORE_ADDR scan_limit;
- CORE_ADDR *pl_endptr; /* var parameter */
- unsigned long *framelength;
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+decode_prologue (CORE_ADDR start_pc, CORE_ADDR scan_limit, CORE_ADDR *pl_endptr, /* var parameter */
+ unsigned long *framelength, struct frame_info *fi,
+ struct frame_saved_regs *fsr)
{
unsigned long framesize;
int insn;
Find end of function prologue */
CORE_ADDR
-m32r_skip_prologue (pc)
- CORE_ADDR pc;
+m32r_skip_prologue (CORE_ADDR pc)
{
CORE_ADDR func_addr, func_end;
struct symtab_and_line sal;
}
static unsigned long
-m32r_scan_prologue (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+m32r_scan_prologue (struct frame_info *fi, struct frame_saved_regs *fsr)
{
struct symtab_and_line sal;
CORE_ADDR prologue_start, prologue_end, current_pc;
examine the prologue. */
void
-m32r_init_extra_frame_info (fi)
- struct frame_info *fi;
+m32r_init_extra_frame_info (struct frame_info *fi)
{
int reg;
any frame pointer offsets. */
void
-m32r_virtual_frame_pointer (pc, reg, offset)
- CORE_ADDR pc;
- long *reg;
- long *offset;
+m32r_virtual_frame_pointer (CORE_ADDR pc, long *reg, long *offset)
{
struct frame_info fi;
caller-saves registers for an inner frame. */
CORE_ADDR
-m32r_find_callers_reg (fi, regnum)
- struct frame_info *fi;
- int regnum;
+m32r_find_callers_reg (struct frame_info *fi, int regnum)
{
for (; fi; fi = fi->next)
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
For m32r, we save the frame size when we initialize the frame_info. */
CORE_ADDR
-m32r_frame_chain (fi)
- struct frame_info *fi;
+m32r_frame_chain (struct frame_info *fi)
{
CORE_ADDR fn_start, callers_pc, fp;
(ie. when using an empty CALL_DUMMY) */
CORE_ADDR
-m32r_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+m32r_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
write_register (RP_REGNUM, CALL_DUMMY_ADDRESS ());
return sp;
restoring all saved registers. */
struct frame_info *
-m32r_pop_frame (frame)
- struct frame_info *frame;
+m32r_pop_frame (struct frame_info *frame)
{
int regnum;
in the stack anywhere, otherwise we get it from the registers. */
CORE_ADDR
-m32r_frame_saved_pc (fi)
- struct frame_info *fi;
+m32r_frame_saved_pc (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
passed as an implicit first argument, always in R0. */
CORE_ADDR
-m32r_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+m32r_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int stack_offset, stack_alloc;
int argreg;
is the target of the target function call. */
void
-m32r_fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR pc;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+m32r_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
+ value_ptr *args, struct type *type, int gcc_p)
{
/* ld24 r8, <(imm24) fun> */
*(unsigned long *) (dummy) = (fun & 0x00ffffff) | 0xe8000000;
we must actually write one of those two as well, depending on PSW. */
void
-m32r_write_sp (val)
- CORE_ADDR val;
+m32r_write_sp (CORE_ADDR val)
{
unsigned long psw = read_register (PSW_REGNUM);
}
void
-_initialize_m32r_tdep ()
+_initialize_m32r_tdep (void)
{
tm_print_insn = print_insn_m32r;
}
registers. */
void
-m68hc11_pop_frame ()
+m68hc11_pop_frame (void)
{
m68hc11_not_yet ("m68hc11_pop_frame");
}
CORE_ADDR
-m68hc11_call_dummy_address ()
+m68hc11_call_dummy_address (void)
{
m68hc11_not_yet ("m68hc11_call_dummy_address");
return 0;
}
void
-_initialize_m68hc11_tdep ()
+_initialize_m68hc11_tdep (void)
{
tm_print_insn = print_insn_m68hc11;
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
void
-initializeRemcomErrorFrame()
+initializeRemcomErrorFrame (void)
{
lastFrame = ((Frame *) &gdbFrameStack[FRAMESIZE-1]) - 1;
lastFrame->previous = lastFrame;
was moved back here from tm-m68k.h. FIXME? */
extern CORE_ADDR
-altos_skip_prologue (pc)
- CORE_ADDR pc;
+altos_skip_prologue (CORE_ADDR pc)
{
register int op = read_memory_integer (pc, 2);
if (op == P_LINKW_FP)
was moved back here from tm-m68k.h. FIXME? */
extern CORE_ADDR
-isi_skip_prologue (pc)
- CORE_ADDR pc;
+isi_skip_prologue (CORE_ADDR pc)
{
register int op = read_memory_integer (pc, 2);
if (op == P_LINKW_FP)
}
int
-delta68_in_sigtramp (pc, name)
- CORE_ADDR pc;
- char *name;
+delta68_in_sigtramp (CORE_ADDR pc, char *name)
{
if (name != NULL)
return strcmp (name, "_sigcode") == 0;
}
CORE_ADDR
-delta68_frame_args_address (frame_info)
- struct frame_info * frame_info;
+delta68_frame_args_address (struct frame_info *frame_info)
{
/* we assume here that the only frameless functions are the system calls
or other functions who do not put anything on the stack. */
}
CORE_ADDR
-delta68_frame_saved_pc (frame_info)
- struct frame_info * frame_info;
+delta68_frame_saved_pc (struct frame_info *frame_info)
{
return read_memory_integer (delta68_frame_args_address (frame_info) + 4, 4);
}
Can return -1, meaning no way to tell. */
int
-isi_frame_num_args (fi)
- struct frame_info *fi;
+isi_frame_num_args (struct frame_info *fi)
{
int val;
CORE_ADDR pc = FRAME_SAVED_PC (fi);
}
int
-delta68_frame_num_args (fi)
- struct frame_info *fi;
+delta68_frame_num_args (struct frame_info *fi)
{
int val;
CORE_ADDR pc = FRAME_SAVED_PC (fi);
}
int
-news_frame_num_args (fi)
- struct frame_info *fi;
+news_frame_num_args (struct frame_info *fi)
{
int val;
CORE_ADDR pc = FRAME_SAVED_PC (fi);
/* Push an empty stack frame, to record the current PC, etc. */
void
-m68k_push_dummy_frame ()
+m68k_push_dummy_frame (void)
{
register CORE_ADDR sp = read_register (SP_REGNUM);
register int regnum;
restoring all saved registers. */
void
-m68k_pop_frame ()
+m68k_pop_frame (void)
{
register struct frame_info *frame = get_current_frame ();
register CORE_ADDR fp;
*/
CORE_ADDR
-m68k_skip_prologue (ip)
- CORE_ADDR ip;
+m68k_skip_prologue (CORE_ADDR ip)
{
register CORE_ADDR limit;
struct symtab_and_line sal;
}
void
-m68k_find_saved_regs (frame_info, saved_regs)
- struct frame_info *frame_info;
- struct frame_saved_regs *saved_regs;
+m68k_find_saved_regs (struct frame_info *frame_info,
+ struct frame_saved_regs *saved_regs)
{
register int regnum;
register int regmask;
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
char *from;
them all. */
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *to;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR sp, jb_addr;
prior to doing the trap. */
CORE_ADDR
-m68k_saved_pc_after_call (frame)
- struct frame_info *frame;
+m68k_saved_pc_after_call (struct frame_info *frame)
{
#ifdef SYSCALL_TRAP
int op;
void
-_initialize_m68k_tdep ()
+_initialize_m68k_tdep (void)
{
tm_print_insn = print_insn_m68k;
}
is stored. */
int
-m68k_linux_register_u_addr (blockend, regnum)
- int blockend;
- int regnum;
+m68k_linux_register_u_addr (int blockend, int regnum)
{
return (blockend + 4 * regmap[regnum]);
}
#include "gregset.h"
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
int regi;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
int regi;
\f
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
/* Return non-zero if PC points into the signal trampoline. */
int
-in_sigtramp (pc)
- CORE_ADDR pc;
+in_sigtramp (CORE_ADDR pc)
{
CORE_ADDR sp;
char buf[TARGET_SHORT_BIT / TARGET_CHAR_BIT];
#include "inferior.h"
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
}
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
};
static void
-fetch_core_registers (core_reg_sect, core_reg_size, which, ignore)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR ignore;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR ignore)
{
struct md_core *core_reg = (struct md_core *) core_reg_sect;
};
void
-_initialize_m68knbsd_nat ()
+_initialize_m68knbsd_nat (void)
{
add_core_fns (&m68knbsd_core_fns);
}
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
/* blockend is the address of the end of the user structure */
-m88k_register_u_addr (blockend, regnum)
+m88k_register_u_addr (int blockend, int regnum)
{
struct USER u;
int ustart = blockend - sizeof (struct USER);
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = (greg_t *) gregsetp;
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = (greg_t *) gregsetp;
of an instruction. Shrug. */
CORE_ADDR
-m88k_addr_bits_remove (addr)
- CORE_ADDR addr;
+m88k_addr_bits_remove (CORE_ADDR addr)
{
return ((addr) & ~3);
}
the function prologue to determine the caller's sp value, and return it. */
CORE_ADDR
-frame_chain (thisframe)
- struct frame_info *thisframe;
+frame_chain (struct frame_info *thisframe)
{
frame_find_saved_regs (thisframe, (struct frame_saved_regs *) 0);
}
int
-frameless_function_invocation (frame)
- struct frame_info *frame;
+frameless_function_invocation (struct frame_info *frame)
{
frame_find_saved_regs (frame, (struct frame_saved_regs *) 0);
}
void
-init_extra_frame_info (fromleaf, frame)
- int fromleaf;
- struct frame_info *frame;
+init_extra_frame_info (int fromleaf, struct frame_info *frame)
{
frame->fsr = 0; /* Not yet allocated */
frame->args_pointer = 0; /* Unknown */
is stored at 'pword1'. */
CORE_ADDR
-next_insn (memaddr, pword1)
- unsigned long *pword1;
- CORE_ADDR memaddr;
+next_insn (CORE_ADDR memaddr, unsigned long *pword1)
{
*pword1 = read_memory_integer (memaddr, BYTES_PER_88K_INSN);
return memaddr + BYTES_PER_88K_INSN;
/* Read a register from frames called by us (or from the hardware regs). */
static int
-read_next_frame_reg (frame, regno)
- struct frame_info *frame;
- int regno;
+read_next_frame_reg (struct frame_info *frame, int regno)
{
for (; frame; frame = frame->next)
{
to reflect the offsets of the arg pointer and the locals pointer. */
static CORE_ADDR
-examine_prologue (ip, limit, frame_sp, fsr, fi)
- register CORE_ADDR ip;
- register CORE_ADDR limit;
- CORE_ADDR frame_sp;
- struct frame_saved_regs *fsr;
- struct frame_info *fi;
+examine_prologue (register CORE_ADDR ip, register CORE_ADDR limit,
+ CORE_ADDR frame_sp, struct frame_saved_regs *fsr,
+ struct frame_info *fi)
{
register CORE_ADDR next_ip;
register int src;
fairly expensive. */
void
-frame_find_saved_regs (fi, fsr)
- struct frame_info *fi;
- struct frame_saved_regs *fsr;
+frame_find_saved_regs (struct frame_info *fi, struct frame_saved_regs *fsr)
{
register struct frame_saved_regs *cache_fsr;
CORE_ADDR ip;
argument pointer, so this is the same as frame_args_address(). */
CORE_ADDR
-frame_locals_address (fi)
- struct frame_info *fi;
+frame_locals_address (struct frame_info *fi)
{
struct frame_saved_regs fsr;
described by FI. Returns 0 if the address is unknown. */
CORE_ADDR
-frame_args_address (fi)
- struct frame_info *fi;
+frame_args_address (struct frame_info *fi)
{
struct frame_saved_regs fsr;
just use the register SRP_REGNUM itself. */
CORE_ADDR
-frame_saved_pc (frame)
- struct frame_info *frame;
+frame_saved_pc (struct frame_info *frame)
{
return read_next_frame_reg (frame, SRP_REGNUM);
}
#define DUMMY_FRAME_SIZE 192
static void
-write_word (sp, word)
- CORE_ADDR sp;
- ULONGEST word;
+write_word (CORE_ADDR sp, ULONGEST word)
{
register int len = REGISTER_SIZE;
char buffer[MAX_REGISTER_RAW_SIZE];
}
void
-m88k_push_dummy_frame ()
+m88k_push_dummy_frame (void)
{
register CORE_ADDR sp = read_register (SP_REGNUM);
register int rn;
}
void
-pop_frame ()
+pop_frame (void)
{
register struct frame_info *frame = get_current_frame ();
register CORE_ADDR fp;
}
void
-_initialize_m88k_tdep ()
+_initialize_m88k_tdep (void)
{
tm_print_insn = print_insn_m88k;
}
/* Attach to process PID, then initialize for debugging it. */
static void
-child_attach (args, from_tty)
- char *args;
- int from_tty;
+child_attach (char *args, int from_tty)
{
ProcessSerialNumber psn;
ProcessInfoRec inforec;
}
static void
-child_detach (args, from_tty)
- char *args;
- int from_tty;
+child_detach (char *args, int from_tty)
{
char *exec_file;
/* Print status information about what we're accessing. */
static void
-child_files_info (ignore)
- struct target_ops *ignore;
+child_files_info (struct target_ops *ignore)
{
printf_unfiltered ("\tUsing the running image of %s %s.\n",
attach_flag ? "attached" : "child", target_pid_to_str (inferior_pid));
/* ARGSUSED */
static void
-child_open (arg, from_tty)
- char *arg;
- int from_tty;
+child_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a Mac application.");
}
ENV is the environment vector to pass. Errors reported with error(). */
static void
-child_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+child_create_inferior (char *exec_file, char *allargs, char **env)
{
LaunchParamBlockRec launchparms;
FSSpec fsspec;
}
static void
-child_mourn_inferior ()
+child_mourn_inferior (void)
{
unpush_target (&child_ops);
generic_mourn_inferior ();
}
static void
-child_stop ()
+child_stop (void)
{
}
}
static void
-child_prepare_to_store ()
+child_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static int
-child_can_run ()
+child_can_run (void)
{
return 1;
}
static void
-child_close ()
+child_close (void)
{
}
static void
-info_proc (args, from_tty)
- char *args;
- int from_tty;
+info_proc (char *args, int from_tty)
{
ProcessSerialNumber psn;
ProcessInfoRec inforec;
};
void
-_initialize_mac_nat ()
+_initialize_mac_nat (void)
{
init_child_ops ();
Rect console_text_rect;
/* This will go away eventually. */
-gdb_has_a_terminal ()
+gdb_has_a_terminal (void)
{
return 1;
}
-mac_init ()
+mac_init (void)
{
SysEnvRec se;
int eventloopdone = 0;
new_console_window ();
}
-new_console_window ()
+new_console_window (void)
{
/* Create the main window we're going to play in. */
if (has_color_qd)
SelectWindow (console_window);
}
-mac_command_loop ()
+mac_command_loop (void)
{
SysEnvRec se;
int eventloopdone = 0;
/* Collect the global coordinates of the mouse pointer. */
-get_global_mouse (mouse)
- Point *mouse;
+get_global_mouse (Point *mouse)
{
EventRecord evt;
/* Change the cursor's appearance to be appropriate for the given mouse
location. */
-adjust_cursor (mouse, region)
- Point mouse;
- RgnHandle region;
+adjust_cursor (Point mouse, RgnHandle region)
{
}
/* Decipher an event, maybe do something with it. */
-do_event (evt)
- EventRecord *evt;
+do_event (EventRecord *evt)
{
short part, err, rslt = 0;
WindowPtr win;
/* Do any idle-time activities. */
-do_idle ()
+do_idle (void)
{
TEIdle (console_text);
}
-grow_window (win, where)
- WindowPtr win;
- Point where;
+grow_window (WindowPtr win, Point where)
{
long winsize;
int h, v;
}
}
-zoom_window (win, where, part)
- WindowPtr win;
- Point where;
- short part;
+zoom_window (WindowPtr win, Point where, short part)
{
ZoomWindow (win, part, (win == FrontWindow ()));
if (win == console_window)
}
}
-resize_console_window ()
+resize_console_window (void)
{
adjust_console_sizes ();
adjust_console_scrollbars ();
InvalRect (&console_window->portRect);
}
-close_window (win)
- WindowPtr win;
+close_window (WindowPtr win)
{
}
}
}
-scroll_text (hlines, vlines)
- int hlines, vlines;
+scroll_text (int hlines, int vlines)
{
}
-activate_window (win, activate)
- WindowPtr win;
- int activate;
+activate_window (WindowPtr win, int activate)
{
Rect grow_rect;
}
}
-update_window (win)
- WindowPtr win;
+update_window (WindowPtr win)
{
int controls = 1, growbox = 0;
GrafPtr oldport;
SetPort (oldport);
}
-adjust_menus ()
+adjust_menus (void)
{
}
-do_menu_command (which)
- long which;
+do_menu_command (long which)
{
short menuid, menuitem;
short itemHit;
char commandbuf[1000];
-do_keyboard_command (key)
- int key;
+do_keyboard_command (int key)
{
int startpos, endpos, i, len;
char *last_newline;
/* Draw all graphical stuff in the console window. */
-draw_console ()
+draw_console (void)
{
SetPort (console_window);
TEUpdate (&(console_window->portRect), console_text);
/* Cause an update of a given window's entire contents. */
-force_update (win)
- WindowPtr win;
+force_update (WindowPtr win)
{
GrafPtr oldport;
SetPort (oldport);
}
-adjust_console_sizes ()
+adjust_console_sizes (void)
{
Rect tmprect;
(*console_text)->viewRect = tmprect;
}
-adjust_console_scrollbars ()
+adjust_console_scrollbars (void)
{
int lines, newmax, value;
/* Scroll the TE record so that it is consistent with the scrollbar(s). */
-adjust_console_text ()
+adjust_console_text (void)
{
TEScroll (((*console_text)->viewRect.left
- (*console_text)->destRect.left)
}
int
-unstifle_history ()
+unstifle_history (void)
{
}
*/
static void
-maintenance_command (args, from_tty)
- char *args;
- int from_tty;
+maintenance_command (char *args, int from_tty)
{
printf_unfiltered ("\"maintenance\" must be followed by the name of a maintenance command.\n");
help_list (maintenancelist, "maintenance ", -1, gdb_stdout);
#ifndef _WIN32
/* ARGSUSED */
static void
-maintenance_dump_me (args, from_tty)
- char *args;
- int from_tty;
+maintenance_dump_me (char *args, int from_tty)
{
if (query ("Should GDB dump core? "))
{
demangle and print what it points to, etc. (FIXME) */
static void
-maintenance_demangle (args, from_tty)
- char *args;
- int from_tty;
+maintenance_demangle (char *args, int from_tty)
{
char *demangled;
}
static void
-maintenance_time_display (args, from_tty)
- char *args;
- int from_tty;
+maintenance_time_display (char *args, int from_tty)
{
extern int display_time;
}
static void
-maintenance_space_display (args, from_tty)
- char *args;
- int from_tty;
+maintenance_space_display (char *args, int from_tty)
{
extern int display_space;
/* ARGSUSED */
static void
-maintenance_info_command (arg, from_tty)
- char *arg;
- int from_tty;
+maintenance_info_command (char *arg, int from_tty)
{
printf_unfiltered ("\"maintenance info\" must be followed by the name of an info command.\n");
help_list (maintenanceinfolist, "maintenance info ", -1, gdb_stdout);
}
static void
-print_section_table (abfd, asect, ignore)
- bfd *abfd;
- asection *asect;
- PTR ignore;
+print_section_table (bfd *abfd, asection *asect, PTR ignore)
{
flagword flags;
/* ARGSUSED */
static void
-maintenance_info_sections (arg, from_tty)
- char *arg;
- int from_tty;
+maintenance_info_sections (char *arg, int from_tty)
{
if (exec_bfd)
{
/* ARGSUSED */
void
-maintenance_print_statistics (args, from_tty)
- char *args;
- int from_tty;
+maintenance_print_statistics (char *args, int from_tty)
{
print_objfile_statistics ();
print_symbol_bcache_statistics ();
/* ARGSUSED */
static void
-maintenance_print_command (arg, from_tty)
- char *arg;
- int from_tty;
+maintenance_print_command (char *arg, int from_tty)
{
printf_unfiltered ("\"maintenance print\" must be followed by the name of a print command.\n");
help_list (maintenanceprintlist, "maintenance print ", -1, gdb_stdout);
*/
static void
-maintenance_translate_address (arg, from_tty)
- char *arg;
- int from_tty;
+maintenance_translate_address (char *arg, int from_tty)
{
CORE_ADDR address;
asection *sect;
void
-_initialize_maint_cmds ()
+_initialize_maint_cmds (void)
{
add_prefix_cmd ("maintenance", class_maintenance, maintenance_command,
"Commands for use by GDB maintainers.\n\
int
-picobug_dumpregs ()
+picobug_dumpregs (void)
{
char buf[1024];
int resp_len;
}
void
-_initialize_picobug_rom ()
+_initialize_picobug_rom (void)
{
int i;
}
void
-_initialize_mcore_tdep ()
+_initialize_mcore_tdep (void)
{
extern int print_insn_mcore (bfd_vma, disassemble_info *);
tm_print_insn = print_insn_mcore;
/* Allocate zeroed memory */
static PTR
-xzalloc (size)
- unsigned int size;
+xzalloc (unsigned int size)
{
PTR p = xmalloc (size);
and reorders the symtab list at the end */
static void
-mdebug_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+mdebug_psymtab_to_symtab (struct partial_symtab *pst)
{
if (!pst)
/* Find a file descriptor given its index RF relative to a file CF */
static FDR *
-get_rfd (cf, rf)
- int cf, rf;
+get_rfd (int cf, int rf)
{
FDR *fdrs;
register FDR *f;
/* Return a safer print NAME for a file descriptor */
static char *
-fdr_name (f)
- FDR *f;
+fdr_name (FDR *f)
{
if (f->rss == -1)
return "<stripped file>";
different sections are relocated via the SECTION_OFFSETS. */
void
-mdebug_build_psymtabs (objfile, swap, info)
- struct objfile *objfile;
- const struct ecoff_debug_swap *swap;
- struct ecoff_debug_info *info;
+mdebug_build_psymtabs (struct objfile *objfile,
+ const struct ecoff_debug_swap *swap,
+ struct ecoff_debug_info *info)
{
cur_bfd = objfile->obfd;
debug_swap = swap;
/* Enter a new lexical context */
static void
-push_parse_stack ()
+push_parse_stack (void)
{
struct parse_stack *new;
/* Exit a lexical context */
static void
-pop_parse_stack ()
+pop_parse_stack (void)
{
if (!top_stack)
return;
/* Check whether we already saw symbol SH in file FH */
static struct mdebug_pending *
-is_pending_symbol (fh, sh)
- FDR *fh;
- char *sh;
+is_pending_symbol (FDR *fh, char *sh)
{
int f_idx = fh - debug_info->fdr;
register struct mdebug_pending *p;
/* Add a new symbol SH of type T */
static void
-add_pending (fh, sh, t)
- FDR *fh;
- char *sh;
- struct type *t;
+add_pending (FDR *fh, char *sh, struct type *t)
{
int f_idx = fh - debug_info->fdr;
struct mdebug_pending *p = is_pending_symbol (fh, sh);
SYMR's handled (normally one). */
static int
-parse_symbol (sh, ax, ext_sh, bigend, section_offsets, objfile)
- SYMR *sh;
- union aux_ext *ax;
- char *ext_sh;
- int bigend;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
+parse_symbol (SYMR *sh, union aux_ext *ax, char *ext_sh, int bigend,
+ struct section_offsets *section_offsets, struct objfile *objfile)
{
const bfd_size_type external_sym_size = debug_swap->external_sym_size;
void (*const swap_sym_in) (bfd *, PTR, SYMR *) = debug_swap->swap_sym_in;
they are big-endian or little-endian (from fh->fBigendian). */
static struct type *
-parse_type (fd, ax, aux_index, bs, bigend, sym_name)
- int fd;
- union aux_ext *ax;
- unsigned int aux_index;
- int *bs;
- int bigend;
- char *sym_name;
+parse_type (int fd, union aux_ext *ax, unsigned int aux_index, int *bs,
+ int bigend, char *sym_name)
{
/* Null entries in this map are treated specially */
static struct type **map_bt[] =
Returns the number of aux symbols we parsed. */
static int
-upgrade_type (fd, tpp, tq, ax, bigend, sym_name)
- int fd;
- struct type **tpp;
- int tq;
- union aux_ext *ax;
- int bigend;
- char *sym_name;
+upgrade_type (int fd, struct type **tpp, int tq, union aux_ext *ax, int bigend,
+ char *sym_name)
{
int off;
struct type *t;
static void parse_procedure (PDR *, struct symtab *, struct partial_symtab *);
static void
-parse_procedure (pr, search_symtab, pst)
- PDR *pr;
- struct symtab *search_symtab;
- struct partial_symtab *pst;
+parse_procedure (PDR *pr, struct symtab *search_symtab,
+ struct partial_symtab *pst)
{
struct symbol *s, *i;
struct block *b;
/* Relocate the extra function info pointed to by the symbol table. */
void
-ecoff_relocate_efi (sym, delta)
- struct symbol *sym;
- CORE_ADDR delta;
+ecoff_relocate_efi (struct symbol *sym, CORE_ADDR delta)
{
struct mips_extra_func_info *e;
struct objfile *);
static void
-parse_external (es, bigend, section_offsets, objfile)
- EXTR *es;
- int bigend;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
+parse_external (EXTR *es, int bigend, struct section_offsets *section_offsets,
+ struct objfile *objfile)
{
union aux_ext *ax;
struct partial_symtab *, CORE_ADDR);
static void
-parse_lines (fh, pr, lt, maxlines, pst, lowest_pdr_addr)
- FDR *fh;
- PDR *pr;
- struct linetable *lt;
- int maxlines;
- struct partial_symtab *pst;
- CORE_ADDR lowest_pdr_addr;
+parse_lines (FDR *fh, PDR *pr, struct linetable *lt, int maxlines,
+ struct partial_symtab *pst, CORE_ADDR lowest_pdr_addr)
{
unsigned char *base;
int j, k;
into a partial_symtab. */
static void
-parse_partial_symbols (objfile)
- struct objfile *objfile;
+parse_partial_symbols (struct objfile *objfile)
{
const bfd_size_type external_sym_size = debug_swap->external_sym_size;
const bfd_size_type external_rfd_size = debug_swap->external_rfd_size;
all the the enum constants to the partial symbol table. */
static void
-handle_psymbol_enumerators (objfile, fh, stype, svalue)
- struct objfile *objfile;
- FDR *fh;
- int stype;
- CORE_ADDR svalue;
+handle_psymbol_enumerators (struct objfile *objfile, FDR *fh, int stype,
+ CORE_ADDR svalue)
{
const bfd_size_type external_sym_size = debug_swap->external_sym_size;
void (*const swap_sym_in) (bfd *, PTR, SYMR *) = debug_swap->swap_sym_in;
The flow of control and even the memory allocation differs. FIXME. */
static void
-psymtab_to_symtab_1 (pst, filename)
- struct partial_symtab *pst;
- char *filename;
+psymtab_to_symtab_1 (struct partial_symtab *pst, char *filename)
{
bfd_size_type external_sym_size;
bfd_size_type external_pdr_size;
to an opaque aggregate type, else 0. */
static int
-has_opaque_xref (fh, sh)
- FDR *fh;
- SYMR *sh;
+has_opaque_xref (FDR *fh, SYMR *sh)
{
TIR tir;
union aux_ext *ax;
Return value says how many aux symbols we ate. */
static int
-cross_ref (fd, ax, tpp, type_code, pname, bigend, sym_name)
- int fd;
- union aux_ext *ax;
- struct type **tpp;
- enum type_code type_code; /* Use to alloc new type if none is found. */
- char **pname;
- int bigend;
- char *sym_name;
+cross_ref (int fd, union aux_ext *ax, struct type **tpp, enum type_code type_code, /* Use to alloc new type if none is found. */
+ char **pname, int bigend, char *sym_name)
{
RNDXR rn[1];
unsigned int rf;
keeping the symtab sorted */
static struct symbol *
-mylookup_symbol (name, block, namespace, class)
- char *name;
- register struct block *block;
- namespace_enum namespace;
- enum address_class class;
+mylookup_symbol (char *name, register struct block *block,
+ namespace_enum namespace, enum address_class class)
{
register int bot, top, inc;
register struct symbol *sym;
that's the only time we know how big the block is. FIXME. */
static void
-add_symbol (s, b)
- struct symbol *s;
- struct block *b;
+add_symbol (struct symbol *s, struct block *b)
{
int nsyms = BLOCK_NSYMS (b)++;
struct block *origb;
/* Add a new block B to a symtab S */
static void
-add_block (b, s)
- struct block *b;
- struct symtab *s;
+add_block (struct block *b, struct symtab *s)
{
struct blockvector *bv = BLOCKVECTOR (s);
This is another reason why -ggdb debugging format is preferable. */
static int
-add_line (lt, lineno, adr, last)
- struct linetable *lt;
- int lineno;
- CORE_ADDR adr;
- int last;
+add_line (struct linetable *lt, int lineno, CORE_ADDR adr, int last)
{
/* DEC c89 sometimes produces zero linenos which confuse gdb.
Change them to something sensible. */
/* Blocks with a smaller low bound should come first */
static int
-compare_blocks (arg1, arg2)
- const PTR arg1;
- const PTR arg2;
+compare_blocks (const PTR arg1, const PTR arg2)
{
register int addr_diff;
struct block **b1 = (struct block **) arg1;
as required by some MI search routines */
static void
-sort_blocks (s)
- struct symtab *s;
+sort_blocks (struct symtab *s)
{
struct blockvector *bv = BLOCKVECTOR (s);
MAXSYMS and linenumbers MAXLINES we'll put in it */
static struct symtab *
-new_symtab (name, maxsyms, maxlines, objfile)
- char *name;
- int maxsyms;
- int maxlines;
- struct objfile *objfile;
+new_symtab (char *name, int maxsyms, int maxlines, struct objfile *objfile)
{
struct symtab *s = allocate_symtab (name, objfile);
/* Allocate a new partial_symtab NAME */
static struct partial_symtab *
-new_psymtab (name, objfile)
- char *name;
- struct objfile *objfile;
+new_psymtab (char *name, struct objfile *objfile)
{
struct partial_symtab *psymtab;
proper size to allocate. */
static struct linetable *
-new_linetable (size)
- int size;
+new_linetable (int size)
{
struct linetable *l;
calculating the proper size to allocate. */
static struct linetable *
-shrink_linetable (lt)
- struct linetable *lt;
+shrink_linetable (struct linetable *lt)
{
return (struct linetable *) xrealloc ((PTR) lt,
/* Allocate and zero a new blockvector of NBLOCKS blocks. */
static struct blockvector *
-new_bvect (nblocks)
- int nblocks;
+new_bvect (int nblocks)
{
struct blockvector *bv;
int size;
/* Allocate and zero a new block of MAXSYMS symbols */
static struct block *
-new_block (maxsyms)
- int maxsyms;
+new_block (int maxsyms)
{
int size = sizeof (struct block) + (maxsyms - 1) * sizeof (struct symbol *);
Shrink_block can also be used by add_symbol to grow a block. */
static struct block *
-shrink_block (b, s)
- struct block *b;
- struct symtab *s;
+shrink_block (struct block *b, struct symtab *s)
{
struct block *new;
struct blockvector *bv = BLOCKVECTOR (s);
/* Create a new symbol with printname NAME */
static struct symbol *
-new_symbol (name)
- char *name;
+new_symbol (char *name)
{
struct symbol *s = ((struct symbol *)
obstack_alloc (¤t_objfile->symbol_obstack,
/* Create a new type with printname NAME */
static struct type *
-new_type (name)
- char *name;
+new_type (char *name)
{
struct type *t;
it as normal. */
void
-elfmdebug_build_psymtabs (objfile, swap, sec)
- struct objfile *objfile;
- const struct ecoff_debug_swap *swap;
- asection *sec;
+elfmdebug_build_psymtabs (struct objfile *objfile,
+ const struct ecoff_debug_swap *swap, asection *sec)
{
bfd *abfd = objfile->obfd;
struct ecoff_debug_info *info;
#ifdef TM_MIPS_H
void
-fixup_sigtramp ()
+fixup_sigtramp (void)
{
struct symbol *s;
struct symtab *st;
#endif /* TM_MIPS_H */
void
-_initialize_mdebugread ()
+_initialize_mdebugread (void)
{
mdebug_type_void =
init_type (TYPE_CODE_VOID, 1,
for inserting the breakpoint. */
unsigned char *
-memory_breakpoint_from_pc (pcptr, lenptr)
- CORE_ADDR *pcptr;
- int *lenptr;
+memory_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
{
/* {BIG_,LITTLE_}BREAKPOINT is the sequence of bytes we insert for a
breakpoint. On some machines, breakpoints are handled by the
is accomplished via BREAKPOINT_MAX). */
int
-default_memory_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+default_memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int val;
unsigned char *bp;
int
-default_memory_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+default_memory_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
unsigned char *bp;
int bplen;
int
-memory_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
return MEMORY_INSERT_BREAKPOINT(addr, contents_cache);
}
int
-memory_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+memory_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
return MEMORY_REMOVE_BREAKPOINT(addr, contents_cache);
}
}
void
-_initialize_mi_cmds ()
+_initialize_mi_cmds (void)
{
build_table (mi_cmds);
memset (&stats, 0, sizeof (stats));
}
static void
-mi_command_loop ()
+mi_command_loop (void)
{
/* HACK: Force stdout/stderr to point at the console. This avoids
any potential side effects caused by legacy code that is still
}
static void
-setup_architecture_data ()
+setup_architecture_data (void)
{
/* don't trust REGISTER_BYTES to be zero. */
old_regs = xmalloc (REGISTER_BYTES + 1);
}
static void
-mi_init_ui (arg0)
- char *arg0;
+mi_init_ui (char *arg0)
{
/* Eventually this will contain code that takes control of the
console. */
}
void
-_initialize_mi_main ()
+_initialize_mi_main (void)
{
/* If we're _the_ interpreter, take control. */
if (interpreter_p
/* Mark beginning of a table */
void
-mi_table_begin (uiout, nbrofcols, tblid)
- struct ui_out *uiout;
- int nbrofcols;
- char *tblid;
+mi_table_begin (struct ui_out *uiout, int nbrofcols, char *tblid)
{
struct ui_out_data *data = ui_out_data (uiout);
field_separator (uiout);
/* Mark beginning of a table body */
void
-mi_table_body (uiout)
- struct ui_out *uiout;
+mi_table_body (struct ui_out *uiout)
{
struct ui_out_data *data = ui_out_data (uiout);
/* close the table header line if there were any headers */
/* Mark end of a table */
void
-mi_table_end (uiout)
- struct ui_out *uiout;
+mi_table_end (struct ui_out *uiout)
{
struct ui_out_data *data = ui_out_data (uiout);
list_close (uiout);
/* Specify table header */
void
-mi_table_header (uiout, width, alignment, colhdr)
- struct ui_out *uiout;
- int width;
- int alignment;
- char *colhdr;
+mi_table_header (struct ui_out *uiout, int width, int alignment, char *colhdr)
{
struct ui_out_data *data = ui_out_data (uiout);
if (!data->first_header++)
/* Mark beginning of a list */
void
-mi_list_begin (uiout, list_flag, lstid)
- struct ui_out *uiout;
- int list_flag;
- char *lstid;
+mi_list_begin (struct ui_out *uiout, int list_flag, char *lstid)
{
struct ui_out_data *data = ui_out_data (uiout);
field_separator (uiout);
/* Mark end of a list */
void
-mi_list_end (uiout, list_flag)
- struct ui_out *uiout;
- int list_flag;
+mi_list_end (struct ui_out *uiout, int list_flag)
{
struct ui_out_data *data = ui_out_data (uiout);
list_close (uiout);
/* output an int field */
void
-mi_field_int (uiout, fldno, width, alignment, fldname, value)
- struct ui_out *uiout;
- int fldno;
- int width;
- int alignment;
- char *fldname;
- int value;
+mi_field_int (struct ui_out *uiout, int fldno, int width, int alignment,
+ char *fldname, int value)
{
char buffer[20]; /* FIXME: how many chars long a %d can become? */
/* used to ommit a field */
void
-mi_field_skip (uiout, fldno, width, alignment, fldname)
- struct ui_out *uiout;
- int fldno;
- int width;
- int alignment;
- char *fldname;
+mi_field_skip (struct ui_out *uiout, int fldno, int width, int alignment,
+ char *fldname)
{
mi_field_string (uiout, fldno, width, alignment, fldname, "");
}
}
void
-mi_spaces (uiout, numspaces)
- struct ui_out *uiout;
- int numspaces;
+mi_spaces (struct ui_out *uiout, int numspaces)
{
}
void
-mi_text (uiout, string)
- struct ui_out *uiout;
- char *string;
+mi_text (struct ui_out *uiout, char *string)
{
}
}
void
-mi_wrap_hint (uiout, identstring)
- struct ui_out *uiout;
- char *identstring;
+mi_wrap_hint (struct ui_out *uiout, char *identstring)
{
wrap_here (identstring);
}
void
-mi_flush (uiout)
- struct ui_out *uiout;
+mi_flush (struct ui_out *uiout)
{
struct ui_out_data *data = ui_out_data (uiout);
gdb_flush (data->buffer);
/* standard gdb initialization hook */
void
-_initialize_mi_out ()
+_initialize_mi_out (void)
{
/* nothing happens here */
}
}
void
-_initialize_mi_parse ()
+_initialize_mi_parse (void)
{
}
names (the dynamic linker deals with the duplication). */
struct minimal_symbol *
-lookup_minimal_symbol (name, sfile, objf)
- register const char *name;
- const char *sfile;
- struct objfile *objf;
+lookup_minimal_symbol (register const char *name, const char *sfile,
+ struct objfile *objf)
{
struct objfile *objfile;
struct minimal_symbol *msymbol;
*/
struct minimal_symbol *
-lookup_minimal_symbol_text (name, sfile, objf)
- register const char *name;
- const char *sfile;
- struct objfile *objf;
+lookup_minimal_symbol_text (register const char *name, const char *sfile,
+ struct objfile *objf)
{
struct objfile *objfile;
struct minimal_symbol *msymbol;
*/
struct minimal_symbol *
-lookup_minimal_symbol_solib_trampoline (name, sfile, objf)
- register const char *name;
- const char *sfile;
- struct objfile *objf;
+lookup_minimal_symbol_solib_trampoline (register const char *name,
+ const char *sfile, struct objfile *objf)
{
struct objfile *objfile;
struct minimal_symbol *msymbol;
0x40000 and objfile B has .text at 0x234 and .data at 0x40048. */
struct minimal_symbol *
-lookup_minimal_symbol_by_pc_section (pc, section)
- CORE_ADDR pc;
- asection *section;
+lookup_minimal_symbol_by_pc_section (CORE_ADDR pc, asection *section)
{
int lo;
int hi;
for a matching PC (no section given) */
struct minimal_symbol *
-lookup_minimal_symbol_by_pc (pc)
- CORE_ADDR pc;
+lookup_minimal_symbol_by_pc (CORE_ADDR pc)
{
return lookup_minimal_symbol_by_pc_section (pc, find_pc_mapped_section (pc));
}
#ifdef SOFUN_ADDRESS_MAYBE_MISSING
CORE_ADDR
-find_stab_function_addr (namestring, filename, objfile)
- char *namestring;
- char *filename;
- struct objfile *objfile;
+find_stab_function_addr (char *namestring, char *filename,
+ struct objfile *objfile)
{
struct minimal_symbol *msym;
char *p;
static int get_symbol_leading_char (bfd *);
static int
-get_symbol_leading_char (abfd)
- bfd *abfd;
+get_symbol_leading_char (bfd *abfd)
{
if (abfd != NULL)
return bfd_get_symbol_leading_char (abfd);
symbol to allocate the memory for the first bunch. */
void
-init_minimal_symbol_collection ()
+init_minimal_symbol_collection (void)
{
msym_count = 0;
msym_bunch = NULL;
}
void
-prim_record_minimal_symbol (name, address, ms_type, objfile)
- const char *name;
- CORE_ADDR address;
- enum minimal_symbol_type ms_type;
- struct objfile *objfile;
+prim_record_minimal_symbol (const char *name, CORE_ADDR address,
+ enum minimal_symbol_type ms_type,
+ struct objfile *objfile)
{
int section;
newly created. */
struct minimal_symbol *
-prim_record_minimal_symbol_and_info (name, address, ms_type, info, section,
- bfd_section, objfile)
- const char *name;
- CORE_ADDR address;
- enum minimal_symbol_type ms_type;
- char *info;
- int section;
- asection *bfd_section;
- struct objfile *objfile;
+prim_record_minimal_symbol_and_info (const char *name, CORE_ADDR address,
+ enum minimal_symbol_type ms_type,
+ char *info, int section,
+ asection *bfd_section,
+ struct objfile *objfile)
{
register struct msym_bunch *new;
register struct minimal_symbol *msymbol;
Within groups with the same address, sort by name. */
static int
-compare_minimal_symbols (fn1p, fn2p)
- const PTR fn1p;
- const PTR fn2p;
+compare_minimal_symbols (const PTR fn1p, const PTR fn2p)
{
register const struct minimal_symbol *fn1;
register const struct minimal_symbol *fn2;
overwrite its type with the type from the one we are compacting out. */
static int
-compact_minimal_symbols (msymbol, mcount, objfile)
- struct minimal_symbol *msymbol;
- int mcount;
- struct objfile *objfile;
+compact_minimal_symbols (struct minimal_symbol *msymbol, int mcount,
+ struct objfile *objfile)
{
struct minimal_symbol *copyfrom;
struct minimal_symbol *copyto;
attempts to demangle them if we later add more minimal symbols. */
void
-install_minimal_symbols (objfile)
- struct objfile *objfile;
+install_minimal_symbols (struct objfile *objfile)
{
register int bindex;
register int mcount;
/* Sort all the minimal symbols in OBJFILE. */
void
-msymbols_sort (objfile)
- struct objfile *objfile;
+msymbols_sort (struct objfile *objfile)
{
qsort (objfile->msymbols, objfile->minimal_symbol_count,
sizeof (struct minimal_symbol), compare_minimal_symbols);
in a trampoline code stub. */
struct minimal_symbol *
-lookup_solib_trampoline_symbol_by_pc (pc)
- CORE_ADDR pc;
+lookup_solib_trampoline_symbol_by_pc (CORE_ADDR pc)
{
struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (pc);
a duplicate function in case this matters someday. */
CORE_ADDR
-find_solib_trampoline_target (pc)
- CORE_ADDR pc;
+find_solib_trampoline_target (CORE_ADDR pc)
{
struct objfile *objfile;
struct minimal_symbol *msymbol;
/* Get all registers from the inferior */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[MAX_REGISTER_RAW_SIZE];
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
CORE_ADDR jb_addr;
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
*/
static void
-fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR reg_addr;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR reg_addr)
{
register int regno;
register unsigned int addr;
BLOCKEND is the address of the end of the user structure. */
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
CORE_ADDR addr;
};
void
-_initialize_core_mips ()
+_initialize_core_mips (void)
{
add_core_fns (&mips_core_fns);
}
char **mips_processor_reg_names = mips_generic_reg_names;
char *
-mips_register_name (i)
- int i;
+mips_register_name (int i)
{
return mips_processor_reg_names[i];
}
/* Should call_function allocate stack space for a struct return? */
int
-mips_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+mips_use_struct_convention (int gcc_p, struct type *type)
{
if (MIPS_EABI)
return (TYPE_LENGTH (type) > 2 * MIPS_SAVED_REGSIZE);
}
static void
-mips32_heuristic_proc_desc (start_pc, limit_pc, next_frame, sp)
- CORE_ADDR start_pc, limit_pc;
- struct frame_info *next_frame;
- CORE_ADDR sp;
+mips32_heuristic_proc_desc (CORE_ADDR start_pc, CORE_ADDR limit_pc,
+ struct frame_info *next_frame, CORE_ADDR sp)
{
CORE_ADDR cur_pc;
CORE_ADDR frame_addr = 0; /* Value of $r30. Used by gcc for frame-pointer */
/* Fech thread's registers. if regno == -1, fetch all regs */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
kern_return_t ret;
*/
void
-store_inferior_registers (regno)
- register int regno;
+store_inferior_registers (register int regno)
{
thread_state_data_t state;
kern_return_t ret;
extern CORE_ADDR sigtramp_address;
static void
-mipscoff_new_init (ignore)
- struct objfile *ignore;
+mipscoff_new_init (struct objfile *ignore)
{
sigtramp_address = 0;
stabsread_new_init ();
/* Initialize to read a symbol file (nothing to do). */
static void
-mipscoff_symfile_init (objfile)
- struct objfile *objfile;
+mipscoff_symfile_init (struct objfile *objfile)
{
}
/* Read a symbol file from a file. */
static void
-mipscoff_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+mipscoff_symfile_read (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
struct cleanup *back_to;
particular objfile. */
static void
-mipscoff_symfile_finish (objfile)
- struct objfile *objfile;
+mipscoff_symfile_finish (struct objfile *objfile)
{
}
if so, stash away some access information for the section. */
static void
-alphacoff_locate_sections (ignore_abfd, sectp, sip)
- bfd *ignore_abfd;
- asection *sectp;
- PTR sip;
+alphacoff_locate_sections (bfd *ignore_abfd, asection *sectp, PTR sip)
{
register struct alphacoff_dynsecinfo *si;
add them to the minimal symbol table. */
static void
-read_alphacoff_dynamic_symtab (section_offsets, objfile)
- struct section_offsets *section_offsets;
- struct objfile *objfile;
+read_alphacoff_dynamic_symtab (struct section_offsets *section_offsets,
+ struct objfile *objfile)
{
bfd *abfd = objfile->obfd;
struct alphacoff_dynsecinfo si;
};
void
-_initialize_mipsread ()
+_initialize_mipsread (void)
{
add_symtab_fns (&ecoff_sym_fns);
}
*/
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
register int regi;
register greg_t *regp = &(*gregsetp)[0];
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
register greg_t *regp = &(*gregsetp)[0];
*/
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
register int regi;
static char zerobuf[MAX_REGISTER_RAW_SIZE] =
}
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *from, *to;
This routine returns true on success. */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
CORE_ADDR jb_addr;
/* Should call_function allocate stack space for a struct return? */
int
-mn10200_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+mn10200_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_NFIELDS (type) > 1 || TYPE_LENGTH (type) > 8);
}
#define NO_MORE_FRAMES 0x8
static CORE_ADDR
-mn10200_analyze_prologue (fi, pc)
- struct frame_info *fi;
- CORE_ADDR pc;
+mn10200_analyze_prologue (struct frame_info *fi, CORE_ADDR pc)
{
CORE_ADDR func_addr, func_end, addr, stop;
CORE_ADDR stack_size;
stack pointer that was in use at the time the function call was made? */
CORE_ADDR
-mn10200_frame_chain (fi)
- struct frame_info *fi;
+mn10200_frame_chain (struct frame_info *fi)
{
struct frame_info dummy_frame;
Return the address of the first inst past the prologue of the function. */
CORE_ADDR
-mn10200_skip_prologue (pc)
- CORE_ADDR pc;
+mn10200_skip_prologue (CORE_ADDR pc)
{
/* We used to check the debug symbols, but that can lose if
we have a null prologue. */
command, or the call dummy breakpoint gets hit. */
void
-mn10200_pop_frame (frame)
- struct frame_info *frame;
+mn10200_pop_frame (struct frame_info *frame)
{
int regnum;
order on the stack. */
CORE_ADDR
-mn10200_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+mn10200_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int argnum = 0;
int len = 0;
Needed for targets where we don't actually execute a JSR/BSR instruction */
CORE_ADDR
-mn10200_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+mn10200_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
unsigned char buf[4];
call. */
CORE_ADDR
-mn10200_store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+mn10200_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
/* The structure return address is passed as the first argument. */
write_register (0, addr);
will be found. */
CORE_ADDR
-mn10200_frame_saved_pc (fi)
- struct frame_info *fi;
+mn10200_frame_saved_pc (struct frame_info *fi)
{
/* The saved PC will always be at the base of the current frame. */
return (read_memory_integer (fi->frame, REGISTER_SIZE) & 0xffffff);
pointer just prior to calling the target function (see run_stack_dummy). */
void
-mn10200_init_extra_frame_info (fi)
- struct frame_info *fi;
+mn10200_init_extra_frame_info (struct frame_info *fi)
{
if (fi->next)
fi->pc = FRAME_SAVED_PC (fi->next);
}
void
-_initialize_mn10200_tdep ()
+_initialize_mn10200_tdep (void)
{
tm_print_insn = print_insn_mn10200;
}
static int am33_mode;
char *
-mn10300_register_name (i)
- int i;
+mn10300_register_name (int i)
{
return mn10300_register_names[i];
}
CORE_ADDR
-mn10300_saved_pc_after_call (fi)
- struct frame_info *fi;
+mn10300_saved_pc_after_call (struct frame_info *fi)
{
return read_memory_integer (read_register (SP_REGNUM), 4);
}
void
-mn10300_extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+mn10300_extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
if (TYPE_CODE (type) == TYPE_CODE_PTR)
memcpy (valbuf, regbuf + REGISTER_BYTE (4), TYPE_LENGTH (type));
}
CORE_ADDR
-mn10300_extract_struct_value_address (regbuf)
- char *regbuf;
+mn10300_extract_struct_value_address (char *regbuf)
{
return extract_address (regbuf + REGISTER_BYTE (4),
REGISTER_RAW_SIZE (4));
}
void
-mn10300_store_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+mn10300_store_return_value (struct type *type, char *valbuf)
{
if (TYPE_CODE (type) == TYPE_CODE_PTR)
write_register_bytes (REGISTER_BYTE (4), valbuf, TYPE_LENGTH (type));
static struct frame_info *analyze_dummy_frame (CORE_ADDR, CORE_ADDR);
static struct frame_info *
-analyze_dummy_frame (pc, frame)
- CORE_ADDR pc;
- CORE_ADDR frame;
+analyze_dummy_frame (CORE_ADDR pc, CORE_ADDR frame)
{
static struct frame_info *dummy = NULL;
if (dummy == NULL)
/* Should call_function allocate stack space for a struct return? */
int
-mn10300_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+mn10300_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_NFIELDS (type) > 1 || TYPE_LENGTH (type) > 8);
}
one, so we defined it ourselves. */
unsigned char *
-mn10300_breakpoint_from_pc (bp_addr, bp_size)
- CORE_ADDR *bp_addr;
- int *bp_size;
+mn10300_breakpoint_from_pc (CORE_ADDR *bp_addr, int *bp_size)
{
static char breakpoint[] =
{0xff};
function for mn10300_analyze_prologue. */
static void
-fix_frame_pointer (fi, stack_size)
- struct frame_info *fi;
- int stack_size;
+fix_frame_pointer (struct frame_info *fi, int stack_size)
{
if (fi && fi->next == NULL)
{
This is a helper function for mn10300_analyze_prologue. */
static void
-set_movm_offsets (fi, movm_args)
- struct frame_info *fi;
- int movm_args;
+set_movm_offsets (struct frame_info *fi, int movm_args)
{
int offset = 0;
frame chain to not bother trying to unwind past this frame. */
static CORE_ADDR
-mn10300_analyze_prologue (fi, pc)
- struct frame_info *fi;
- CORE_ADDR pc;
+mn10300_analyze_prologue (struct frame_info *fi, CORE_ADDR pc)
{
CORE_ADDR func_addr, func_end, addr, stop;
CORE_ADDR stack_size;
stack pointer that was in use at the time the function call was made? */
CORE_ADDR
-mn10300_frame_chain (fi)
- struct frame_info *fi;
+mn10300_frame_chain (struct frame_info *fi)
{
struct frame_info *dummy;
/* Walk through the prologue to determine the stack size,
Return the address of the first inst past the prologue of the function. */
CORE_ADDR
-mn10300_skip_prologue (pc)
- CORE_ADDR pc;
+mn10300_skip_prologue (CORE_ADDR pc)
{
/* We used to check the debug symbols, but that can lose if
we have a null prologue. */
command, or the call dummy breakpoint gets hit. */
void
-mn10300_pop_frame (frame)
- struct frame_info *frame;
+mn10300_pop_frame (struct frame_info *frame)
{
int regnum;
order on the stack. */
CORE_ADDR
-mn10300_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+mn10300_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int argnum = 0;
int len = 0;
Needed for targets where we don't actually execute a JSR/BSR instruction */
CORE_ADDR
-mn10300_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+mn10300_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
unsigned char buf[4];
call. */
CORE_ADDR
-mn10300_store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+mn10300_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
/* The structure return address is passed as the first argument. */
write_register (0, addr);
will be found. */
CORE_ADDR
-mn10300_frame_saved_pc (fi)
- struct frame_info *fi;
+mn10300_frame_saved_pc (struct frame_info *fi)
{
int adjust = 0;
pointer just prior to calling the target function (see run_stack_dummy). */
void
-mn10300_init_extra_frame_info (fi)
- struct frame_info *fi;
+mn10300_init_extra_frame_info (struct frame_info *fi)
{
if (fi->next)
fi->pc = FRAME_SAVED_PC (fi->next);
any frame pointer offsets. */
void
-mn10300_virtual_frame_pointer (pc, reg, offset)
- CORE_ADDR pc;
- long *reg;
- long *offset;
+mn10300_virtual_frame_pointer (CORE_ADDR pc, long *reg, long *offset)
{
struct frame_info *dummy = analyze_dummy_frame (pc, 0);
/* Set up a dummy frame_info, Analyze the prolog and fill in the
/* This can be made more generic later. */
static void
-set_machine_hook (filename)
- char *filename;
+set_machine_hook (char *filename)
{
int i;
}
void
-_initialize_mn10300_tdep ()
+_initialize_mn10300_tdep (void)
{
/* printf("_initialize_mn10300_tdep\n"); */
#ifdef USE_GENERIC_LOAD
static void
-mon960_load_gen (filename, from_tty)
- char *filename;
- int from_tty;
+mon960_load_gen (char *filename, int from_tty)
{
extern int inferior_pid;
#else
static void
-mon960_load (desc, file, hashmark)
- serial_t desc;
- char *file;
- int hashmark;
+mon960_load (serial_t desc, char *file, int hashmark)
{
bfd *abfd;
asection *s;
};
static void
-mon960_open (args, from_tty)
- char *args;
- int from_tty;
+mon960_open (char *args, int from_tty)
{
char buf[64];
}
void
-_initialize_mon960 ()
+_initialize_mon960 (void)
{
memcpy (mon960_regnames, full_regnames, sizeof (full_regnames));
/* Convert hex digit A to a number. */
static int
-fromhex (a)
- int a;
+fromhex (int a)
{
if (a >= '0' && a <= '9')
return a - '0';
*/
static void
-monitor_vsprintf (sndbuf, pattern, args)
- char *sndbuf;
- char *pattern;
- va_list args;
+monitor_vsprintf (char *sndbuf, char *pattern, va_list args)
{
char format[10];
char fmt;
/* Write characters to the remote system. */
void
-monitor_write (buf, buflen)
- char *buf;
- int buflen;
+monitor_write (char *buf, int buflen)
{
if (SERIAL_WRITE (monitor_desc, buf, buflen))
fprintf_unfiltered (gdb_stderr, "SERIAL_WRITE failed: %s\n",
and without printing remote debug information. */
int
-monitor_readchar ()
+monitor_readchar (void)
{
int c;
int looping;
timeout stuff. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
static enum
will be at the end of BUF. */
int
-monitor_expect (string, buf, buflen)
- char *string;
- char *buf;
- int buflen;
+monitor_expect (char *string, char *buf, int buflen)
{
char *p = string;
int obuflen = buflen;
/* Search for a regexp. */
static int
-monitor_expect_regexp (pat, buf, buflen)
- struct re_pattern_buffer *pat;
- char *buf;
- int buflen;
+monitor_expect_regexp (struct re_pattern_buffer *pat, char *buf, int buflen)
{
char *mybuf;
char *p;
getting into states from which we can't recover. */
int
-monitor_expect_prompt (buf, buflen)
- char *buf;
- int buflen;
+monitor_expect_prompt (char *buf, int buflen)
{
monitor_debug ("MON Expecting prompt\n");
return monitor_expect (current_monitor->prompt, buf, buflen);
#if 0
static unsigned long
-get_hex_word ()
+get_hex_word (void)
{
unsigned long val;
int i;
#endif
static void
-compile_pattern (pattern, compiled_pattern, fastmap)
- char *pattern;
- struct re_pattern_buffer *compiled_pattern;
- char *fastmap;
+compile_pattern (char *pattern, struct re_pattern_buffer *compiled_pattern,
+ char *fastmap)
{
int tmp;
const char *val;
for communication. */
void
-monitor_open (args, mon_ops, from_tty)
- char *args;
- struct monitor_ops *mon_ops;
- int from_tty;
+monitor_open (char *args, struct monitor_ops *mon_ops, int from_tty)
{
char *name;
char **p;
control. */
void
-monitor_close (quitting)
- int quitting;
+monitor_close (int quitting)
{
if (monitor_desc)
SERIAL_CLOSE (monitor_desc);
when you want to detach and do something else with your gdb. */
static void
-monitor_detach (args, from_tty)
- char *args;
- int from_tty;
+monitor_detach (char *args, int from_tty)
{
pop_target (); /* calls monitor_close to do the real work */
if (from_tty)
/* Convert VALSTR into the target byte-ordered value of REGNO and store it. */
char *
-monitor_supply_register (regno, valstr)
- int regno;
- char *valstr;
+monitor_supply_register (int regno, char *valstr)
{
ULONGEST val;
unsigned char regbuf[MAX_REGISTER_RAW_SIZE];
/* Tell the remote machine to resume. */
void
-flush_monitor_dcache ()
+flush_monitor_dcache (void)
{
dcache_flush (remote_dcache);
}
static void
-monitor_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+monitor_resume (int pid, int step, enum target_signal sig)
{
/* Some monitors require a different command when starting a program */
monitor_debug ("MON resume\n");
string which are passed down to monitor specific code. */
static void
-parse_register_dump (buf, len)
- char *buf;
- int len;
+parse_register_dump (char *buf, int len)
{
monitor_debug ("MON Parsing register dump\n");
while (1)
packet. */
static void
-monitor_interrupt (signo)
- int signo;
+monitor_interrupt (int signo)
{
/* If this doesn't work, try more severe steps. */
signal (signo, monitor_interrupt_twice);
/* The user typed ^C twice. */
static void
-monitor_interrupt_twice (signo)
- int signo;
+monitor_interrupt_twice (int signo)
{
signal (signo, ofunc);
/* Ask the user what to do when an interrupt is received. */
static void
-monitor_interrupt_query ()
+monitor_interrupt_query (void)
{
target_terminal_ours ();
}
static void
-monitor_wait_cleanup (old_timeout)
- void *old_timeout;
+monitor_wait_cleanup (void *old_timeout)
{
timeout = *(int *) old_timeout;
signal (SIGINT, ofunc);
status just as `wait' would. */
static int
-monitor_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+monitor_wait (int pid, struct target_waitstatus *status)
{
int old_timeout = timeout;
char buf[TARGET_BUF_SIZE];
errno value. */
static void
-monitor_fetch_register (regno)
- int regno;
+monitor_fetch_register (int regno)
{
char *name;
char *zerobuf;
/* Call the specific function if it has been provided */
static void
-monitor_dump_regs ()
+monitor_dump_regs (void)
{
char buf[TARGET_BUF_SIZE];
int resp_len;
}
static void
-monitor_fetch_registers (regno)
- int regno;
+monitor_fetch_registers (int regno)
{
monitor_debug ("MON fetchregs\n");
if (current_monitor->getreg.cmd)
/* Store register REGNO, or all if REGNO == 0. Return errno value. */
static void
-monitor_store_register (regno)
- int regno;
+monitor_store_register (int regno)
{
char *name;
ULONGEST val;
/* Store the remote registers. */
static void
-monitor_store_registers (regno)
- int regno;
+monitor_store_registers (int regno)
{
if (regno >= 0)
{
debugged. */
static void
-monitor_prepare_to_store ()
+monitor_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-monitor_files_info (ops)
- struct target_ops *ops;
+monitor_files_info (struct target_ops *ops)
{
printf_unfiltered ("\tAttached to %s at %d baud.\n", dev_name, baud_rate);
}
static int
-monitor_write_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_write_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
unsigned int val, hostval;
char *cmd;
static int
-monitor_write_even_block (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_write_even_block (CORE_ADDR memaddr, char *myaddr, int len)
{
unsigned int val;
int written = 0;;
static int
-monitor_write_memory_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_write_memory_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
unsigned char val;
int written = 0;
Which possably entails endian conversions
*/
static int
-monitor_write_memory_longlongs (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_write_memory_longlongs (CORE_ADDR memaddr, char *myaddr, int len)
{
static char hexstage[20]; /* At least 16 digits required, plus null */
char *endstring;
*/
static int
-monitor_write_memory_block (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_write_memory_block (CORE_ADDR memaddr, char *myaddr, int len)
{
int written;
written = 0;
which can only read a single byte/word/etc. at a time. */
static int
-monitor_read_memory_single (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_read_memory_single (CORE_ADDR memaddr, char *myaddr, int len)
{
unsigned int val;
char membuf[sizeof (int) * 2 + 1];
than 16 bytes at a time. */
static int
-monitor_read_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+monitor_read_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
unsigned int val;
char buf[512];
}
static void
-monitor_kill ()
+monitor_kill (void)
{
return; /* ignore attempts to kill target system */
}
the program at that point. */
static void
-monitor_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+monitor_create_inferior (char *exec_file, char *args, char **env)
{
if (args && (*args != '\000'))
error ("Args are not supported by the monitor.");
instructions. */
static void
-monitor_mourn_inferior ()
+monitor_mourn_inferior (void)
{
unpush_target (targ_ops);
generic_mourn_inferior (); /* Do all the proper things now */
/* Tell the monitor to add a breakpoint. */
static int
-monitor_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+monitor_insert_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
unsigned char *bp;
/* Tell the monitor to remove a breakpoint. */
static int
-monitor_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+monitor_remove_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
an S-record. Return non-zero if the ACK is received properly. */
static int
-monitor_wait_srec_ack ()
+monitor_wait_srec_ack (void)
{
int ch;
/* monitor_load -- download a file. */
static void
-monitor_load (file, from_tty)
- char *file;
- int from_tty;
+monitor_load (char *file, int from_tty)
{
dcache_flush (remote_dcache);
monitor_debug ("MON load\n");
}
static void
-monitor_stop ()
+monitor_stop (void)
{
monitor_debug ("MON stop\n");
if ((current_monitor->flags & MO_SEND_BREAK_ON_STOP) != 0)
#if 0
static int
-from_hex (a)
- int a;
+from_hex (int a)
{
if (a >= '0' && a <= '9')
return a - '0';
#endif
char *
-monitor_get_dev_name ()
+monitor_get_dev_name (void)
{
return dev_name;
}
/* Init the target_ops structure pointed at by OPS */
void
-init_monitor_ops (ops)
- struct target_ops *ops;
+init_monitor_ops (struct target_ops *ops)
{
if (monitor_ops.to_magic != OPS_MAGIC)
init_base_monitor_ops ();
/* Define additional commands that are usually only used by monitors. */
void
-_initialize_remote_monitors ()
+_initialize_remote_monitors (void)
{
init_base_monitor_ops ();
add_show_from_set (add_set_cmd ("hash", no_class, var_boolean,
*/
-execle (name, args)
- char *name, *args;
+execle (char *name, char *args)
{
register char **env = &args;
while (*env++)
they display this frame. */
int
-nindy_frame_chain_valid (chain, curframe)
- CORE_ADDR chain;
- struct frame_info *curframe;
+nindy_frame_chain_valid (CORE_ADDR chain, struct frame_info *curframe)
{
struct symbol *sym;
struct minimal_symbol *msymbol;
that's OK because we will be the only thread running anyhow. */
static int
-getDebugChar ()
+getDebugChar (void)
{
int err;
LONG got;
non-zero on success. */
static int
-putDebugChar (c)
- unsigned char c;
+putDebugChar (unsigned char c)
{
int err;
LONG put;
/* Turn a hex character into a number. */
static int
-hex (ch)
- char ch;
+hex (char ch)
{
if ((ch >= 'a') && (ch <= 'f'))
return (ch-'a'+10);
non-zero on success. */
static int
-getpacket (buffer)
- char * buffer;
+getpacket (char *buffer)
{
unsigned char checksum;
unsigned char xmitcsum;
success. */
static int
-putpacket (buffer)
- char * buffer;
+putpacket (char *buffer)
{
unsigned char checksum;
int count;
static short error;
static void
-debug_error (format, parm)
- char *format;
- char *parm;
+debug_error (char *format, char *parm)
{
if (remote_debug)
{
saved). */
int
-get_char (addr)
- char *addr;
+get_char (char *addr)
{
return *addr;
}
void
-set_char (addr, val)
- char *addr;
- int val;
+set_char (char *addr, int val)
{
*addr = val;
}
a fault; if zero treat a fault like any other fault in the stub. */
char *
-mem2hex (mem, buf, count, may_fault)
- void *mem;
- char *buf;
- int count;
- int may_fault;
+mem2hex (void *mem, char *buf, int count, int may_fault)
{
int i;
unsigned char ch;
/* return a pointer to the character AFTER the last byte written */
char *
-hex2mem (buf, mem, count, may_fault)
- char *buf;
- void *mem;
- int count;
- int may_fault;
+hex2mem (char *buf, void *mem, int count, int may_fault)
{
int i;
unsigned char ch;
translate this number into a unix compatible signal value. */
int
-computeSignal (exceptionVector)
- int exceptionVector;
+computeSignal (int exceptionVector)
{
int sigval;
switch (exceptionVector)
/* RETURN NUMBER OF CHARS PROCESSED */
/**********************************************/
static int
-hexToInt(ptr, intValue)
- char **ptr;
- int *intValue;
+hexToInt (char **ptr, int *intValue)
{
int numChars = 0;
int hexValue;
debugged. */
static LONG
-handle_exception (frame)
- struct StackFrame *frame;
+handle_exception (struct StackFrame *frame)
{
int addr, length;
char *ptr;
to have to figure out how to do that. */
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
int hardware, board, port;
BYTE bitRate;
extern int computeSignal (int exceptionVector);
void
-flush_i_cache()
+flush_i_cache (void)
{
}
/* Get the registers out of the frame information. */
void
-frame_to_registers (frame, regs)
- struct StackFrame *frame;
- char *regs;
+frame_to_registers (struct StackFrame *frame, char *regs)
{
/* Copy EAX -> EDI */
mem2hex (&frame->ExceptionEAX, ®s[0 * 4 * 2], 4 * 8, 0);
/* Put the registers back into the frame information. */
void
-registers_to_frame (regs, frame)
- char *regs;
- struct StackFrame *frame;
+registers_to_frame (char *regs, struct StackFrame *frame)
{
/* Copy EAX -> EDI */
hex2mem (®s[0 * 4 * 2], &frame->ExceptionEAX, 4 * 8, 0);
}
void
-set_step_traps (frame)
- struct StackFrame *frame;
+set_step_traps (struct StackFrame *frame)
{
frame->ExceptionSystemFlags |= 0x100;
}
void
-clear_step_traps (frame)
- struct StackFrame *frame;
+clear_step_traps (struct StackFrame *frame)
{
frame->ExceptionSystemFlags &= ~0x100;
}
void
-do_status (ptr, frame)
- char *ptr;
- struct StackFrame *frame;
+do_status (char *ptr, struct StackFrame *frame)
{
int sigval;
/* Get the registers out of the frame information. */
void
-frame_to_registers (frame, regs)
- struct StackFrame *frame;
- char *regs;
+frame_to_registers (struct StackFrame *frame, char *regs)
{
mem2hex (&frame->ExceptionState.CsavedRegs, ®s[GP0_REGNUM * 4 * 2], 4 * 32, 0);
/* Put the registers back into the frame information. */
void
-registers_to_frame (regs, frame)
- char *regs;
- struct StackFrame *frame;
+registers_to_frame (char *regs, struct StackFrame *frame)
{
hex2mem (®s[GP0_REGNUM * 4 * 2], &frame->ExceptionState.CsavedRegs, 4 * 32, 0);
extern int ReadByteAltDebugger (char* addr, char *theByte);
extern int WriteByteAltDebugger (char* addr, char theByte);
int
-get_char (addr)
- char *addr;
+get_char (char *addr)
{
char c;
}
void
-set_char (addr, val)
- char *addr;
- int val;
+set_char (char *addr, int val)
{
if (!WriteByteAltDebugger (addr, val))
mem_err = 1;
#endif
int
-mem_write (dst, src, len)
- char *dst, *src;
- int len;
+mem_write (char *dst, char *src, int len)
{
while (len-- && !mem_err)
set_char (dst++, *src++);
static LONG *saved_target_inst_pc = 0;
void
-set_step_traps (frame)
- struct StackFrame *frame;
+set_step_traps (struct StackFrame *frame)
{
union inst inst;
LONG *target;
set. */
int
-clear_step_traps (frame)
- struct StackFrame *frame;
+clear_step_traps (struct StackFrame *frame)
{
int retcode;
LONG *pc = (LONG *)frame->ExceptionPC;
}
void
-do_status (ptr, frame)
- char *ptr;
- struct StackFrame *frame;
+do_status (char *ptr, struct StackFrame *frame)
{
int sigval;
file at some point in the near future. */
static void
-nlm_new_init (ignore)
- struct objfile *ignore;
+nlm_new_init (struct objfile *ignore)
{
stabsread_new_init ();
buildsym_new_init ();
just a stub. */
static void
-nlm_symfile_init (ignore)
- struct objfile *ignore;
+nlm_symfile_init (struct objfile *ignore)
{
}
*/
static void
-nlm_symtab_read (abfd, addr, objfile)
- bfd *abfd;
- CORE_ADDR addr;
- struct objfile *objfile;
+nlm_symtab_read (bfd *abfd, CORE_ADDR addr, struct objfile *objfile)
{
long storage_needed;
asymbol *sym;
is not currently used. */
static void
-nlm_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+nlm_symfile_read (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
struct cleanup *back_to;
objfile struct from the global list of known objfiles. */
static void
-nlm_symfile_finish (objfile)
- struct objfile *objfile;
+nlm_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_private != NULL)
{
};
void
-_initialize_nlmread ()
+_initialize_nlmread (void)
{
add_symtab_fns (&nlm_sym_fns);
}
#include "defs.h"
void
-_initialize_ns32k_tdep ()
+_initialize_ns32k_tdep (void)
{
tm_print_insn = print_insn_ns32k;
}
to reach some "real" code. */
CORE_ADDR
-merlin_skip_prologue (pc)
- CORE_ADDR pc;
+merlin_skip_prologue (CORE_ADDR pc)
{
register int op = read_memory_integer (pc, 1);
if (op == 0x82)
}
CORE_ADDR
-umax_skip_prologue (pc)
- CORE_ADDR pc;
+umax_skip_prologue (CORE_ADDR pc)
{
register unsigned char op = read_memory_integer (pc, 1);
if (op == 0x82)
Can return -1, meaning no way to tell. */
int
-merlin_frame_num_args (fi)
- struct frame_info *fi;
+merlin_frame_num_args (struct frame_info *fi)
{
int numargs;
CORE_ADDR pc;
so this will often not work properly. If the arg names
are known, it's likely most of them will be printed. */
int
-umax_frame_num_args (fi)
- struct frame_info *fi;
+umax_frame_num_args (struct frame_info *fi)
{
int numargs;
CORE_ADDR pc;
}
-sign_extend (value, bits)
+sign_extend (int value, int bits)
{
value = value & ((1 << bits) - 1);
return (value & (1 << (bits - 1))
}
void
-flip_bytes (ptr, count)
- char *ptr;
- int count;
+flip_bytes (char *ptr, int count)
{
char tmp;
FRAME_FIND_SAVED_REGS. */
int
-ns32k_localcount (enter_pc)
- CORE_ADDR enter_pc;
+ns32k_localcount (CORE_ADDR enter_pc)
{
unsigned char localtype;
int localcount;
/* Nonzero if instruction at PC is a return instruction. */
static int
-ns32k_about_to_return (pc)
- CORE_ADDR pc;
+ns32k_about_to_return (CORE_ADDR pc)
{
return (read_memory_integer (pc, 1) == 0x12);
}
*/
CORE_ADDR
-ns32k_get_enter_addr (pc)
- CORE_ADDR pc;
+ns32k_get_enter_addr (CORE_ADDR pc)
{
CORE_ADDR enter_addr;
unsigned char op;
*/
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
* On mach3 all registers are always saved in one call.
*/
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
kern_return_t ret;
thread_state_data_t state;
memcpy(&dst, ®isters[REGISTER_BYTE(src)], sizeof(dst))
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fpregisters;
}
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fpregisters;
};
void
-_initialize_ns32knbsd_nat ()
+_initialize_ns32knbsd_nat (void)
{
add_core_fns (&nat_core_fns);
}
* Called by kcore-nbsd.c:get_kcore_registers().
*/
void
-fetch_kcore_registers (pcb)
- struct pcb *pcb;
+fetch_kcore_registers (struct pcb *pcb)
{
struct switchframe sf;
struct reg intreg;
#endif /* FETCH_KCORE_REGISTERS */
void
-clear_regs ()
+clear_regs (void)
{
double zero = 0.0;
int null = 0;
Can return -1, meaning no way to tell. */
int
-frame_num_args (fi)
- struct frame_info *fi;
+frame_num_args (struct frame_info *fi)
{
CORE_ADDR enter_addr;
CORE_ADDR argp;
the end of the table (objfile->sections_end). */
static void
-add_to_objfile_sections (abfd, asect, objfile_p_char)
- bfd *abfd;
- sec_ptr asect;
- PTR objfile_p_char;
+add_to_objfile_sections (bfd *abfd, sec_ptr asect, PTR objfile_p_char)
{
struct objfile *objfile = (struct objfile *) objfile_p_char;
struct obj_section section;
we are building the table, we're pretty much hosed. */
int
-build_objfile_section_table (objfile)
- struct objfile *objfile;
+build_objfile_section_table (struct objfile *objfile)
{
/* objfile->sections can be already set when reading a mapped symbol
file. I believe that we do need to rebuild the section table in
member. */
struct objfile *
-allocate_objfile (abfd, flags)
- bfd *abfd;
- int flags;
+allocate_objfile (bfd *abfd, int flags)
{
struct objfile *objfile = NULL;
struct objfile *last_one = NULL;
/* Put OBJFILE at the front of the list. */
void
-objfile_to_front (objfile)
- struct objfile *objfile;
+objfile_to_front (struct objfile *objfile)
{
struct objfile **objp;
for (objp = &object_files; *objp != NULL; objp = &((*objp)->next))
between the OBJFILE and the list. */
void
-unlink_objfile (objfile)
- struct objfile *objfile;
+unlink_objfile (struct objfile *objfile)
{
struct objfile **objpp;
we free objects in the reusable area. */
void
-free_objfile (objfile)
- struct objfile *objfile;
+free_objfile (struct objfile *objfile)
{
/* First do any symbol file specific actions required when we are
finished with a particular symbol file. Note that if the objfile
/* Free all the object files at once and clean up their users. */
void
-free_all_objfiles ()
+free_all_objfiles (void)
{
struct objfile *objfile, *temp;
/* Relocate OBJFILE to NEW_OFFSETS. There should be OBJFILE->NUM_SECTIONS
entries in new_offsets. */
void
-objfile_relocate (objfile, new_offsets)
- struct objfile *objfile;
- struct section_offsets *new_offsets;
+objfile_relocate (struct objfile *objfile, struct section_offsets *new_offsets)
{
struct section_offsets *delta =
(struct section_offsets *) alloca (SIZEOF_SECTION_OFFSETS);
available, nonzero otherwise. */
int
-have_partial_symbols ()
+have_partial_symbols (void)
{
struct objfile *ofp;
available, nonzero otherwise. */
int
-have_full_symbols ()
+have_full_symbols (void)
{
struct objfile *ofp;
command.
*/
void
-objfile_purge_solibs ()
+objfile_purge_solibs (void)
{
struct objfile *objf;
struct objfile *temp;
available, nonzero otherwise. */
int
-have_minimal_symbols ()
+have_minimal_symbols (void)
{
struct objfile *ofp;
Otherwise, returns the open file descriptor. */
static int
-open_existing_mapped_file (symsfilename, mtime, flags)
- char *symsfilename;
- long mtime;
- int flags;
+open_existing_mapped_file (char *symsfilename, long mtime, int flags)
{
int fd = -1;
struct stat sbuf;
/bin for example). */
static int
-open_mapped_file (filename, mtime, flags)
- char *filename;
- long mtime;
- int flags;
+open_mapped_file (char *filename, long mtime, int flags)
{
int fd;
char *symsfilename;
}
static PTR
-map_to_file (fd)
- int fd;
+map_to_file (int fd)
{
PTR md;
CORE_ADDR mapto;
contains a pointer to the bfd struct sec section. */
struct obj_section *
-find_pc_sect_section (pc, section)
- CORE_ADDR pc;
- struct sec *section;
+find_pc_sect_section (CORE_ADDR pc, struct sec *section)
{
struct obj_section *s;
struct objfile *objfile;
Backward compatibility, no section. */
struct obj_section *
-find_pc_section (pc)
- CORE_ADDR pc;
+find_pc_section (CORE_ADDR pc)
{
return find_pc_sect_section (pc, find_pc_mapped_section (pc));
}
a trampoline. */
int
-in_plt_section (pc, name)
- CORE_ADDR pc;
- char *name;
+in_plt_section (CORE_ADDR pc, char *name)
{
struct obj_section *s;
int retval = 0;
return zero. */
int
-is_in_import_list (name, objfile)
- char *name;
- struct objfile *objfile;
+is_in_import_list (char *name, struct objfile *objfile)
{
register int i;
static serial_t ocd_desc = NULL;
\f
void
-ocd_error (s, error_code)
- char *s;
- int error_code;
+ocd_error (char *s, int error_code)
{
char buf[100];
/* Return nonzero if the thread TH is still alive on the remote system. */
int
-ocd_thread_alive (th)
- int th;
+ocd_thread_alive (int th)
{
return 1;
}
/* ARGSUSED */
void
-ocd_close (quitting)
- int quitting;
+ocd_close (int quitting)
{
if (ocd_desc)
SERIAL_CLOSE (ocd_desc);
/* Stub for catch_errors. */
static int
-ocd_start_remote (dummy)
- PTR dummy;
+ocd_start_remote (PTR dummy)
{
unsigned char buf[10], *p;
int pktlen;
static DCACHE *ocd_dcache;
void
-ocd_open (name, from_tty, target_type, ops)
- char *name;
- int from_tty;
- enum ocd_target_type target_type;
- struct target_ops *ops;
+ocd_open (char *name, int from_tty, enum ocd_target_type target_type,
+ struct target_ops *ops)
{
unsigned char buf[10], *p;
int pktlen;
die when it hits one. */
void
-ocd_detach (args, from_tty)
- char *args;
- int from_tty;
+ocd_detach (char *args, int from_tty)
{
if (args)
error ("Argument given to \"detach\" when remotely debugging.");
/* Tell the remote machine to resume. */
void
-ocd_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+ocd_resume (int pid, int step, enum target_signal siggnal)
{
int pktlen;
}
\f
void
-ocd_stop ()
+ocd_stop (void)
{
int status;
int pktlen;
packet. */
static void
-ocd_interrupt (signo)
- int signo;
+ocd_interrupt (int signo)
{
/* If this doesn't work, try more severe steps. */
signal (signo, ocd_interrupt_twice);
/* The user typed ^C twice. */
static void
-ocd_interrupt_twice (signo)
- int signo;
+ocd_interrupt_twice (int signo)
{
signal (signo, ofunc);
/* Ask the user what to do when an interrupt is received. */
static void
-interrupt_query ()
+interrupt_query (void)
{
target_terminal_ours ();
means in the case of this target). */
int
-ocd_wait ()
+ocd_wait (void)
{
unsigned char *p;
int error_code;
Returns a pointer to a static array containing the register contents. */
unsigned char *
-ocd_read_bdm_registers (first_bdm_regno, last_bdm_regno, reglen)
- int first_bdm_regno;
- int last_bdm_regno;
- int *reglen;
+ocd_read_bdm_registers (int first_bdm_regno, int last_bdm_regno, int *reglen)
{
unsigned char buf[10];
int i;
/* Read register BDM_REGNO and returns its value ala read_register() */
CORE_ADDR
-ocd_read_bdm_register (bdm_regno)
- int bdm_regno;
+ocd_read_bdm_register (int bdm_regno)
{
int reglen;
unsigned char *p;
}
void
-ocd_write_bdm_registers (first_bdm_regno, regptr, reglen)
- int first_bdm_regno;
- unsigned char *regptr;
- int reglen;
+ocd_write_bdm_registers (int first_bdm_regno, unsigned char *regptr, int reglen)
{
unsigned char *buf;
unsigned char *p;
}
void
-ocd_write_bdm_register (bdm_regno, reg)
- int bdm_regno;
- CORE_ADDR reg;
+ocd_write_bdm_register (int bdm_regno, CORE_ADDR reg)
{
unsigned char buf[4];
}
\f
void
-ocd_prepare_to_store ()
+ocd_prepare_to_store (void)
{
}
\f
static int write_mem_command = OCD_WRITE_MEM;
int
-ocd_write_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+ocd_write_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
char buf[256 + 10];
unsigned char *p;
Returns number of bytes transferred, or 0 for error. */
static int
-ocd_read_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+ocd_read_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
char buf[256 + 10];
unsigned char *p;
}
\f
void
-ocd_files_info (ignore)
- struct target_ops *ignore;
+ocd_files_info (struct target_ops *ignore)
{
puts_filtered ("Debugging a target over a serial line.\n");
}
/* Read a single character from the remote side, handling wierd errors. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int ch;
mistaken for real data). */
static int
-get_quoted_char (timeout)
- int timeout;
+get_quoted_char (int timeout)
{
int ch;
static unsigned char pkt[256 * 2 + 10], *pktp; /* Worst case */
static void
-reset_packet ()
+reset_packet (void)
{
pktp = pkt;
}
static void
-output_packet ()
+output_packet (void)
{
if (SERIAL_WRITE (ocd_desc, pkt, pktp - pkt))
perror_with_name ("output_packet: write failed");
through untouched. */
static void
-put_quoted_char (c)
- int c;
+put_quoted_char (int c)
{
switch (c)
{
byte count. */
static void
-stu_put_packet (buf, len)
- unsigned char *buf;
- int len;
+stu_put_packet (unsigned char *buf, int len)
{
unsigned char checksum;
unsigned char c;
byte count. */
static void
-ocd_put_packet (buf, len)
- unsigned char *buf;
- int len;
+ocd_put_packet (unsigned char *buf, int len)
{
unsigned char checksum;
unsigned char c;
*/
static unsigned char *
-stu_get_packet (cmd, lenp, timeout)
- unsigned char cmd;
- int *lenp;
+stu_get_packet (unsigned char cmd, int *lenp, int timeout)
{
int ch;
int len;
*/
static unsigned char *
-ocd_get_packet (cmd, lenp, timeout)
- int cmd;
- int *lenp;
+ocd_get_packet (int cmd, int *lenp, int timeout)
{
int ch;
int len;
following the error code. */
static unsigned char *
-ocd_do_command (cmd, statusp, lenp)
- int cmd;
- int *statusp;
- int *lenp;
+ocd_do_command (int cmd, int *statusp, int *lenp)
{
unsigned char buf[100], *p;
int status, error_code;
}
\f
void
-ocd_kill ()
+ocd_kill (void)
{
/* For some mysterious reason, wait_for_inferior calls kill instead of
mourn after it gets TARGET_WAITKIND_SIGNALLED. Work around it. */
}
void
-ocd_mourn ()
+ocd_mourn (void)
{
unpush_target (current_ops);
generic_mourn_inferior ();
the program at that point. */
void
-ocd_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+ocd_create_inferior (char *exec_file, char *args, char **env)
{
if (args && (*args != '\000'))
error ("Args are not supported by BDM.");
}
void
-ocd_load (args, from_tty)
- char *args;
- int from_tty;
+ocd_load (char *args, int from_tty)
{
generic_load (args, from_tty);
/* BDM (at least on CPU32) uses a different breakpoint */
int
-ocd_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+ocd_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
static char break_insn[] = BDM_BREAKPOINT;
int val;
}
int
-ocd_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+ocd_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
static char break_insn[] = BDM_BREAKPOINT;
int val;
}
static void
-bdm_command (args, from_tty)
- char *args;
- int from_tty;
+bdm_command (char *args, int from_tty)
{
error ("bdm command must be followed by `reset'");
}
static void
-bdm_reset_command (args, from_tty)
- char *args;
- int from_tty;
+bdm_reset_command (char *args, int from_tty)
{
int status, pktlen;
}
static void
-bdm_restart_command (args, from_tty)
- char *args;
- int from_tty;
+bdm_restart_command (char *args, int from_tty)
{
int status, pktlen;
generic_load from trying to set the PC. */
static void
-noop_store_registers (regno)
- int regno;
+noop_store_registers (int regno)
{
}
static void
-bdm_update_flash_command (args, from_tty)
- char *args;
- int from_tty;
+bdm_update_flash_command (char *args, int from_tty)
{
int status, pktlen;
struct cleanup *old_chain;
}
static void
-bdm_read_register_command (args, from_tty)
- char *args;
- int from_tty;
+bdm_read_register_command (char *args, int from_tty)
{
/* XXX repeat should go on to the next register */
}
\f
void
-_initialize_remote_ocd ()
+_initialize_remote_ocd (void)
{
extern struct cmd_list_element *cmdlist;
static struct cmd_list_element *ocd_cmd_list = NULL;
};
static void
-op50n_open (args, from_tty)
- char *args;
- int from_tty;
+op50n_open (char *args, int from_tty)
{
monitor_open (args, &op50n_cmds, from_tty);
}
void
-_initialize_op50n ()
+_initialize_op50n (void)
{
init_op50n_cmds ();
init_monitor_ops (&op50n_ops);
#define N_ABS 6
static void
-record_minimal_symbol (name, address, type, objfile)
- char *name;
- CORE_ADDR address;
- int type;
- struct objfile *objfile;
+record_minimal_symbol (char *name, CORE_ADDR address, int type,
+ struct objfile *objfile)
{
enum minimal_symbol_type ms_type;
#define STBSYMSIZE 10
static void
-read_minimal_symbols (objfile)
- struct objfile *objfile;
+read_minimal_symbols (struct objfile *objfile)
{
FILE *fp;
bfd *abfd;
file, e.g. a shared library). */
static void
-os9k_new_init (ignore)
- struct objfile *ignore;
+os9k_new_init (struct objfile *ignore)
{
stabsread_new_init ();
buildsym_new_init ();
FIXME, there should be a cleaner peephole into the BFD environment here. */
static void
-os9k_symfile_init (objfile)
- struct objfile *objfile;
+os9k_symfile_init (struct objfile *objfile)
{
bfd *sym_bfd = objfile->obfd;
char *name = bfd_get_filename (sym_bfd);
objfile struct from the global list of known objfiles. */
static void
-os9k_symfile_finish (objfile)
- struct objfile *objfile;
+os9k_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_stab_info != NULL)
{
#define VER_ULTRAC ((short)5)
static int
-fill_sym (dbg_file, abfd)
- FILE *dbg_file;
- bfd *abfd;
+fill_sym (FILE *dbg_file, bfd *abfd)
{
short si, nmask;
long li;
SYMFILE_NAME is the name of the file we are reading from. */
static void
-read_os9k_psymtab (objfile, text_addr, text_size)
- struct objfile *objfile;
- CORE_ADDR text_addr;
- int text_size;
+read_os9k_psymtab (struct objfile *objfile, CORE_ADDR text_addr, int text_size)
{
register struct internal_symstruct *bufp = 0; /* =0 avoids gcc -Wall glitch */
register char *namestring;
static struct partial_symtab *
-os9k_start_psymtab (objfile,
- filename, textlow, ldsymoff, ldsymcnt, global_syms, static_syms)
- struct objfile *objfile;
- char *filename;
- CORE_ADDR textlow;
- int ldsymoff;
- int ldsymcnt;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+os9k_start_psymtab (struct objfile *objfile, char *filename, CORE_ADDR textlow,
+ int ldsymoff, int ldsymcnt,
+ struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
struct partial_symtab *result =
start_psymtab_common (objfile, objfile->section_offsets,
}
\f
static void
-os9k_psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+os9k_psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct cleanup *old_chain;
int i;
Be verbose about it if the user wants that. */
static void
-os9k_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+os9k_psymtab_to_symtab (struct partial_symtab *pst)
{
bfd *sym_bfd;
/* Read in a defined section of a specific object file's symbols. */
static void
-os9k_read_ofile_symtab (pst)
- struct partial_symtab *pst;
+os9k_read_ofile_symtab (struct partial_symtab *pst)
{
register struct internal_symstruct *bufp;
unsigned char type;
It is used in end_symtab. */
static void
-os9k_process_one_symbol (type, desc, valu, name, section_offsets, objfile)
- int type, desc;
- CORE_ADDR valu;
- char *name;
- struct section_offsets *section_offsets;
- struct objfile *objfile;
+os9k_process_one_symbol (int type, int desc, CORE_ADDR valu, char *name,
+ struct section_offsets *section_offsets,
+ struct objfile *objfile)
{
register struct context_stack *new;
/* The stab type used for the definition of the last function.
};
void
-_initialize_os9kread ()
+_initialize_os9kread (void)
{
add_symtab_fns (&os9k_sym_fns);
}
static int ldr_read_memory (CORE_ADDR, char *, int, int);
static int
-ldr_read_memory (memaddr, myaddr, len, readstring)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int readstring;
+ldr_read_memory (CORE_ADDR memaddr, char *myaddr, int len, int readstring)
{
int result;
char *buffer;
*/
static int
-solib_map_sections (arg)
- char *arg;
+solib_map_sections (char *arg)
{
struct so_list *so = (struct so_list *) arg; /* catch_errors bogon */
char *filename;
*/
static struct link_map *
-first_link_map_member ()
+first_link_map_member (void)
{
struct link_map *lm = NULL;
static struct link_map first_lm;
}
static struct link_map *
-next_link_map_member (so_list_ptr)
- struct so_list *so_list_ptr;
+next_link_map_member (struct so_list *so_list_ptr)
{
struct link_map *lm = NULL;
static struct link_map next_lm;
}
static void
-xfer_link_map_member (so_list_ptr, lm)
- struct so_list *so_list_ptr;
- struct link_map *lm;
+xfer_link_map_member (struct so_list *so_list_ptr, struct link_map *lm)
{
int i;
so_list_ptr->lm = *lm;
/* A small stub to get us past the arg-passing pinhole of catch_errors. */
static int
-symbol_add_stub (arg)
- char *arg;
+symbol_add_stub (char *arg)
{
register struct so_list *so = (struct so_list *) arg; /* catch_errs bogon */
CORE_ADDR text_addr = 0;
*/
void
-solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
register struct so_list *so = NULL; /* link map state variable */
*/
static void
-info_sharedlibrary_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+info_sharedlibrary_command (char *ignore, int from_tty)
{
register struct so_list *so = NULL; /* link map state variable */
int header_done = 0;
*/
char *
-solib_address (address)
- CORE_ADDR address;
+solib_address (CORE_ADDR address)
{
register struct so_list *so = 0; /* link map state variable */
/* Called by free_all_symtabs */
void
-clear_solib ()
+clear_solib (void)
{
struct so_list *next;
char *bfd_filename;
*/
void
-solib_create_inferior_hook ()
+solib_create_inferior_hook (void)
{
/* Nothing to do for statically bound executables. */
*/
static void
-sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
solib_add (args, from_tty, (struct target_ops *) 0);
}
void
-_initialize_solib ()
+_initialize_solib (void)
{
add_com ("sharedlibrary", class_files, sharedlibrary_command,
"Load shared object library symbols for files matching REGEXP.");
In_quotes is reset to 0 if a char is written with #4 notation */
static void
-pascal_one_char (c, stream, in_quotes)
- register int c;
- struct ui_file *stream;
- int *in_quotes;
+pascal_one_char (register int c, struct ui_file *stream, int *in_quotes)
{
c &= 0xFF; /* Avoid sign bit follies */
characters and strings is language specific. */
static void
-pascal_emit_char (c, stream, quoter)
- register int c;
- struct ui_file *stream;
- int quoter;
+pascal_emit_char (register int c, struct ui_file *stream, int quoter)
{
int in_quotes = 0;
pascal_one_char (c, stream, &in_quotes);
}
void
-pascal_printchar (c, stream)
- int c;
- struct ui_file *stream;
+pascal_printchar (int c, struct ui_file *stream)
{
int in_quotes = 0;
pascal_one_char (c, stream, &in_quotes);
had to stop before printing LENGTH characters, or if FORCE_ELLIPSES. */
void
-pascal_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+pascal_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
register unsigned int i;
unsigned int things_printed = 0;
struct type *
-pascal_create_fundamental_type (objfile, typeid)
- struct objfile *objfile;
- int typeid;
+pascal_create_fundamental_type (struct objfile *objfile, int typeid)
{
register struct type *type = NULL;
};
void
-_initialize_pascal_language ()
+_initialize_pascal_language (void)
{
add_language (&pascal_language_defn);
}
/* LEVEL is the depth to indent lines by. */
void
-pascal_print_type (type, varstring, stream, show, level)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
- int level;
+pascal_print_type (struct type *type, char *varstring, struct ui_file *stream,
+ int show, int level)
{
register enum type_code code;
int demangled_args;
the form that they appear in the source code. */
static void
-pascal_type_print_derivation_info (stream, type)
- struct ui_file *stream;
- struct type *type;
+pascal_type_print_derivation_info (struct ui_file *stream, struct type *type)
{
char *name;
int i;
/* Print the Pascal method arguments ARGS to the file STREAM. */
void
-pascal_type_print_method_args (physname, methodname, stream)
- char *physname;
- char *methodname;
- struct ui_file *stream;
+pascal_type_print_method_args (char *physname, char *methodname,
+ struct ui_file *stream)
{
int is_constructor = STREQN (physname, "__ct__", 6);
int is_destructor = STREQN (physname, "__dt__", 6);
SHOW is always zero on recursive calls. */
void
-pascal_type_print_varspec_prefix (type, stream, show, passed_a_ptr)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
+pascal_type_print_varspec_prefix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr)
{
char *name;
if (type == 0)
}
static void
-pascal_type_print_args (type, stream)
- struct type *type;
- struct ui_file *stream;
+pascal_type_print_args (struct type *type, struct ui_file *stream)
{
int i;
struct type **args;
Args work like pascal_type_print_varspec_prefix. */
static void
-pascal_type_print_varspec_suffix (type, stream, show, passed_a_ptr, demangled_args)
- struct type *type;
- struct ui_file *stream;
- int show;
- int passed_a_ptr;
- int demangled_args;
+pascal_type_print_varspec_suffix (struct type *type, struct ui_file *stream,
+ int show, int passed_a_ptr,
+ int demangled_args)
{
if (type == 0)
return;
We increase it for some recursive calls. */
void
-pascal_type_print_base (type, stream, show, level)
- struct type *type;
- struct ui_file *stream;
- int show;
- int level;
+pascal_type_print_base (struct type *type, struct ui_file *stream, int show,
+ int level)
{
register int i;
register int len;
int
-pascal_val_print (type, valaddr, embedded_offset, address, stream, format, deref_ref, recurse,
- pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+pascal_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
register unsigned int i = 0; /* Number of characters printed */
unsigned len;
}
\f
int
-pascal_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+pascal_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
struct type *type = VALUE_TYPE (val);
int, int, enum val_prettyprint, struct type **);
void
-pascal_object_print_class_method (valaddr, type, stream)
- char *valaddr;
- struct type *type;
- struct ui_file *stream;
+pascal_object_print_class_method (char *valaddr, struct type *type,
+ struct ui_file *stream)
{
struct type *domain;
struct fn_field *f = NULL;
"pointer to virtual function". */
int
-pascal_object_is_vtbl_ptr_type (type)
- struct type *type;
+pascal_object_is_vtbl_ptr_type (struct type *type)
{
char *typename = type_name_no_tag (type);
"pointer to virtual function table". */
int
-pascal_object_is_vtbl_member (type)
- struct type *type;
+pascal_object_is_vtbl_member (struct type *type)
{
if (TYPE_CODE (type) == TYPE_CODE_PTR)
{
should not print, or zero if called from top level. */
void
-pascal_object_print_value_fields (type, valaddr, address, stream, format, recurse, pretty,
- dont_print_vb, dont_print_statmem)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
- struct type **dont_print_vb;
- int dont_print_statmem;
+pascal_object_print_value_fields (struct type *type, char *valaddr,
+ CORE_ADDR address, struct ui_file *stream,
+ int format, int recurse,
+ enum val_prettyprint pretty,
+ struct type **dont_print_vb,
+ int dont_print_statmem)
{
int i, len, n_baseclasses;
struct obstack tmp_obstack;
baseclasses. */
void
-pascal_object_print_value (type, valaddr, address, stream, format, recurse, pretty,
- dont_print_vb)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
- struct type **dont_print_vb;
+pascal_object_print_value (struct type *type, char *valaddr, CORE_ADDR address,
+ struct ui_file *stream, int format, int recurse,
+ enum val_prettyprint pretty,
+ struct type **dont_print_vb)
{
struct obstack tmp_obstack;
struct type **last_dont_print
have the same meanings as in c_val_print. */
static void
-pascal_object_print_static_field (type, val, stream, format, recurse, pretty)
- struct type *type;
- value_ptr val;
- struct ui_file *stream;
- int format;
- int recurse;
- enum val_prettyprint pretty;
+pascal_object_print_static_field (struct type *type, value_ptr val,
+ struct ui_file *stream, int format,
+ int recurse, enum val_prettyprint pretty)
{
if (TYPE_CODE (type) == TYPE_CODE_STRUCT)
{
}
void
-pascal_object_print_class_member (valaddr, domain, stream, prefix)
- char *valaddr;
- struct type *domain;
- struct ui_file *stream;
- char *prefix;
+pascal_object_print_class_member (char *valaddr, struct type *domain,
+ struct ui_file *stream, char *prefix)
{
/* VAL is a byte offset into the structure type DOMAIN.
void
-_initialize_pascal_valprint ()
+_initialize_pascal_valprint (void)
{
add_show_from_set
(add_set_cmd ("pascal_static-members", class_support, var_boolean,
/* Return a ballbark figure for the amount of memory GDB will need to
allocate to read in the debug symbols from FILENAME. */
static LONGEST
-pa64_solib_sizeof_symbol_table (filename)
- char *filename;
+pa64_solib_sizeof_symbol_table (char *filename)
{
bfd *abfd;
int i;
/* Add a shared library to the objfile list and load its symbols into
GDB's symbol table. */
static void
-pa64_solib_add_solib_objfile (so, name, from_tty, text_addr)
- struct so_list *so;
- char *name;
- int from_tty;
- CORE_ADDR text_addr;
+pa64_solib_add_solib_objfile (struct so_list *so, char *name, int from_tty,
+ CORE_ADDR text_addr)
{
bfd *tmp_bfd;
asection *sec;
NULL if we are not attaching to a process or reading a core file. */
static void
-pa64_solib_load_symbols (so, name, from_tty, text_addr, target)
- struct so_list *so;
- char *name;
- int from_tty;
- CORE_ADDR text_addr;
- struct target_ops *target;
+pa64_solib_load_symbols (struct so_list *so, char *name, int from_tty,
+ CORE_ADDR text_addr, struct target_ops *target)
{
struct section_table *p;
asection *sec;
be exceeded. */
void
-pa64_solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+pa64_solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
struct minimal_symbol *msymbol;
CORE_ADDR addr;
call the breakpoint routine for significant events. */
void
-pa64_solib_create_inferior_hook ()
+pa64_solib_create_inferior_hook (void)
{
struct minimal_symbol *msymbol;
unsigned int dld_flags, status;
GDB may already have been notified of. */
void
-pa64_solib_remove_inferior_hook (pid)
- int pid;
+pa64_solib_remove_inferior_hook (int pid)
{
/* Turn off the DT_HP_DEBUG_CALLBACK bit in the dynamic linker flags. */
dld_cache.dld_flags &= ~DT_HP_DEBUG_CALLBACK;
pa64_solib_create_inferior_hook. */
void
-pa64_solib_create_catch_load_hook (pid, tempflag, filename, cond_string)
- int pid;
- int tempflag;
- char *filename;
- char *cond_string;
+pa64_solib_create_catch_load_hook (int pid, int tempflag, char *filename,
+ char *cond_string)
{
create_solib_load_event_breakpoint ("", tempflag, filename, cond_string);
}
pa64_solib_create_inferior_hook. */
void
-pa64_solib_create_catch_unload_hook (pid, tempflag, filename, cond_string)
- int pid;
- int tempflag;
- char *filename;
- char *cond_string;
+pa64_solib_create_catch_unload_hook (int pid, int tempflag, char *filename,
+ char *cond_string)
{
create_solib_unload_event_breakpoint ("", tempflag, filename, cond_string);
}
has been loaded. */
int
-pa64_solib_have_load_event (pid)
- int pid;
+pa64_solib_have_load_event (int pid)
{
CORE_ADDR event_kind;
/* Return nonzero if the dynamic linker has reproted that a library
has been unloaded. */
int
-pa64_solib_have_unload_event (pid)
- int pid;
+pa64_solib_have_unload_event (int pid)
{
CORE_ADDR event_kind;
restarted. */
char *
-pa64_solib_loaded_library_pathname (pid)
- int pid;
+pa64_solib_loaded_library_pathname (int pid)
{
static char dll_path[MAXPATHLEN];
CORE_ADDR dll_path_addr = read_register (ARG3_REGNUM);
restarted. */
char *
-pa64_solib_unloaded_library_pathname (pid)
- int pid;
+pa64_solib_unloaded_library_pathname (int pid)
{
static char dll_path[MAXPATHLEN];
CORE_ADDR dll_path_addr = read_register (ARG3_REGNUM);
/* Return nonzero if PC is an address inside the dynamic linker. */
int
-pa64_solib_in_dynamic_linker (pid, pc)
- int pid;
- CORE_ADDR pc;
+pa64_solib_in_dynamic_linker (int pid, CORE_ADDR pc)
{
asection *shlib_info;
ADDR isn't in any known shared library, return zero. */
CORE_ADDR
-pa64_solib_get_got_by_pc (addr)
- CORE_ADDR addr;
+pa64_solib_get_got_by_pc (CORE_ADDR addr)
{
struct so_list *so_list = so_list_head;
CORE_ADDR got_value = 0;
This function is used in hppa_fix_call_dummy in hppa-tdep.c. */
CORE_ADDR
-pa64_solib_get_solib_by_pc (addr)
- CORE_ADDR addr;
+pa64_solib_get_solib_by_pc (CORE_ADDR addr)
{
struct so_list *so_list = so_list_head;
CORE_ADDR retval = 0;
/* Dump information about all the currently loaded shared libraries. */
static void
-pa64_sharedlibrary_info_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+pa64_sharedlibrary_info_command (char *ignore, int from_tty)
{
struct so_list *so_list = so_list_head;
/* Load up one or more shared libraries as directed by the user. */
static void
-pa64_solib_sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+pa64_solib_sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
pa64_solib_add (args, from_tty, (struct target_ops *) 0);
is not contained in any known shared library. */
char *
-pa64_solib_address (addr)
- CORE_ADDR addr;
+pa64_solib_address (CORE_ADDR addr)
{
struct so_list *so = so_list_head;
/* We are killing the inferior and restarting the program. */
void
-pa64_solib_restart ()
+pa64_solib_restart (void)
{
struct so_list *sl = so_list_head;
}
void
-_initialize_pa64_solib ()
+_initialize_pa64_solib (void)
{
add_com ("sharedlibrary", class_files, pa64_solib_sharedlibrary_command,
"Load shared object library symbols for files matching REGEXP.");
/* Get some HPUX-specific data from a shared lib. */
CORE_ADDR
-so_lib_thread_start_addr (so)
- struct so_list *so;
+so_lib_thread_start_addr (struct so_list *so)
{
return so->pa64_solib_desc.tls_start_addr;
}
return nonzero. */
static boolean
-read_dld_descriptor (target)
- struct target_ops *target;
+read_dld_descriptor (struct target_ops *target)
{
char *dll_path;
asection *dyninfo_sect;
was used as a model for this. */
static boolean
-read_dynamic_info (dyninfo_sect, dld_cache_p)
- asection *dyninfo_sect;
- dld_cache_t *dld_cache_p;
+read_dynamic_info (asection *dyninfo_sect, dld_cache_t *dld_cache_p)
{
char *buf;
char *bufend;
/* Wrapper for target_read_memory to make dlgetmodinfo happy. */
static void *
-pa64_target_read_memory (buffer, ptr, bufsiz, ident)
- void *buffer;
- CORE_ADDR ptr;
- size_t bufsiz;
- int ident;
+pa64_target_read_memory (void *buffer, CORE_ADDR ptr, size_t bufsiz, int ident)
{
if (target_read_memory (ptr, buffer, bufsiz) != 0)
return 0;
be read from the inferior process at the address load_module_desc_addr. */
static void
-add_to_solist (from_tty, dll_path, load_module_desc_p,
- load_module_desc_addr, target)
- boolean from_tty;
- char *dll_path;
- struct load_module_desc *load_module_desc_p;
- CORE_ADDR load_module_desc_addr;
- struct target_ops *target;
+add_to_solist (boolean from_tty, char *dll_path,
+ struct load_module_desc *load_module_desc_p,
+ CORE_ADDR load_module_desc_addr, struct target_ops *target)
{
struct so_list *new_so, *so_list_tail;
int pa64_solib_st_size_threshhold_exceeded;
*/
static CORE_ADDR
-bfd_lookup_symbol (abfd, symname)
- bfd *abfd;
- char *symname;
+bfd_lookup_symbol (bfd *abfd, char *symname)
{
unsigned int storage_needed;
asymbol *sym;
REGISTER_NAME; std_regs; or a target specific alias hook. */
int
-target_map_name_to_register (str, len)
- char *str;
- int len;
+target_map_name_to_register (char *str, int len)
{
int i;
saving the data about any containing call. */
void
-start_arglist ()
+start_arglist (void)
{
register struct funcall *new;
and restore the data for the containing function call. */
int
-end_arglist ()
+end_arglist (void)
{
register int val = arglist_len;
register struct funcall *call = funcall_chain;
a register through here */
void
-write_exp_elt (expelt)
- union exp_element expelt;
+write_exp_elt (union exp_element expelt)
{
if (expout_ptr >= expout_size)
{
}
void
-write_exp_elt_opcode (expelt)
- enum exp_opcode expelt;
+write_exp_elt_opcode (enum exp_opcode expelt)
{
union exp_element tmp;
}
void
-write_exp_elt_sym (expelt)
- struct symbol *expelt;
+write_exp_elt_sym (struct symbol *expelt)
{
union exp_element tmp;
}
void
-write_exp_elt_block (b)
- struct block *b;
+write_exp_elt_block (struct block *b)
{
union exp_element tmp;
tmp.block = b;
}
void
-write_exp_elt_longcst (expelt)
- LONGEST expelt;
+write_exp_elt_longcst (LONGEST expelt)
{
union exp_element tmp;
}
void
-write_exp_elt_dblcst (expelt)
- DOUBLEST expelt;
+write_exp_elt_dblcst (DOUBLEST expelt)
{
union exp_element tmp;
}
void
-write_exp_elt_type (expelt)
- struct type *expelt;
+write_exp_elt_type (struct type *expelt)
{
union exp_element tmp;
}
void
-write_exp_elt_intern (expelt)
- struct internalvar *expelt;
+write_exp_elt_intern (struct internalvar *expelt)
{
union exp_element tmp;
void
-write_exp_string (str)
- struct stoken str;
+write_exp_string (struct stoken str)
{
register int len = str.length;
register int lenelt;
either end of the bitstring. */
void
-write_exp_bitstring (str)
- struct stoken str;
+write_exp_bitstring (struct stoken str)
{
register int bits = str.length; /* length in bits */
register int len = (bits + HOST_CHAR_BIT - 1) / HOST_CHAR_BIT;
static struct type *msym_unknown_symbol_type;
void
-write_exp_msymbol (msymbol, text_symbol_type, data_symbol_type)
- struct minimal_symbol *msymbol;
- struct type *text_symbol_type;
- struct type *data_symbol_type;
+write_exp_msymbol (struct minimal_symbol *msymbol,
+ struct type *text_symbol_type, struct type *data_symbol_type)
{
CORE_ADDR addr;
*/
void
-write_dollar_variable (str)
- struct stoken str;
+write_dollar_variable (struct stoken str)
{
/* Handle the tokens $digits; also $ (short for $0) and $$ (short for $$1)
and $$digits (equivalent to $<-digits> if you could type that). */
{':', ':'};
struct symbol *
-parse_nested_classes_for_hpacc (name, len, token, class_prefix, argptr)
- char *name;
- int len;
- char **token;
- int *class_prefix;
- char **argptr;
+parse_nested_classes_for_hpacc (char *name, int len, char **token,
+ int *class_prefix, char **argptr)
{
/* Comment below comes from decode_line_1 which has very similar
code, which is called for "break" command parsing. */
}
char *
-find_template_name_end (p)
- char *p;
+find_template_name_end (char *p)
{
int depth = 1;
int just_seen_right = 0;
of a string token. */
char *
-copy_name (token)
- struct stoken token;
+copy_name (struct stoken token)
{
memcpy (namecopy, token.ptr, token.length);
namecopy[token.length] = 0;
to prefix form (in which we can conveniently print or execute it). */
static void
-prefixify_expression (expr)
- register struct expression *expr;
+prefixify_expression (register struct expression *expr)
{
register int len =
sizeof (struct expression) + EXP_ELEM_TO_BYTES (expr->nelts);
whose last exp_element is at index ENDPOS - 1 in EXPR. */
int
-length_of_subexp (expr, endpos)
- register struct expression *expr;
- register int endpos;
+length_of_subexp (register struct expression *expr, register int endpos)
{
register int oplen = 1;
register int args = 0;
In the process, convert it from suffix to prefix form. */
static void
-prefixify_subexp (inexpr, outexpr, inend, outbeg)
- register struct expression *inexpr;
- struct expression *outexpr;
- register int inend;
- int outbeg;
+prefixify_subexp (register struct expression *inexpr,
+ struct expression *outexpr, register int inend, int outbeg)
{
register int oplen = 1;
register int args = 0;
If COMMA is nonzero, stop if a comma is reached. */
struct expression *
-parse_exp_1 (stringptr, block, comma)
- char **stringptr;
- struct block *block;
- int comma;
+parse_exp_1 (char **stringptr, struct block *block, int comma)
{
struct cleanup *old_chain;
to use up all of the contents of STRING. */
struct expression *
-parse_expression (string)
- char *string;
+parse_expression (char *string)
{
register struct expression *exp;
exp = parse_exp_1 (&string, 0, 0);
probably useful for any language which declares its types "backwards". */
void
-push_type (tp)
- enum type_pieces tp;
+push_type (enum type_pieces tp)
{
if (type_stack_depth == type_stack_size)
{
}
void
-push_type_int (n)
- int n;
+push_type_int (int n)
{
if (type_stack_depth == type_stack_size)
{
}
enum type_pieces
-pop_type ()
+pop_type (void)
{
if (type_stack_depth)
return type_stack[--type_stack_depth].piece;
}
int
-pop_type_int ()
+pop_type_int (void)
{
if (type_stack_depth)
return type_stack[--type_stack_depth].int_val;
/* Pop the type stack and return the type which corresponds to FOLLOW_TYPE
as modified by all the stuff on the stack. */
struct type *
-follow_types (follow_type)
- struct type *follow_type;
+follow_types (struct type *follow_type)
{
int done = 0;
int array_size;
\f
static void build_parse (void);
static void
-build_parse ()
+build_parse (void)
{
int i;
}
void
-_initialize_parse ()
+_initialize_parse (void)
{
type_stack_size = 80;
type_stack_depth = 0;
NAME is the filename used for communication. */
static void
-bdm_ppc_open (name, from_tty)
- char *name;
- int from_tty;
+bdm_ppc_open (char *name, int from_tty)
{
CORE_ADDR watchdogaddr = 0xff000004;
means in the case of this target). */
static int
-bdm_ppc_wait (pid, target_status)
- int pid;
- struct target_waitstatus *target_status;
+bdm_ppc_wait (int pid, struct target_waitstatus *target_status)
{
int stop_reason;
*/
static void
-bdm_ppc_fetch_registers (regno)
- int regno;
+bdm_ppc_fetch_registers (int regno)
{
int i;
unsigned char *regs, *beginregs, *endregs, *almostregs;
of REGISTERS. FIXME: ignores errors. */
static void
-bdm_ppc_store_registers (regno)
- int regno;
+bdm_ppc_store_registers (int regno)
{
int i;
int first_regno, last_regno;
} /* init_bdm_ppc_ops */
void
-_initialize_bdm_ppc ()
+_initialize_bdm_ppc (void)
{
init_bdm_ppc_ops ();
add_target (&bdm_ppc_ops);
#include "gregset.h"
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
starting from r4. */
CORE_ADDR
-ppc_sysv_abi_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+ppc_sysv_abi_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int argno;
int greg, freg;
#include "serial.h"
static void
-ppcbug_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+ppcbug_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno = 0;
static struct monitor_ops ppcbug_cmds1;
static void
-ppcbug_open0 (args, from_tty)
- char *args;
- int from_tty;
+ppcbug_open0 (char *args, int from_tty)
{
monitor_open (args, &ppcbug_cmds0, from_tty);
}
static void
-ppcbug_open1 (args, from_tty)
- char *args;
- int from_tty;
+ppcbug_open1 (char *args, int from_tty)
{
monitor_open (args, &ppcbug_cmds1, from_tty);
}
void
-_initialize_ppcbug_rom ()
+_initialize_ppcbug_rom (void)
{
init_ppc_cmds ("lo 0\r", &ppcbug_cmds0, &ppcbug_ops0);
init_ppc_cmds ("lo 1\r", &ppcbug_cmds1, &ppcbug_ops1);
memcpy(&dst, ®isters[REGISTER_BYTE(src)], sizeof(dst))
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
}
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct reg inferior_registers;
struct fpreg inferior_fp_registers;
};
void
-fetch_core_registers (core_reg_sect, core_reg_size, which, ignore)
- char *core_reg_sect;
- unsigned core_reg_size;
- int which;
- CORE_ADDR ignore;
+fetch_core_registers (char *core_reg_sect, unsigned core_reg_size, int which,
+ CORE_ADDR ignore)
{
struct md_core *core_reg = (struct md_core *) core_reg_sect;
int i;
};
void
-_initialize_ppcnbsd_nat ()
+_initialize_ppcnbsd_nat (void)
{
add_core_fns (&ppcnbsd_core_fns);
}
past the specification and past all whitespace following it. */
static struct format_data
-decode_format (string_ptr, oformat, osize)
- char **string_ptr;
- int oformat;
- int osize;
+decode_format (char **string_ptr, int oformat, int osize)
{
struct format_data val;
register char *p = *string_ptr;
This is used to pad hex numbers so they line up. */
static void
-print_formatted (val, format, size, stream)
- register value_ptr val;
- register int format;
- int size;
- struct ui_file *stream;
+print_formatted (register value_ptr val, register int format, int size,
+ struct ui_file *stream)
{
struct type *type = check_typedef (VALUE_TYPE (val));
int len = TYPE_LENGTH (type);
with a format. */
void
-print_scalar_formatted (valaddr, type, format, size, stream)
- char *valaddr;
- struct type *type;
- int format;
- int size;
- struct ui_file *stream;
+print_scalar_formatted (char *valaddr, struct type *type, int format, int size,
+ struct ui_file *stream)
{
LONGEST val_long;
unsigned int len = TYPE_LENGTH (type);
`info lines' uses this. */
void
-set_next_address (addr)
- CORE_ADDR addr;
+set_next_address (CORE_ADDR addr)
{
next_address = addr;
settings of the demangle and asm_demangle variables. */
void
-print_address_symbolic (addr, stream, do_demangle, leadin)
- CORE_ADDR addr;
- struct ui_file *stream;
- int do_demangle;
- char *leadin;
+print_address_symbolic (CORE_ADDR addr, struct ui_file *stream, int do_demangle,
+ char *leadin)
{
char *name = NULL;
char *filename = NULL;
/* Print address ADDR on STREAM. USE_LOCAL means the same thing as for
print_longest. */
void
-print_address_numeric (addr, use_local, stream)
- CORE_ADDR addr;
- int use_local;
- struct ui_file *stream;
+print_address_numeric (CORE_ADDR addr, int use_local, struct ui_file *stream)
{
/* Truncate address to the size of a target pointer, avoiding shifts
larger or equal than the width of a CORE_ADDR. The local
<SYMBOL + OFFSET> after the number. */
void
-print_address (addr, stream)
- CORE_ADDR addr;
- struct ui_file *stream;
+print_address (CORE_ADDR addr, struct ui_file *stream)
{
print_address_numeric (addr, 1, stream);
print_address_symbolic (addr, stream, asm_demangle, " ");
or not. */
void
-print_address_demangle (addr, stream, do_demangle)
- CORE_ADDR addr;
- struct ui_file *stream;
- int do_demangle;
+print_address_demangle (CORE_ADDR addr, struct ui_file *stream, int do_demangle)
{
if (addr == 0)
{
Fetch it from memory and print on gdb_stdout. */
static void
-do_examine (fmt, addr, sect)
- struct format_data fmt;
- CORE_ADDR addr;
- asection *sect;
+do_examine (struct format_data fmt, CORE_ADDR addr, asection *sect)
{
register char format = 0;
register char size;
}
\f
static void
-validate_format (fmt, cmdname)
- struct format_data fmt;
- char *cmdname;
+validate_format (struct format_data fmt, char *cmdname)
{
if (fmt.size != 0)
error ("Size letters are meaningless in \"%s\" command.", cmdname);
*/
static void
-print_command_1 (exp, inspect, voidprint)
- char *exp;
- int inspect;
- int voidprint;
+print_command_1 (char *exp, int inspect, int voidprint)
{
struct expression *expr;
register struct cleanup *old_chain = 0;
/* ARGSUSED */
static void
-print_command (exp, from_tty)
- char *exp;
- int from_tty;
+print_command (char *exp, int from_tty)
{
print_command_1 (exp, 0, 1);
}
/* Same as print, except in epoch, it gets its own window */
/* ARGSUSED */
static void
-inspect_command (exp, from_tty)
- char *exp;
- int from_tty;
+inspect_command (char *exp, int from_tty)
{
extern int epoch_interface;
/* Same as print, except it doesn't print void results. */
/* ARGSUSED */
static void
-call_command (exp, from_tty)
- char *exp;
- int from_tty;
+call_command (char *exp, int from_tty)
{
print_command_1 (exp, 0, 0);
}
/* ARGSUSED */
void
-output_command (exp, from_tty)
- char *exp;
- int from_tty;
+output_command (char *exp, int from_tty)
{
struct expression *expr;
register struct cleanup *old_chain;
/* ARGSUSED */
static void
-set_command (exp, from_tty)
- char *exp;
- int from_tty;
+set_command (char *exp, int from_tty)
{
struct expression *expr = parse_expression (exp);
register struct cleanup *old_chain =
/* ARGSUSED */
static void
-sym_info (arg, from_tty)
- char *arg;
- int from_tty;
+sym_info (char *arg, int from_tty)
{
struct minimal_symbol *msymbol;
struct objfile *objfile;
/* ARGSUSED */
static void
-address_info (exp, from_tty)
- char *exp;
- int from_tty;
+address_info (char *exp, int from_tty)
{
register struct symbol *sym;
register struct minimal_symbol *msymbol;
}
\f
void
-x_command (exp, from_tty)
- char *exp;
- int from_tty;
+x_command (char *exp, int from_tty)
{
struct expression *expr;
struct format_data fmt;
Specify the expression. */
static void
-display_command (exp, from_tty)
- char *exp;
- int from_tty;
+display_command (char *exp, int from_tty)
{
struct format_data fmt;
register struct expression *expr;
}
static void
-free_display (d)
- struct display *d;
+free_display (struct display *d)
{
free ((PTR) d->exp);
free ((PTR) d);
the types stored in many expressions. */
void
-clear_displays ()
+clear_displays (void)
{
register struct display *d;
/* Delete the auto-display number NUM. */
static void
-delete_display (num)
- int num;
+delete_display (int num)
{
register struct display *d1, *d;
Specify the element numbers. */
static void
-undisplay_command (args, from_tty)
- char *args;
- int from_tty;
+undisplay_command (char *args, int from_tty)
{
register char *p = args;
register char *p1;
or if the display is disabled. */
static void
-do_one_display (d)
- struct display *d;
+do_one_display (struct display *d)
{
int within_current_scope;
evaluated in the current scope. */
void
-do_displays ()
+do_displays (void)
{
register struct display *d;
This is done when there is an error or a signal. */
void
-disable_display (num)
- int num;
+disable_display (int num)
{
register struct display *d;
}
void
-disable_current_display ()
+disable_current_display (void)
{
if (current_display_number >= 0)
{
}
static void
-display_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+display_info (char *ignore, int from_tty)
{
register struct display *d;
}
static void
-enable_display (args, from_tty)
- char *args;
- int from_tty;
+enable_display (char *args, int from_tty)
{
register char *p = args;
register char *p1;
/* ARGSUSED */
static void
-disable_display_command (args, from_tty)
- char *args;
- int from_tty;
+disable_display_command (char *args, int from_tty)
{
register char *p = args;
register char *p1;
specified by a struct symbol. */
void
-print_variable_value (var, frame, stream)
- struct symbol *var;
- struct frame_info *frame;
- struct ui_file *stream;
+print_variable_value (struct symbol *var, struct frame_info *frame,
+ struct ui_file *stream)
{
value_ptr val = read_var_value (var, frame);
according to the stack frame". At least for VAX, i386, isi. */
void
-print_frame_args (func, fi, num, stream)
- struct symbol *func;
- struct frame_info *fi;
- int num;
- struct ui_file *stream;
+print_frame_args (struct symbol *func, struct frame_info *fi, int num,
+ struct ui_file *stream)
{
struct block *b = NULL;
int nsyms = 0;
the first nameless arg). */
static void
-print_frame_nameless_args (fi, start, num, first, stream)
- struct frame_info *fi;
- long start;
- int num;
- int first;
- struct ui_file *stream;
+print_frame_nameless_args (struct frame_info *fi, long start, int num,
+ int first, struct ui_file *stream)
{
int i;
CORE_ADDR argsaddr;
\f
/* ARGSUSED */
static void
-printf_command (arg, from_tty)
- char *arg;
- int from_tty;
+printf_command (char *arg, int from_tty)
{
register char *f = NULL;
register char *s = arg;
/* ARGSUSED */
static void
-disassemble_command (arg, from_tty)
- char *arg;
- int from_tty;
+disassemble_command (char *arg, int from_tty)
{
CORE_ADDR low, high;
char *name;
on STREAM. Returns length of the instruction, in bytes. */
static int
-print_insn (memaddr, stream)
- CORE_ADDR memaddr;
- struct ui_file *stream;
+print_insn (CORE_ADDR memaddr, struct ui_file *stream)
{
if (TARGET_BYTE_ORDER == BIG_ENDIAN)
TARGET_PRINT_INSN_INFO->endian = BFD_ENDIAN_BIG;
\f
void
-_initialize_printcmd ()
+_initialize_printcmd (void)
{
current_display_number = -1;
}
static void
-set_procfs_trace_cmd (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_procfs_trace_cmd (char *args, int from_tty, struct cmd_list_element *c)
{
#if 0 /* not sure what I might actually need to do here, if anything */
if (procfs_file)
}
static void
-set_procfs_file_cmd (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_procfs_file_cmd (char *args, int from_tty, struct cmd_list_element *c)
{
/* Just changed the filename for procfs tracing.
If a file was already open, close it. */
};
int
-ioctl_with_trace (fd, opcode, ptr, file, line)
- int fd;
- long opcode;
- void *ptr;
- char *file;
- int line;
+ioctl_with_trace (int fd, long opcode, void *ptr, char *file, int line)
{
int i, ret, arg1;
static off_t lseek_offset;
int
-write_with_trace (fd, varg, len, file, line)
- int fd;
- void *varg;
- size_t len;
- char *file;
- int line;
+write_with_trace (int fd, void *varg, size_t len, char *file, int line)
{
int i;
int ret;
}
off_t
-lseek_with_trace (fd, offset, whence, file, line)
- int fd;
- off_t offset;
- int whence;
- char *file;
- int line;
+lseek_with_trace (int fd, off_t offset, int whence, char *file, int line)
{
off_t ret;
#endif /* NEW_PROC_API */
int
-open_with_trace (filename, mode, file, line)
- char *filename;
- int mode;
- char *file;
- int line;
+open_with_trace (char *filename, int mode, char *file, int line)
{
int ret;
}
int
-close_with_trace (fd, file, line)
- int fd;
- char *file;
- int line;
+close_with_trace (int fd, char *file, int line)
{
int ret;
}
pid_t
-wait_with_trace (wstat, file, line)
- int *wstat;
- char *file;
- int line;
+wait_with_trace (int *wstat, char *file, int line)
{
int ret, lstat = 0;
}
void
-procfs_note (msg, file, line)
- char *msg;
- char *file;
- int line;
+procfs_note (char *msg, char *file, int line)
{
prepare_to_trace ();
if (procfs_trace)
}
void
-proc_prettyfprint_status (flags, why, what, thread)
- long flags;
- int why;
- int what;
- int thread;
+proc_prettyfprint_status (long flags, int why, int what, int thread)
{
prepare_to_trace ();
if (procfs_trace)
void
-_initialize_proc_api ()
+_initialize_proc_api (void)
{
struct cmd_list_element *c;
*/
void
-proc_prettyfprint_syscall (file, num, verbose)
- FILE *file;
- int num;
- int verbose;
+proc_prettyfprint_syscall (FILE *file, int num, int verbose)
{
if (syscall_table[num])
fprintf (file, "SYS_%s ", syscall_table[num]);
}
void
-proc_prettyprint_syscall (num, verbose)
- int num;
- int verbose;
+proc_prettyprint_syscall (int num, int verbose)
{
proc_prettyfprint_syscall (stdout, num, verbose);
}
*/
void
-proc_prettyfprint_syscalls (file, sysset, verbose)
- FILE *file;
- sysset_t *sysset;
- int verbose;
+proc_prettyfprint_syscalls (FILE *file, sysset_t *sysset, int verbose)
{
int i;
}
void
-proc_prettyprint_syscalls (sysset, verbose)
- sysset_t *sysset;
- int verbose;
+proc_prettyprint_syscalls (sysset_t *sysset, int verbose)
{
proc_prettyfprint_syscalls (stdout, sysset, verbose);
}
*/
void
-proc_prettyfprint_signal (file, signo, verbose)
- FILE *file;
- int signo;
- int verbose;
+proc_prettyfprint_signal (FILE *file, int signo, int verbose)
{
int i;
}
void
-proc_prettyprint_signal (signo, verbose)
- int signo;
- int verbose;
+proc_prettyprint_signal (int signo, int verbose)
{
proc_prettyfprint_signal (stdout, signo, verbose);
}
*/
void
-proc_prettyfprint_signalset (file, sigset, verbose)
- FILE *file;
- sigset_t *sigset;
- int verbose;
+proc_prettyfprint_signalset (FILE *file, sigset_t *sigset, int verbose)
{
int i;
}
void
-proc_prettyprint_signalset (sigset, verbose)
- sigset_t *sigset;
- int verbose;
+proc_prettyprint_signalset (sigset_t *sigset, int verbose)
{
proc_prettyfprint_signalset (stdout, sigset, verbose);
}
*/
static void
-prettyfprint_faulttable_entry (file, i, verbose)
- FILE *file;
- int i;
- int verbose;
+prettyfprint_faulttable_entry (FILE *file, int i, int verbose)
{
fprintf (file, "%s", fault_table[i].name);
if (verbose)
*/
void
-proc_prettyfprint_fault (file, faultno, verbose)
- FILE *file;
- int faultno;
- int verbose;
+proc_prettyfprint_fault (FILE *file, int faultno, int verbose)
{
int i;
}
void
-proc_prettyprint_fault (faultno, verbose)
- int faultno;
- int verbose;
+proc_prettyprint_fault (int faultno, int verbose)
{
proc_prettyfprint_fault (stdout, faultno, verbose);
}
*/
void
-proc_prettyfprint_faultset (file, fltset, verbose)
- FILE *file;
- fltset_t *fltset;
- int verbose;
+proc_prettyfprint_faultset (FILE *file, fltset_t *fltset, int verbose)
{
int i;
}
void
-proc_prettyprint_faultset (fltset, verbose)
- fltset_t *fltset;
- int verbose;
+proc_prettyprint_faultset (fltset_t *fltset, int verbose)
{
proc_prettyfprint_faultset (stdout, fltset, verbose);
}
}
void
-_initialize_proc_events ()
+_initialize_proc_events (void)
{
init_syscall_table ();
}
};
void
-proc_prettyfprint_flags (file, flags, verbose)
- FILE *file;
- unsigned long flags;
- int verbose;
+proc_prettyfprint_flags (FILE *file, unsigned long flags, int verbose)
{
int i;
}
void
-proc_prettyprint_flags (flags, verbose)
- unsigned long flags;
- int verbose;
+proc_prettyprint_flags (unsigned long flags, int verbose)
{
proc_prettyfprint_flags (stdout, flags, verbose);
}
};
void
-proc_prettyfprint_why (file, why, what, verbose)
- FILE *file;
- unsigned long why;
- unsigned long what;
- int verbose;
+proc_prettyfprint_why (FILE *file, unsigned long why, unsigned long what,
+ int verbose)
{
int i;
}
void
-proc_prettyprint_why (why, what, verbose)
- unsigned long why;
- unsigned long what;
- int verbose;
+proc_prettyprint_why (unsigned long why, unsigned long what, int verbose)
{
proc_prettyfprint_why (stdout, why, what, verbose);
}
struct target_ops procfs_ops; /* the target vector */
static void
-init_procfs_ops ()
+init_procfs_ops (void)
{
procfs_ops.to_shortname = "procfs";
procfs_ops.to_longname = "Unix /proc child process";
*/
static procinfo *
-find_procinfo (pid, tid)
- int pid;
- int tid;
+find_procinfo (int pid, int tid)
{
procinfo *pi;
*/
static procinfo *
-find_procinfo_or_die (pid, tid)
- int pid;
- int tid;
+find_procinfo_or_die (int pid, int tid)
{
procinfo *pi = find_procinfo (pid, tid);
enum { FD_CTL, FD_STATUS, FD_AS };
static int
-open_procinfo_files (pi, which)
- procinfo *pi;
- int which;
+open_procinfo_files (procinfo *pi, int which)
{
#ifdef NEW_PROC_API
char tmp[MAX_PROC_NAME_SIZE];
*/
static procinfo *
-create_procinfo (pid, tid)
- int pid;
- int tid;
+create_procinfo (int pid, int tid)
{
procinfo *pi, *parent;
*/
static void
-close_procinfo_files (pi)
- procinfo *pi;
+close_procinfo_files (procinfo *pi)
{
if (pi->ctl_fd > 0)
close (pi->ctl_fd);
*/
static void
-destroy_one_procinfo (list, pi)
- procinfo **list;
- procinfo *pi;
+destroy_one_procinfo (procinfo **list, procinfo *pi)
{
procinfo *ptr;
}
static void
-destroy_procinfo (pi)
- procinfo *pi;
+destroy_procinfo (procinfo *pi)
{
procinfo *tmp;
*/
static void
-dead_procinfo (pi, msg, kill_p)
- procinfo *pi;
- char *msg;
- int kill_p;
+dead_procinfo (procinfo *pi, char *msg, int kill_p)
{
char procfile[80];
void proc_error (procinfo * pi, char *func, int line);
void
-proc_warn (pi, func, line)
- procinfo *pi;
- char *func;
- int line;
+proc_warn (procinfo *pi, char *func, int line)
{
sprintf (errmsg, "procfs: %s line %d, %s", func, line, pi->pathname);
print_sys_errmsg (errmsg, errno);
}
void
-proc_error (pi, func, line)
- procinfo *pi;
- char *func;
- int line;
+proc_error (procinfo *pi, char *func, int line)
{
sprintf (errmsg, "procfs: %s line %d, %s", func, line, pi->pathname);
perror_with_name (errmsg);
*/
int
-proc_get_status (pi)
- procinfo *pi;
+proc_get_status (procinfo *pi)
{
/* Status file descriptor is opened "lazily" */
if (pi->status_fd == 0 &&
*/
long
-proc_flags (pi)
- procinfo *pi;
+proc_flags (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
*/
int
-proc_why (pi)
- procinfo *pi;
+proc_why (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
*/
int
-proc_what (pi)
- procinfo *pi;
+proc_what (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
*/
int
-proc_nsysarg (pi)
- procinfo *pi;
+proc_nsysarg (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
*/
long *
-proc_sysargs (pi)
- procinfo *pi;
+proc_sysargs (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
*/
int
-proc_syscall (pi)
- procinfo *pi;
+proc_syscall (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
enum { FLAG_RESET, FLAG_SET };
static int
-proc_modify_flag (pi, flag, mode)
- procinfo *pi;
- long flag;
- long mode;
+proc_modify_flag (procinfo *pi, long flag, long mode)
{
long win = 0; /* default to fail */
*/
int
-proc_set_run_on_last_close (pi)
- procinfo *pi;
+proc_set_run_on_last_close (procinfo *pi)
{
return proc_modify_flag (pi, PR_RLC, FLAG_SET);
}
*/
int
-proc_unset_run_on_last_close (pi)
- procinfo *pi;
+proc_unset_run_on_last_close (procinfo *pi)
{
return proc_modify_flag (pi, PR_RLC, FLAG_RESET);
}
*/
int
-proc_set_kill_on_last_close (pi)
- procinfo *pi;
+proc_set_kill_on_last_close (procinfo *pi)
{
return proc_modify_flag (pi, PR_KLC, FLAG_SET);
}
*/
int
-proc_unset_kill_on_last_close (pi)
- procinfo *pi;
+proc_unset_kill_on_last_close (procinfo *pi)
{
return proc_modify_flag (pi, PR_KLC, FLAG_RESET);
}
*/
int
-proc_set_inherit_on_fork (pi)
- procinfo *pi;
+proc_set_inherit_on_fork (procinfo *pi)
{
return proc_modify_flag (pi, PR_FORK, FLAG_SET);
}
*/
int
-proc_unset_inherit_on_fork (pi)
- procinfo *pi;
+proc_unset_inherit_on_fork (procinfo *pi)
{
return proc_modify_flag (pi, PR_FORK, FLAG_RESET);
}
*/
int
-proc_set_async (pi)
- procinfo *pi;
+proc_set_async (procinfo *pi)
{
return proc_modify_flag (pi, PR_ASYNC, FLAG_SET);
}
*/
int
-proc_unset_async (pi)
- procinfo *pi;
+proc_unset_async (procinfo *pi)
{
return proc_modify_flag (pi, PR_ASYNC, FLAG_RESET);
}
*/
int
-proc_stop_process (pi)
- procinfo *pi;
+proc_stop_process (procinfo *pi)
{
int win;
*/
int
-proc_wait_for_stop (pi)
- procinfo *pi;
+proc_wait_for_stop (procinfo *pi)
{
int win;
*/
int
-proc_run_process (pi, step, signo)
- procinfo *pi;
- int step;
- int signo;
+proc_run_process (procinfo *pi, int step, int signo)
{
int win;
int runflags;
*/
int
-proc_set_traced_signals (pi, sigset)
- procinfo *pi;
- sigset_t *sigset;
+proc_set_traced_signals (procinfo *pi, sigset_t *sigset)
{
int win;
*/
int
-proc_set_traced_faults (pi, fltset)
- procinfo *pi;
- fltset_t *fltset;
+proc_set_traced_faults (procinfo *pi, fltset_t *fltset)
{
int win;
*/
int
-proc_set_traced_sysentry (pi, sysset)
- procinfo *pi;
- sysset_t *sysset;
+proc_set_traced_sysentry (procinfo *pi, sysset_t *sysset)
{
int win;
*/
int
-proc_set_traced_sysexit (pi, sysset)
- procinfo *pi;
- sysset_t *sysset;
+proc_set_traced_sysexit (procinfo *pi, sysset_t *sysset)
{
int win;
*/
int
-proc_set_held_signals (pi, sighold)
- procinfo *pi;
- sigset_t *sighold;
+proc_set_held_signals (procinfo *pi, sigset_t *sighold)
{
int win;
*/
sigset_t *
-proc_get_pending_signals (pi, save)
- procinfo *pi;
- sigset_t *save;
+proc_get_pending_signals (procinfo *pi, sigset_t *save)
{
sigset_t *ret = NULL;
*/
struct sigaction *
-proc_get_signal_actions (pi, save)
- procinfo *pi;
- struct sigaction *save;
+proc_get_signal_actions (procinfo *pi, struct sigaction *save)
{
struct sigaction *ret = NULL;
*/
sigset_t *
-proc_get_held_signals (pi, save)
- procinfo *pi;
- sigset_t *save;
+proc_get_held_signals (procinfo *pi, sigset_t *save)
{
sigset_t *ret = NULL;
*/
sigset_t *
-proc_get_traced_signals (pi, save)
- procinfo *pi;
- sigset_t *save;
+proc_get_traced_signals (procinfo *pi, sigset_t *save)
{
sigset_t *ret = NULL;
*/
int
-proc_trace_signal (pi, signo)
- procinfo *pi;
- int signo;
+proc_trace_signal (procinfo *pi, int signo)
{
sigset_t temp;
*/
int
-proc_ignore_signal (pi, signo)
- procinfo *pi;
- int signo;
+proc_ignore_signal (procinfo *pi, int signo)
{
sigset_t temp;
*/
fltset_t *
-proc_get_traced_faults (pi, save)
- procinfo *pi;
- fltset_t *save;
+proc_get_traced_faults (procinfo *pi, fltset_t *save)
{
fltset_t *ret = NULL;
*/
sysset_t *
-proc_get_traced_sysentry (pi, save)
- procinfo *pi;
- sysset_t *save;
+proc_get_traced_sysentry (procinfo *pi, sysset_t *save)
{
sysset_t *ret = NULL;
*/
sysset_t *
-proc_get_traced_sysexit (pi, save)
- procinfo *pi;
- sysset_t *save;
+proc_get_traced_sysexit (procinfo *pi, sysset_t *save)
{
sysset_t * ret = NULL;
*/
int
-proc_clear_current_fault (pi)
- procinfo *pi;
+proc_clear_current_fault (procinfo *pi)
{
int win;
*/
int
-proc_set_current_signal (pi, signo)
- procinfo *pi;
- int signo;
+proc_set_current_signal (procinfo *pi, int signo)
{
int win;
struct {
*/
int
-proc_clear_current_signal (pi)
- procinfo *pi;
+proc_clear_current_signal (procinfo *pi)
{
int win;
*/
gdb_gregset_t *
-proc_get_gregs (pi)
- procinfo *pi;
+proc_get_gregs (procinfo *pi)
{
if (!pi->status_valid || !pi->gregs_valid)
if (!proc_get_status (pi))
*/
gdb_fpregset_t *
-proc_get_fpregs (pi)
- procinfo *pi;
+proc_get_fpregs (procinfo *pi)
{
#ifdef NEW_PROC_API
if (!pi->status_valid || !pi->fpregs_valid)
*/
int
-proc_set_gregs (pi)
- procinfo *pi;
+proc_set_gregs (procinfo *pi)
{
gdb_gregset_t *gregs;
int win;
*/
int
-proc_set_fpregs (pi)
- procinfo *pi;
+proc_set_fpregs (procinfo *pi)
{
gdb_fpregset_t *fpregs;
int win;
*/
int
-proc_kill (pi, signo)
- procinfo *pi;
- int signo;
+proc_kill (procinfo *pi, int signo)
{
int win;
*/
int
-proc_parent_pid (pi)
- procinfo *pi;
+proc_parent_pid (procinfo *pi)
{
/*
* We should never have to apply this operation to any procinfo
*/
int
-proc_set_watchpoint (pi, addr, len, wflags)
- procinfo *pi;
- CORE_ADDR addr;
- int len;
- int wflags;
+proc_set_watchpoint (procinfo *pi, CORE_ADDR addr, int len, int wflags)
{
#if !defined (TARGET_HAS_HARDWARE_WATCHPOINTS)
return 0;
*/
struct ssd *
-proc_get_LDT_entry (pi, key)
- procinfo *pi;
- int key;
+proc_get_LDT_entry (procinfo *pi, int key)
{
static struct ssd *ldt_entry = NULL;
#ifdef NEW_PROC_API
* OSF version
*/
int
-proc_get_nthreads (pi)
- procinfo *pi;
+proc_get_nthreads (procinfo *pi)
{
int nthreads = 0;
* Solaris and Unixware version
*/
int
-proc_get_nthreads (pi)
- procinfo *pi;
+proc_get_nthreads (procinfo *pi)
{
if (!pi->status_valid)
if (!proc_get_status (pi))
* Default version
*/
int
-proc_get_nthreads (pi)
- procinfo *pi;
+proc_get_nthreads (procinfo *pi)
{
return 0;
}
* Solaris and Unixware version
*/
int
-proc_get_current_thread (pi)
- procinfo *pi;
+proc_get_current_thread (procinfo *pi)
{
/*
* Note: this should be applied to the root procinfo for the process,
* OSF version
*/
int
-proc_get_current_thread (pi)
- procinfo *pi;
+proc_get_current_thread (procinfo *pi)
{
#if 0 /* FIXME: not ready for prime time? */
return pi->prstatus.pr_tid;
* Default version
*/
int
-proc_get_current_thread (pi)
- procinfo *pi;
+proc_get_current_thread (procinfo *pi)
{
return 0;
}
*/
int
-proc_delete_dead_threads (parent, thread, ignore)
- procinfo *parent;
- procinfo *thread;
- void *ignore;
+proc_delete_dead_threads (procinfo *parent, procinfo *thread, void *ignore)
{
if (thread && parent) /* sanity */
{
* Solaris 2.5 (ioctl) version
*/
int
-proc_update_threads (pi)
- procinfo *pi;
+proc_update_threads (procinfo *pi)
{
gdb_prstatus_t *prstatus;
struct cleanup *old_chain = NULL;
}
int
-proc_update_threads (pi)
- procinfo *pi;
+proc_update_threads (procinfo *pi)
{
char pathname[MAX_PROC_NAME_SIZE + 16];
struct dirent *direntry;
* OSF version
*/
int
-proc_update_threads (pi)
- procinfo *pi;
+proc_update_threads (procinfo *pi)
{
int nthreads, i;
tid_t *threads;
* Default version
*/
int
-proc_update_threads (pi)
- procinfo *pi;
+proc_update_threads (procinfo *pi)
{
return 0;
}
*/
static int
-procfs_debug_inferior (pi)
- procinfo *pi;
+procfs_debug_inferior (procinfo *pi)
{
fltset_t traced_faults;
sigset_t traced_signals;
}
static void
-procfs_attach (args, from_tty)
- char *args;
- int from_tty;
+procfs_attach (char *args, int from_tty)
{
char *exec_file;
int pid;
}
static void
-procfs_detach (args, from_tty)
- char *args;
- int from_tty;
+procfs_detach (char *args, int from_tty)
{
char *exec_file;
int signo = 0;
}
static int
-do_attach (pid)
- int pid;
+do_attach (int pid)
{
procinfo *pi;
int fail;
}
static void
-do_detach (signo)
- int signo;
+do_detach (int signo)
{
procinfo *pi;
*/
static void
-procfs_fetch_registers (regno)
- int regno;
+procfs_fetch_registers (int regno)
{
gdb_fpregset_t *fpregs;
gdb_gregset_t *gregs;
from the program being debugged. */
static void
-procfs_prepare_to_store ()
+procfs_prepare_to_store (void)
{
#ifdef CHILD_PREPARE_TO_STORE
CHILD_PREPARE_TO_STORE ();
*/
static void
-procfs_store_registers (regno)
- int regno;
+procfs_store_registers (int regno)
{
gdb_fpregset_t *fpregs;
gdb_gregset_t *gregs;
*/
static int
-procfs_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+procfs_wait (int pid, struct target_waitstatus *status)
{
/* First cut: loosely based on original version 2.1 */
procinfo *pi;
static int
-invalidate_cache (parent, pi, ptr)
- procinfo *parent;
- procinfo *pi;
- void *ptr;
+invalidate_cache (procinfo *parent, procinfo *pi, void *ptr)
{
/*
* About to run the child; invalidate caches and do any other cleanup.
*/
static int
-make_signal_thread_runnable (process, pi, ptr)
- procinfo *process;
- procinfo *pi;
- void *ptr;
+make_signal_thread_runnable (procinfo *process, procinfo *pi, void *ptr)
{
#ifdef PR_ASLWP
if (proc_flags (pi) & PR_ASLWP)
*/
static void
-procfs_resume (pid, step, signo)
- int pid;
- int step;
- enum target_signal signo;
+procfs_resume (int pid, int step, enum target_signal signo)
{
procinfo *pi, *thread;
int native_signo;
*/
static int
-register_gdb_signals (pi, signals)
- procinfo *pi;
- sigset_t *signals;
+register_gdb_signals (procinfo *pi, sigset_t *signals)
{
int signo;
*/
static void
-procfs_notice_signals (pid)
- int pid;
+procfs_notice_signals (int pid)
{
sigset_t signals;
procinfo *pi = find_procinfo_or_die (PIDGET (pid), 0);
*/
static void
-procfs_files_info (ignore)
- struct target_ops *ignore;
+procfs_files_info (struct target_ops *ignore)
{
printf_filtered ("\tUsing the running image of %s %s via /proc.\n",
attach_flag? "attached": "child",
*/
static void
-procfs_open (args, from_tty)
- char *args;
- int from_tty;
+procfs_open (char *args, int from_tty)
{
error ("Use the \"run\" command to start a Unix child process.");
}
static int
-procfs_can_run ()
+procfs_can_run (void)
{
/* This variable is controlled by modules that sit atop procfs that
may layer their own process structure atop that provided here.
*/
static void
-procfs_stop ()
+procfs_stop (void)
{
extern pid_t inferior_process_group;
*/
static void
-unconditionally_kill_inferior (pi)
- procinfo *pi;
+unconditionally_kill_inferior (procinfo *pi)
{
int parent_pid;
*/
static void
-procfs_kill_inferior ()
+procfs_kill_inferior (void)
{
if (inferior_pid != 0) /* ? */
{
*/
static void
-procfs_mourn_inferior ()
+procfs_mourn_inferior (void)
{
procinfo *pi;
*/
static void
-procfs_init_inferior (pid)
- int pid;
+procfs_init_inferior (int pid)
{
procinfo *pi;
sigset_t signals;
*/
static void
-procfs_set_exec_trap ()
+procfs_set_exec_trap (void)
{
/* This routine called on the child side (inferior side)
after GDB forks the inferior. It must use only local variables,
*/
static void
-procfs_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+procfs_create_inferior (char *exec_file, char *allargs, char **env)
{
char *shell_file = getenv ("SHELL");
char *tryname;
*/
static int
-procfs_notice_thread (pi, thread, ptr)
- procinfo *pi;
- procinfo *thread;
- void *ptr;
+procfs_notice_thread (procinfo *pi, procinfo *thread, void *ptr)
{
int gdb_threadid = MERGEPID (pi->pid, thread->tid);
*/
void
-procfs_find_new_threads ()
+procfs_find_new_threads (void)
{
procinfo *pi;
*/
static int
-procfs_thread_alive (pid)
- int pid;
+procfs_thread_alive (int pid)
{
int proc, thread;
procinfo *pi;
*/
char *
-procfs_pid_to_str (pid)
- int pid;
+procfs_pid_to_str (int pid)
{
static char buf[80];
int proc, thread;
*/
int
-procfs_set_watchpoint (pid, addr, len, rwflag, after)
- int pid;
- CORE_ADDR addr;
- int len;
- int rwflag;
- int after;
+procfs_set_watchpoint (int pid, CORE_ADDR addr, int len, int rwflag, int after)
{
#ifndef UNIXWARE
int pflags = 0;
*/
int
-procfs_stopped_by_watchpoint (pid)
- int pid;
+procfs_stopped_by_watchpoint (int pid)
{
procinfo *pi;
*/
struct ssd *
-procfs_find_LDT_entry (pid)
- int pid;
+procfs_find_LDT_entry (int pid)
{
gdb_gregset_t *gregs;
int key;
static void
-info_proc_cmd (args, from_tty)
- char *args;
- int from_tty;
+info_proc_cmd (char *args, int from_tty)
{
struct cleanup *old_chain;
procinfo *process = NULL;
}
static void
-proc_trace_syscalls (args, from_tty, entry_or_exit, mode)
- char *args;
- int from_tty;
- int entry_or_exit;
- int mode;
+proc_trace_syscalls (char *args, int from_tty, int entry_or_exit, int mode)
{
procinfo *pi;
sysset_t *sysset;
}
static void
-proc_trace_sysentry_cmd (args, from_tty)
- char *args;
- int from_tty;
+proc_trace_sysentry_cmd (char *args, int from_tty)
{
proc_trace_syscalls (args, from_tty, PR_SYSENTRY, FLAG_SET);
}
static void
-proc_trace_sysexit_cmd (args, from_tty)
- char *args;
- int from_tty;
+proc_trace_sysexit_cmd (char *args, int from_tty)
{
proc_trace_syscalls (args, from_tty, PR_SYSEXIT, FLAG_SET);
}
static void
-proc_untrace_sysentry_cmd (args, from_tty)
- char *args;
- int from_tty;
+proc_untrace_sysentry_cmd (char *args, int from_tty)
{
proc_trace_syscalls (args, from_tty, PR_SYSENTRY, FLAG_RESET);
}
static void
-proc_untrace_sysexit_cmd (args, from_tty)
- char *args;
- int from_tty;
+proc_untrace_sysexit_cmd (char *args, int from_tty)
{
proc_trace_syscalls (args, from_tty, PR_SYSEXIT, FLAG_RESET);
}
void
-_initialize_procfs ()
+_initialize_procfs (void)
{
init_procfs_ops ();
add_target (&procfs_ops);
*/
int
-procfs_first_available ()
+procfs_first_available (void)
{
if (procinfo_list)
return procinfo_list->pid;
register values. */
void
-supply_gregset (gregsetp)
- gregset_t *gregsetp;
+supply_gregset (gregset_t *gregsetp)
{
supply_register (EAX_REGNUM, (char *) &(*gregsetp)[EAX]);
supply_register (EDX_REGNUM, (char *) &(*gregsetp)[EDX]);
}
void
-fill_gregset (gregsetp, regno)
- gregset_t *gregsetp;
- int regno;
+fill_gregset (gregset_t *gregsetp, int regno)
{
int regi;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- fpregset_t *fpregsetp;
+supply_fpregset (fpregset_t *fpregsetp)
{
supply_fpu_registers ((struct fpusave *) &fpregsetp->fp_reg_set);
supply_fpa_registers ((struct fpasave *) &fpregsetp->f_wregs);
them all. */
void
-fill_fpregset (fpregsetp, regno)
- fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (fpregset_t *fpregsetp, int regno)
{
int regi;
char *to;
#define ON 1
#define OFF 0
static void
-rawmode (desc, turnon)
- int desc;
- int turnon;
+rawmode (int desc, int turnon)
{
TERMINAL sg;
}
/* Suck up all the input from the adapt */
-slurp_input ()
+slurp_input (void)
{
char buf[8];
/* Read a character from the remote system, doing all the fancy
timeout stuff. */
static int
-readchar ()
+readchar (void)
{
char buf;
/* Keep discarding input from the remote system, until STRING is found.
Let the user break out immediately. */
static void
-expect (string)
- char *string;
+expect (char *string)
{
char *p = string;
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt ()
+expect_prompt (void)
{
#if defined (LOG_FILE)
/* This is a convenient place to do this. The idea is to do it often
/* Get a hex digit from the remote system & return its value.
If ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
static int
-get_hex_digit (ignore_space)
- int ignore_space;
+get_hex_digit (int ignore_space)
{
int ch;
while (1)
/* Get a byte from adapt_desc and put it in *BYT. Accept any number
leading spaces. */
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
/* Read a 32-bit hex word from the adapt, preceded by a space */
static long
-get_hex_word ()
+get_hex_word (void)
{
long val;
int j;
/* Get N 32-bit hex words from remote, each preceded by a space
and put them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
while (n--)
volatile int n_alarms;
void
-adapt_timer ()
+adapt_timer (void)
{
#if 0
if (kiodebug)
static int need_artificial_trap = 0;
void
-adapt_kill (arg, from_tty)
- char *arg;
- int from_tty;
+adapt_kill (char *arg, int from_tty)
{
fprintf (adapt_stream, "K");
fprintf (adapt_stream, "\r");
* FIXME: Assumes the file to download is a binary coff file.
*/
static void
-adapt_load (args, fromtty)
- char *args;
- int fromtty;
+adapt_load (char *args, int fromtty)
{
FILE *fp;
int n;
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
void
-adapt_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+adapt_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
};
static int
-damn_b (rate)
- int rate;
+damn_b (int rate)
{
int i;
static int baudrate = 9600;
static void
-adapt_open (name, from_tty)
- char *name;
- int from_tty;
+adapt_open (char *name, int from_tty)
{
TERMINAL sg;
unsigned int prl;
/* Close out all files and local state before this target loses control. */
static void
-adapt_close (quitting)
- int quitting;
+adapt_close (int quitting)
{
/* Clear any break points */
/* Attach to the target that is already loaded and possibly running */
static void
-adapt_attach (args, from_tty)
- char *args;
- int from_tty;
+adapt_attach (char *args, int from_tty)
{
if (from_tty)
Use this when you want to detach and do something else
with your gdb. */
void
-adapt_detach (args, from_tty)
- char *args;
- int from_tty;
+adapt_detach (char *args, int from_tty)
{
if (adapt_stream)
/* Tell the remote machine to resume. */
void
-adapt_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+adapt_resume (int pid, int step, enum target_signal sig)
{
if (step)
{
storing status in STATUS just as `wait' would. */
int
-adapt_wait (status)
- struct target_waitstatus *status;
+adapt_wait (struct target_waitstatus *status)
{
/* Strings to look for. '?' means match any single character.
Note that with the algorithm we use, the initial character
Returns a pointer to a static buffer containing the answer. */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char buf[80];
if (regno >= GR96_REGNUM && regno < GR96_REGNUM + 32)
/* Read the remote registers. */
static void
-adapt_fetch_registers ()
+adapt_fetch_registers (void)
{
int reg_index;
int regnum_index;
/* Fetch register REGNO, or all registers if REGNO is -1.
*/
static void
-adapt_fetch_register (regno)
- int regno;
+adapt_fetch_register (int regno)
{
if (regno == -1)
adapt_fetch_registers ();
/* Store the remote registers from the contents of the block REGS. */
static void
-adapt_store_registers ()
+adapt_store_registers (void)
{
int i, j;
/* Store register REGNO, or all if REGNO == -1.
Return errno value. */
void
-adapt_store_register (regno)
- int regno;
+adapt_store_register (int regno)
{
/* printf("adapt_store_register() called.\n"); fflush(stdout); /* */
if (regno == -1)
debugged. */
void
-adapt_prepare_to_store ()
+adapt_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static CORE_ADDR
-translate_addr (addr)
- CORE_ADDR addr;
+translate_addr (CORE_ADDR addr)
{
#if defined(KERNEL_DEBUGGING)
/* Check for a virtual address in the kernel */
/* FIXME! Merge these two. */
int
-adapt_xfer_inferior_memory (memaddr, myaddr, len, write)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
+adapt_xfer_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len, int write)
{
memaddr = translate_addr (memaddr);
}
void
-adapt_files_info ()
+adapt_files_info (void)
{
printf_filtered ("\tAttached to %s at %d baud and running program %s\n",
dev_name, baudrate, prog_name);
* sb/sh instructions don't work on unaligned addresses, when TU=1.
*/
int
-adapt_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+adapt_write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
unsigned int cps;
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns errno value. */
int
-adapt_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+adapt_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
/* Clear the adapts notion of what the break points are */
static int
-adapt_clear_breakpoints ()
+adapt_clear_breakpoints (void)
{
if (adapt_stream)
{
num_brkpts = 0;
}
static void
-adapt_mourn ()
+adapt_mourn (void)
{
adapt_clear_breakpoints ();
pop_target (); /* Pop back to no-child state */
* specified string
*/
static int
-display_until (str)
- char *str;
+display_until (char *str)
{
int i = 0, j, c;
FIXME: Can't handle commands that take input. */
void
-adapt_com (args, fromtty)
- char *args;
- int fromtty;
+adapt_com (char *args, int fromtty)
{
if (!adapt_stream)
{
} /* init_adapt_ops */
void
-_initialize_remote_adapt ()
+_initialize_remote_adapt (void)
{
init_adapt_ops ();
add_target (&adapt_ops);
* timeout stuff.
*/
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
* it out. Let the user break out immediately.
*/
static void
-expect (string, discard)
- char *string;
- int discard;
+expect (char *string, int discard)
{
char *p = string;
int c;
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt (discard)
- int discard;
+expect_prompt (int discard)
{
expect (ARRAY_PROMPT, discard);
}
* junk -- ignore junk characters. Returns a 1 if junk, 0 otherwise
*/
static int
-junk (ch)
- char ch;
+junk (char ch)
{
switch (ch)
{
* If ignore is nonzero, ignore spaces, newline & tabs.
*/
static int
-get_hex_digit (ignore)
- int ignore;
+get_hex_digit (int ignore)
{
static int ch;
while (1)
* Accept any number leading spaces.
*/
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
* and put them in registers starting at REGNO.
*/
static int
-get_hex_word ()
+get_hex_word (void)
{
long val, newval;
int i;
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-array_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+array_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
static char dev_name[100];
static void
-array_open (args, name, from_tty)
- char *args;
- char *name;
- int from_tty;
+array_open (char *args, char *name, int from_tty)
{
char packet[PBUFSIZ];
*/
static void
-array_close (quitting)
- int quitting;
+array_close (int quitting)
{
SERIAL_CLOSE (array_desc);
array_desc = NULL;
* else with your gdb.
*/
static void
-array_detach (from_tty)
- int from_tty;
+array_detach (int from_tty)
{
debuglogs (1, "array_detach ()");
* array_attach -- attach GDB to the target.
*/
static void
-array_attach (args, from_tty)
- char *args;
- int from_tty;
+array_attach (char *args, int from_tty)
{
if (from_tty)
printf ("Starting remote %s debugging\n", target_shortname);
* array_resume -- Tell the remote machine to resume.
*/
static void
-array_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+array_resume (int pid, int step, enum target_signal sig)
{
debuglogs (1, "array_resume (step=%d, sig=%d)", step, sig);
* storing status in status just as `wait' would.
*/
static int
-array_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+array_wait (int pid, struct target_waitstatus *status)
{
int old_timeout = timeout;
int result, i;
* block regs.
*/
static void
-array_fetch_registers (ignored)
- int ignored;
+array_fetch_registers (int ignored)
{
int regno, i;
char *p;
* protocol based on GDB's remote protocol.
*/
static void
-array_fetch_register (ignored)
- int ignored;
+array_fetch_register (int ignored)
{
array_fetch_registers ();
}
* Get all the registers from the targets. They come back in a large array.
*/
static void
-array_store_registers (ignored)
- int ignored;
+array_store_registers (int ignored)
{
int regno;
unsigned long i;
* protocol based on GDB's remote protocol.
*/
static void
-array_store_register (ignored)
- int ignored;
+array_store_register (int ignored)
{
array_store_registers ();
}
debugged. */
static void
-array_prepare_to_store ()
+array_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-array_files_info ()
+array_files_info (void)
{
printf ("\tAttached to %s at %d baud.\n",
dev_name, baudrate);
* memory at MYADDR to inferior's memory at MEMADDR. Returns length moved.
*/
static int
-array_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+array_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
unsigned long i;
int j;
* length moved.
*/
static int
-array_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+array_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int j;
char buf[20];
}
static void
-array_kill (args, from_tty)
- char *args;
- int from_tty;
+array_kill (char *args, int from_tty)
{
return; /* ignore attempts to kill target system */
}
instructions. */
static void
-array_mourn_inferior ()
+array_mourn_inferior (void)
{
remove_breakpoints ();
generic_mourn_inferior (); /* Do all the proper things now */
* array_insert_breakpoint -- add a breakpoint
*/
static int
-array_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+array_insert_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
int bp_size = 0;
* _remove_breakpoint -- Tell the monitor to remove a breakpoint
*/
static int
-array_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+array_remove_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
}
static void
-array_stop ()
+array_stop (void)
{
debuglogs (1, "array_stop()");
printf_monitor ("\003");
* expect_prompt is seen. FIXME
*/
static void
-monitor_command (args, fromtty)
- char *args;
- int fromtty;
+monitor_command (char *args, int fromtty)
{
debuglogs (1, "monitor_command (args=%s)", args);
*
*/
static void
-make_gdb_packet (buf, data)
- char *buf, *data;
+make_gdb_packet (char *buf, char *data)
{
int i;
unsigned char csum = 0;
* successful transmition, or a 0 for a failure.
*/
static int
-array_send_packet (packet)
- char *packet;
+array_send_packet (char *packet)
{
int c, retries, i;
char junk[PBUFSIZ];
* packet, or a 0 it the packet wasn't transmitted correctly.
*/
static int
-array_get_packet (packet)
- char *packet;
+array_get_packet (char *packet)
{
int c;
int retries;
* ascii2hexword -- convert an ascii number represented by 8 digits to a hex value.
*/
static unsigned long
-ascii2hexword (mem)
- unsigned char *mem;
+ascii2hexword (unsigned char *mem)
{
unsigned long val;
int i;
* digits.
*/
static void
-hexword2ascii (mem, num)
- unsigned char *mem;
- unsigned long num;
+hexword2ascii (unsigned char *mem, unsigned long num)
{
int i;
unsigned char ch;
/* Convert hex digit A to a number. */
static int
-from_hex (a)
- int a;
+from_hex (int a)
{
if (a == 0)
return 0;
/* Convert number NIB to a hex digit. */
static int
-tohex (nib)
- int nib;
+tohex (int nib)
{
if (nib < 10)
return '0' + nib;
* are usually only used by monitors.
*/
void
-_initialize_remote_monitors ()
+_initialize_remote_monitors (void)
{
/* generic monitor command */
add_com ("monitor", class_obscure, monitor_command,
* _initialize_array -- do any special init stuff for the target.
*/
void
-_initialize_array ()
+_initialize_array (void)
{
init_array_ops ();
add_target (&array_ops);
*/
static void
-bug_load (args, fromtty)
- char *args;
- int fromtty;
+bug_load (char *args, int fromtty)
{
bfd *abfd;
asection *s;
#if 0
static char *
-get_word (p)
- char **p;
+get_word (char **p)
{
char *s = *p;
char *word;
};
static void
-bug_open (args, from_tty)
- char *args;
- int from_tty;
+bug_open (char *args, int from_tty)
{
if (args == NULL)
args = "";
/* Tell the remote machine to resume. */
void
-bug_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+bug_resume (int pid, int step, enum target_signal sig)
{
dcache_flush (gr_get_dcache ());
};
int
-bug_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+bug_wait (int pid, struct target_waitstatus *status)
{
int old_timeout = sr_get_timeout ();
int old_immediate_quit = immediate_quit;
Returns a pointer to a static buffer containing the answer. */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char *rn[] =
{
success, -1 on failure. */
static int
-bug_scan (s)
- char *s;
+bug_scan (char *s)
{
int c;
#endif /* never */
static int
-bug_srec_write_cr (s)
- char *s;
+bug_srec_write_cr (char *s)
{
char *p = s;
/* Store register REGNO, or all if REGNO == -1. */
static void
-bug_fetch_register (regno)
- int regno;
+bug_fetch_register (int regno)
{
sr_check_open ();
/* Store register REGNO, or all if REGNO == -1. */
static void
-bug_store_register (regno)
- int regno;
+bug_store_register (int regno)
{
char buffer[1024];
sr_check_open ();
}
static void
-start_load ()
+start_load (void)
{
char *command;
};
static int
-bug_write_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+bug_write_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int done;
int checksum;
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns errno value. */
static int
-bug_read_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+bug_read_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
char request[100];
char *buffer;
/* Clear the bugs notion of what the break points are */
static int
-bug_clear_breakpoints ()
+bug_clear_breakpoints (void)
{
if (sr_is_open ())
} /* init_bug_ops */
void
-_initialize_remote_bug ()
+_initialize_remote_bug (void)
{
init_bug_ops ();
add_target (&bug_ops);
/* Send data to e7000debug. */
static void
-puts_e7000debug (buf)
- char *buf;
+puts_e7000debug (char *buf)
{
if (!e7000_desc)
error ("Use \"target e7000 ...\" first.");
}
static void
-putchar_e7000 (x)
- int x;
+putchar_e7000 (int x)
{
char b[1];
}
static void
-write_e7000 (s)
- char *s;
+write_e7000 (char *s)
{
SERIAL_WRITE (e7000_desc, s, strlen (s));
}
static int
-normal (x)
- int x;
+normal (int x)
{
if (x == '\n')
return '\r';
returns -1, else returns next char. Discards chars > 127. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
#if 0
char *
-tl (x)
+tl (int x)
{
static char b[8][10];
static int p;
out. Let the user break out immediately. */
static void
-expect (string)
- char *string;
+expect (char *string)
{
char *p = string;
int c;
into states from which we can't recover. */
static void
-expect_prompt ()
+expect_prompt (void)
{
expect (":");
}
static void
-expect_full_prompt ()
+expect_full_prompt (void)
{
expect ("\r:");
}
static int
-convert_hex_digit (ch)
- int ch;
+convert_hex_digit (int ch)
{
if (ch >= '0' && ch <= '9')
return ch - '0';
}
static int
-get_hex (start)
- int *start;
+get_hex (int *start)
{
int value = convert_hex_digit (*start);
int try;
them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
int i;
user types "run" after having attached. */
static void
-e7000_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+e7000_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
/* Grab the next token and buy some space for it */
static char *
-next (ptr)
- char **ptr;
+next (char **ptr)
{
char *p = *ptr;
char *s;
}
static void
-e7000_login_command (args, from_tty)
- char *args;
- int from_tty;
+e7000_login_command (char *args, int from_tty)
{
if (args)
{
/* Start an ftp transfer from the E7000 to a host */
static void
-e7000_ftp_command (args, from_tty)
- char *args;
- int from_tty;
+e7000_ftp_command (char *args, int from_tty)
{
/* FIXME: arbitrary limit on machine names and such. */
char buf[200];
}
static int
-e7000_parse_device (args, dev_name, baudrate)
- char *args;
- char *dev_name;
- int baudrate;
+e7000_parse_device (char *args, char *dev_name, int baudrate)
{
char junk[128];
int n = 0;
/* Stub for catch_errors. */
static int
-e7000_start_remote (dummy)
- char *dummy;
+e7000_start_remote (char *dummy)
{
int loop;
int sync;
}
static void
-e7000_open (args, from_tty)
- char *args;
- int from_tty;
+e7000_open (char *args, int from_tty)
{
int n;
/* Close out all files and local state before this target loses control. */
static void
-e7000_close (quitting)
- int quitting;
+e7000_close (int quitting)
{
if (e7000_desc)
{
when you want to detach and do something else with your gdb. */
static void
-e7000_detach (from_tty)
- int from_tty;
+e7000_detach (int from_tty)
{
pop_target (); /* calls e7000_close to do the real work */
if (from_tty)
/* Tell the remote machine to resume. */
static void
-e7000_resume (pid, step, sig)
- int pid, step, sig;
+e7000_resume (int pid, int step, int sig)
{
if (step)
puts_e7000debug ("S\r");
R4_BANK1-R7_BANK1 %37 %38 %39 %40";
static int
-gch ()
+gch (void)
{
return readchar (timeout);
}
static unsigned int
-gbyte ()
+gbyte (void)
{
int high = convert_hex_digit (gch ());
int low = convert_hex_digit (gch ());
}
static void
-e7000_fetch_registers ()
+e7000_fetch_registers (void)
{
int regno;
char *wanted;
errno value. */
static void
-e7000_fetch_register (regno)
- int regno;
+e7000_fetch_register (int regno)
{
e7000_fetch_registers ();
}
/* Store the remote registers from the contents of the block REGS. */
static void
-e7000_store_registers ()
+e7000_store_registers (void)
{
int regno;
/* Store register REGNO, or all if REGNO == 0. Return errno value. */
static void
-e7000_store_register (regno)
- int regno;
+e7000_store_register (int regno)
{
char buf[200];
debugged. */
static void
-e7000_prepare_to_store ()
+e7000_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-e7000_files_info ()
+e7000_files_info (void)
{
printf_unfiltered ("\tAttached to %s at %d baud.\n", dev_name, baudrate);
}
static int
-stickbyte (where, what)
- char *where;
- unsigned int what;
+stickbyte (char *where, unsigned int what)
{
static CONST char digs[] = "0123456789ABCDEF";
/* Write a small ammount of memory. */
static int
-write_small (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+write_small (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int i;
char buf[200];
*/
static int
-write_large (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+write_large (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int i;
#define maxstride 128
then. */
static int
-e7000_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+e7000_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
if (len < 16 || using_tcp || using_pc)
return write_small (memaddr, myaddr, len);
*/
static int
-e7000_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+e7000_read_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int count;
int c;
*/
static int
-e7000_read_inferior_memory_large (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+e7000_read_inferior_memory_large (CORE_ADDR memaddr, unsigned char *myaddr,
+ int len)
{
int count;
int c;
#if 0
static int
-fast_but_for_the_pause_e7000_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+fast_but_for_the_pause_e7000_read_inferior_memory (CORE_ADDR memaddr,
+ char *myaddr, int len)
{
int loop;
int c;
}
static void
-e7000_kill (args, from_tty)
- char *args;
- int from_tty;
+e7000_kill (char *args, int from_tty)
{
}
static void
-e7000_load (args, from_tty)
- char *args;
- int from_tty;
+e7000_load (char *args, int from_tty)
{
struct cleanup *old_chain;
asection *section;
instructions. */
static void
-e7000_mourn_inferior ()
+e7000_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&e7000_ops);
{0};
static int
-e7000_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- unsigned char *shadow;
+e7000_insert_breakpoint (CORE_ADDR addr, unsigned char *shadow)
{
int i;
char buf[200];
}
static int
-e7000_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- unsigned char *shadow;
+e7000_remove_breakpoint (CORE_ADDR addr, unsigned char *shadow)
{
int i;
char buf[200];
is placed on the users terminal until the prompt is seen. */
static void
-e7000_command (args, fromtty)
- char *args;
- int fromtty;
+e7000_command (char *args, int fromtty)
{
/* FIXME: arbitrary limit on length of args. */
char buf[200];
static void
-e7000_drain_command (args, fromtty)
- char *args;
- int fromtty;
-
+e7000_drain_command (char *args, int fromtty)
{
int c;
#define NITEMS 7
static int
-why_stop ()
+why_stop (void)
{
static char *strings[NITEMS] =
{
otherwise echo them. */
int
-expect_n (strings)
- char **strings;
+expect_n (char **strings)
{
char *(ptr[10]);
int n;
pc, and the simulators never do. */
static void
-sub2_from_pc ()
+sub2_from_pc (void)
{
char buf[4];
char buf2[200];
STATUS just as `wait' would. */
static int
-e7000_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+e7000_wait (int pid, struct target_waitstatus *status)
{
int stop_reason;
int regno;
/* Stop the running program. */
static void
-e7000_stop ()
+e7000_stop (void)
{
/* Sending a ^C is supposed to stop the running program. */
putchar_e7000 (CTRLC);
};
void
-_initialize_remote_e7000 ()
+_initialize_remote_e7000 (void)
{
init_e7000_ops ();
add_target (&e7000_ops);
/* Read a character from the remote system, doing all the fancy
timeout stuff. */
static int
-readchar ()
+readchar (void)
{
char buf;
/* Keep discarding input from the remote system, until STRING is found.
Let the user break out immediately. */
static void
-expect (string)
- char *string;
+expect (char *string)
{
char *p = string;
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt ()
+expect_prompt (void)
{
#if defined (LOG_FILE)
/* This is a convenient place to do this. The idea is to do it often
/* Get a hex digit from the remote system & return its value.
If ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
static int
-get_hex_digit (ignore_space)
- int ignore_space;
+get_hex_digit (int ignore_space)
{
int ch;
while (1)
/* Get a byte from eb_desc and put it in *BYT. Accept any number
leading spaces. */
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
/* Get N 32-bit words from remote, each preceded by a space,
and put them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
int i;
volatile int n_alarms;
void
-eb_timer ()
+eb_timer (void)
{
#if 0
if (kiodebug)
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-eb_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+eb_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
};
int
-damn_b (rate)
- int rate;
+damn_b (int rate)
{
int i;
static int baudrate = 9600;
static char *dev_name;
void
-eb_open (name, from_tty)
- char *name;
- int from_tty;
+eb_open (char *name, int from_tty)
{
TERMINAL sg;
/* Close out all files and local state before this target loses control. */
static void
-eb_close (quitting)
- int quitting;
+eb_close (int quitting)
{
/* Due to a bug in Unix, fclose closes not only the stdio stream,
Use this when you want to detach and do something else
with your gdb. */
void
-eb_detach (from_tty)
- int from_tty;
+eb_detach (int from_tty)
{
pop_target (); /* calls eb_close to do the real work */
if (from_tty)
/* Tell the remote machine to resume. */
void
-eb_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+eb_resume (int pid, int step, enum target_signal sig)
{
if (step)
{
storing status in STATUS just as `wait' would. */
int
-eb_wait (status)
- struct target_waitstatus *status;
+eb_wait (struct target_waitstatus *status)
{
/* Strings to look for. '?' means match any single character.
Note that with the algorithm we use, the initial character
Returns a pointer to a static buffer containing the answer. */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char buf[80];
if (regno >= GR96_REGNUM && regno < GR96_REGNUM + 32)
/* Read the remote registers into the block REGS. */
static void
-eb_fetch_registers ()
+eb_fetch_registers (void)
{
int reg_index;
int regnum_index;
/* Fetch register REGNO, or all registers if REGNO is -1.
Returns errno value. */
void
-eb_fetch_register (regno)
- int regno;
+eb_fetch_register (int regno)
{
if (regno == -1)
eb_fetch_registers ();
/* Store the remote registers from the contents of the block REGS. */
static void
-eb_store_registers ()
+eb_store_registers (void)
{
int i, j;
fprintf (eb_stream, "s gr1,%x\n", read_register (GR1_REGNUM));
/* Store register REGNO, or all if REGNO == 0.
Return errno value. */
void
-eb_store_register (regno)
- int regno;
+eb_store_register (int regno)
{
if (regno == -1)
eb_store_registers ();
debugged. */
void
-eb_prepare_to_store ()
+eb_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
}
void
-eb_files_info ()
+eb_files_info (void)
{
printf ("\tAttached to %s at %d baud and running program %s.\n",
dev_name, baudrate, prog_name);
/* Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns length moved. */
int
-eb_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+eb_write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns length moved. */
int
-eb_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+eb_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
}
static void
-eb_kill (args, from_tty)
- char *args;
- int from_tty;
+eb_kill (char *args, int from_tty)
{
return; /* Ignore attempts to kill target system */
}
instructions. */
void
-eb_mourn_inferior ()
+eb_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&eb_ops);
};
void
-_initialize_remote_eb ()
+_initialize_remote_eb (void)
{
init_eb_ops ();
add_target (&eb_ops);
Rely on global variables: old_sigint(), interrupt */
static void
-es1800_request_quit ()
+es1800_request_quit (void)
{
/* restore original signalhandler */
signal (SIGINT, old_sigint);
quit - return to '(esgdb)' prompt or continue */
static void
-es1800_reset (quit)
- char *quit;
+es1800_reset (char *quit)
{
char buf[80];
from_tty - says whether to be verbose or not */
static void
-es1800_open (name, from_tty)
- char *name;
- int from_tty;
+es1800_open (char *name, int from_tty)
{
char buf[PBUFSIZ];
char *p;
quitting - are we quitting gdb now? */
static void
-es1800_close (quitting)
- int quitting;
+es1800_close (int quitting)
{
if (es1800_desc != NULL)
{
from_tty - says whether to be verbose or not */
static void
-es1800_attach (args, from_tty)
- char *args;
- int from_tty;
+es1800_attach (char *args, int from_tty)
{
error ("Cannot attach to pid %s, this feature is not implemented yet.",
args);
from_tty - says whether to be verbose or not */
static void
-es1800_detach (args, from_tty)
- char *args;
- int from_tty;
+es1800_detach (char *args, int from_tty)
{
if (args)
{
siggnal - the signal value to be given to the target (0 = no signal) */
static void
-es1800_resume (pid, step, siggnal)
- int pid;
- int step;
- enum target_signal siggnal;
+es1800_resume (int pid, int step, enum target_signal siggnal)
{
char buf[PBUFSIZ];
status - */
static int
-es1800_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+es1800_wait (int pid, struct target_waitstatus *status)
{
unsigned char buf[PBUFSIZ];
int old_timeout = timeout;
regno - the register to be fetched (fetch all registers if -1) */
static void
-es1800_fetch_register (regno)
- int regno;
+es1800_fetch_register (int regno)
{
char buf[PBUFSIZ];
int k;
Always fetches all registers. */
static void
-es1800_fetch_registers ()
+es1800_fetch_registers (void)
{
char buf[PBUFSIZ];
char SR_buf[PBUFSIZ];
FIXME: Return errno value. */
static void
-es1800_store_register (regno)
- int regno;
+es1800_store_register (int regno)
{
static char regtab[18][4] =
/* Prepare to store registers. */
static void
-es1800_prepare_to_store ()
+es1800_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
/* Convert hex digit A to a number. */
static int
-fromhex (a)
- int a;
+fromhex (int a)
{
if (a >= '0' && a <= '9')
{
/* Convert number NIB to a hex digit. */
static int
-tohex (nib)
- int nib;
+tohex (int nib)
{
if (nib < 10)
{
len - number of bytes */
static void
-es1800_write_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+es1800_write_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
char buf[PBUFSIZ];
int i;
len - number of bytes */
static void
-es1800_read_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+es1800_read_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
static int DB_tab[16] =
{8, 11, 14, 17, 20, 23, 26, 29, 34, 37, 40, 43, 46, 49, 52, 55};
the target_arch transfer vector, if we ever have one... */
static int
-es1800_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+es1800_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int val;
BREAKPOINT bytes. */
static int
-es1800_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+es1800_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
return (target_write_memory (addr, contents_cache,
Primitive datastructures containing the es1800 breakpoint instruction */
static void
-es1800_create_break_insn (ins, vec)
- char *ins;
- int vec;
+es1800_create_break_insn (char *ins, int vec)
{
if (vec == 15)
{
vec - trap vector used for breakpoints */
static int
-verify_break (vec)
- int vec;
+verify_break (int vec)
{
CORE_ADDR memaddress;
char buf[8];
addrp - store the address here */
static void
-get_break_addr (vec, addrp)
- int vec;
- CORE_ADDR *addrp;
+get_break_addr (int vec, CORE_ADDR *addrp)
{
CORE_ADDR memaddress = 0;
int status;
/* Kill an inferior process */
static void
-es1800_kill ()
+es1800_kill (void)
{
if (inferior_pid != 0)
{
FIXME Uses emulator overlay memory for trap routine */
static void
-es1800_load (filename, from_tty)
- char *filename;
- int from_tty;
+es1800_load (char *filename, int from_tty)
{
FILE *instream;
#define NUMCPYBYTES 20
static void
-bfd_copy (from_bfd, to_bfd)
- bfd *from_bfd;
- bfd *to_bfd;
+bfd_copy (bfd *from_bfd, bfd *to_bfd)
{
asection *p, *new;
int i;
env - the environment vector to pass */
static void
-es1800_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+es1800_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
int pid;
/* The process has died, clean up. */
static void
-es1800_mourn_inferior ()
+es1800_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&es1800_child_ops);
read until string is found (== 0) */
static void
-expect (string, nowait)
- char *string;
- int nowait;
+expect (char *string, int nowait)
{
char c;
char *p = string;
/* Keep discarding input until we see the prompt. */
static void
-expect_prompt ()
+expect_prompt (void)
{
expect (">", 0);
}
/* read from stdin */
static int
-readchar ()
+readchar (void)
{
char buf[1];
timeout stuff. */
static int
-readchar ()
+readchar (void)
{
int ch;
len - size of buf */
static void
-send_with_reply (string, buf, len)
- char *string, *buf;
- int len;
+send_with_reply (char *string, char *buf, int len)
{
send (string);
SERIAL_WRITE (es1800_desc, "\r", 1);
string - the es1800 command */
static void
-send_command (string)
- char *string;
+send_command (char *string)
{
send (string);
SERIAL_WRITE (es1800_desc, "\r", 1);
string - the es1800 command */
static void
-send (string)
- char *string;
+send (char *string)
{
if (kiodebug)
{
len - size of buf */
static void
-getmessage (buf, len)
- char *buf;
- int len;
+getmessage (char *buf, int len)
{
char *bp;
int c;
}
static void
-download (instream, from_tty, format)
- FILE *instream;
- int from_tty;
- int format;
+download (FILE *instream, int from_tty, int format)
{
char c;
char buf[160];
/*ARGSUSED */
static void
-es1800_transparent (args, from_tty)
- char *args;
- int from_tty;
+es1800_transparent (char *args, int from_tty)
{
int console;
struct sgttyb modebl;
#endif /* PROVIDE_TRANSPARENT */
static void
-es1800_init_break (args, from_tty)
- char *args;
- int from_tty;
+es1800_init_break (char *args, int from_tty)
{
CORE_ADDR memaddress = 0;
char buf[PBUFSIZ];
}
static void
-es1800_child_open (arg, from_tty)
- char *arg;
- int from_tty;
+es1800_child_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a child process.");
}
static void
-es1800_child_detach (args, from_tty)
- char *args;
- int from_tty;
+es1800_child_detach (char *args, int from_tty)
{
if (args)
{
}
void
-_initialize_es1800 ()
+_initialize_es1800 (void)
{
init_es1800_ops ();
init_es1800_child_ops ();
static void est_open (char *args, int from_tty);
static void
-est_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+est_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
} /* init_est_cmds */
static void
-est_open (args, from_tty)
- char *args;
- int from_tty;
+est_open (char *args, int from_tty)
{
monitor_open (args, &est_cmds, from_tty);
}
void
-_initialize_est ()
+_initialize_est (void)
{
init_est_cmds ();
init_monitor_ops (&est_ops);
static void hms_open (char *args, int from_tty);
static void
-hms_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+hms_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int regno;
} /* init_hms-cmds */
static void
-hms_open (args, from_tty)
- char *args;
- int from_tty;
+hms_open (char *args, int from_tty)
{
monitor_open (args, &hms_cmds, from_tty);
}
int write_dos_tick_delay;
void
-_initialize_remote_hms ()
+_initialize_remote_hms (void)
{
init_hms_cmds ();
init_monitor_ops (&hms_ops);
static void
-close_ports ()
+close_ports (void)
{
mips_is_open = 0;
SERIAL_CLOSE (mips_desc);
^x notation or in hex. */
static void
-fputc_readable (ch, file)
- int ch;
- struct ui_file *file;
+fputc_readable (int ch, struct ui_file *file)
{
if (ch == '\n')
fputc_unfiltered ('\n', file);
^x notation or in hex. */
static void
-fputs_readable (string, file)
- char *string;
- struct ui_file *file;
+fputs_readable (char *string, struct ui_file *file)
{
int c;
*/
int
-mips_expect_timeout (string, timeout)
- char *string;
- int timeout;
+mips_expect_timeout (char *string, int timeout)
{
char *p = string;
*/
int
-mips_expect (string)
- char *string;
+mips_expect (char *string)
{
return mips_expect_timeout (string, 2);
}
/* Read the required number of characters into the given buffer (which
is assumed to be large enough). The only failure is a timeout. */
int
-mips_getstring (string, n)
- char *string;
- int n;
+mips_getstring (char *string, int n)
{
char *p = string;
int c;
port. */
static int
-mips_readchar (timeout)
- int timeout;
+mips_readchar (int timeout)
{
int ch;
static int state = 0;
or -1 for timeout. */
static int
-mips_receive_header (hdr, pgarbage, ch, timeout)
- unsigned char *hdr;
- int *pgarbage;
- int ch;
- int timeout;
+mips_receive_header (unsigned char *hdr, int *pgarbage, int ch, int timeout)
{
int i;
for success, -1 for timeout, -2 for error. */
static int
-mips_receive_trailer (trlr, pgarbage, pch, timeout)
- unsigned char *trlr;
- int *pgarbage;
- int *pch;
- int timeout;
+mips_receive_trailer (unsigned char *trlr, int *pgarbage, int *pch, int timeout)
{
int i;
int ch;
DATA points to the packet data. LEN is the length of DATA. */
static int
-mips_cksum (hdr, data, len)
- const unsigned char *hdr;
- const unsigned char *data;
- int len;
+mips_cksum (const unsigned char *hdr, const unsigned char *data, int len)
{
register const unsigned char *p;
register int c;
/* Send a packet containing the given ASCII string. */
static void
-mips_send_packet (s, get_ack)
- const char *s;
- int get_ack;
+mips_send_packet (const char *s, int get_ack)
{
/* unsigned */ int len;
unsigned char *packet;
don't print an error message and return -1. */
static int
-mips_receive_packet (buff, throw_error, timeout)
- char *buff;
- int throw_error;
- int timeout;
+mips_receive_packet (char *buff, int throw_error, int timeout)
{
int ch;
int garbage;
}
static void
-mips_initialize_cleanups (arg)
- PTR arg;
+mips_initialize_cleanups (PTR arg)
{
mips_initializing = 0;
}
static void
-mips_exit_cleanups (arg)
- PTR arg;
+mips_exit_cleanups (PTR arg)
{
mips_exiting = 0;
}
static void
-mips_send_command (cmd, prompt)
- const char *cmd;
- int prompt;
+mips_send_command (const char *cmd, int prompt)
{
SERIAL_WRITE (mips_desc, cmd, strlen (cmd));
mips_expect (cmd);
/* Enter remote (dbx) debug mode: */
static void
-mips_enter_debug ()
+mips_enter_debug (void)
{
/* Reset the sequence numbers, ready for the new debug sequence: */
mips_send_seq = 0;
/* Exit remote (dbx) debug mode, returning to the monitor prompt: */
static int
-mips_exit_debug ()
+mips_exit_debug (void)
{
int err;
struct cleanup *old_cleanups = make_cleanup (mips_exit_cleanups, NULL);
really connected. */
static void
-mips_initialize ()
+mips_initialize (void)
{
int err;
struct cleanup *old_cleanups = make_cleanup (mips_initialize_cleanups, NULL);
/* Open a connection to the remote board. */
static void
-common_open (ops, name, from_tty, new_monitor, new_monitor_prompt)
- struct target_ops *ops;
- char *name;
- int from_tty;
- enum mips_monitor_type new_monitor;
- char *new_monitor_prompt;
+common_open (struct target_ops *ops, char *name, int from_tty,
+ enum mips_monitor_type new_monitor, char *new_monitor_prompt)
{
char *ptype;
char *serial_port_name;
}
static void
-mips_open (name, from_tty)
- char *name;
- int from_tty;
+mips_open (char *name, int from_tty)
{
const char *monitor_prompt = NULL;
if (TARGET_ARCHITECTURE != NULL
}
static void
-pmon_open (name, from_tty)
- char *name;
- int from_tty;
+pmon_open (char *name, int from_tty)
{
common_open (&pmon_ops, name, from_tty, MON_PMON, "PMON> ");
}
static void
-ddb_open (name, from_tty)
- char *name;
- int from_tty;
+ddb_open (char *name, int from_tty)
{
common_open (&ddb_ops, name, from_tty, MON_DDB, "NEC010>");
}
static void
-lsi_open (name, from_tty)
- char *name;
- int from_tty;
+lsi_open (char *name, int from_tty)
{
int i;
/* Close a connection to the remote board. */
static void
-mips_close (quitting)
- int quitting;
+mips_close (int quitting)
{
if (mips_is_open)
{
/* Detach from the remote board. */
static void
-mips_detach (args, from_tty)
- char *args;
- int from_tty;
+mips_detach (char *args, int from_tty)
{
if (args)
error ("Argument given to \"detach\" when remotely debugging.");
where PMON does return a reply. */
static void
-mips_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+mips_resume (int pid, int step, enum target_signal siggnal)
{
int err;
/* Return the signal corresponding to SIG, where SIG is the number which
the MIPS protocol uses for the signal. */
enum target_signal
-mips_signal_from_protocol (sig)
- int sig;
+mips_signal_from_protocol (int sig)
{
/* We allow a few more signals than the IDT board actually returns, on
the theory that there is at least *some* hope that perhaps the numbering
/* Wait until the remote stops, and return a wait status. */
static int
-mips_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+mips_wait (int pid, struct target_waitstatus *status)
{
int rstatus;
int err;
#define REGNO_OFFSET 96
static int
-mips_map_regno (regno)
- int regno;
+mips_map_regno (int regno)
{
if (regno < 32)
return regno;
/* Fetch the remote registers. */
static void
-mips_fetch_registers (regno)
- int regno;
+mips_fetch_registers (int regno)
{
unsigned LONGEST val;
int err;
registers, so this function doesn't have to do anything. */
static void
-mips_prepare_to_store ()
+mips_prepare_to_store (void)
{
}
/* Store remote register(s). */
static void
-mips_store_registers (regno)
- int regno;
+mips_store_registers (int regno)
{
int err;
/* Fetch a word from the target board. */
static unsigned int
-mips_fetch_word (addr)
- CORE_ADDR addr;
+mips_fetch_word (CORE_ADDR addr)
{
unsigned int val;
int err;
/* FIXME! make sure only 32-bit quantities get stored! */
static int
-mips_store_word (addr, val, old_contents)
- CORE_ADDR addr;
- unsigned int val;
- char *old_contents;
+mips_store_word (CORE_ADDR addr, unsigned int val, char *old_contents)
{
int err;
unsigned int oldcontents;
static int mask_address_p = 1;
static int
-mips_xfer_memory (memaddr, myaddr, len, write, ignore)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
- struct target_ops *ignore;
+mips_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int write,
+ struct target_ops *ignore)
{
int i;
CORE_ADDR addr;
/* Print info on this target. */
static void
-mips_files_info (ignore)
- struct target_ops *ignore;
+mips_files_info (struct target_ops *ignore)
{
printf_unfiltered ("Debugging a MIPS board over a serial line.\n");
}
right port, we could interrupt the process with a break signal. */
static void
-mips_kill ()
+mips_kill (void)
{
if (!mips_wait_flag)
return;
/* Start running on the target board. */
static void
-mips_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+mips_create_inferior (char *execfile, char *args, char **env)
{
CORE_ADDR entry_pt;
/* Clean up after a process. Actually nothing to do. */
static void
-mips_mourn_inferior ()
+mips_mourn_inferior (void)
{
if (current_ops != NULL)
unpush_target (current_ops);
is accomplished via BREAKPOINT_MAX). */
static int
-mips_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+mips_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (monitor_supports_breakpoints)
return set_breakpoint (addr, MIPS_INSTLEN, BREAK_FETCH);
}
static int
-mips_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+mips_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (monitor_supports_breakpoints)
return clear_breakpoint (addr, MIPS_INSTLEN, BREAK_FETCH);
/* NOTE: The code relies on this vector being zero-initialised by the system */
static int
-pmon_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+pmon_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int status;
}
static int
-pmon_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+pmon_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (monitor_supports_breakpoints)
{
implements the TARGET_CAN_USE_HARDWARE_WATCHPOINT macro. */
int
-remote_mips_can_use_hardware_watchpoint (cnt)
- int cnt;
+remote_mips_can_use_hardware_watchpoint (int cnt)
{
return cnt < MAX_LSI_BREAKPOINTS && strcmp (target_shortname, "lsi") == 0;
}
This is used for memory ref breakpoints. */
static unsigned long
-calculate_mask (addr, len)
- CORE_ADDR addr;
- int len;
+calculate_mask (CORE_ADDR addr, int len)
{
unsigned long mask;
int i;
implement ordinary breakpoints using hardware facilities. */
int
-remote_mips_insert_hw_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+remote_mips_insert_hw_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (strcmp (target_shortname, "lsi") == 0)
return mips_insert_breakpoint (addr, contents_cache);
implement ordinary breakpoints using hardware facilities. */
int
-remote_mips_remove_hw_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+remote_mips_remove_hw_breakpoint (CORE_ADDR addr, char *contents_cache)
{
if (strcmp (target_shortname, "lsi") == 0)
return mips_remove_breakpoint (addr, contents_cache);
watchpoint. */
int
-remote_mips_set_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+remote_mips_set_watchpoint (CORE_ADDR addr, int len, int type)
{
if (set_breakpoint (addr, len, type))
return -1;
}
int
-remote_mips_remove_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+remote_mips_remove_watchpoint (CORE_ADDR addr, int len, int type)
{
if (clear_breakpoint (addr, len, type))
return -1;
/* Insert a breakpoint. */
static int
-set_breakpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- enum break_type type;
+set_breakpoint (CORE_ADDR addr, int len, enum break_type type)
{
return common_breakpoint (1, addr, len, type);
}
/* Clear a breakpoint. */
static int
-clear_breakpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- enum break_type type;
+clear_breakpoint (CORE_ADDR addr, int len, enum break_type type)
{
return common_breakpoint (0, addr, len, type);
}
This is a helper function for common_breakpoint. */
static int
-check_lsi_error (addr, rerrflg)
- CORE_ADDR addr;
- int rerrflg;
+check_lsi_error (CORE_ADDR addr, int rerrflg)
{
struct lsi_error *err;
char *saddr = paddr_nz (addr); /* printable address string */
Return 0 if successful; otherwise 1. */
static int
-common_breakpoint (set, addr, len, type)
- int set;
- CORE_ADDR addr;
- int len;
- enum break_type type;
+common_breakpoint (int set, CORE_ADDR addr, int len, enum break_type type)
{
char buf[DATA_MAXLEN + 1];
char cmd, rcmd;
}
\f
static void
-send_srec (srec, len, addr)
- char *srec;
- int len;
- CORE_ADDR addr;
+send_srec (char *srec, int len, CORE_ADDR addr)
{
while (1)
{
/* Download a binary file by converting it to S records. */
static void
-mips_load_srec (args)
- char *args;
+mips_load_srec (char *args)
{
bfd *abfd;
asection *s;
*/
static int
-mips_make_srec (buf, type, memaddr, myaddr, len)
- char *buf;
- int type;
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+mips_make_srec (char *buf, int type, CORE_ADDR memaddr, unsigned char *myaddr,
+ int len)
{
unsigned char checksum;
int i;
pointer non-NULL). The function returns the number of encoded
characters written into the buffer. */
static int
-pmon_makeb64 (v, p, n, chksum)
- unsigned long v;
- char *p;
- int n;
- int *chksum;
+pmon_makeb64 (unsigned long v, char *p, int n, int *chksum)
{
int count = (n / 6);
/* Shorthand function (that could be in-lined) to output the zero-fill
escape sequence into the data stream. */
static int
-pmon_zeroset (recsize, buff, amount, chksum)
- int recsize;
- char **buff;
- int *amount;
- unsigned int *chksum;
+pmon_zeroset (int recsize, char **buff, int *amount, unsigned int *chksum)
{
int count;
}
static int
-pmon_checkset (recsize, buff, value)
- int recsize;
- char **buff;
- int *value;
+pmon_checkset (int recsize, char **buff, int *value)
{
int count;
is for PMON 5.x on the Cogent Vr4300 board. */
static void
-pmon_make_fastrec (outbuf, inbuf, inptr, inamount, recsize, csum, zerofill)
- char **outbuf;
- unsigned char *inbuf;
- int *inptr;
- int inamount;
- int *recsize;
- unsigned int *csum;
- unsigned int *zerofill;
+pmon_make_fastrec (char **outbuf, unsigned char *inbuf, int *inptr,
+ int inamount, int *recsize, unsigned int *csum,
+ unsigned int *zerofill)
{
int count = 0;
char *p = *outbuf;
}
static int
-pmon_check_ack (mesg)
- char *mesg;
+pmon_check_ack (char *mesg)
{
#if defined(DOETXACK)
int c;
which is either a serial port or a UDP socket. */
static void
-pmon_start_download ()
+pmon_start_download (void)
{
if (tftp_in_use)
{
}
static void
-pmon_end_download (final, bintotal)
- int final;
- int bintotal;
+pmon_end_download (int final, int bintotal)
{
char hexnumber[9]; /* includes '\0' space */
}
static void
-pmon_download (buffer, length)
- char *buffer;
- int length;
+pmon_download (char *buffer, int length)
{
if (tftp_in_use)
fwrite (buffer, 1, length, tftp_file);
}
static void
-pmon_load_fast (file)
- char *file;
+pmon_load_fast (char *file)
{
bfd *abfd;
asection *s;
/* mips_load -- download a file. */
static void
-mips_load (file, from_tty)
- char *file;
- int from_tty;
+mips_load (char *file, int from_tty)
{
/* Get the board out of remote debugging mode. */
if (mips_exit_debug ())
/* Pass the command argument as a packet to PMON verbatim. */
static void
-pmon_command (args, from_tty)
- char *args;
- int from_tty;
+pmon_command (char *args, int from_tty)
{
char buf[DATA_MAXLEN + 1];
int rlen;
}
\f
void
-_initialize_remote_mips ()
+_initialize_remote_mips (void)
{
/* Initialize the fields in mips_ops that are common to all four targets. */
mips_ops.to_longname = "Remote MIPS debugging over serial line";
volatile int n_alarms;
static void
-mm_timer ()
+mm_timer (void)
{
#if 0
if (kiodebug)
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-mm_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+mm_create_inferior (char *execfile, char *args, char **env)
{
#define MAX_TOKENS 25
#define BUFFER_SIZE 256
}
/**************************************************** REMOTE_MOURN_INFERIOR */
static void
-mm_mourn ()
+mm_mourn (void)
{
pop_target (); /* Pop back to no-child state */
generic_mourn_inferior ();
};
static int
-damn_b (rate)
- int rate;
+damn_b (int rate)
{
int i;
static char *dev_name;
int baudrate = 9600;
static void
-mm_open (name, from_tty)
- char *name;
- int from_tty;
+mm_open (char *name, int from_tty)
{
TERMINAL sg;
unsigned int prl;
Use this when you want to detach and do something else
with your gdb. */
static void
-mm_close (quitting) /*FIXME: how is quitting used */
- int quitting;
+mm_close ( /*FIXME: how is quitting used */
+ int quitting)
{
if (mm_desc < 0)
error ("Can't close remote connection: not debugging remotely.");
* Upon exiting the process's execution is stopped.
*/
static void
-mm_attach (args, from_tty)
- char *args;
- int from_tty;
+mm_attach (char *args, int from_tty)
{
if (!mm_stream)
Use this when you want to detach and do something else
with your gdb. Leave remote process running (with no breakpoints set). */
static void
-mm_detach (args, from_tty)
- char *args;
- int from_tty;
+mm_detach (char *args, int from_tty)
{
remove_breakpoints (); /* Just in case there were any left in */
out_msg_buf->go_msg.code = GO;
** Tell the remote machine to resume. */
static void
-mm_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+mm_resume (int pid, int step, enum target_signal sig)
{
if (sig != TARGET_SIGNAL_0)
warning ("Can't send signals to a remote MiniMon system.");
storing status in STATUS just as `wait' would. */
static int
-mm_wait (status)
- struct target_waitstatus *status;
+mm_wait (struct target_waitstatus *status)
{
int i, result;
int old_timeout = timeout;
* If regno==-1 then read all the registers.
*/
static void
-mm_fetch_registers (regno)
- int regno;
+mm_fetch_registers (int regno)
{
INT32 *data_p;
*/
static void
-mm_store_registers (regno)
- int regno;
+mm_store_registers (int regno)
{
int result;
debugged. */
static void
-mm_prepare_to_store ()
+mm_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
/******************************************************* REMOTE_XFER_MEMORY */
static CORE_ADDR
-translate_addr (addr)
- CORE_ADDR addr;
+translate_addr (CORE_ADDR addr)
{
#if defined(KERNEL_DEBUGGING)
/* Check for a virtual address in the kernel */
/******************************************************* REMOTE_FILES_INFO */
static void
-mm_files_info ()
+mm_files_info (void)
{
printf ("\tAttached to %s at %d baud and running program %s.\n",
dev_name, baudrate, prog_name);
/************************************************* REMOTE_INSERT_BREAKPOINT */
static int
-mm_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+mm_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
out_msg_buf->bkpt_set_msg.code = BKPT_SET;
out_msg_buf->bkpt_set_msg.length = 4 * 4;
/************************************************* REMOTE_DELETE_BREAKPOINT */
static int
-mm_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+mm_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
out_msg_buf->bkpt_rm_msg.code = BKPT_RM;
out_msg_buf->bkpt_rm_msg.length = 4 * 3;
/******************************************************* REMOTE_KILL */
static void
-mm_kill (arg, from_tty)
- char *arg;
- int from_tty;
+mm_kill (char *arg, int from_tty)
{
char buf[4];
* Load a program into the target.
*/
static void
-mm_load (arg_string, from_tty)
- char *arg_string;
- int from_tty;
+mm_load (char *arg_string, int from_tty)
{
dont_repeat ();
** Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns number of bytes written. */
static int
-mm_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+mm_write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i, nwritten;
** Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns number of bytes read. */
static int
-mm_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+mm_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i, nread;
/* FIXME! Merge these two. */
static int
-mm_xfer_inferior_memory (memaddr, myaddr, len, write)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
+mm_xfer_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len, int write)
{
memaddr = translate_addr (memaddr);
*/
int
-msg_send_serial (msg_ptr)
- union msg_t *msg_ptr;
+msg_send_serial (union msg_t *msg_ptr)
{
INT32 message_size;
int byte_count;
*/
int
-msg_recv_serial (msg_ptr)
- union msg_t *msg_ptr;
+msg_recv_serial (union msg_t *msg_ptr)
{
static INT32 length = 0;
static INT32 byte_count = 0;
TERMINAL kbd_tbuf;
int
-kbd_raw ()
+kbd_raw (void)
{
int result;
TERMINAL tbuf;
*/
int
-kbd_restore ()
+kbd_restore (void)
{
int result;
* Returns 0/-1 on success/failure.
*/
static int
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
int result;
out_msg_buf->read_req_msg.code = READ_REQ;
* Returns 0/-1 on success/failure.
*/
static int
-store_register (regno)
- int regno;
+store_register (int regno)
{
int result;
* Convert a gdb special register number to a 29000 special register number.
*/
static int
-regnum_to_srnum (regno)
- int regno;
+regnum_to_srnum (int regno)
{
switch (regno)
{
* Initialize the target debugger (minimon only).
*/
static void
-init_target_mm (tstart, tend, dstart, dend, entry, ms_size, rs_size, arg_start)
- ADDR32 tstart, tend, dstart, dend, entry;
- INT32 ms_size, rs_size;
- ADDR32 arg_start;
+init_target_mm (ADDR32 tstart, ADDR32 tend, ADDR32 dstart, ADDR32 dend,
+ ADDR32 entry, INT32 ms_size, INT32 rs_size, ADDR32 arg_start)
{
out_msg_buf->init_msg.code = INIT;
out_msg_buf->init_msg.length = sizeof (struct init_msg_t) - 2 * sizeof (INT32);
* to be called with.
*/
static char *
-msg_str (code)
- INT32 code;
+msg_str (INT32 code)
{
static char cbuf[32];
* Selected (not all of them) error codes that we might get.
*/
static char *
-error_msg_str (code)
- INT32 code;
+error_msg_str (INT32 code)
{
static char cbuf[50];
* FIXME: Doesn't know anything about I_CACHE/D_CACHE.
*/
static int
-mm_memory_space (addr)
- CORE_ADDR *addr;
+mm_memory_space (CORE_ADDR *addr)
{
ADDR32 tstart = target_config.I_mem_start;
ADDR32 tend = tstart + target_config.I_mem_size;
};
void
-_initialize_remote_mm ()
+_initialize_remote_mm (void)
{
init_mm_ops ();
add_target (&mm_ops);
}
#ifdef NO_HIF_SUPPORT
-service_HIF (msg)
- union msg_t *msg;
+service_HIF (union msg_t *msg)
{
return (0); /* Emulate a failure */
}
static char *savename;
static void
-nindy_close (quitting)
- int quitting;
+nindy_close (int quitting)
{
if (nindy_serial != NULL)
SERIAL_CLOSE (nindy_serial);
now specified with gdb command-line options (old_protocol,
and initial_brk). */
void
-nindy_open (name, from_tty)
- char *name; /* "/dev/ttyXX", "ttyXX", or "XX": tty to be opened */
- int from_tty;
+nindy_open (char *name, /* "/dev/ttyXX", "ttyXX", or "XX": tty to be opened */
+ int from_tty)
{
char baudrate[1024];
/* User-initiated quit of nindy operations. */
static void
-nindy_detach (name, from_tty)
- char *name;
- int from_tty;
+nindy_detach (char *name, int from_tty)
{
if (name)
error ("Too many arguments");
}
static void
-nindy_files_info ()
+nindy_files_info (void)
{
/* FIXME: this lies about the baud rate if we autobauded. */
printf_unfiltered ("\tAttached to %s at %d bits per second%s%s.\n", savename,
/* Tell the remote machine to resume. */
void
-nindy_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+nindy_resume (int pid, int step, enum target_signal siggnal)
{
if (siggnal != TARGET_SIGNAL_0 && siggnal != stop_signal)
warning ("Can't send signals to remote NINDY targets.");
static struct clean_up_tty_args tty_args;
static void
-clean_up_tty (ptrarg)
- PTR ptrarg;
+clean_up_tty (PTR ptrarg)
{
struct clean_up_tty_args *args = (struct clean_up_tty_args *) ptrarg;
SERIAL_SET_TTY_STATE (args->serial, args->state);
#endif
static void
-clean_up_int ()
+clean_up_int (void)
{
SERIAL_SET_TTY_STATE (tty_args.serial, tty_args.state);
free (tty_args.state);
*/
static int
-nindy_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+nindy_wait (int pid, struct target_waitstatus *status)
{
fd_set fds;
int c;
};
static void
-nindy_fetch_registers (regno)
- int regno;
+nindy_fetch_registers (int regno)
{
struct nindy_regs nindy_regs;
int regnum;
}
static void
-nindy_prepare_to_store ()
+nindy_prepare_to_store (void)
{
/* Fetch all regs if they aren't already here. */
read_register_bytes (0, NULL, REGISTER_BYTES);
}
static void
-nindy_store_registers (regno)
- int regno;
+nindy_store_registers (int regno)
{
struct nindy_regs nindy_regs;
int regnum;
}
\f
static void
-nindy_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+nindy_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
int pid;
}
static void
-reset_command (args, from_tty)
- char *args;
- int from_tty;
+reset_command (char *args, int from_tty)
{
if (nindy_serial == NULL)
{
}
void
-nindy_kill (args, from_tty)
- char *args;
- int from_tty;
+nindy_kill (char *args, int from_tty)
{
return; /* Ignore attempts to kill target system */
}
instructions. */
void
-nindy_mourn_inferior ()
+nindy_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&nindy_ops);
\f
/* Pass the args the way catch_errors wants them. */
static int
-nindy_open_stub (arg)
- char *arg;
+nindy_open_stub (char *arg)
{
nindy_open (arg, 1);
return 1;
}
static void
-nindy_load (filename, from_tty)
- char *filename;
- int from_tty;
+nindy_load (char *filename, int from_tty)
{
asection *s;
/* Can't do unix style forking on a VMS system, so we'll use bfd to do
}
static int
-load_stub (arg)
- char *arg;
+load_stub (char *arg)
{
target_load (arg, 1);
return 1;
an i960 object file on the host system. */
void
-nindy_before_main_loop ()
+nindy_before_main_loop (void)
{
char ttyname[100];
char *p, *p2;
}
void
-_initialize_nindy ()
+_initialize_nindy (void)
{
init_nindy_ops ();
add_target (&nindy_ops);
don't match. */
static int
-expect (string)
- char *string;
+expect (char *string)
{
char *p = string;
int c;
}
static void
-nrom_kill ()
+nrom_kill (void)
{
nrom_close (0);
}
static serial_t
-open_socket (name, port)
- char *name;
- int port;
+open_socket (char *name, int port)
{
char sockname[100];
serial_t desc;
}
static void
-load_cleanup ()
+load_cleanup (void)
{
SERIAL_CLOSE (load_desc);
load_desc = NULL;
/* Download a file specified in ARGS to the netROM. */
static void
-nrom_load (args, fromtty)
- char *args;
- int fromtty;
+nrom_load (char *args, int fromtty)
{
int fd, rd_amt, fsize;
bfd *pbfd;
/* Open a connection to the remote NetROM devices. */
static void
-nrom_open (name, from_tty)
- char *name;
- int from_tty;
+nrom_open (char *name, int from_tty)
{
int errn;
/* Close out all files and local state before this target loses control. */
static void
-nrom_close (quitting)
- int quitting;
+nrom_close (int quitting)
{
if (load_desc)
SERIAL_CLOSE (load_desc);
/* Pass arguments directly to the NetROM. */
static void
-nrom_passthru (args, fromtty)
- char *args;
- int fromtty;
+nrom_passthru (char *args, int fromtty)
{
char buf[1024];
}
static void
-nrom_mourn ()
+nrom_mourn (void)
{
unpush_target (&nrom_ops);
generic_mourn_inferior ();
};
void
-_initialize_remote_nrom ()
+_initialize_remote_nrom (void)
{
init_nrom_ops ();
add_target (&nrom_ops);
/* Read a character from the remote system, doing all the fancy timeout stuff */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
non-zero, then discard non-matching input, else print it out.
Let the user break out immediately. */
static void
-expect (string, discard)
- char *string;
- int discard;
+expect (char *string, int discard)
{
char *p = string;
int c;
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt (discard)
- int discard;
+expect_prompt (int discard)
{
if (monitor_log)
/* This is a convenient place to do this. The idea is to do it often
/* Get a hex digit from the remote system & return its value.
If ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
static int
-get_hex_digit (ignore_space)
- int ignore_space;
+get_hex_digit (int ignore_space)
{
int ch;
while (1)
/* Get a byte from monitor and put it in *BYT. Accept any number
leading spaces. */
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
/* Get N 32-bit words from remote, each preceded by a space,
and put them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
int i;
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-rombug_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+rombug_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
static char dev_name[100];
static void
-rombug_open (args, from_tty)
- char *args;
- int from_tty;
+rombug_open (char *args, int from_tty)
{
if (args == NULL)
error ("Use `target RomBug DEVICE-NAME' to use a serial port, or \n\
*/
static void
-rombug_close (quitting)
- int quitting;
+rombug_close (int quitting)
{
if (rombug_is_open)
{
}
int
-rombug_link (mod_name, text_reloc)
- char *mod_name;
- CORE_ADDR *text_reloc;
+rombug_link (char *mod_name, CORE_ADDR *text_reloc)
{
int i, j;
unsigned long val;
Use this when you want to detach and do something else
with your gdb. */
static void
-rombug_detach (from_tty)
- int from_tty;
+rombug_detach (int from_tty)
{
if (attach_flag)
{
* Tell the remote machine to resume.
*/
static void
-rombug_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+rombug_resume (int pid, int step, enum target_signal sig)
{
if (monitor_log)
fprintf (log_file, "\nIn Resume (step=%d, sig=%d)\n", step, sig);
*/
static int
-rombug_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+rombug_wait (int pid, struct target_waitstatus *status)
{
int old_timeout = timeout;
struct section_offsets *offs;
monitor wants. Lets take advantage of that just as long as possible! */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char buf[50];
char *p;
/* read the remote registers into the block regs. */
static void
-rombug_fetch_registers ()
+rombug_fetch_registers (void)
{
int regno, j, i;
long val;
/* Fetch register REGNO, or all registers if REGNO is -1.
Returns errno value. */
static void
-rombug_fetch_register (regno)
- int regno;
+rombug_fetch_register (int regno)
{
int val, j;
unsigned char b;
/* Store the remote registers from the contents of the block REGS. */
static void
-rombug_store_registers ()
+rombug_store_registers (void)
{
int regno;
/* Store register REGNO, or all if REGNO == 0.
return errno value. */
static void
-rombug_store_register (regno)
- int regno;
+rombug_store_register (int regno)
{
char *name;
debugged. */
static void
-rombug_prepare_to_store ()
+rombug_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-rombug_files_info ()
+rombug_files_info (void)
{
printf ("\tAttached to %s at %d baud.\n",
dev_name, sr_get_baud_rate ());
/* Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns length moved. */
static int
-rombug_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+rombug_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int i;
char buf[10];
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns length moved. */
static int
-rombug_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+rombug_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i, j;
}
static void
-rombug_kill (args, from_tty)
- char *args;
- int from_tty;
+rombug_kill (char *args, int from_tty)
{
return; /* ignore attempts to kill target system */
}
instructions. */
static void
-rombug_mourn_inferior ()
+rombug_mourn_inferior (void)
{
remove_breakpoints ();
generic_mourn_inferior (); /* Do all the proper things now */
{0};
static int
-rombug_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+rombug_insert_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
CORE_ADDR bp_addr = addr;
* _remove_breakpoint -- Tell the monitor to remove a breakpoint
*/
static int
-rombug_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+rombug_remove_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
#define DOWNLOAD_LINE_SIZE 100
static void
-rombug_load (arg)
- char *arg;
+rombug_load (char *arg)
{
/* this part comment out for os9* */
#if 0
is seen. */
static void
-rombug_command (args, fromtty)
- char *args;
- int fromtty;
+rombug_command (char *args, int fromtty)
{
if (monitor_desc == NULL)
error ("monitor target not open.");
static struct ttystate ttystate;
static void
-cleanup_tty ()
+cleanup_tty (void)
{
printf ("\r\n[Exiting connect mode]\r\n");
/*SERIAL_RESTORE(0, &ttystate); */
}
static void
-connect_command (args, fromtty)
- char *args;
- int fromtty;
+connect_command (char *args, int fromtty)
{
fd_set readfds;
int numfds;
}
void
-_initialize_remote_os9k ()
+_initialize_remote_os9k (void)
{
init_rombug_ops ();
add_target (&rombug_ops);
/* Stub for catch_errors. */
static int
-arm_rdi_start_remote (dummy)
- char *dummy;
+arm_rdi_start_remote (char *dummy)
{
return 1;
}
these to forward output from the target system and so forth. */
void
-voiddummy ()
+voiddummy (void)
{
fprintf_unfiltered (gdb_stdout, "void dummy\n");
}
static void
-myprint (arg, format, ap)
- PTR arg;
- const char *format;
- va_list ap;
+myprint (PTR arg, const char *format, va_list ap)
{
vfprintf_unfiltered (gdb_stdout, format, ap);
}
static void
-mywritec (arg, c)
- PTR arg;
- int c;
+mywritec (PTR arg, int c)
{
if (isascii (c))
fputc_unfiltered (c, gdb_stdout);
}
static int
-mywrite (arg, buffer, len)
- PTR arg;
- char const *buffer;
- int len;
+mywrite (PTR arg, char const *buffer, int len)
{
int i;
char *e;
}
static void
-mypause (arg)
- PTR arg;
+mypause (PTR arg)
{
}
being interrupted more carefully */
static int
-myreadc (arg)
- PTR arg;
+myreadc (PTR arg)
{
return fgetc (stdin);
}
static char *
-mygets (arg, buffer, len)
- PTR arg;
- char *buffer;
- int len;
+mygets (PTR arg, char *buffer, int len)
{
return fgets (buffer, len, stdin);
}
for communication. */
static void
-arm_rdi_open (name, from_tty)
- char *name;
- int from_tty;
+arm_rdi_open (char *name, int from_tty)
{
int rslt, i;
unsigned long arg1, arg2;
user types "run" after having attached. */
static void
-arm_rdi_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+arm_rdi_create_inferior (char *exec_file, char *args, char **env)
{
int len, rslt;
unsigned long arg1, arg2;
die when it hits one. */
static void
-arm_rdi_detach (args, from_tty)
- char *args;
- int from_tty;
+arm_rdi_detach (char *args, int from_tty)
{
pop_target ();
}
/* Clean up connection to a remote debugger. */
static void
-arm_rdi_close (quitting)
- int quitting;
+arm_rdi_close (int quitting)
{
int rslt;
/* Tell the remote machine to resume. */
static void
-arm_rdi_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+arm_rdi_resume (int pid, int step, enum target_signal siggnal)
{
int rslt;
PointHandle point;
packet. */
static void
-arm_rdi_interrupt (signo)
- int signo;
+arm_rdi_interrupt (int signo)
{
}
/* The user typed ^C twice. */
static void
-arm_rdi_interrupt_twice (signo)
- int signo;
+arm_rdi_interrupt_twice (int signo)
{
}
/* Ask the user what to do when an interrupt is received. */
static void
-interrupt_query ()
+interrupt_query (void)
{
}
what, if anything, that means in the case of this target). */
static int
-arm_rdi_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+arm_rdi_wait (int pid, struct target_waitstatus *status)
{
status->kind = (execute_status == RDIError_NoError ?
TARGET_WAITKIND_EXITED : TARGET_WAITKIND_STOPPED);
/* ARGSUSED */
static void
-arm_rdi_fetch_registers (regno)
- int regno;
+arm_rdi_fetch_registers (int regno)
{
int rslt, rdi_regmask;
unsigned long rawreg, rawregs[32];
}
static void
-arm_rdi_prepare_to_store ()
+arm_rdi_prepare_to_store (void)
{
/* Nothing to do. */
}
of REGISTERS. FIXME: ignores errors. */
static void
-arm_rdi_store_registers (regno)
- int regno;
+arm_rdi_store_registers (int regno)
{
int rslt, rdi_regmask;
/* Display random info collected from the target. */
static void
-arm_rdi_files_info (ignore)
- struct target_ops *ignore;
+arm_rdi_files_info (struct target_ops *ignore)
{
char *file = "nothing";
int rslt;
}
\f
static void
-arm_rdi_kill ()
+arm_rdi_kill (void)
{
int rslt;
}
static void
-arm_rdi_mourn_inferior ()
+arm_rdi_mourn_inferior (void)
{
/* We remove the inserted breakpoints in case the user wants to
issue another target and load commands to rerun his application;
here. */
static int
-arm_rdi_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+arm_rdi_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int rslt;
PointHandle point;
}
static int
-arm_rdi_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+arm_rdi_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int rslt;
PointHandle point;
}
\f
static char *
-rdi_error_message (err)
- int err;
+rdi_error_message (int err)
{
switch (err)
{
/* Convert the ARM error messages to signals that GDB knows about. */
static enum target_signal
-rdi_error_signal (err)
- int err;
+rdi_error_signal (int err)
{
switch (err)
{
/* Define the target operations structure. */
static void
-init_rdi_ops ()
+init_rdi_ops (void)
{
arm_rdi_ops.to_shortname = "rdi";
arm_rdi_ops.to_longname = "ARM RDI";
}
void
-_initialize_remote_rdi ()
+_initialize_remote_rdi (void)
{
init_rdi_ops ();
add_target (&arm_rdi_ops);
/* A little dummy to make linking with the library succeed. */
int
-Fail ()
+Fail (void)
{
return 0;
}
/* Stuff for talking to the serial layer. */
static unsigned char
-get_byte ()
+get_byte (void)
{
int c = SERIAL_READCHAR (io, timeout);
/* Note that the target always speaks little-endian to us,
even if it's a big endian machine. */
static unsigned int
-get_word ()
+get_word (void)
{
unsigned int val = 0;
unsigned int c;
}
static void
-put_byte (val)
- char val;
+put_byte (char val)
{
if (remote_debug)
fprintf_unfiltered (gdb_stdlog, "(%02x)\n", val);
}
static void
-put_word (val)
- int val;
+put_word (int val)
{
/* We always send in little endian */
unsigned char b[4];
*/
static void
-rdp_init (cold, tty)
- int cold;
- int tty;
+rdp_init (int cold, int tty)
{
int sync = 0;
int type = cold ? RDP_OPEN_TYPE_COLD : RDP_OPEN_TYPE_WARM;
static int
-rdp_write (memaddr, buf, len)
- CORE_ADDR memaddr;
- char *buf;
- int len;
+rdp_write (CORE_ADDR memaddr, char *buf, int len)
{
int res;
int val;
static int
-rdp_read (memaddr, buf, len)
- CORE_ADDR memaddr;
- char *buf;
- int len;
+rdp_read (CORE_ADDR memaddr, char *buf, int len)
{
int res;
int val;
}
static void
-rdp_fetch_one_register (mask, buf)
- int mask;
- char *buf;
+rdp_fetch_one_register (int mask, char *buf)
{
int val;
send_rdp ("bbw-SWZ", RDP_CPU_READ, RDP_CPU_READWRITE_MODE_CURRENT, mask, &val);
}
static void
-rdp_fetch_one_fpu_register (mask, buf)
- int mask;
- char *buf;
+rdp_fetch_one_fpu_register (int mask, char *buf)
{
#if 0
/* !!! Since the PIE board doesn't work as documented,
static void
-rdp_store_one_register (mask, buf)
- int mask;
- char *buf;
+rdp_store_one_register (int mask, char *buf)
{
int val = extract_unsigned_integer (buf, 4);
static void
-rdp_store_one_fpu_register (mask, buf)
- int mask;
- char *buf;
+rdp_store_one_fpu_register (int mask, char *buf)
{
#if 0
/* See comment in fetch_one_fpu_register */
/* Convert between GDB requests and the RDP layer. */
static void
-remote_rdp_fetch_register (regno)
- int regno;
+remote_rdp_fetch_register (int regno)
{
if (regno == -1)
{
static void
-remote_rdp_store_register (regno)
- int regno;
+remote_rdp_store_register (int regno)
{
if (regno == -1)
{
}
static void
-remote_rdp_kill ()
+remote_rdp_kill (void)
{
callback->shutdown (callback);
}
static void
-rdp_info ()
+rdp_info (void)
{
send_rdp ("bw-S-W-Z", RDP_INFO, RDP_INFO_ABOUT_STEP,
&ds.step_info);
static void
-rdp_execute_start ()
+rdp_execute_start (void)
{
/* Start it off, but don't wait for it */
send_rdp ("bb-", RDP_EXEC, RDP_EXEC_TYPE_SYNC);
static void
-rdp_set_command_line (command, args)
- char *command;
- char *args;
+rdp_set_command_line (char *command, char *args)
{
/*
** We could use RDP_INFO_SET_CMDLINE to send this, but EmbeddedICE systems
}
static void
-rdp_catch_vectors ()
+rdp_catch_vectors (void)
{
/*
** We want the target monitor to intercept the abort vectors
};
static int
-exec_swi (swi, args)
- int swi;
- argsin *args;
+exec_swi (int swi, argsin *args)
{
int i;
char c;
static void
-handle_swi ()
+handle_swi (void)
{
argsin args[3];
char *buf;
}
static void
-rdp_execute_finish ()
+rdp_execute_finish (void)
{
int running = 1;
static void
-rdp_execute ()
+rdp_execute (void)
{
rdp_execute_start ();
rdp_execute_finish ();
}
static int
-remote_rdp_insert_breakpoint (addr, save)
- CORE_ADDR addr;
- char *save;
+remote_rdp_insert_breakpoint (CORE_ADDR addr, char *save)
{
int res;
if (ds.rdi_level > 0)
}
static int
-remote_rdp_remove_breakpoint (addr, save)
- CORE_ADDR addr;
- char *save;
+remote_rdp_remove_breakpoint (CORE_ADDR addr, char *save)
{
int res;
if (ds.rdi_level > 0)
}
static void
-rdp_step ()
+rdp_step (void)
{
if (ds.can_step && 0)
{
}
static void
-remote_rdp_open (args, from_tty)
- char *args;
- int from_tty;
+remote_rdp_open (char *args, int from_tty)
{
int not_icebreaker;
/* Close out all files and local state before this target loses control. */
static void
-remote_rdp_close (quitting)
- int quitting;
+remote_rdp_close (int quitting)
{
callback->shutdown (callback);
if (io)
to the target, or zero for no signal. */
static void
-remote_rdp_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+remote_rdp_resume (int pid, int step, enum target_signal siggnal)
{
if (step)
rdp_step ();
just as `wait' would. */
static int
-remote_rdp_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+remote_rdp_wait (int pid, struct target_waitstatus *status)
{
switch (ds.rdi_stopped_status)
{
debugged. */
static void
-remote_rdp_prepare_to_store ()
+remote_rdp_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-dump_bits (t, info)
- struct yn *t;
- int info;
+dump_bits (struct yn *t, int info)
{
while (t->name)
{
}
static void
-remote_rdp_files_info (target)
- struct target_ops *target;
+remote_rdp_files_info (struct target_ops *target)
{
printf_filtered ("Target capabilities:\n");
dump_bits (stepinfo, ds.step_info);
static void
-remote_rdp_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+remote_rdp_create_inferior (char *exec_file, char *allargs, char **env)
{
CORE_ADDR entry_point;
/* Accept any stray run/attach commands */
static int
-remote_rdp_can_run ()
+remote_rdp_can_run (void)
{
return 1;
}
/* Attach doesn't need to do anything */
static void
-remote_rdp_attach (args, from_tty)
- char *args;
- int from_tty;
+remote_rdp_attach (char *args, int from_tty)
{
return;
}
}
void
-_initialize_remote_rdp ()
+_initialize_remote_rdp (void)
{
init_remote_rdp_ops ();
add_target (&remote_rdp_ops);
/* ARGSUSED */
static void
-sds_close (quitting)
- int quitting;
+sds_close (int quitting)
{
if (sds_desc)
SERIAL_CLOSE (sds_desc);
/* Stub for catch_errors. */
static int
-sds_start_remote (dummy)
- PTR dummy;
+sds_start_remote (PTR dummy)
{
char c;
unsigned char buf[200];
static DCACHE *sds_dcache;
static void
-sds_open (name, from_tty)
- char *name;
- int from_tty;
+sds_open (char *name, int from_tty)
{
if (name == 0)
error ("To open a remote debug connection, you need to specify what serial\n\
die when it hits one. */
static void
-sds_detach (args, from_tty)
- char *args;
- int from_tty;
+sds_detach (char *args, int from_tty)
{
char buf[PBUFSIZ];
/* Convert hex digit A to a number. */
static int
-fromhex (a)
- int a;
+fromhex (int a)
{
if (a >= '0' && a <= '9')
return a - '0';
/* Convert number NIB to a hex digit. */
static int
-tohex (nib)
- int nib;
+tohex (int nib)
{
if (nib < 10)
return '0' + nib;
}
static int
-tob64 (inbuf, outbuf, len)
- unsigned char *inbuf;
- char *outbuf;
- int len;
+tob64 (unsigned char *inbuf, char *outbuf, int len)
{
int i, sum;
char *p;
}
static int
-fromb64 (inbuf, outbuf, len)
- char *inbuf, *outbuf;
- int len;
+fromb64 (char *inbuf, char *outbuf, int len)
{
int i, sum;
int last_sent_step;
static void
-sds_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+sds_resume (int pid, int step, enum target_signal siggnal)
{
unsigned char buf[PBUFSIZ];
us a message pending notice. */
static void
-sds_interrupt (signo)
- int signo;
+sds_interrupt (int signo)
{
unsigned char buf[PBUFSIZ];
/* The user typed ^C twice. */
static void
-sds_interrupt_twice (signo)
- int signo;
+sds_interrupt_twice (int signo)
{
signal (signo, ofunc);
/* Ask the user what to do when an interrupt is received. */
static void
-interrupt_query ()
+interrupt_query (void)
{
target_terminal_ours ();
what, if anything, that means in the case of this target). */
static int
-sds_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+sds_wait (int pid, struct target_waitstatus *status)
{
unsigned char buf[PBUFSIZ];
int retlen;
/* ARGSUSED */
static void
-sds_fetch_registers (regno)
- int regno;
+sds_fetch_registers (int regno)
{
unsigned char buf[PBUFSIZ];
int i, retlen;
read out the ones we don't want to change first. */
static void
-sds_prepare_to_store ()
+sds_prepare_to_store (void)
{
/* Make sure the entire registers array is valid. */
read_register_bytes (0, (char *) NULL, REGISTER_BYTES);
of REGISTERS. FIXME: ignores errors. */
static void
-sds_store_registers (regno)
- int regno;
+sds_store_registers (int regno)
{
unsigned char *p, buf[PBUFSIZ];
int i;
Returns number of bytes transferred, or 0 for error. */
static int
-sds_write_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+sds_write_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
int max_buf_size; /* Max size of packet output buffer */
int origlen;
Returns number of bytes transferred, or 0 for error. */
static int
-sds_read_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+sds_read_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
int max_buf_size; /* Max size of packet output buffer */
int origlen, retlen;
\f
static void
-sds_files_info (ignore)
- struct target_ops *ignore;
+sds_files_info (struct target_ops *ignore)
{
puts_filtered ("Debugging over a serial connection, using SDS protocol.\n");
}
/* Read a single character from the remote end, masking it down to 7 bits. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int ch;
because 253, 254, and 255 are special flags in the protocol.) */
static int
-compute_checksum (csum, buf, len)
- int csum, len;
- char *buf;
+compute_checksum (int csum, char *buf, int len)
{
int i;
into BUF also. */
static int
-sds_send (buf, len)
- unsigned char *buf;
- int len;
+sds_send (unsigned char *buf, int len)
{
putmessage (buf, len);
/* Send a message to the remote machine. */
static int
-putmessage (buf, len)
- unsigned char *buf;
- int len;
+putmessage (unsigned char *buf, int len)
{
int i, enclen;
unsigned char csum = 0;
into BUF. Returns 0 on any error, 1 on success. */
static int
-read_frame (buf)
- char *buf;
+read_frame (char *buf)
{
char *bp;
int c;
while the target is executing user code. */
static int
-getmessage (buf, forever)
- unsigned char *buf;
- int forever;
+getmessage (unsigned char *buf, int forever)
{
int c, c2, c3;
int tries;
}
\f
static void
-sds_kill ()
+sds_kill (void)
{
/* Don't try to do anything to the target. */
}
static void
-sds_mourn ()
+sds_mourn (void)
{
unpush_target (&sds_ops);
generic_mourn_inferior ();
}
static void
-sds_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+sds_create_inferior (char *exec_file, char *args, char **env)
{
inferior_pid = 42000;
}
static void
-sds_load (filename, from_tty)
- char *filename;
- int from_tty;
+sds_load (char *filename, int from_tty)
{
generic_load (filename, from_tty);
replaced instruction back to the debugger. */
static int
-sds_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+sds_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int i, retlen;
unsigned char *p, buf[PBUFSIZ];
}
static int
-sds_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+sds_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int i, retlen;
unsigned char *p, buf[PBUFSIZ];
}
\f
static void
-init_sds_ops ()
+init_sds_ops (void)
{
sds_ops.to_shortname = "sds";
sds_ops.to_longname = "Remote serial target with SDS protocol";
reply message. */
static void
-sds_command (args, from_tty)
- char *args;
- int from_tty;
+sds_command (char *args, int from_tty)
{
char *p;
int i, len, retlen;
}
void
-_initialize_remote_sds ()
+_initialize_remote_sds (void)
{
init_sds_ops ();
add_target (&sds_ops);
static SIM_DESC gdbsim_desc = 0;
static void
-dump_mem (buf, len)
- char *buf;
- int len;
+dump_mem (char *buf, int len)
{
if (len <= 8)
{
/* Initialize gdb_callback. */
static void
-init_callbacks ()
+init_callbacks (void)
{
if (!callbacks_initialized)
{
/* Release callbacks (free resources used by them). */
static void
-end_callbacks ()
+end_callbacks (void)
{
if (callbacks_initialized)
{
/* GDB version of os_write_stdout callback. */
static int
-gdb_os_write_stdout (p, buf, len)
- host_callback *p;
- const char *buf;
- int len;
+gdb_os_write_stdout (host_callback *p, const char *buf, int len)
{
int i;
char b[2];
/* GDB version of os_flush_stdout callback. */
static void
-gdb_os_flush_stdout (p)
- host_callback *p;
+gdb_os_flush_stdout (host_callback *p)
{
gdb_flush (gdb_stdtarg);
}
/* GDB version of os_write_stderr callback. */
static int
-gdb_os_write_stderr (p, buf, len)
- host_callback *p;
- const char *buf;
- int len;
+gdb_os_write_stderr (host_callback *p, const char *buf, int len)
{
int i;
char b[2];
/* GDB version of os_flush_stderr callback. */
static void
-gdb_os_flush_stderr (p)
- host_callback *p;
+gdb_os_flush_stderr (host_callback *p)
{
gdb_flush (gdb_stderr);
}
#endif
static void
-gdbsim_fetch_register (regno)
- int regno;
+gdbsim_fetch_register (int regno)
{
static int warn_user = 1;
if (regno == -1)
static void
-gdbsim_store_register (regno)
- int regno;
+gdbsim_store_register (int regno)
{
if (regno == -1)
{
and releasing other resources acquired by the simulated program. */
static void
-gdbsim_kill ()
+gdbsim_kill (void)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_kill\n");
GDB's symbol tables to match. */
static void
-gdbsim_load (prog, fromtty)
- char *prog;
- int fromtty;
+gdbsim_load (char *prog, int fromtty)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_load: prog \"%s\"\n", prog);
user types "run" after having attached. */
static void
-gdbsim_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+gdbsim_create_inferior (char *exec_file, char *args, char **env)
{
int len;
char *arg_buf, **argv;
/* Called when selecting the simulator. EG: (gdb) target sim name. */
static void
-gdbsim_open (args, from_tty)
- char *args;
- int from_tty;
+gdbsim_open (char *args, int from_tty)
{
int len;
char *arg_buf;
/* Close out all files and local state before this target loses control. */
static void
-gdbsim_close (quitting)
- int quitting;
+gdbsim_close (int quitting)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_close: quitting %d\n", quitting);
Use this when you want to detach and do something else with your gdb. */
static void
-gdbsim_detach (args, from_tty)
- char *args;
- int from_tty;
+gdbsim_detach (char *args, int from_tty)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_detach: args \"%s\"\n", args);
static int resume_step;
static void
-gdbsim_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+gdbsim_resume (int pid, int step, enum target_signal siggnal)
{
if (inferior_pid != 42)
error ("The program is not being run.");
For simulators that do not support this operation, just abort */
static void
-gdbsim_stop ()
+gdbsim_stop (void)
{
if (!sim_stop (gdbsim_desc))
{
Taken from gdb/util.c - should be in a library */
static int
-gdb_os_poll_quit (p)
- host_callback *p;
+gdb_os_poll_quit (host_callback *p)
{
if (ui_loop_hook != NULL)
ui_loop_hook (0);
just as `wait' would. */
static void
-gdbsim_cntrl_c (signo)
- int signo;
+gdbsim_cntrl_c (int signo)
{
gdbsim_stop ();
}
static int
-gdbsim_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+gdbsim_wait (int pid, struct target_waitstatus *status)
{
static RETSIGTYPE (*prev_sigint) ();
int sigrc = 0;
debugged. */
static void
-gdbsim_prepare_to_store ()
+gdbsim_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
}
static void
-gdbsim_files_info (target)
- struct target_ops *target;
+gdbsim_files_info (struct target_ops *target)
{
char *file = "nothing";
/* Clear the simulator's notion of what the break points are. */
static void
-gdbsim_mourn_inferior ()
+gdbsim_mourn_inferior (void)
{
if (sr_get_debug ())
printf_filtered ("gdbsim_mourn_inferior:\n");
}
static int
-gdbsim_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+gdbsim_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
#ifdef SIM_HAS_BREAKPOINTS
SIM_RC retcode;
}
static int
-gdbsim_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+gdbsim_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
#ifdef SIM_HAS_BREAKPOINTS
SIM_RC retcode;
simulator must do any command interpretation work. */
void
-simulator_command (args, from_tty)
- char *args;
- int from_tty;
+simulator_command (char *args, int from_tty)
{
if (gdbsim_desc == NULL)
{
}
void
-_initialize_remote_sim ()
+_initialize_remote_sim (void)
{
init_gdbsim_ops ();
add_target (&gdbsim_ops);
stuff. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int c;
non-zero, then discard non-matching input, else print it out.
Let the user break out immediately. */
static void
-expect (string, discard)
- char *string;
- int discard;
+expect (char *string, int discard)
{
char *p = string;
int c;
necessary to prevent getting into states from which we can't
recover. */
static void
-expect_prompt (discard)
- int discard;
+expect_prompt (int discard)
{
#if defined (LOG_FILE)
/* This is a convenient place to do this. The idea is to do it often
/* Get a hex digit from the remote system & return its value.
If ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
static int
-get_hex_digit (ignore_space)
- int ignore_space;
+get_hex_digit (int ignore_space)
{
int ch;
while (1)
/* Get a byte from stdebug and put it in *BYT. Accept any number
leading spaces. */
static void
-get_hex_byte (byt)
- char *byt;
+get_hex_byte (char *byt)
{
int val;
/* Get N 32-bit words from remote, each preceded by a space,
and put them in registers starting at REGNO. */
static void
-get_hex_regs (n, regno)
- int n;
- int regno;
+get_hex_regs (int n, int regno)
{
long val;
int i;
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
static void
-st2000_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+st2000_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
static char dev_name[100];
static void
-st2000_open (args, from_tty)
- char *args;
- int from_tty;
+st2000_open (char *args, int from_tty)
{
int n;
char junk[100];
/* Close out all files and local state before this target loses control. */
static void
-st2000_close (quitting)
- int quitting;
+st2000_close (int quitting)
{
SERIAL_CLOSE (st2000_desc);
Use this when you want to detach and do something else
with your gdb. */
static void
-st2000_detach (from_tty)
- int from_tty;
+st2000_detach (int from_tty)
{
pop_target (); /* calls st2000_close to do the real work */
if (from_tty)
/* Tell the remote machine to resume. */
static void
-st2000_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+st2000_resume (int pid, int step, enum target_signal sig)
{
if (step)
{
storing status in STATUS just as `wait' would. */
static int
-st2000_wait (status)
- struct target_waitstatus *status;
+st2000_wait (struct target_waitstatus *status)
{
int old_timeout = timeout;
STDEBUG wants. Lets take advantage of that just as long as possible! */
static char *
-get_reg_name (regno)
- int regno;
+get_reg_name (int regno)
{
static char buf[50];
const char *p;
/* Read the remote registers into the block REGS. */
static void
-st2000_fetch_registers ()
+st2000_fetch_registers (void)
{
int regno;
/* Fetch register REGNO, or all registers if REGNO is -1.
Returns errno value. */
static void
-st2000_fetch_register (regno)
- int regno;
+st2000_fetch_register (int regno)
{
if (regno == -1)
st2000_fetch_registers ();
/* Store the remote registers from the contents of the block REGS. */
static void
-st2000_store_registers ()
+st2000_store_registers (void)
{
int regno;
/* Store register REGNO, or all if REGNO == 0.
Return errno value. */
static void
-st2000_store_register (regno)
- int regno;
+st2000_store_register (int regno)
{
if (regno == -1)
st2000_store_registers ();
debugged. */
static void
-st2000_prepare_to_store ()
+st2000_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static void
-st2000_files_info ()
+st2000_files_info (void)
{
printf ("\tAttached to %s at %d baud.\n",
dev_name, baudrate);
/* Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns length moved. */
static int
-st2000_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned char *myaddr;
- int len;
+st2000_write_inferior_memory (CORE_ADDR memaddr, unsigned char *myaddr, int len)
{
int i;
/* Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns length moved. */
static int
-st2000_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+st2000_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int i;
}
static void
-st2000_kill (args, from_tty)
- char *args;
- int from_tty;
+st2000_kill (char *args, int from_tty)
{
return; /* Ignore attempts to kill target system */
}
instructions. */
static void
-st2000_mourn_inferior ()
+st2000_mourn_inferior (void)
{
remove_breakpoints ();
unpush_target (&st2000_ops);
{0};
static int
-st2000_insert_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+st2000_insert_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
CORE_ADDR bp_addr = addr;
}
static int
-st2000_remove_breakpoint (addr, shadow)
- CORE_ADDR addr;
- char *shadow;
+st2000_remove_breakpoint (CORE_ADDR addr, char *shadow)
{
int i;
on the users terminal until the prompt is seen. */
static void
-st2000_command (args, fromtty)
- char *args;
- int fromtty;
+st2000_command (char *args, int fromtty)
{
if (!st2000_desc)
error ("st2000 target not open.");
/*static struct ttystate ttystate; */
static void
-cleanup_tty ()
+cleanup_tty (void)
{
printf ("\r\n[Exiting connect mode]\r\n");
/* SERIAL_RESTORE(0, &ttystate); */
/* This all should now be in serial.c */
static void
-connect_command (args, fromtty)
- char *args;
- int fromtty;
+connect_command (char *args, int fromtty)
{
fd_set readfds;
int numfds;
};
void
-_initialize_remote_st2000 ()
+_initialize_remote_st2000 (void)
{
init_st2000_ops ();
add_target (&st2000_ops);
user types "run" after having attached. */
static void
-udi_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+udi_create_inferior (char *execfile, char *args, char **env)
{
char *args1;
}
static void
-udi_mourn ()
+udi_mourn (void)
{
#if 0
/* Requiring "target udi" each time you run is a major pain. I suspect
/* XXX - need cleanups for udiconnect for various failures!!! */
static void
-udi_open (name, from_tty)
- char *name;
- int from_tty;
+udi_open (char *name, int from_tty)
{
unsigned int prl;
char *p;
Use this when you want to detach and do something else
with your gdb. */
static void
-udi_close (quitting) /*FIXME: how is quitting used */
- int quitting;
+udi_close ( /*FIXME: how is quitting used */
+ int quitting)
{
if (udi_session_id < 0)
return;
* Upon exiting the process's execution is stopped.
*/
static void
-udi_attach (args, from_tty)
- char *args;
- int from_tty;
+udi_attach (char *args, int from_tty)
{
UDIResource From;
UDIInt32 PC_adds;
Use this when you want to detach and do something else
with your gdb. Leave remote process running (with no breakpoints set). */
static void
-udi_detach (args, from_tty)
- char *args;
- int from_tty;
+udi_detach (char *args, int from_tty)
{
remove_breakpoints (); /* Just in case there were any left in */
** Tell the remote machine to resume. */
static void
-udi_resume (pid, step, sig)
- int pid, step;
- enum target_signal sig;
+udi_resume (int pid, int step, enum target_signal sig)
{
UDIError tip_error;
UDIUInt32 Steps = 1;
storing status in STATUS just as `wait' would. */
static int
-udi_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+udi_wait (int pid, struct target_waitstatus *status)
{
UDIInt32 MaxTime;
UDIPId PId;
#if 0
/* Handy for debugging */
-udi_pc ()
+udi_pc (void)
{
UDIResource From;
UDIUInt32 *To;
* If regno==-1 then read all the registers.
*/
static void
-udi_fetch_registers (regno)
- int regno;
+udi_fetch_registers (int regno)
{
UDIResource From;
UDIUInt32 *To;
*/
static void
-udi_store_registers (regno)
- int regno;
+udi_store_registers (int regno)
{
UDIUInt32 *From;
UDIResource To;
debugged. */
static void
-udi_prepare_to_store ()
+udi_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
/********************************************************** TRANSLATE_ADDR */
static CORE_ADDR
-translate_addr (addr)
- CORE_ADDR addr;
+translate_addr (CORE_ADDR addr)
{
#if defined(ULTRA3) && defined(KERNEL_DEBUGGING)
/* Check for a virtual address in the kernel */
/************************************************* UDI_XFER_INFERIOR_MEMORY */
/* FIXME! Merge these two. */
static int
-udi_xfer_inferior_memory (memaddr, myaddr, len, write)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
+udi_xfer_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len, int write)
{
memaddr = translate_addr (memaddr);
/********************************************************** UDI_FILES_INFO */
static void
-udi_files_info ()
+udi_files_info (void)
{
printf_unfiltered ("\tAttached to UDI socket to %s", udi_config_id);
if (prog_name != NULL)
/**************************************************** UDI_INSERT_BREAKPOINT */
static int
-udi_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+udi_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int cnt;
UDIError err;
/**************************************************** UDI_REMOVE_BREAKPOINT */
static int
-udi_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+udi_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int cnt;
UDIError err;
}
static void
-udi_kill (arg, from_tty)
- char *arg;
- int from_tty;
+udi_kill (char *arg, int from_tty)
{
#if 0
*/
static void
-download (load_arg_string, from_tty)
- char *load_arg_string;
- int from_tty;
+download (char *load_arg_string, int from_tty)
{
#define DEFAULT_MEM_STACK_SIZE 0x6000
#define DEFAULT_REG_STACK_SIZE 0x2000
/* Function to download an image into the remote target. */
static void
-udi_load (args, from_tty)
- char *args;
- int from_tty;
+udi_load (char *args, int from_tty)
{
download (args, from_tty);
** Copy LEN bytes of data from debugger memory at MYADDR
to inferior's memory at MEMADDR. Returns number of bytes written. */
static int
-udi_write_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+udi_write_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int nwritten = 0;
UDIUInt32 *From;
** Read LEN bytes from inferior memory at MEMADDR. Put the result
at debugger address MYADDR. Returns number of bytes read. */
static int
-udi_read_inferior_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+udi_read_inferior_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
int nread = 0;
UDIResource From;
/********************************************************************* WARNING
*/
-udi_warning (num)
- int num;
+udi_warning (int num)
{
error ("ERROR while loading program into remote TIP: $d\n", num);
}
* Returns 0/-1 on success/failure.
*/
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
UDIResource From;
UDIUInt32 To;
* Returns 0/-1 on success/failure.
*/
static int
-store_register (regno)
- int regno;
+store_register (int regno)
{
int result;
UDIUInt32 From;
* Convert a gdb special register number to a 29000 special register number.
*/
static int
-regnum_to_srnum (regno)
- int regno;
+regnum_to_srnum (int regno)
{
switch (regno)
{
* FIXME: Doesn't know anything about I_CACHE/D_CACHE.
*/
static CPUSpace
-udi_memory_space (addr)
- CORE_ADDR addr;
+udi_memory_space (CORE_ADDR addr)
{
UDIUInt32 tstart = IMemStart;
UDIUInt32 tend = tstart + IMemSize;
*/
void
-convert16 ()
+convert16 (void)
{;
}
void
-convert32 ()
+convert32 (void)
{;
}
struct ui_file *EchoFile = 0; /* used for debugging */
int QuietMode = 0; /* used for debugging */
\f
#ifdef NO_HIF_SUPPORT
-service_HIF (msg)
- union msg_t *msg;
+service_HIF (union msg_t *msg)
{
return (0); /* Emulate a failure */
}
};
void
-_initialize_remote_udi ()
+_initialize_remote_udi (void)
{
init_udi_ops ();
add_target (&udi_ops);
static void sr_com (char *, int);
static void
-usage (proto, junk)
- char *proto;
- char *junk;
+usage (char *proto, char *junk)
{
if (junk != NULL)
fprintf_unfiltered (gdb_stderr, "Unrecognized arguments: `%s'.\n", junk);
}
void
-sr_scan_args (proto, args)
- char *proto;
- char *args;
+sr_scan_args (char *proto, char *args)
{
int n;
char *p, *q;
}
void
-gr_generic_checkin ()
+gr_generic_checkin (void)
{
sr_write_cr ("");
gr_expect_prompt ();
}
void
-gr_open (args, from_tty, gr)
- char *args;
- int from_tty;
- struct gr_settings *gr;
+gr_open (char *args, int from_tty, struct gr_settings *gr)
{
target_preopen (from_tty);
sr_scan_args (gr->ops->to_shortname, args);
and doing all the fancy timeout stuff. */
int
-sr_readchar ()
+sr_readchar (void)
{
int buf;
}
int
-sr_pollchar ()
+sr_pollchar (void)
{
int buf;
/* Keep discarding input from the remote system, until STRING is found.
Let the user break out immediately. */
void
-sr_expect (string)
- char *string;
+sr_expect (char *string)
{
char *p = string;
}
void
-sr_write (a, l)
- char *a;
- int l;
+sr_write (char *a, int l)
{
int i;
}
void
-sr_write_cr (s)
- char *s;
+sr_write_cr (char *s)
{
sr_write (s, strlen (s));
sr_write ("\r", 1);
}
int
-sr_timed_read (buf, n)
- char *buf;
- int n;
+sr_timed_read (char *buf, int n)
{
int i;
char c;
ignore_space is nonzero, ignore spaces (not newline, tab, etc). */
int
-sr_get_hex_digit (ignore_space)
- int ignore_space;
+sr_get_hex_digit (int ignore_space)
{
int ch;
/* Get a byte from the remote and put it in *BYT. Accept any number
leading spaces. */
void
-sr_get_hex_byte (byt)
- char *byt;
+sr_get_hex_byte (char *byt)
{
int val;
/* Read a 32-bit hex word from the remote, preceded by a space */
long
-sr_get_hex_word ()
+sr_get_hex_word (void)
{
long val;
int j;
FIXME: Can't handle commands that take input. */
static void
-sr_com (args, fromtty)
- char *args;
- int fromtty;
+sr_com (char *args, int fromtty)
{
sr_check_open ();
}
void
-gr_close (quitting)
- int quitting;
+gr_close (int quitting)
{
gr_clear_all_breakpoints ();
with your gdb. */
void
-gr_detach (args, from_tty)
- char *args;
- int from_tty;
+gr_detach (char *args, int from_tty)
{
if (args)
error ("Argument given to \"detach\" when remotely debugging.");
}
void
-gr_files_info (ops)
- struct target_ops *ops;
+gr_files_info (struct target_ops *ops)
{
#ifdef __GO32__
printf_filtered ("\tAttached to DOS asynctsr\n");
}
void
-gr_mourn ()
+gr_mourn (void)
{
gr_clear_all_breakpoints ();
unpush_target (gr_get_ops ());
}
void
-gr_kill ()
+gr_kill (void)
{
return;
}
/* This is called not only when we first attach, but also when the
user types "run" after having attached. */
void
-gr_create_inferior (execfile, args, env)
- char *execfile;
- char *args;
- char **env;
+gr_create_inferior (char *execfile, char *args, char **env)
{
int entry_pt;
debugged. */
void
-gr_prepare_to_store ()
+gr_prepare_to_store (void)
{
/* Do nothing, since we assume we can store individual regs */
}
void
-_initialize_sr_support ()
+_initialize_sr_support (void)
{
/* FIXME-now: if target is open... */
add_show_from_set (add_set_cmd ("remotedevice", no_class,
Returns 0 for success, -1 for failure. */
static int
-net_load (filename, pTextAddr, pDataAddr, pBssAddr)
- char *filename;
- CORE_ADDR *pTextAddr;
- CORE_ADDR *pDataAddr;
- CORE_ADDR *pBssAddr;
+net_load (char *filename, CORE_ADDR *pTextAddr, CORE_ADDR *pDataAddr,
+ CORE_ADDR *pBssAddr)
{
enum clnt_stat status;
struct ldfile ldstruct;
/* returns 0 if successful, errno if RPC failed or VxWorks complains. */
static int
-net_break (addr, procnum)
- int addr;
- u_long procnum;
+net_break (int addr, u_long procnum)
{
enum clnt_stat status;
int break_status;
/* returns 0 if successful, errno otherwise */
static int
-vx_insert_breakpoint (addr)
- int addr;
+vx_insert_breakpoint (int addr)
{
return net_break (addr, VX_BREAK_ADD);
}
/* returns 0 if successful, errno otherwise */
static int
-vx_remove_breakpoint (addr)
- int addr;
+vx_remove_breakpoint (int addr)
{
return net_break (addr, VX_BREAK_DELETE);
}
On VxWorks, we ignore exec_file. */
static void
-vx_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+vx_create_inferior (char *exec_file, char *args, char **env)
{
enum clnt_stat status;
arg_array passArgs;
argument string ARGSTRING. */
static void
-parse_args (arg_string, arg_struct)
- register char *arg_string;
- arg_array *arg_struct;
+parse_args (register char *arg_string, arg_array *arg_struct)
{
register int arg_count = 0; /* number of arguments */
register int arg_index = 0;
to the first non-white character. */
static char *
-skip_white_space (p)
- register char *p;
+skip_white_space (register char *p)
{
while (*p == ' ' || *p == '\t')
p++;
if no whitespace is found. */
static char *
-find_white_space (p)
- register char *p;
+find_white_space (register char *p)
{
register int c;
Returns -1 if remote wait failed, task status otherwise. */
static int
-net_wait (pEvent)
- RDB_EVENT *pEvent;
+net_wait (RDB_EVENT *pEvent)
{
int pid;
enum clnt_stat status;
Returns -1 if suspend fails on target system, 0 otherwise. */
static int
-net_quit ()
+net_quit (void)
{
int pid;
int quit_status;
/* Read a register or registers from the remote system. */
void
-net_read_registers (reg_buf, len, procnum)
- char *reg_buf;
- int len;
- u_long procnum;
+net_read_registers (char *reg_buf, int len, u_long procnum)
{
int status;
Rptrace ptrace_in;
a utility routine used by vx_write_register (). */
void
-net_write_registers (reg_buf, len, procnum)
- char *reg_buf;
- int len;
- u_long procnum;
+net_write_registers (char *reg_buf, int len, u_long procnum)
{
int status;
Rptrace ptrace_in;
read out their current values now. */
static void
-vx_prepare_to_store ()
+vx_prepare_to_store (void)
{
/* Fetch all registers, if any of them are not yet fetched. */
read_register_bytes (0, NULL, REGISTER_BYTES);
}
static void
-vx_files_info ()
+vx_files_info (void)
{
printf_unfiltered ("\tAttached to host `%s'", vx_host);
printf_unfiltered (", which has %sfloating point", target_has_fp ? "" : "no ");
}
static void
-vx_run_files_info ()
+vx_run_files_info (void)
{
printf_unfiltered ("\tRunning %s VxWorks process %s",
vx_running ? "child" : "attached",
}
static void
-vx_resume (pid, step, siggnal)
- int pid;
- int step;
- enum target_signal siggnal;
+vx_resume (int pid, int step, enum target_signal siggnal)
{
int status;
Rptrace ptrace_in;
}
static void
-vx_mourn_inferior ()
+vx_mourn_inferior (void)
{
pop_target (); /* Pop back to no-child state */
generic_mourn_inferior ();
static void find_sect (bfd *, asection *, void *);
static void
-find_sect (abfd, sect, obj)
- bfd *abfd;
- asection *sect;
- PTR obj;
+find_sect (bfd *abfd, asection *sect, PTR obj)
{
struct find_sect_args *args = (struct find_sect_args *) obj;
}
static void
-vx_add_symbols (name, from_tty, text_addr, data_addr, bss_addr)
- char *name;
- int from_tty;
- CORE_ADDR text_addr;
- CORE_ADDR data_addr;
- CORE_ADDR bss_addr;
+vx_add_symbols (char *name, int from_tty, CORE_ADDR text_addr,
+ CORE_ADDR data_addr, CORE_ADDR bss_addr)
{
struct section_offsets *offs;
struct objfile *objfile;
/* This function allows the addition of incrementally linked object files. */
static void
-vx_load_command (arg_string, from_tty)
- char *arg_string;
- int from_tty;
+vx_load_command (char *arg_string, int from_tty)
{
CORE_ADDR text_addr;
CORE_ADDR data_addr;
Returns -1 if remote single-step operation fails, else 0. */
static int
-net_step ()
+net_step (void)
{
enum clnt_stat status;
int step_status;
Returns nonzero (-1) if RPC status to VxWorks is bad, 0 otherwise. */
static int
-net_ptrace_clnt_call (request, pPtraceIn, pPtraceOut)
- enum ptracereq request;
- Rptrace *pPtraceIn;
- Ptrace_return *pPtraceOut;
+net_ptrace_clnt_call (enum ptracereq request, Rptrace *pPtraceIn,
+ Ptrace_return *pPtraceOut)
{
enum clnt_stat status;
Returns -1 if rpc failed, 0 otherwise. */
static int
-net_get_boot_file (pBootFile)
- char **pBootFile;
+net_get_boot_file (char **pBootFile)
{
enum clnt_stat status;
{"Lost contact with VxWorks target", 0, 0};
static int
-vx_lookup_symbol (name, pAddr)
- char *name; /* symbol name */
- CORE_ADDR *pAddr;
+vx_lookup_symbol (char *name, /* symbol name */
+ CORE_ADDR *pAddr)
{
enum clnt_stat status;
SYMBOL_ADDR symbolAddr;
Calls error() if rpc fails. */
static int
-net_check_for_fp ()
+net_check_for_fp (void)
{
enum clnt_stat status;
bool_t fp = 0; /* true if fp processor is present on target board */
Calls error () if unable to establish connection. */
static void
-net_connect (host)
- char *host;
+net_connect (char *host)
{
struct sockaddr_in destAddr;
struct hostent *destHost;
*/
static void
-sleep_ms (ms)
- long ms;
+sleep_ms (long ms)
{
struct timeval select_timeout;
int status;
}
static int
-vx_wait (pid_to_wait_for, status)
- int pid_to_wait_for;
- struct target_waitstatus *status;
+vx_wait (int pid_to_wait_for, struct target_waitstatus *status)
{
register int pid;
RDB_EVENT rdbEvent;
}
\f
static int
-symbol_stub (arg)
- char *arg;
+symbol_stub (char *arg)
{
symbol_file_command (arg, 0);
return 1;
}
static int
-add_symbol_stub (arg)
- char *arg;
+add_symbol_stub (char *arg)
{
struct ldfile *pLoadFile = (struct ldfile *) arg;
debugging. */
static void
-vx_open (args, from_tty)
- char *args;
- int from_tty;
+vx_open (char *args, int from_tty)
{
extern int close ();
char *bootFile;
This stops it cold in its tracks and allows us to start tracing it. */
static void
-vx_attach (args, from_tty)
- char *args;
- int from_tty;
+vx_attach (char *args, int from_tty)
{
unsigned long pid;
char *cptr = 0;
started via the normal ptrace (PTRACE_TRACEME). */
static void
-vx_detach (args, from_tty)
- char *args;
- int from_tty;
+vx_detach (char *args, int from_tty)
{
Rptrace ptrace_in;
Ptrace_return ptrace_out;
/* vx_kill -- takes a running task and wipes it out. */
static void
-vx_kill ()
+vx_kill (void)
{
Rptrace ptrace_in;
Ptrace_return ptrace_out;
/* Clean up from the VxWorks process target as it goes away. */
static void
-vx_proc_close (quitting)
- int quitting;
+vx_proc_close (int quitting)
{
inferior_pid = 0; /* No longer have a process. */
if (vx_running)
Returns RPC status. */
static enum clnt_stat
-net_clnt_call (procNum, inProc, in, outProc, out)
- enum ptracereq procNum;
- xdrproc_t inProc;
- char *in;
- xdrproc_t outProc;
- char *out;
+net_clnt_call (enum ptracereq procNum, xdrproc_t inProc, char *in,
+ xdrproc_t outProc, char *out)
{
enum clnt_stat status;
/* Clean up before losing control. */
static void
-vx_close (quitting)
- int quitting;
+vx_close (int quitting)
{
if (pClient)
clnt_destroy (pClient); /* The net connection */
/* A vxprocess target should be started via "run" not "target". */
/*ARGSUSED */
static void
-vx_proc_open (name, from_tty)
- char *name;
- int from_tty;
+vx_proc_open (char *name, int from_tty)
{
error ("Use the \"run\" command to start a VxWorks process.");
}
static void
-init_vx_ops ()
+init_vx_ops (void)
{
vx_ops.to_shortname = "vxworks";
vx_ops.to_longname = "VxWorks target memory via RPC over TCP/IP";
};
static void
-init_vx_run_ops ()
+init_vx_run_ops (void)
{
vx_run_ops.to_shortname = "vxprocess";
vx_run_ops.to_longname = "VxWorks process";
}
\f
void
-_initialize_vx ()
+_initialize_vx (void)
{
init_vx_ops ();
add_target (&vx_ops);
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_read_register (regno)
- int regno;
+vx_read_register (int regno)
{
char am29k_greg_packet[AM29K_GREG_PLEN];
char am29k_fpreg_packet[AM29K_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_write_register (regno)
- int regno;
+vx_write_register (int regno)
{
char am29k_greg_packet[AM29K_GREG_PLEN];
char am29k_fpreg_packet[AM29K_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_read_register (regno)
- int regno;
+vx_read_register (int regno)
{
char mc68k_greg_packet[MC68K_GREG_PLEN];
char mc68k_fpreg_packet[MC68K_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_write_register (regno)
- int regno;
+vx_write_register (int regno)
{
char mc68k_greg_packet[MC68K_GREG_PLEN];
char mc68k_fpreg_packet[MC68K_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_read_register (regno)
- int regno;
+vx_read_register (int regno)
{
char i960_greg_packet[I960_GREG_PLEN];
char i960_fpreg_packet[I960_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_write_register (regno)
- int regno;
+vx_write_register (int regno)
{
char i960_greg_packet[I960_GREG_PLEN];
char i960_fpreg_packet[I960_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_read_register (regno)
- int regno;
+vx_read_register (int regno)
{
char mips_greg_packet[MIPS_GREG_PLEN];
char mips_fpreg_packet[MIPS_FPREG_PLEN];
REGNO is the register to store, or -1 for all; currently,
it is ignored. FIXME look at regno to improve efficiency. */
-vx_write_register (regno)
- int regno;
+vx_write_register (int regno)
{
char mips_greg_packet[MIPS_GREG_PLEN];
char mips_fpreg_packet[MIPS_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_read_register (regno)
- int regno;
+vx_read_register (int regno)
{
char sparc_greg_packet[SPARC_GREG_PLEN];
char sparc_fpreg_packet[SPARC_FPREG_PLEN];
it is ignored. FIXME look at regno to improve efficiency. */
void
-vx_write_register (regno)
- int regno;
+vx_write_register (int regno)
{
char sparc_greg_packet[SPARC_GREG_PLEN];
char sparc_fpreg_packet[SPARC_FPREG_PLEN];
};
static void
-set_packet_config_cmd (config, c)
- struct packet_config *config;
- struct cmd_list_element *c;
+set_packet_config_cmd (struct packet_config *config, struct cmd_list_element *c)
{
if (config->state == packet_enable)
{
}
static void
-show_packet_config_cmd (config)
- struct packet_config *config;
+show_packet_config_cmd (struct packet_config *config)
{
char *support = "internal-error";
switch (config->support)
}
static void
-init_packet_config (config)
- struct packet_config *config;
+init_packet_config (struct packet_config *config)
{
switch (config->detect)
{
static struct packet_config remote_protocol_P;
static void
-set_remote_protocol_P_packet_cmd (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_remote_protocol_P_packet_cmd (char *args, int from_tty,
+ struct cmd_list_element *c)
{
set_packet_config_cmd (&remote_protocol_P, c);
}
static void
-show_remote_protocol_P_packet_cmd (args, from_tty)
- char *args;
- int from_tty;
+show_remote_protocol_P_packet_cmd (char *args, int from_tty)
{
show_packet_config_cmd (&remote_protocol_P);
}
static struct packet_config remote_protocol_Z;
static void
-set_remote_protocol_Z_packet_cmd (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_remote_protocol_Z_packet_cmd (char *args, int from_tty,
+ struct cmd_list_element *c)
{
set_packet_config_cmd (&remote_protocol_Z, c);
}
static void
-show_remote_protocol_Z_packet_cmd (args, from_tty)
- char *args;
- int from_tty;
+show_remote_protocol_Z_packet_cmd (char *args, int from_tty)
{
show_packet_config_cmd (&remote_protocol_Z);
}
*/
static void
-record_currthread (currthread)
- int currthread;
+record_currthread (int currthread)
{
general_thread = currthread;
#define MAGIC_NULL_PID 42000
static void
-set_thread (th, gen)
- int th;
- int gen;
+set_thread (int th, int gen)
{
char *buf = alloca (PBUFSIZ);
int state = gen ? general_thread : continue_thread;
/* Return nonzero if the thread TH is still alive on the remote system. */
static int
-remote_thread_alive (tid)
- int tid;
+remote_thread_alive (int tid)
{
char buf[16];
static const char hexchars[] = "0123456789abcdef";
static int
-ishex (ch, val)
- int ch;
- int *val;
+ishex (int ch, int *val)
{
if ((ch >= 'a') && (ch <= 'f'))
{
}
static int
-stubhex (ch)
- int ch;
+stubhex (int ch)
{
if (ch >= 'a' && ch <= 'f')
return ch - 'a' + 10;
}
static int
-stub_unpack_int (buff, fieldlength)
- char *buff;
- int fieldlength;
+stub_unpack_int (char *buff, int fieldlength)
{
int nibble;
int retval = 0;
}
char *
-unpack_varlen_hex (buff, result)
- char *buff; /* packet to parse */
- int *result;
+unpack_varlen_hex (char *buff, /* packet to parse */
+ int *result)
{
int nibble;
int retval = 0;
}
static char *
-unpack_nibble (buf, val)
- char *buf;
- int *val;
+unpack_nibble (char *buf, int *val)
{
ishex (*buf++, val);
return buf;
}
static char *
-pack_nibble (buf, nibble)
- char *buf;
- int nibble;
+pack_nibble (char *buf, int nibble)
{
*buf++ = hexchars[(nibble & 0x0f)];
return buf;
}
static char *
-pack_hex_byte (pkt, byte)
- char *pkt;
- int byte;
+pack_hex_byte (char *pkt, int byte)
{
*pkt++ = hexchars[(byte >> 4) & 0xf];
*pkt++ = hexchars[(byte & 0xf)];
}
static char *
-unpack_byte (buf, value)
- char *buf;
- int *value;
+unpack_byte (char *buf, int *value)
{
*value = stub_unpack_int (buf, 2);
return buf + 2;
}
static char *
-pack_int (buf, value)
- char *buf;
- int value;
+pack_int (char *buf, int value)
{
buf = pack_hex_byte (buf, (value >> 24) & 0xff);
buf = pack_hex_byte (buf, (value >> 16) & 0xff);
}
static char *
-unpack_int (buf, value)
- char *buf;
- int *value;
+unpack_int (char *buf, int *value)
{
*value = stub_unpack_int (buf, 8);
return buf + 8;
static char *pack_string (char *pkt, char *string);
static char *
-pack_string (pkt, string)
- char *pkt;
- char *string;
+pack_string (char *pkt, char *string)
{
char ch;
int len;
#endif /* 0 (unused) */
static char *
-unpack_string (src, dest, length)
- char *src;
- char *dest;
- int length;
+unpack_string (char *src, char *dest, int length)
{
while (length--)
*dest++ = *src++;
}
static char *
-pack_threadid (pkt, id)
- char *pkt;
- threadref *id;
+pack_threadid (char *pkt, threadref *id)
{
char *limit;
unsigned char *altid;
static char *
-unpack_threadid (inbuf, id)
- char *inbuf;
- threadref *id;
+unpack_threadid (char *inbuf, threadref *id)
{
char *altref;
char *limit = inbuf + BUF_THREAD_ID_SIZE;
function. */
void
-int_to_threadref (id, value)
- threadref *id;
- int value;
+int_to_threadref (threadref *id, int value)
{
unsigned char *scan;
}
static int
-threadref_to_int (ref)
- threadref *ref;
+threadref_to_int (threadref *ref)
{
int i, value = 0;
unsigned char *scan;
}
static void
-copy_threadref (dest, src)
- threadref *dest;
- threadref *src;
+copy_threadref (threadref *dest, threadref *src)
{
int i;
unsigned char *csrc, *cdest;
}
static int
-threadmatch (dest, src)
- threadref *dest;
- threadref *src;
+threadmatch (threadref *dest, threadref *src)
{
/* things are broken right now, so just assume we got a match */
#if 0
/* Encoding: 'Q':8,'P':8,mask:32,threadid:64 */
static char *
-pack_threadinfo_request (pkt, mode, id)
- char *pkt;
- int mode;
- threadref *id;
+pack_threadinfo_request (char *pkt, int mode, threadref *id)
{
*pkt++ = 'q'; /* Info Query */
*pkt++ = 'P'; /* process or thread info */
the process */
static int
-remote_unpack_thread_info_response (pkt, expectedref, info)
- char *pkt;
- threadref *expectedref;
- struct gdb_ext_thread_info *info;
+remote_unpack_thread_info_response (char *pkt, threadref *expectedref,
+ struct gdb_ext_thread_info *info)
{
int mask, length;
unsigned int tag;
}
static int
-remote_get_threadinfo (threadid, fieldset, info)
- threadref *threadid;
- int fieldset; /* TAG mask */
- struct gdb_ext_thread_info *info;
+remote_get_threadinfo (threadref *threadid, int fieldset, /* TAG mask */
+ struct gdb_ext_thread_info *info)
{
int result;
char *threadinfo_pkt = alloca (PBUFSIZ);
representation of a threadid. */
static int
-adapt_remote_get_threadinfo (ref, selection, info)
- gdb_threadref *ref;
- int selection;
- struct gdb_ext_thread_info *info;
+adapt_remote_get_threadinfo (gdb_threadref *ref, int selection,
+ struct gdb_ext_thread_info *info)
{
threadref lclref;
/* Format: i'Q':8,i"L":8,initflag:8,batchsize:16,lastthreadid:32 */
static char *
-pack_threadlist_request (pkt, startflag, threadcount, nextthread)
- char *pkt;
- int startflag;
- int threadcount;
- threadref *nextthread;
+pack_threadlist_request (char *pkt, int startflag, int threadcount,
+ threadref *nextthread)
{
*pkt++ = 'q'; /* info query packet */
*pkt++ = 'L'; /* Process LIST or threadLIST request */
/* Encoding: 'q':8,'M':8,count:16,done:8,argthreadid:64,(threadid:64)* */
static int
-parse_threadlist_response (pkt, result_limit, original_echo, resultlist,
- doneflag)
- char *pkt;
- int result_limit;
- threadref *original_echo;
- threadref *resultlist;
- int *doneflag;
+parse_threadlist_response (char *pkt, int result_limit,
+ threadref *original_echo, threadref *resultlist,
+ int *doneflag)
{
char *limit;
int count, resultcount, done;
}
static int
-remote_get_threadlist (startflag, nextthread, result_limit,
- done, result_count, threadlist)
- int startflag;
- threadref *nextthread;
- int result_limit;
- int *done;
- int *result_count;
- threadref *threadlist;
-
+remote_get_threadlist (int startflag, threadref *nextthread, int result_limit,
+ int *done, int *result_count, threadref *threadlist)
{
static threadref echo_nextthread;
char *threadlist_packet = alloca (PBUFSIZ);
#define MAXTHREADLISTRESULTS 32
static int
-remote_threadlist_iterator (stepfunction, context, looplimit)
- rmt_thread_action stepfunction;
- void *context;
- int looplimit;
+remote_threadlist_iterator (rmt_thread_action stepfunction, void *context,
+ int looplimit)
{
int done, i, result_count;
int startflag = 1;
}
static int
-remote_newthread_step (ref, context)
- threadref *ref;
- void *context;
+remote_newthread_step (threadref *ref, void *context)
{
int pid;
#define CRAZY_MAX_THREADS 1000
static int
-remote_current_thread (oldpid)
- int oldpid;
+remote_current_thread (int oldpid)
{
char *buf = alloca (PBUFSIZ);
*/
static void
-remote_find_new_threads ()
+remote_find_new_threads (void)
{
remote_threadlist_iterator (remote_newthread_step, 0,
CRAZY_MAX_THREADS);
/* Restart the remote side; this is an extended protocol operation. */
static void
-extended_remote_restart ()
+extended_remote_restart (void)
{
char *buf = alloca (PBUFSIZ);
/* ARGSUSED */
static void
-remote_close (quitting)
- int quitting;
+remote_close (int quitting)
{
if (remote_desc)
SERIAL_CLOSE (remote_desc);
/* Query the remote side for the text, data and bss offsets. */
static void
-get_offsets ()
+get_offsets (void)
{
char *buf = alloca (PBUFSIZ);
char *ptr;
*/
void
-remote_cisco_objfile_relocate (text_off, data_off, bss_off)
- bfd_signed_vma text_off;
- bfd_signed_vma data_off;
- bfd_signed_vma bss_off;
+remote_cisco_objfile_relocate (bfd_signed_vma text_off, bfd_signed_vma data_off,
+ bfd_signed_vma bss_off)
{
struct section_offsets *offs;
}
static int
-remote_start_remote (dummy)
- PTR dummy;
+remote_start_remote (PTR dummy)
{
immediate_quit = 1; /* Allow user to interrupt it */
NAME is the filename used for communication. */
static void
-remote_open (name, from_tty)
- char *name;
- int from_tty;
+remote_open (char *name, int from_tty)
{
remote_open_1 (name, from_tty, &remote_ops, 0);
}
/* Just like remote_open, but with asynchronous support. */
static void
-remote_async_open (name, from_tty)
- char *name;
- int from_tty;
+remote_async_open (char *name, int from_tty)
{
remote_async_open_1 (name, from_tty, &remote_async_ops, 0);
}
remote gdb protocol. NAME is the filename used for communication. */
static void
-extended_remote_open (name, from_tty)
- char *name;
- int from_tty;
+extended_remote_open (char *name, int from_tty)
{
remote_open_1 (name, from_tty, &extended_remote_ops, 1 /*extended_p */ );
}
/* Just like extended_remote_open, but with asynchronous support. */
static void
-extended_remote_async_open (name, from_tty)
- char *name;
- int from_tty;
+extended_remote_async_open (char *name, int from_tty)
{
remote_async_open_1 (name, from_tty, &extended_async_remote_ops, 1 /*extended_p */ );
}
static DCACHE *remote_dcache;
static void
-remote_open_1 (name, from_tty, target, extended_p)
- char *name;
- int from_tty;
- struct target_ops *target;
- int extended_p;
+remote_open_1 (char *name, int from_tty, struct target_ops *target,
+ int extended_p)
{
if (name == 0)
error ("To open a remote debug connection, you need to specify what\n\
/* Just like remote_open but with asynchronous support. */
static void
-remote_async_open_1 (name, from_tty, target, extended_p)
- char *name;
- int from_tty;
- struct target_ops *target;
- int extended_p;
+remote_async_open_1 (char *name, int from_tty, struct target_ops *target,
+ int extended_p)
{
if (name == 0)
error ("To open a remote debug connection, you need to specify what\n\
die when it hits one. */
static void
-remote_detach (args, from_tty)
- char *args;
- int from_tty;
+remote_detach (char *args, int from_tty)
{
char *buf = alloca (PBUFSIZ);
/* Same as remote_detach, but with async support. */
static void
-remote_async_detach (args, from_tty)
- char *args;
- int from_tty;
+remote_async_detach (char *args, int from_tty)
{
char *buf = alloca (PBUFSIZ);
/* Convert hex digit A to a number. */
int
-fromhex (a)
- int a;
+fromhex (int a)
{
if (a >= '0' && a <= '9')
return a - '0';
/* Convert number NIB to a hex digit. */
static int
-tohex (nib)
- int nib;
+tohex (int nib)
{
if (nib < 10)
return '0' + nib;
static int last_sent_step;
static void
-remote_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+remote_resume (int pid, int step, enum target_signal siggnal)
{
char *buf = alloca (PBUFSIZ);
/* Same as remote_resume, but with async support. */
static void
-remote_async_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+remote_async_resume (int pid, int step, enum target_signal siggnal)
{
char *buf = alloca (PBUFSIZ);
/* Set up the signal handler for SIGINT, while the target is
executing, ovewriting the 'regular' SIGINT signal handler. */
static void
-initialize_sigint_signal_handler ()
+initialize_sigint_signal_handler (void)
{
sigint_remote_token =
create_async_signal_handler (async_remote_interrupt, NULL);
/* Signal handler for SIGINT, while the target is executing. */
static void
-handle_remote_sigint (sig)
- int sig;
+handle_remote_sigint (int sig)
{
signal (sig, handle_remote_sigint_twice);
sigint_remote_twice_token =
sent once. It will take effect the second time that the user sends
a ^C. */
static void
-handle_remote_sigint_twice (sig)
- int sig;
+handle_remote_sigint_twice (int sig)
{
signal (sig, handle_sigint);
sigint_remote_twice_token =
/* Perform the real interruption of the target execution, in response
to a ^C. */
static void
-async_remote_interrupt (arg)
- gdb_client_data arg;
+async_remote_interrupt (gdb_client_data arg)
{
if (remote_debug)
fprintf_unfiltered (gdb_stdlog, "remote_interrupt called\n");
/* Perform interrupt, if the first attempt did not succeed. Just give
up on the target alltogether. */
void
-async_remote_interrupt_twice (arg)
- gdb_client_data arg;
+async_remote_interrupt_twice (gdb_client_data arg)
{
if (remote_debug)
fprintf_unfiltered (gdb_stdlog, "remote_interrupt_twice called\n");
response from the target (it didn't stop when the user requested it),
we ask the user if he'd like to detach from the target. */
static void
-remote_interrupt (signo)
- int signo;
+remote_interrupt (int signo)
{
/* If this doesn't work, try more severe steps. */
signal (signo, remote_interrupt_twice);
/* The user typed ^C twice. */
static void
-remote_interrupt_twice (signo)
- int signo;
+remote_interrupt_twice (int signo)
{
signal (signo, ofunc);
interrupt_query ();
interrupt is requested, either by the command line or the GUI, we
will eventually end up here. */
static void
-remote_stop ()
+remote_stop (void)
{
/* Send a break or a ^C, depending on user preference. */
if (remote_debug)
/* Ask the user what to do when an interrupt is received. */
static void
-interrupt_query ()
+interrupt_query (void)
{
target_terminal_ours ();
remote OS, is the thread-id. */
static int
-remote_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+remote_wait (int pid, struct target_waitstatus *status)
{
unsigned char *buf = alloca (PBUFSIZ);
int thread_num = -1;
/* Async version of remote_wait. */
static int
-remote_async_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+remote_async_wait (int pid, struct target_waitstatus *status)
{
unsigned char *buf = alloca (PBUFSIZ);
int thread_num = -1;
/* ARGSUSED */
static void
-remote_fetch_registers (regno)
- int regno;
+remote_fetch_registers (int regno)
{
char *buf = alloca (PBUFSIZ);
int i;
first. */
static void
-remote_prepare_to_store ()
+remote_prepare_to_store (void)
{
/* Make sure the entire registers array is valid. */
switch (remote_protocol_P.support)
of REGISTERS. FIXME: ignores errors. */
static void
-remote_store_registers (regno)
- int regno;
+remote_store_registers (int regno)
{
char *buf = alloca (PBUFSIZ);
int i;
/* Return the number of hex digits in num. */
static int
-hexnumlen (num)
- ULONGEST num;
+hexnumlen (ULONGEST num)
{
int i;
/* Set BUF to the minimum number of hex digits representing NUM. */
static int
-hexnumstr (buf, num)
- char *buf;
- ULONGEST num;
+hexnumstr (char *buf, ULONGEST num)
{
int len = hexnumlen (num);
return hexnumnstr (buf, num, len);
/* Set BUF to the hex digits representing NUM, padded to WIDTH characters. */
static int
-hexnumnstr (buf, num, width)
- char *buf;
- ULONGEST num;
- int width;
+hexnumnstr (char *buf, ULONGEST num, int width)
{
int i;
/* Mask all but the least significant REMOTE_ADDRESS_SIZE bits. */
static CORE_ADDR
-remote_address_masked (addr)
- CORE_ADDR addr;
+remote_address_masked (CORE_ADDR addr)
{
if (remote_address_size > 0
&& remote_address_size < (sizeof (ULONGEST) * 8))
X-packet". */
static void
-check_binary_download (addr)
- CORE_ADDR addr;
+check_binary_download (CORE_ADDR addr)
{
switch (remote_protocol_binary_download.support)
{
handling partial reads. */
static int
-remote_read_bytes (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+remote_read_bytes (CORE_ADDR memaddr, char *myaddr, int len)
{
char *buf;
int max_buf_size; /* Max size of packet output buffer */
#endif /* 0 */
\f
static void
-remote_files_info (ignore)
- struct target_ops *ignore;
+remote_files_info (struct target_ops *ignore)
{
puts_filtered ("Debugging a target over a serial line.\n");
}
/* Read a single character from the remote end, masking it down to 7 bits. */
static int
-readchar (timeout)
- int timeout;
+readchar (int timeout)
{
int ch;
string notation. */
static void
-print_packet (buf)
- char *buf;
+print_packet (char *buf)
{
puts_filtered ("\"");
fputstr_filtered (buf, '"', gdb_stdout);
}
int
-putpkt (buf)
- char *buf;
+putpkt (char *buf)
{
return putpkt_binary (buf, strlen (buf));
}
debugging (remote_debug) and want to print the sent packet as a string */
static int
-putpkt_binary (buf, cnt)
- char *buf;
- int cnt;
+putpkt_binary (char *buf, int cnt)
{
int i;
unsigned char csum = 0;
}
\f
static void
-remote_kill ()
+remote_kill (void)
{
/* For some mysterious reason, wait_for_inferior calls kill instead of
mourn after it gets TARGET_WAITKIND_SIGNALLED. Work around it. */
/* Async version of remote_kill. */
static void
-remote_async_kill ()
+remote_async_kill (void)
{
/* Unregister the file descriptor from the event loop. */
if (target_is_async_p ())
}
static void
-remote_mourn ()
+remote_mourn (void)
{
remote_mourn_1 (&remote_ops);
}
static void
-remote_async_mourn ()
+remote_async_mourn (void)
{
remote_mourn_1 (&remote_async_ops);
}
static void
-extended_remote_mourn ()
+extended_remote_mourn (void)
{
/* We do _not_ want to mourn the target like this; this will
remove the extended remote target from the target stack,
/* Worker function for remote_mourn. */
static void
-remote_mourn_1 (target)
- struct target_ops *target;
+remote_mourn_1 (struct target_ops *target)
{
unpush_target (target);
generic_mourn_inferior ();
we're debugging, arguments and an environment. */
static void
-extended_remote_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+extended_remote_create_inferior (char *exec_file, char *args, char **env)
{
/* Rip out the breakpoints; we'll reinsert them after restarting
the remote server. */
/* Async version of extended_remote_create_inferior. */
static void
-extended_remote_async_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+extended_remote_async_create_inferior (char *exec_file, char *args, char **env)
{
/* Rip out the breakpoints; we'll reinsert them after restarting
the remote server. */
is accomplished via BREAKPOINT_MAX). */
static int
-remote_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+remote_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
#ifdef REMOTE_BREAKPOINT
int val;
}
static int
-remote_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+remote_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
int bp_size;
#ifdef TARGET_HAS_HARDWARE_WATCHPOINTS
int
-remote_insert_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+remote_insert_watchpoint (CORE_ADDR addr, int len, int type)
{
char *buf = alloca (PBUFSIZ);
char *p;
}
int
-remote_remove_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+remote_remove_watchpoint (CORE_ADDR addr, int len, int type)
{
char *buf = alloca (PBUFSIZ);
char *p;
}
int
-remote_insert_hw_breakpoint (addr, len)
- CORE_ADDR addr;
- int len;
+remote_insert_hw_breakpoint (CORE_ADDR addr, int len)
{
char *buf = alloca (PBUFSIZ);
char *p = buf;
}
int
-remote_remove_hw_breakpoint (addr, len)
- CORE_ADDR addr;
- int len;
+remote_remove_hw_breakpoint (CORE_ADDR addr, int len)
{
char *buf = alloca (PBUFSIZ);
char *p = buf;
already..." message. Usually a call to pop_target() suffices. */
void
-push_remote_target (name, from_tty)
- char *name;
- int from_tty;
+push_remote_target (char *name, int from_tty)
{
printf_filtered ("Switching to remote protocol\n");
remote_open (name, from_tty);
certain remote_ops overridden. */
void
-open_remote_target (name, from_tty, target, extended_p)
- char *name;
- int from_tty;
- struct target_ops *target;
- int extended_p;
+open_remote_target (char *name, int from_tty, struct target_ops *target,
+ int extended_p)
{
printf_filtered ("Selecting the %sremote protocol\n",
(extended_p ? "extended-" : ""));
{0, 0};
static unsigned long
-crc32 (buf, len, crc)
- unsigned char *buf;
- int len;
- unsigned int crc;
+crc32 (unsigned char *buf, int len, unsigned int crc)
{
if (!crc32_table[1])
{
generic_load()) to make use of this target functionality. */
static void
-compare_sections_command (args, from_tty)
- char *args;
- int from_tty;
+compare_sections_command (char *args, int from_tty)
{
asection *s;
unsigned long host_crc, target_crc;
}
static int
-remote_query (query_type, buf, outbuf, bufsiz)
- int query_type;
- char *buf;
- char *outbuf;
- int *bufsiz;
+remote_query (int query_type, char *buf, char *outbuf, int *bufsiz)
{
int i;
char *buf2 = alloca (PBUFSIZ);
}
static void
-packet_command (args, from_tty)
- char *args;
- int from_tty;
+packet_command (char *args, int from_tty)
{
char *buf = alloca (PBUFSIZ);
#define SAMPLE_THREAD 0x05060708 /* Truncated 64 bit threadid */
static void
-threadset_test_cmd (cmd, tty)
- char *cmd;
- int tty;
+threadset_test_cmd (char *cmd, int tty)
{
int sample_thread = SAMPLE_THREAD;
static void
-threadalive_test (cmd, tty)
- char *cmd;
- int tty;
+threadalive_test (char *cmd, int tty)
{
int sample_thread = SAMPLE_THREAD;
void output_threadid (char *title, threadref * ref);
void
-output_threadid (title, ref)
- char *title;
- threadref *ref;
+output_threadid (char *title, threadref *ref)
{
char hexid[20];
}
static void
-threadlist_test_cmd (cmd, tty)
- char *cmd;
- int tty;
+threadlist_test_cmd (char *cmd, int tty)
{
int startflag = 1;
threadref nextthread;
}
void
-display_thread_info (info)
- struct gdb_ext_thread_info *info;
+display_thread_info (struct gdb_ext_thread_info *info)
{
output_threadid ("Threadid: ", &info->threadid);
printf_filtered ("Name: %s\n ", info->shortname);
}
int
-get_and_display_threadinfo (ref)
- threadref *ref;
+get_and_display_threadinfo (threadref *ref)
{
int result;
int set;
}
static void
-threadinfo_test_cmd (cmd, tty)
- char *cmd;
- int tty;
+threadinfo_test_cmd (char *cmd, int tty)
{
int athread = SAMPLE_THREAD;
threadref thread;
}
static int
-thread_display_step (ref, context)
- threadref *ref;
- void *context;
+thread_display_step (threadref *ref, void *context)
{
/* output_threadid(" threadstep ",ref); *//* simple test */
return get_and_display_threadinfo (ref);
}
static void
-threadlist_update_test_cmd (cmd, tty)
- char *cmd;
- int tty;
+threadlist_update_test_cmd (char *cmd, int tty)
{
printf_filtered ("Remote Threadlist update test\n");
remote_threadlist_iterator (thread_display_step, 0, CRAZY_MAX_THREADS);
#endif /* 0 */
static void
-init_remote_ops ()
+init_remote_ops (void)
{
remote_ops.to_shortname = "remote";
remote_ops.to_longname = "Remote serial target in gdb-specific protocol";
remote vector and adding to it. */
static void
-init_extended_remote_ops ()
+init_extended_remote_ops (void)
{
extended_remote_ops = remote_ops;
}
static void
-init_remote_cisco_ops ()
+init_remote_cisco_ops (void)
{
remote_cisco_ops.to_shortname = "cisco";
remote_cisco_ops.to_longname = "Remote serial target in cisco-specific protocol";
static void
-build_remote_gdbarch_data ()
+build_remote_gdbarch_data (void)
{
build_remote_packet_sizes ();
}
void
-_initialize_remote ()
+_initialize_remote (void)
{
static struct cmd_list_element *remote_set_cmdlist;
static struct cmd_list_element *remote_show_cmdlist;
static void rom68k_open (char *args, int from_tty);
static void
-rom68k_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+rom68k_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int numregs;
int regno;
} /* init_rom68k_cmds */
static void
-rom68k_open (args, from_tty)
- char *args;
- int from_tty;
+rom68k_open (char *args, int from_tty)
{
monitor_open (args, &rom68k_cmds, from_tty);
}
void
-_initialize_rom68k ()
+_initialize_rom68k (void)
{
init_rom68k_cmds ();
init_monitor_ops (&rom68k_ops);
of data in register N. */
static struct type *
-rs6000_register_virtual_type (n)
+rs6000_register_virtual_type (int n)
{
struct gdbarch_tdep *tdep = TDEP;
const struct reg *reg = tdep->regs + n;
/* Initialization code. */
void
-_initialize_rs6000_tdep ()
+_initialize_rs6000_tdep (void)
{
register_gdbarch_init (bfd_arch_rs6000, rs6000_gdbarch_init);
register_gdbarch_init (bfd_arch_powerpc, rs6000_gdbarch_init);
static void scm_lreadr (int);
static LONGEST
-scm_istr2int (str, len, radix)
- char *str;
- int len;
- int radix;
+scm_istr2int (char *str, int len, int radix)
{
int i = 0;
LONGEST inum = 0;
}
static LONGEST
-scm_istring2number (str, len, radix)
- char *str;
- int len;
- int radix;
+scm_istring2number (char *str, int len, int radix)
{
int i = 0;
char ex = 0;
}
static void
-scm_read_token (c, weird)
- int c;
- int weird;
+scm_read_token (int c, int weird)
{
while (1)
{
}
static int
-scm_skip_ws ()
+scm_skip_ws (void)
{
register int c;
while (1)
}
static void
-scm_lreadparen (skipping)
- int skipping;
+scm_lreadparen (int skipping)
{
for (;;)
{
}
static void
-scm_lreadr (skipping)
- int skipping;
+scm_lreadr (int skipping)
{
int c, j;
struct stoken str;
}
int
-scm_parse ()
+scm_parse (void)
{
char *start;
while (*lexptr == ' ')
struct type *builtin_type_scm;
void
-scm_printchar (c, stream)
- int c;
- struct ui_file *stream;
+scm_printchar (int c, struct ui_file *stream)
{
fprintf_filtered (stream, "#\\%c", c);
}
static void
-scm_printstr (stream, string, length, width, force_ellipses)
- struct ui_file *stream;
- char *string;
- unsigned int length;
- int width;
- int force_ellipses;
+scm_printstr (struct ui_file *stream, char *string, unsigned int length,
+ int width, int force_ellipses)
{
fprintf_filtered (stream, "\"%s\"", string);
}
int
-is_scmvalue_type (type)
- struct type *type;
+is_scmvalue_type (struct type *type)
{
if (TYPE_CODE (type) == TYPE_CODE_INT
&& TYPE_NAME (type) && strcmp (TYPE_NAME (type), "SCM") == 0)
of the 0'th one. */
LONGEST
-scm_get_field (svalue, index)
- LONGEST svalue;
- int index;
+scm_get_field (LONGEST svalue, int index)
{
char buffer[20];
read_memory (SCM2PTR (svalue) + index * TYPE_LENGTH (builtin_type_scm),
or Boolean (CONTEXT == TYPE_CODE_BOOL). */
LONGEST
-scm_unpack (type, valaddr, context)
- struct type *type;
- char *valaddr;
- enum type_code context;
+scm_unpack (struct type *type, char *valaddr, enum type_code context)
{
if (is_scmvalue_type (type))
{
/* True if we're correctly in Guile's eval.c (the evaluator and apply). */
static int
-in_eval_c ()
+in_eval_c (void)
{
if (current_source_symtab && current_source_symtab->filename)
{
function), then try lookup_symbol for compiled variables. */
static value_ptr
-scm_lookup_name (str)
- char *str;
+scm_lookup_name (char *str)
{
value_ptr args[3];
int len = strlen (str);
}
value_ptr
-scm_evaluate_string (str, len)
- char *str;
- int len;
+scm_evaluate_string (char *str, int len)
{
value_ptr func;
value_ptr addr = value_allocate_space_in_inferior (len + 1);
}
static value_ptr
-evaluate_subexp_scm (expect_type, exp, pos, noside)
- struct type *expect_type;
- register struct expression *exp;
- register int *pos;
- enum noside noside;
+evaluate_subexp_scm (struct type *expect_type, register struct expression *exp,
+ register int *pos, enum noside noside)
{
enum exp_opcode op = exp->elts[*pos].opcode;
int len, pc;
};
void
-_initialize_scheme_language ()
+_initialize_scheme_language (void)
{
add_language (&scm_language_defn);
builtin_type_scm = init_type (TYPE_CODE_INT,
print VALUE. */
static int
-scm_inferior_print (value, stream, format, deref_ref, recurse, pretty)
- LONGEST value;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+scm_inferior_print (LONGEST value, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
return -1;
}
};
static void
-scm_scmlist_print (svalue, stream, format, deref_ref, recurse, pretty)
- LONGEST svalue;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+scm_scmlist_print (LONGEST svalue, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
unsigned int more = print_max;
if (recurse > 6)
}
static void
-scm_ipruk (hdr, ptr, stream)
- char *hdr;
- LONGEST ptr;
- struct ui_file *stream;
+scm_ipruk (char *hdr, LONGEST ptr, struct ui_file *stream)
{
fprintf_filtered (stream, "#<unknown-%s", hdr);
#define SCM_SIZE TYPE_LENGTH (builtin_type_scm)
}
void
-scm_scmval_print (svalue, stream, format, deref_ref, recurse, pretty)
- LONGEST svalue;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+scm_scmval_print (LONGEST svalue, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
taloop:
switch (7 & (int) svalue)
}
int
-scm_val_print (type, valaddr, embedded_offset, address,
- stream, format, deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+scm_val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format,
+ int deref_ref, int recurse, enum val_prettyprint pretty)
{
if (is_scmvalue_type (type))
{
}
int
-scm_value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+scm_value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
return (val_print (VALUE_TYPE (val), VALUE_CONTENTS (val), 0,
VALUE_ADDRESS (val), stream, format, 1, 0, pretty));
#endif /* _MSC_VER */
static int
-e7000pc_init ()
+e7000pc_init (void)
{
int try;
unsigned long dsbase;
that TIMEOUT == 0 is a poll, and TIMEOUT == -1 means wait forever. */
static int
-dosasync_read (fd, buf, len, timeout)
- int fd;
- char *buf;
- int len;
- int timeout;
-
+dosasync_read (int fd, char *buf, int len, int timeout)
{
long now;
long then;
static int
-dosasync_write (fd, buf, len)
- int fd;
- const char *buf;
- int len;
+dosasync_write (int fd, const char *buf, int len)
{
int i;
char dummy[1000];
}
static int
-e7000pc_open (scb, name)
- serial_t scb;
- const char *name;
+e7000pc_open (serial_t scb, const char *name)
{
if (strncasecmp (name, "pc", 2) != 0)
{
}
static int
-e7000pc_noop (scb)
- serial_t scb;
+e7000pc_noop (serial_t scb)
{
return 0;
}
static void
-e7000pc_raw (scb)
- serial_t scb;
+e7000pc_raw (serial_t scb)
{
/* Always in raw mode */
}
static int
-e7000pc_readchar (scb, timeout)
- serial_t scb;
- int timeout;
+e7000pc_readchar (serial_t scb, int timeout)
{
char buf;
vector. Someday, they may do something real... */
static serial_ttystate
-e7000pc_get_tty_state (scb)
- serial_t scb;
+e7000pc_get_tty_state (serial_t scb)
{
struct e7000pc_ttystate *state;
}
static int
-e7000pc_set_tty_state (scb, ttystate)
- serial_t scb;
- serial_ttystate ttystate;
+e7000pc_set_tty_state (serial_t scb, serial_ttystate ttystate)
{
return 0;
}
static int
-e7000pc_noflush_set_tty_state (scb, new_ttystate, old_ttystate)
- serial_t scb;
- serial_ttystate new_ttystate;
- serial_ttystate old_ttystate;
+e7000pc_noflush_set_tty_state (serial_t scb, serial_ttystate new_ttystate,
+ serial_ttystate old_ttystate)
{
return 0;
}
}
static int
-e7000pc_setbaudrate (scb, rate)
- serial_t scb;
- int rate;
+e7000pc_setbaudrate (serial_t scb, int rate)
{
return 0;
}
static int
-e7000pc_write (scb, str, len)
- serial_t scb;
- const char *str;
- int len;
+e7000pc_write (serial_t scb, const char *str, int len)
{
dosasync_write (scb->fd, str, len);
}
static void
-e7000pc_close (scb)
- serial_t scb;
+e7000pc_close (serial_t scb)
{
}
};
void
-_initialize_ser_e7000pc ()
+_initialize_ser_e7000pc (void)
{
serial_add_interface (&e7000pc_ops);
}
#else
void
-_initialize_ser_e7000pc ()
+_initialize_ser_e7000pc (void)
{
}
static int
-dos_getc (port)
- volatile struct dos_ttystate *port;
+dos_getc (volatile struct dos_ttystate *port)
{
int c;
static int
-dos_putc (c, port)
- int c;
- struct dos_ttystate *port;
+dos_putc (int c, struct dos_ttystate *port)
{
if (port->count >= CBSIZE - 1)
return -1;
static void
-dos_comisr (irq)
- int irq;
+dos_comisr (int irq)
{
struct dos_ttystate *port;
unsigned char iir, lsr, c;
static void
-dos_unhookirq (intr)
- struct intrupt *intr;
+dos_unhookirq (struct intrupt *intr)
{
unsigned int irq, vec;
unsigned char mask;
static int
-dos_open (scb, name)
- serial_t scb;
- const char *name;
+dos_open (serial_t scb, const char *name)
{
struct dos_ttystate *port;
int fd, i;
static void
-dos_close (scb)
- serial_t scb;
+dos_close (serial_t scb)
{
struct dos_ttystate *port;
struct intrupt *intrupt;
}
static int
-dos_readchar (scb, timeout)
- serial_t scb;
- int timeout;
+dos_readchar (serial_t scb, int timeout)
{
struct dos_ttystate *port = &ports[scb->fd];
long then;
static serial_ttystate
-dos_get_tty_state (scb)
- serial_t scb;
+dos_get_tty_state (serial_t scb)
{
struct dos_ttystate *port = &ports[scb->fd];
struct dos_ttystate *state;
}
static int
-dos_set_tty_state (scb, ttystate)
- serial_t scb;
- serial_ttystate ttystate;
+dos_set_tty_state (serial_t scb, serial_ttystate ttystate)
{
struct dos_ttystate *state;
}
static int
-dos_flush_input (scb)
- serial_t scb;
+dos_flush_input (serial_t scb)
{
struct dos_ttystate *port = &ports[scb->fd];
disable ();
}
static int
-dos_baudconv (rate)
- int rate;
+dos_baudconv (int rate)
{
long x, err;
static int
-dos_setbaudrate (scb, rate)
- serial_t scb;
- int rate;
+dos_setbaudrate (serial_t scb, int rate)
{
struct dos_ttystate *port = &ports[scb->fd];
}
static int
-dos_setstopbits (scb, num)
- serial_t scb;
- int num;
+dos_setstopbits (serial_t scb, int num)
{
struct dos_ttystate *port = &ports[scb->fd];
unsigned char cfcr;
}
static int
-dos_write (scb, str, len)
- serial_t scb;
- const char *str;
- int len;
+dos_write (serial_t scb, const char *str, int len)
{
volatile struct dos_ttystate *port = &ports[scb->fd];
int fifosize = port->fifo ? 16 : 1;
static int
-dos_sendbreak (scb)
- serial_t scb;
+dos_sendbreak (serial_t scb)
{
volatile struct dos_ttystate *port = &ports[scb->fd];
unsigned char cfcr;
void
-_initialize_ser_dos ()
+_initialize_ser_dos (void)
{
serial_add_interface (&dos_ops);
char *mac_output_buffer;
static int
-mac_open (scb, name)
- serial_t scb;
- const char *name;
+mac_open (serial_t scb, const char *name)
{
OSErr err;
}
static int
-mac_noop (scb)
- serial_t scb;
+mac_noop (serial_t scb)
{
return 0;
}
static void
-mac_raw (scb)
- serial_t scb;
+mac_raw (serial_t scb)
{
/* Always effectively in raw mode. */
}
dead, or -3 for any other error (see errno in that case). */
static int
-mac_readchar (scb, timeout)
- serial_t scb;
- int timeout;
+mac_readchar (serial_t scb, int timeout)
{
int status, n;
/* time_t */ unsigned long start_time, now;
vector. Someday, they may do something real... */
static serial_ttystate
-mac_get_tty_state (scb)
- serial_t scb;
+mac_get_tty_state (serial_t scb)
{
struct mac_ttystate *state;
}
static int
-mac_set_tty_state (scb, ttystate)
- serial_t scb;
- serial_ttystate ttystate;
+mac_set_tty_state (serial_t scb, serial_ttystate ttystate)
{
return 0;
}
static int
-mac_noflush_set_tty_state (scb, new_ttystate, old_ttystate)
- serial_t scb;
- serial_ttystate new_ttystate;
- serial_ttystate old_ttystate;
+mac_noflush_set_tty_state (serial_t scb, serial_ttystate new_ttystate,
+ serial_ttystate old_ttystate)
{
return 0;
}
};
static int
-mac_set_baud_rate (scb, rate)
- serial_t scb;
- int rate;
+mac_set_baud_rate (serial_t scb, int rate)
{
int i, bits;
}
static int
-mac_set_stop_bits (scb, num)
- serial_t scb;
- int num;
+mac_set_stop_bits (serial_t scb, int num)
{
return 0;
}
int first_mac_write = 0;
static int
-mac_write (scb, str, len)
- serial_t scb;
- const char *str;
- int len;
+mac_write (serial_t scb, const char *str, int len)
{
OSErr err;
IOParam pb;
};
void
-_initialize_ser_mac ()
+_initialize_ser_mac (void)
{
serial_add_interface (&mac_ops);
}
#endif
static int
-ocd_open (scb, name)
- serial_t scb;
- const char *name;
+ocd_open (serial_t scb, const char *name)
{
#ifdef _WIN32
/* Find the wiggler DLL which talks to the board. */
}
static int
-ocd_noop (scb)
- serial_t scb;
+ocd_noop (serial_t scb)
{
return 0;
}
static void
-ocd_raw (scb)
- serial_t scb;
+ocd_raw (serial_t scb)
{
/* Always in raw mode */
}
unsigned char *wiggler_buffer_ptr; /* curr spot in buffer */
static int
-ocd_readchar (scb, timeout)
- serial_t scb;
- int timeout;
+ocd_readchar (serial_t scb, int timeout)
{
/* Catch attempts at reading past the end of the buffer */
if (wiggler_buffer_ptr >
vector. Someday, they may do something real... */
static serial_ttystate
-ocd_get_tty_state (scb)
- serial_t scb;
+ocd_get_tty_state (serial_t scb)
{
struct ocd_ttystate *state;
}
static int
-ocd_set_tty_state (scb, ttystate)
- serial_t scb;
- serial_ttystate ttystate;
+ocd_set_tty_state (serial_t scb, serial_ttystate ttystate)
{
return 0;
}
static int
-ocd_noflush_set_tty_state (scb, new_ttystate, old_ttystate)
- serial_t scb;
- serial_ttystate new_ttystate;
- serial_ttystate old_ttystate;
+ocd_noflush_set_tty_state (serial_t scb, serial_ttystate new_ttystate,
+ serial_ttystate old_ttystate)
{
return 0;
}
}
static int
-ocd_setbaudrate (scb, rate)
- serial_t scb;
- int rate;
+ocd_setbaudrate (serial_t scb, int rate)
{
return 0;
}
static int
-ocd_write (scb, str, len)
- serial_t scb;
- const char *str;
- int len;
+ocd_write (serial_t scb, const char *str, int len)
{
#ifdef _WIN32
/* send packet to Wigglers.dll and store response so we can give it to
}
static void
-ocd_close (scb)
- serial_t scb;
+ocd_close (serial_t scb)
{
}
};
void
-_initialize_ser_ocd_bdm ()
+_initialize_ser_ocd_bdm (void)
{
serial_add_interface (&ocd_ops);
}
}
static int
-hardwire_setstopbits (scb, num)
- serial_t scb;
- int num;
+hardwire_setstopbits (serial_t scb, int num)
{
struct hardwire_ttystate state;
int newbit;
/* scan for the sequence $<data>#<checksum> */
char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
}
void
-gdb_mode()
+gdb_mode (void)
{
ingdbmode = GDBCOOKIE;
breakpoint();
static void
-exceptions()
+exceptions (void)
{
code_for_catch_exception (CPU_BUS_ERROR_VEC);
code_for_catch_exception (DMA_BUS_ERROR_VEC);
void handleError (char theSSR);
void
-nop ()
+nop (void)
{
}
void
-init_serial()
+init_serial (void)
{
int i;
}
int
-putDebugCharReady()
+putDebugCharReady (void)
{
return (SSR1 & SCI_TDRE);
}
}
static unsigned char *
-sh_breakpoint_from_pc (pcptr, lenptr)
- CORE_ADDR *pcptr;
- int *lenptr;
+sh_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
{
/* 0xc3c3 is trapa #c3, and it works in big and little endian modes */
static unsigned char breakpoint[] = {0xc3, 0xc3};
/* Skip the prologue using the debug information. If this fails we'll
fall back on the 'guess' method below. */
static CORE_ADDR
-after_prologue (pc)
- CORE_ADDR pc;
+after_prologue (CORE_ADDR pc)
{
struct symtab_and_line sal;
CORE_ADDR func_addr, func_end;
where the prologue ends. Unfortunately this is not always
accurate. */
static CORE_ADDR
-skip_prologue_hard_way (start_pc)
- CORE_ADDR start_pc;
+skip_prologue_hard_way (CORE_ADDR start_pc)
{
CORE_ADDR here, end;
int updated_fp = 0;
}
static CORE_ADDR
-sh_skip_prologue (pc)
- CORE_ADDR pc;
+sh_skip_prologue (CORE_ADDR pc)
{
CORE_ADDR post_prologue_pc;
The return address is the value saved in the PR register + 4 */
static CORE_ADDR
-sh_saved_pc_after_call (frame)
- struct frame_info *frame;
+sh_saved_pc_after_call (struct frame_info *frame)
{
return (ADDR_BITS_REMOVE(read_register(PR_REGNUM)));
}
/* Should call_function allocate stack space for a struct return? */
static int
-sh_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+sh_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_LENGTH (type) > 1);
}
We store structs through a pointer passed in R0 */
static void
-sh_store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+sh_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
write_register (STRUCT_RETURN_REGNUM, (addr));
}
/* Disassemble an instruction. */
static int
-gdb_print_insn_sh (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_sh (bfd_vma memaddr, disassemble_info *info)
{
if (TARGET_BYTE_ORDER == BIG_ENDIAN)
return print_insn_sh (memaddr, info);
For us, the frame address is its stack pointer value, so we look up
the function prologue to determine the caller's sp value, and return it. */
static CORE_ADDR
-sh_frame_chain (frame)
- struct frame_info *frame;
+sh_frame_chain (struct frame_info *frame)
{
if (PC_IN_CALL_DUMMY (frame->pc, frame->frame, frame->frame))
return frame->frame; /* dummy frame same as caller's frame */
caller-saves registers for an inner frame. */
static CORE_ADDR
-sh_find_callers_reg (fi, regnum)
- struct frame_info *fi;
- int regnum;
+sh_find_callers_reg (struct frame_info *fi, int regnum)
{
for (; fi; fi = fi->next)
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
ways in the stack frame. sp is even more special: the address we
return for it IS the sp for the next frame. */
static void
-sh_nofp_frame_init_saved_regs (fi)
- struct frame_info *fi;
+sh_nofp_frame_init_saved_regs (struct frame_info *fi)
{
int where[NUM_REGS];
int rn;
}
static void
-sh_fp_frame_init_saved_regs (fi)
- struct frame_info *fi;
+sh_fp_frame_init_saved_regs (struct frame_info *fi)
{
int where[NUM_REGS];
int rn;
/* Initialize the extra info saved in a FRAME */
static void
-sh_init_extra_frame_info (fromleaf, fi)
- int fromleaf;
- struct frame_info *fi;
+sh_init_extra_frame_info (int fromleaf, struct frame_info *fi)
{
fi->extra_info = (struct frame_extra_info *)
}
static CORE_ADDR
-sh_frame_saved_pc (frame)
- struct frame_info *frame;
+sh_frame_saved_pc (struct frame_info *frame)
{
return ((frame)->extra_info->return_pc);
}
static CORE_ADDR
-sh_frame_args_address (fi)
- struct frame_info *fi;
+sh_frame_args_address (struct frame_info *fi)
{
return (fi)->frame;
}
static CORE_ADDR
-sh_frame_locals_address (fi)
- struct frame_info *fi;
+sh_frame_locals_address (struct frame_info *fi)
{
return (fi)->frame;
}
/* Discard from the stack the innermost frame,
restoring all saved registers. */
static void
-sh_pop_frame ()
+sh_pop_frame (void)
{
register struct frame_info *frame = get_current_frame ();
register CORE_ADDR fp;
to R7. */
static CORE_ADDR
-sh_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+sh_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int stack_offset, stack_alloc;
int argreg;
Needed for targets where we don't actually execute a JSR/BSR instruction */
static CORE_ADDR
-sh_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+sh_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
write_register (PR_REGNUM, CALL_DUMMY_ADDRESS ());
return sp;
#if 0
void
-sh_fix_call_dummy (dummy, pc, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR pc;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+sh_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
+ value_ptr *args, struct type *type, int gcc_p)
{
*(unsigned long *) (dummy + 8) = fun;
}
containing the (raw) register state a function return value of type
TYPE, and copy that, in virtual format, into VALBUF. */
static void
-sh_extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+sh_extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
int len = TYPE_LENGTH (type);
/* Print the registers in a form similar to the E7000 */
static void
-sh_generic_show_regs ()
+sh_generic_show_regs (void)
{
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
paddr (read_register (PC_REGNUM)),
}
static void
-sh3_show_regs ()
+sh3_show_regs (void)
{
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
paddr (read_register (PC_REGNUM)),
static void
-sh3e_show_regs ()
+sh3e_show_regs (void)
{
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
paddr (read_register (PC_REGNUM)),
}
static void
-sh3_dsp_show_regs ()
+sh3_dsp_show_regs (void)
{
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
paddr (read_register (PC_REGNUM)),
}
static void
-sh4_show_regs ()
+sh4_show_regs (void)
{
int pr = read_register (gdbarch_tdep (current_gdbarch)->FPSCR_REGNUM) & 0x80000;
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
}
static void
-sh_dsp_show_regs ()
+sh_dsp_show_regs (void)
{
printf_filtered ("PC=%s SR=%08lx PR=%08lx MACH=%08lx MACHL=%08lx\n",
paddr (read_register (PC_REGNUM)),
/* Index within `registers' of the first byte of the space for
register N. */
static int
-sh_default_register_byte (reg_nr)
- int reg_nr;
+sh_default_register_byte (int reg_nr)
{
return (reg_nr * 4);
}
static int
-sh_sh4_register_byte (reg_nr)
- int reg_nr;
+sh_sh4_register_byte (int reg_nr)
{
if (reg_nr >= gdbarch_tdep (current_gdbarch)->DR0_REGNUM
&& reg_nr <= gdbarch_tdep (current_gdbarch)->DR14_REGNUM)
/* Number of bytes of storage in the actual machine representation for
register REG_NR. */
static int
-sh_default_register_raw_size (reg_nr)
- int reg_nr;
+sh_default_register_raw_size (int reg_nr)
{
return 4;
}
static int
-sh_sh4_register_raw_size (reg_nr)
- int reg_nr;
+sh_sh4_register_raw_size (int reg_nr)
{
if (reg_nr >= gdbarch_tdep (current_gdbarch)->DR0_REGNUM
&& reg_nr <= gdbarch_tdep (current_gdbarch)->DR14_REGNUM)
/* Number of bytes of storage in the program's representation
for register N. */
static int
-sh_register_virtual_size (reg_nr)
- int reg_nr;
+sh_register_virtual_size (int reg_nr)
{
return 4;
}
of data in register N. */
static struct type *
-sh_sh3e_register_virtual_type (reg_nr)
- int reg_nr;
+sh_sh3e_register_virtual_type (int reg_nr)
{
if ((reg_nr >= FP0_REGNUM
&& (reg_nr <= gdbarch_tdep (current_gdbarch)->FP15_REGNUM))
}
static struct type *
-sh_sh4_register_virtual_type (reg_nr)
- int reg_nr;
+sh_sh4_register_virtual_type (int reg_nr)
{
if ((reg_nr >= FP0_REGNUM
&& (reg_nr <= gdbarch_tdep (current_gdbarch)->FP15_REGNUM))
}
static struct type *
-sh_default_register_virtual_type (reg_nr)
- int reg_nr;
+sh_default_register_virtual_type (int reg_nr)
{
return builtin_type_int;
}
static gdbarch_init_ftype sh_gdbarch_init;
static struct gdbarch *
-sh_gdbarch_init (info, arches)
- struct gdbarch_info info;
- struct gdbarch_list *arches;
+sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
{
static LONGEST sh_call_dummy_words[] = {0};
struct gdbarch *gdbarch;
}
void
-_initialize_sh_tdep ()
+_initialize_sh_tdep (void)
{
struct cmd_list_element *c;
static void sh3_open (char *args, int from_tty);
static void
-sh3_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+sh3_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int numregs;
int regno;
}
static void
-sh3_load (desc, file, hashmark)
- serial_t desc;
- char *file;
- int hashmark;
+sh3_load (serial_t desc, char *file, int hashmark)
{
if (parallel_in_use)
{
static struct monitor_ops sh3e_cmds;
static void
-sh3_open (args, from_tty)
- char *args;
- int from_tty;
+sh3_open (char *args, int from_tty)
{
char *serial_port_name = args;
char *parallel_port_name = 0;
static void
-sh3e_open (args, from_tty)
- char *args;
- int from_tty;
+sh3e_open (char *args, int from_tty)
{
char *serial_port_name = args;
char *parallel_port_name = 0;
}
static void
-sh3_close (quitting)
- int quitting;
+sh3_close (int quitting)
{
monitor_close (quitting);
if (parallel_in_use)
}
void
-_initialize_sh3_rom ()
+_initialize_sh3_rom (void)
{
init_sh3_cmds ();
init_monitor_ops (&sh3_ops);
*/
static char *
-td_err_string (errcode)
- td_err_e errcode;
+td_err_string (td_err_e errcode)
{
static struct string_map
td_err_table[] =
*/
static char *
-td_state_string (statecode)
- td_thr_state_e statecode;
+td_state_string (td_thr_state_e statecode)
{
static struct string_map
td_thr_state_table[] =
*/
static int
-thread_to_lwp (thread_id, default_lwp)
- int thread_id;
- int default_lwp;
+thread_to_lwp (int thread_id, int default_lwp)
{
td_thrinfo_t ti;
td_thrhandle_t th;
*/
static int
-lwp_to_thread (lwp)
- int lwp;
+lwp_to_thread (int lwp)
{
td_thrinfo_t ti;
td_thrhandle_t th;
static struct cleanup *
-save_inferior_pid ()
+save_inferior_pid (void)
{
return make_cleanup (restore_inferior_pid, (void *) inferior_pid);
}
static void
-restore_inferior_pid (pid)
- void *pid;
+restore_inferior_pid (void *pid)
{
inferior_pid = (int) pid;
}
/* ARGSUSED */
static void
-sol_thread_open (arg, from_tty)
- char *arg;
- int from_tty;
+sol_thread_open (char *arg, int from_tty)
{
procfs_ops.to_open (arg, from_tty);
}
and wait for the trace-trap that results from attaching. */
static void
-sol_thread_attach (args, from_tty)
- char *args;
- int from_tty;
+sol_thread_attach (char *args, int from_tty)
{
procfs_ops.to_attach (args, from_tty);
/* Must get symbols from solibs before libthread_db can run! */
started via the normal ptrace (PTRACE_TRACEME). */
static void
-sol_thread_detach (args, from_tty)
- char *args;
- int from_tty;
+sol_thread_detach (char *args, int from_tty)
{
inferior_pid = PIDGET (main_ph.pid);
unpush_target (&sol_thread_ops);
for procfs. */
static void
-sol_thread_resume (pid, step, signo)
- int pid;
- int step;
- enum target_signal signo;
+sol_thread_resume (int pid, int step, enum target_signal signo)
{
struct cleanup *old_chain;
to a LWP id, and vice versa on the way out. */
static int
-sol_thread_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+sol_thread_wait (int pid, struct target_waitstatus *ourstatus)
{
int rtnval;
int save_pid;
}
static void
-sol_thread_fetch_registers (regno)
- int regno;
+sol_thread_fetch_registers (int regno)
{
thread_t thread;
td_thrhandle_t thandle;
}
static void
-sol_thread_store_registers (regno)
- int regno;
+sol_thread_store_registers (int regno)
{
thread_t thread;
td_thrhandle_t thandle;
debugged. */
static void
-sol_thread_prepare_to_store ()
+sol_thread_prepare_to_store (void)
{
procfs_ops.to_prepare_to_store ();
}
/* Print status information about what we're accessing. */
static void
-sol_thread_files_info (ignore)
- struct target_ops *ignore;
+sol_thread_files_info (struct target_ops *ignore)
{
procfs_ops.to_files_info (ignore);
}
static void
-sol_thread_kill_inferior ()
+sol_thread_kill_inferior (void)
{
procfs_ops.to_kill ();
}
static void
-sol_thread_notice_signals (pid)
- int pid;
+sol_thread_notice_signals (int pid)
{
procfs_ops.to_notice_signals (PIDGET (pid));
}
/* Fork an inferior process, and start debugging it with /proc. */
static void
-sol_thread_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+sol_thread_create_inferior (char *exec_file, char *allargs, char **env)
{
procfs_ops.to_create_inferior (exec_file, allargs, env);
static void (*target_new_objfile_chain) (struct objfile *);
void
-sol_thread_new_objfile (objfile)
- struct objfile *objfile;
+sol_thread_new_objfile (struct objfile *objfile)
{
td_err_e val;
/* Clean up after the inferior dies. */
static void
-sol_thread_mourn_inferior ()
+sol_thread_mourn_inferior (void)
{
unpush_target (&sol_thread_ops);
procfs_ops.to_mourn_inferior ();
/* Mark our target-struct as eligible for stray "run" and "attach" commands. */
static int
-sol_thread_can_run ()
+sol_thread_can_run (void)
{
return procfs_suppress_run;
}
*/
static int
-sol_thread_alive (pid)
- int pid;
+sol_thread_alive (int pid)
{
if (is_thread (pid)) /* non-kernel thread */
{
}
static void
-sol_thread_stop ()
+sol_thread_stop (void)
{
procfs_ops.to_stop ();
}
/* Convert a pid to printable form. */
char *
-solaris_pid_to_str (pid)
- int pid;
+solaris_pid_to_str (int pid)
{
static char buf[100];
kernel) thread. */
static int
-sol_find_new_threads_callback (th, ignored)
- const td_thrhandle_t *th;
- void *ignored;
+sol_find_new_threads_callback (const td_thrhandle_t *th, void *ignored)
{
td_err_e retval;
td_thrinfo_t ti;
}
static void
-sol_find_new_threads ()
+sol_find_new_threads (void)
{
/* don't do anything if init failed to resolve the libthread_db library */
if (!procfs_suppress_run)
}
static void
-sol_core_open (filename, from_tty)
- char *filename;
- int from_tty;
+sol_core_open (char *filename, int from_tty)
{
orig_core_ops.to_open (filename, from_tty);
}
static void
-sol_core_close (quitting)
- int quitting;
+sol_core_close (int quitting)
{
orig_core_ops.to_close (quitting);
}
static void
-sol_core_detach (args, from_tty)
- char *args;
- int from_tty;
+sol_core_detach (char *args, int from_tty)
{
unpush_target (&core_ops);
orig_core_ops.to_detach (args, from_tty);
}
static void
-sol_core_files_info (t)
- struct target_ops *t;
+sol_core_files_info (struct target_ops *t)
{
orig_core_ops.to_files_info (t);
}
inferior. Print anything interesting that we can think of. */
static int
-info_cb (th, s)
- const td_thrhandle_t *th;
- void *s;
+info_cb (const td_thrhandle_t *th, void *s)
{
td_err_e ret;
td_thrinfo_t ti;
/* List some state about each Solaris user thread in the inferior. */
static void
-info_solthreads (args, from_tty)
- char *args;
- int from_tty;
+info_solthreads (char *args, int from_tty)
{
p_td_ta_thr_iter (main_ta, info_cb, args,
TD_THR_ANY_STATE, TD_THR_LOWEST_PRIORITY,
}
static int
-ignore (addr, contents)
- CORE_ADDR addr;
- char *contents;
+ignore (CORE_ADDR addr, char *contents)
{
return 0;
}
static void
-init_sol_thread_ops ()
+init_sol_thread_ops (void)
{
sol_thread_ops.to_shortname = "solaris-threads";
sol_thread_ops.to_longname = "Solaris threads and pthread.";
static void
-init_sol_core_ops ()
+init_sol_core_ops (void)
{
sol_core_ops.to_shortname = "solaris-core";
sol_core_ops.to_longname = "Solaris core threads and pthread.";
int coreops_suppress_target = 1;
void
-_initialize_sol_thread ()
+_initialize_sol_thread (void)
{
void *dlhandle;
*/
static int
-solib_map_sections (arg)
- PTR arg;
+solib_map_sections (PTR arg)
{
struct so_list *so = (struct so_list *) arg; /* catch_errors bogon */
char *filename;
/* Allocate the runtime common object file. */
static void
-allocate_rt_common_objfile ()
+allocate_rt_common_objfile (void)
{
struct objfile *objfile;
struct objfile *last_one;
objfile. */
static void
-solib_add_common_symbols (rtc_symp)
- CORE_ADDR rtc_symp;
+solib_add_common_symbols (CORE_ADDR rtc_symp)
{
struct rtc_symb inferior_rtc_symb;
struct nlist inferior_rtc_nlist;
*/
static CORE_ADDR
-bfd_lookup_symbol (abfd, symname)
- bfd *abfd;
- char *symname;
+bfd_lookup_symbol (bfd *abfd, char *symname)
{
unsigned int storage_needed;
asymbol *sym;
*/
static int
-look_for_base (fd, baseaddr)
- int fd;
- CORE_ADDR baseaddr;
+look_for_base (int fd, CORE_ADDR baseaddr)
{
bfd *interp_bfd;
CORE_ADDR address = 0;
*/
static CORE_ADDR
-elf_locate_base ()
+elf_locate_base (void)
{
sec_ptr dyninfo_sect;
int dyninfo_sect_size;
*/
static CORE_ADDR
-locate_base ()
+locate_base (void)
{
#ifndef SVR4_SHARED_LIBS
does the reading. */
static CORE_ADDR
-first_link_map_member ()
+first_link_map_member (void)
{
CORE_ADDR lm = 0;
non-zero iff SONAME matches one of the known main executable names. */
static int
-match_main (soname)
- char *soname;
+match_main (char *soname)
{
char **mainp;
we provide values for. */
static struct so_list *
-current_sos ()
+current_sos (void)
{
CORE_ADDR lm;
struct so_list *head = 0;
/* A small stub to get us past the arg-passing pinhole of catch_errors. */
static int
-symbol_add_stub (arg)
- PTR arg;
+symbol_add_stub (PTR arg)
{
register struct so_list *so = (struct so_list *) arg; /* catch_errs bogon */
struct section_addr_info *sap;
*/
static void
-info_sharedlibrary_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+info_sharedlibrary_command (char *ignore, int from_tty)
{
register struct so_list *so = NULL; /* link map state variable */
int header_done = 0;
*/
char *
-solib_address (address)
- CORE_ADDR address;
+solib_address (CORE_ADDR address)
{
register struct so_list *so = 0; /* link map state variable */
/* Called by free_all_symtabs */
void
-clear_solib ()
+clear_solib (void)
{
/* This function is expected to handle ELF shared libraries. It is
also used on Solaris, which can run either ELF or a.out binaries
}
static void
-do_clear_solib (dummy)
- PTR dummy;
+do_clear_solib (PTR dummy)
{
solib_cleanup_queued = 0;
clear_solib ();
static CORE_ADDR interp_plt_sect_high;
int
-in_svr4_dynsym_resolve_code (pc)
- CORE_ADDR pc;
+in_svr4_dynsym_resolve_code (CORE_ADDR pc)
{
return ((pc >= interp_text_sect_low && pc < interp_text_sect_high)
|| (pc >= interp_plt_sect_low && pc < interp_plt_sect_high)
#ifndef SVR4_SHARED_LIBS
static int
-disable_break ()
+disable_break (void)
{
int status = 1;
*/
static int
-enable_break ()
+enable_break (void)
{
int success = 0;
*/
void
-solib_create_inferior_hook ()
+solib_create_inferior_hook (void)
{
/* If we are using the BKPT_AT_SYMBOL code, then we don't need the base
yet. In fact, in the case of a SunOS4 executable being run on
*/
static void
-special_symbol_handling ()
+special_symbol_handling (void)
{
#ifndef SVR4_SHARED_LIBS
int j;
*/
static void
-sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
solib_add (args, from_tty, (struct target_ops *) 0);
#endif /* HAVE_LINK_H */
void
-_initialize_solib ()
+_initialize_solib (void)
{
#ifdef HAVE_LINK_H
*/
static void
-som_symtab_read (abfd, objfile, section_offsets)
- bfd *abfd;
- struct objfile *objfile;
- struct section_offsets *section_offsets;
+som_symtab_read (bfd *abfd, struct objfile *objfile,
+ struct section_offsets *section_offsets)
{
unsigned int number_of_symbols;
int val, dynamic;
capability even for files compiled without -g. */
static void
-som_symfile_read (objfile, mainline)
- struct objfile *objfile;
- int mainline;
+som_symfile_read (struct objfile *objfile, int mainline)
{
bfd *abfd = objfile->obfd;
struct cleanup *back_to;
We reinitialize buildsym, since we may be reading stabs from a SOM file. */
static void
-som_new_init (ignore)
- struct objfile *ignore;
+som_new_init (struct objfile *ignore)
{
stabsread_new_init ();
buildsym_new_init ();
objfile struct from the global list of known objfiles. */
static void
-som_symfile_finish (objfile)
- struct objfile *objfile;
+som_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_stab_info != NULL)
{
/* SOM specific initialization routine for reading symbols. */
static void
-som_symfile_init (objfile)
- struct objfile *objfile;
+som_symfile_init (struct objfile *objfile)
{
/* SOM objects may be reordered, so set OBJF_REORDERED. If we
find this causes a significant slowdown in gdb then we could
Plain and simple for now. */
static void
-som_symfile_offsets (objfile, addrs)
- struct objfile *objfile;
- struct section_addr_info *addrs;
+som_symfile_offsets (struct objfile *objfile, struct section_addr_info *addrs)
{
int i;
CORE_ADDR text_addr;
with as "loc_indirect" vars.)
Return value = number of import symbols read in. */
int
-init_import_symbols (objfile)
- struct objfile *objfile;
+init_import_symbols (struct objfile *objfile)
{
unsigned int import_list;
unsigned int import_list_size;
with as "loc_indirect" vars.)
Return value = number of import symbols read in. */
int
-init_export_symbols (objfile)
- struct objfile *objfile;
+init_export_symbols (struct objfile *objfile)
{
unsigned int export_list;
unsigned int export_list_size;
};
void
-_initialize_somread ()
+_initialize_somread (void)
{
add_symtab_fns (&som_sym_fns);
}
static void som_solib_sharedlibrary_command (char *, int);
static LONGEST
-som_solib_sizeof_symbol_table (filename)
- char *filename;
+som_solib_sizeof_symbol_table (char *filename)
{
bfd *abfd;
int desc;
static void
-som_solib_add_solib_objfile (so, name, from_tty, text_addr)
- struct so_list *so;
- char *name;
- int from_tty;
- CORE_ADDR text_addr;
+som_solib_add_solib_objfile (struct so_list *so, char *name, int from_tty,
+ CORE_ADDR text_addr)
{
obj_private_data_t *obj_private;
struct section_addr_info section_addrs;
static void
-som_solib_load_symbols (so, name, from_tty, text_addr, target)
- struct so_list *so;
- char *name;
- int from_tty;
- CORE_ADDR text_addr;
- struct target_ops *target;
+som_solib_load_symbols (struct so_list *so, char *name, int from_tty,
+ CORE_ADDR text_addr, struct target_ops *target)
{
struct section_table *p;
int status;
be exceeded. */
void
-som_solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+som_solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
struct minimal_symbol *msymbol;
struct so_list *so_list_tail;
means running until the "_start" is called. */
void
-som_solib_create_inferior_hook ()
+som_solib_create_inferior_hook (void)
{
struct minimal_symbol *msymbol;
unsigned int dld_flags, status, have_endo;
static void
-reset_inferior_pid (saved_inferior_pid)
- int saved_inferior_pid;
+reset_inferior_pid (int saved_inferior_pid)
{
inferior_pid = saved_inferior_pid;
}
GDB may already have been notified of.
*/
void
-som_solib_remove_inferior_hook (pid)
- int pid;
+som_solib_remove_inferior_hook (int pid)
{
CORE_ADDR addr;
struct minimal_symbol *msymbol;
som_solib_create_inferior_hook.
*/
void
-som_solib_create_catch_load_hook (pid, tempflag, filename, cond_string)
- int pid;
- int tempflag;
- char *filename;
- char *cond_string;
+som_solib_create_catch_load_hook (int pid, int tempflag, char *filename,
+ char *cond_string)
{
create_solib_load_event_breakpoint ("__d_trap", tempflag, filename, cond_string);
}
som_solib_create_inferior_hook.
*/
void
-som_solib_create_catch_unload_hook (pid, tempflag, filename, cond_string)
- int pid;
- int tempflag;
- char *filename;
- char *cond_string;
+som_solib_create_catch_unload_hook (int pid, int tempflag, char *filename,
+ char *cond_string)
{
create_solib_unload_event_breakpoint ("__d_trap", tempflag, filename, cond_string);
}
int
-som_solib_have_load_event (pid)
- int pid;
+som_solib_have_load_event (int pid)
{
CORE_ADDR event_kind;
}
int
-som_solib_have_unload_event (pid)
- int pid;
+som_solib_have_unload_event (int pid)
{
CORE_ADDR event_kind;
}
static char *
-som_solib_library_pathname (pid)
- int pid;
+som_solib_library_pathname (int pid)
{
CORE_ADDR dll_handle_address;
CORE_ADDR dll_pathname_address;
}
char *
-som_solib_loaded_library_pathname (pid)
- int pid;
+som_solib_loaded_library_pathname (int pid)
{
if (!som_solib_have_load_event (pid))
error ("Must have a load event to use this query");
}
char *
-som_solib_unloaded_library_pathname (pid)
- int pid;
+som_solib_unloaded_library_pathname (int pid)
{
if (!som_solib_have_unload_event (pid))
error ("Must have an unload event to use this query");
}
static void
-som_solib_desire_dynamic_linker_symbols ()
+som_solib_desire_dynamic_linker_symbols (void)
{
struct objfile *objfile;
struct unwind_table_entry *u;
}
int
-som_solib_in_dynamic_linker (pid, pc)
- int pid;
- CORE_ADDR pc;
+som_solib_in_dynamic_linker (int pid, CORE_ADDR pc)
{
struct unwind_table_entry *u_pc;
ADDR isn't in any known shared library, return zero. */
CORE_ADDR
-som_solib_get_got_by_pc (addr)
- CORE_ADDR addr;
+som_solib_get_got_by_pc (CORE_ADDR addr)
{
struct so_list *so_list = so_list_head;
CORE_ADDR got_value = 0;
/* this function is used in hppa_fix_call_dummy in hppa-tdep.c */
CORE_ADDR
-som_solib_get_solib_by_pc (addr)
- CORE_ADDR addr;
+som_solib_get_solib_by_pc (CORE_ADDR addr)
{
struct so_list *so_list = so_list_head;
int
-som_solib_section_offsets (objfile, offsets)
- struct objfile *objfile;
- struct section_offsets *offsets;
+som_solib_section_offsets (struct objfile *objfile,
+ struct section_offsets *offsets)
{
struct so_list *so_list = so_list_head;
/* Dump information about all the currently loaded shared libraries. */
static void
-som_sharedlibrary_info_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+som_sharedlibrary_info_command (char *ignore, int from_tty)
{
struct so_list *so_list = so_list_head;
}
static void
-som_solib_sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+som_solib_sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
som_solib_add (args, from_tty, (struct target_ops *) 0);
char *
-som_solib_address (addr)
- CORE_ADDR addr;
+som_solib_address (CORE_ADDR addr)
{
struct so_list *so = so_list_head;
void
-som_solib_restart ()
+som_solib_restart (void)
{
struct so_list *sl = so_list_head;
void
-_initialize_som_solib ()
+_initialize_som_solib (void)
{
add_com ("sharedlibrary", class_files, som_solib_sharedlibrary_command,
"Load shared object library symbols for files matching REGEXP.");
/* Get some HPUX-specific data from a shared lib.
*/
CORE_ADDR
-so_lib_thread_start_addr (so)
- struct so_list *so;
+so_lib_thread_start_addr (struct so_list *so)
{
return so->som_solib.tsd_start_addr;
}
before we need to would make things slower than necessary. */
void
-select_source_symtab (s)
- register struct symtab *s;
+select_source_symtab (register struct symtab *s)
{
struct symtabs_and_lines sals;
struct symtab_and_line sal;
}
\f
static void
-show_directories (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_directories (char *ignore, int from_tty)
{
puts_filtered ("Source directories searched: ");
puts_filtered (source_path);
may be found in a different directory now. */
void
-forget_cached_source_info ()
+forget_cached_source_info (void)
{
register struct symtab *s;
register struct objfile *objfile;
}
void
-init_source_path ()
+init_source_path (void)
{
char buf[20];
/* Add zero or more directories to the front of the source path. */
void
-directory_command (dirname, from_tty)
- char *dirname;
- int from_tty;
+directory_command (char *dirname, int from_tty)
{
dont_repeat ();
/* FIXME, this goes to "delete dir"... */
/* Add zero or more directories to the front of an arbitrary path. */
void
-mod_path (dirname, which_path)
- char *dirname;
- char **which_path;
+mod_path (char *dirname, char **which_path)
{
char *old = *which_path;
int prefix = 0;
static void
-source_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+source_info (char *ignore, int from_tty)
{
register struct symtab *s = current_source_symtab;
/* >>>> This should only allow files of certain types,
>>>> eg executable, non-directory */
int
-openp (path, try_cwd_first, string, mode, prot, filename_opened)
- char *path;
- int try_cwd_first;
- char *string;
- int mode;
- int prot;
- char **filename_opened;
+openp (char *path, int try_cwd_first, char *string, int mode, int prot,
+ char **filename_opened)
{
register int fd;
register char *filename;
Else, this functions returns 0, and FULL_PATHNAME is set to NULL.
*/
int
-source_full_path_of (filename, full_pathname)
- char *filename;
- char **full_pathname;
+source_full_path_of (char *filename, char **full_pathname)
{
int fd;
negative number for error. */
int
-open_source_file (s)
- struct symtab *s;
+open_source_file (struct symtab *s)
{
char *path = source_path;
char *p;
if no symtab. */
char *
-symtab_to_filename (s)
- struct symtab *s;
+symtab_to_filename (struct symtab *s)
{
int fd;
All set S->nlines to the number of such lines. */
void
-find_source_lines (s, desc)
- struct symtab *s;
- int desc;
+find_source_lines (struct symtab *s, int desc)
{
struct stat st;
register char *data, *p, *end;
#if 0 /* Currently unused */
int
-source_line_charpos (s, line)
- struct symtab *s;
- int line;
+source_line_charpos (struct symtab *s, int line)
{
if (!s)
return 0;
/* Return the line number of character position POS in symtab S. */
int
-source_charpos_line (s, chr)
- register struct symtab *s;
- register int chr;
+source_charpos_line (register struct symtab *s, register int chr)
{
register int line = 0;
register int *lnp;
or to 0 if the file is not found. */
static int
-get_filename_and_charpos (s, fullname)
- struct symtab *s;
- char **fullname;
+get_filename_and_charpos (struct symtab *s, char **fullname)
{
register int desc, linenums_changed = 0;
Return 1 if successful, 0 if could not find the file. */
int
-identify_source_line (s, line, mid_statement, pc)
- struct symtab *s;
- int line;
- int mid_statement;
- CORE_ADDR pc;
+identify_source_line (struct symtab *s, int line, int mid_statement,
+ CORE_ADDR pc)
{
if (s->line_charpos == 0)
get_filename_and_charpos (s, (char **) NULL);
static void print_source_lines_base (struct symtab *s, int line, int stopline,
int noerror);
static void
-print_source_lines_base (s, line, stopline, noerror)
- struct symtab *s;
- int line;
- int stopline;
- int noerror;
+print_source_lines_base (struct symtab *s, int line, int stopline, int noerror)
{
register int c;
register int desc;
window otherwise it is simply printed */
void
-print_source_lines (s, line, stopline, noerror)
- struct symtab *s;
- int line, stopline, noerror;
+print_source_lines (struct symtab *s, int line, int stopline, int noerror)
{
#if defined(TUI)
if (!tui_version ||
SALS provides the filenames and line numbers. */
static void
-ambiguous_line_spec (sals)
- struct symtabs_and_lines *sals;
+ambiguous_line_spec (struct symtabs_and_lines *sals)
{
int i;
}
static void
-list_command (arg, from_tty)
- char *arg;
- int from_tty;
+list_command (char *arg, int from_tty)
{
struct symtabs_and_lines sals, sals_end;
struct symtab_and_line sal, sal_end;
/* Print info on range of pc's in a specified line. */
static void
-line_info (arg, from_tty)
- char *arg;
- int from_tty;
+line_info (char *arg, int from_tty)
{
struct symtabs_and_lines sals;
struct symtab_and_line sal;
/* ARGSUSED */
static void
-forward_search_command (regex, from_tty)
- char *regex;
- int from_tty;
+forward_search_command (char *regex, int from_tty)
{
register int c;
register int desc;
/* ARGSUSED */
static void
-reverse_search_command (regex, from_tty)
- char *regex;
- int from_tty;
+reverse_search_command (char *regex, int from_tty)
{
register int c;
register int desc;
}
\f
void
-_initialize_source ()
+_initialize_source (void)
{
struct cmd_list_element *c;
current_source_symtab = 0;
marking them as valid so we won't fetch them again. */
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
}
int
-kernel_u_size ()
+kernel_u_size (void)
{
return (sizeof (struct user));
}
};
void
-_initialize_core_sparc ()
+_initialize_core_sparc (void)
{
add_core_fns (&sparc_core_fns);
}
/* Convert ch from a hex digit to an int */
static int
-hex(ch)
- unsigned char ch;
+hex (unsigned char ch)
{
if (ch >= 'a' && ch <= 'f')
return ch-'a'+10;
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
/* send the packet in buffer. */
static void
-putpacket(buffer)
- unsigned char *buffer;
+putpacket (unsigned char *buffer)
{
unsigned char checksum;
int count;
*/
static unsigned char *
-mem2hex(mem, buf, count, may_fault)
- unsigned char *mem;
- unsigned char *buf;
- int count;
- int may_fault;
+mem2hex (unsigned char *mem, unsigned char *buf, int count, int may_fault)
{
unsigned char ch;
* return a pointer to the character AFTER the last byte written */
static char *
-hex2mem(buf, mem, count, may_fault)
- unsigned char *buf;
- unsigned char *mem;
- int count;
- int may_fault;
+hex2mem (unsigned char *buf, unsigned char *mem, int count, int may_fault)
{
int i;
unsigned char ch;
/* Set up exception handlers for tracing and breakpoints */
void
-set_debug_traps()
+set_debug_traps (void)
{
struct hard_trap_info *ht;
");
static void
-set_mem_fault_trap(enable)
- int enable;
+set_mem_fault_trap (int enable)
{
extern void fltr_set_mem_err();
mem_err = 0;
/* Convert the SPARC hardware trap type code to a unix signal number. */
static int
-computeSignal(tt)
- int tt;
+computeSignal (int tt)
{
struct hard_trap_info *ht;
extern void breakinst();
static void
-handle_exception (registers)
- unsigned long *registers;
+handle_exception (unsigned long *registers)
{
int tt; /* Trap type */
int sigval;
the debugger. */
void
-breakpoint()
+breakpoint (void)
{
if (!initialized)
return;
such as sparc86x, instructions are always big-endian. */
static unsigned long
-fetch_instruction (pc)
- CORE_ADDR pc;
+fetch_instruction (CORE_ADDR pc)
{
unsigned long retval;
int i;
set up a simulated single-step, we undo our damage. */
void
-sparc_software_single_step (ignore, insert_breakpoints_p)
- enum target_signal ignore; /* pid, but we don't need it */
- int insert_breakpoints_p;
+sparc_software_single_step (enum target_signal ignore, /* pid, but we don't need it */
+ int insert_breakpoints_p)
{
branch_type br;
CORE_ADDR pc;
been stashed, since their exact position within the frame may vary. */
void
-sparc_init_extra_frame_info (fromleaf, fi)
- int fromleaf;
- struct frame_info *fi;
+sparc_init_extra_frame_info (int fromleaf, struct frame_info *fi)
{
char *name;
CORE_ADDR prologue_start, prologue_end;
}
CORE_ADDR
-sparc_frame_chain (frame)
- struct frame_info *frame;
+sparc_frame_chain (struct frame_info *frame)
{
/* Value that will cause FRAME_CHAIN_VALID to not worry about the chain
value. If it realy is zero, we detect it later in
}
CORE_ADDR
-sparc_extract_struct_value_address (regbuf)
- char *regbuf;
+sparc_extract_struct_value_address (char *regbuf)
{
return extract_address (regbuf + REGISTER_BYTE (O0_REGNUM),
REGISTER_RAW_SIZE (O0_REGNUM));
/* Find the pc saved in frame FRAME. */
CORE_ADDR
-sparc_frame_saved_pc (frame)
- struct frame_info *frame;
+sparc_frame_saved_pc (struct frame_info *frame)
{
char *buf;
CORE_ADDR addr;
difficulty. */
struct frame_info *
-setup_arbitrary_frame (argc, argv)
- int argc;
- CORE_ADDR *argv;
+setup_arbitrary_frame (int argc, CORE_ADDR *argv)
{
struct frame_info *frame;
CORE_ADDR *);
static CORE_ADDR
-examine_prologue (start_pc, frameless_p, fi, saved_regs)
- CORE_ADDR start_pc;
- int frameless_p;
- struct frame_info *fi;
- CORE_ADDR *saved_regs;
+examine_prologue (CORE_ADDR start_pc, int frameless_p, struct frame_info *fi,
+ CORE_ADDR *saved_regs)
{
int insn;
int dest = -1;
}
CORE_ADDR
-sparc_skip_prologue (start_pc, frameless_p)
- CORE_ADDR start_pc;
- int frameless_p;
+sparc_skip_prologue (CORE_ADDR start_pc, int frameless_p)
{
return examine_prologue (start_pc, frameless_p, NULL, NULL);
}
This isn't static as it's used by remote-sa.sparc.c. */
static branch_type
-isbranch (instruction, addr, target)
- long instruction;
- CORE_ADDR addr, *target;
+isbranch (long instruction, CORE_ADDR addr, CORE_ADDR *target)
{
branch_type val = not_branch;
long int offset = 0; /* Must be signed for sign-extend. */
The argument RAW_BUFFER must point to aligned memory. */
void
-sparc_get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval)
- char *raw_buffer;
- int *optimized;
- CORE_ADDR *addrp;
- struct frame_info *frame;
- int regnum;
- enum lval_type *lval;
+sparc_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
+ struct frame_info *frame, int regnum,
+ enum lval_type *lval)
{
struct frame_info *frame1;
CORE_ADDR addr;
(DUMMY_STACK_REG_BUF_SIZE + DUMMY_REG_SAVE_OFFSET)
void
-sparc_push_dummy_frame ()
+sparc_push_dummy_frame (void)
{
CORE_ADDR sp, old_sp;
char *register_temp;
static void sparc_frame_find_saved_regs (struct frame_info *, CORE_ADDR *);
static void
-sparc_frame_find_saved_regs (fi, saved_regs_addr)
- struct frame_info *fi;
- CORE_ADDR *saved_regs_addr;
+sparc_frame_find_saved_regs (struct frame_info *fi, CORE_ADDR *saved_regs_addr)
{
register int regnum;
CORE_ADDR frame_addr = FRAME_FP (fi);
/* Definitely see tm-sparc.h for more doc of the frame format here. */
void
-sparc_pop_frame ()
+sparc_pop_frame (void)
{
register struct frame_info *frame = get_current_frame ();
register CORE_ADDR pc;
a fake insn, step past it. */
CORE_ADDR
-sparc_pc_adjust (pc)
- CORE_ADDR pc;
+sparc_pc_adjust (CORE_ADDR pc)
{
unsigned long insn;
char buf[4];
by hand. */
CORE_ADDR
-sunos4_skip_trampoline_code (pc)
- CORE_ADDR pc;
+sunos4_skip_trampoline_code (CORE_ADDR pc)
{
unsigned long insn1;
char buf[4];
register values. */
void
-supply_gregset (gregsetp)
- gdb_gregset_t *gregsetp;
+supply_gregset (gdb_gregset_t *gregsetp)
{
prgreg_t *regp = (prgreg_t *) gregsetp;
int regi, offset = 0;
}
void
-fill_gregset (gregsetp, regno)
- gdb_gregset_t *gregsetp;
- int regno;
+fill_gregset (gdb_gregset_t *gregsetp, int regno)
{
prgreg_t *regp = (prgreg_t *) gregsetp;
int regi, offset = 0;
idea of the current floating point register values. */
void
-supply_fpregset (fpregsetp)
- gdb_fpregset_t *fpregsetp;
+supply_fpregset (gdb_fpregset_t *fpregsetp)
{
register int regi;
char *from;
/* This will probably need some changes for sparc64. */
void
-fill_fpregset (fpregsetp, regno)
- gdb_fpregset_t *fpregsetp;
- int regno;
+fill_fpregset (gdb_fpregset_t *fpregsetp, int regno)
{
int regi;
char *to;
This routine returns true on success */
int
-get_longjmp_target (pc)
- CORE_ADDR *pc;
+get_longjmp_target (CORE_ADDR *pc)
{
CORE_ADDR jb_addr;
#define LONGJMP_TARGET_SIZE 4
related to C++ mangling, it is done for C too. */
char *
-sunpro_static_transform_name (name)
- char *name;
+sunpro_static_transform_name (char *name)
{
char *p;
if (name[0] == '$')
static void dump_ccreg (char *, int);
static void
-dump_ccreg (reg, val)
- char *reg;
- int val;
+dump_ccreg (char *reg, int val)
{
/* page 41 */
printf_unfiltered ("%s:%s,%s,%s,%s", reg,
}
static char *
-decode_asi (val)
- int val;
+decode_asi (int val)
{
/* page 72 */
switch (val)
/* FIXME: Would be nice if this did some fancy things for 32 bit sparc. */
void
-sparc_print_register_hook (regno)
- int regno;
+sparc_print_register_hook (int regno)
{
ULONGEST val;
}
\f
int
-gdb_print_insn_sparc (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_sparc (bfd_vma memaddr, disassemble_info *info)
{
/* It's necessary to override mach again because print_insn messes it up. */
info->mach = TARGET_ARCHITECTURE->mach;
args are also passed in registers o0 - o5. */
CORE_ADDR
-sparc32_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+sparc32_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
int i, j, oregnum;
int accumulate_size = 0;
into VALBUF. */
void
-sparc32_extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+sparc32_extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
int typelen = TYPE_LENGTH (type);
int regsize = REGISTER_RAW_SIZE (O0_REGNUM);
values are returned in register %o0. */
void
-sparc_store_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+sparc_store_return_value (struct type *type, char *valbuf)
{
int regno;
char *buffer;
has already been customized for a different function). */
void
-sparc_fix_call_dummy (dummy, pc, fun, value_type, using_gcc)
- char *dummy;
- CORE_ADDR pc;
- CORE_ADDR fun;
- struct type *value_type;
- int using_gcc;
+sparc_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun,
+ struct type *value_type, int using_gcc)
{
int i;
/* Set target byte order based on machine type. */
static int
-sparc_target_architecture_hook (ap)
- const bfd_arch_info_type *ap;
+sparc_target_architecture_hook (const bfd_arch_info_type *ap)
{
int i, j;
struct gdbarch_list *arches);
void
-_initialize_sparc_tdep ()
+_initialize_sparc_tdep (void)
{
/* Hook us into the gdbarch mechanism. */
register_gdbarch_init (bfd_arch_sparc, sparc_gdbarch_init);
}
void
-sparc64_write_sp (val)
- CORE_ADDR val;
+sparc64_write_sp (CORE_ADDR val)
{
CORE_ADDR oldsp = read_register (SP_REGNUM);
if (oldsp & 1)
}
void
-sparc64_write_fp (val)
- CORE_ADDR val;
+sparc64_write_fp (CORE_ADDR val)
{
CORE_ADDR oldfp = read_register (FP_REGNUM);
if (oldfp & 1)
int and float, we will waste every other register of both types. */
CORE_ADDR
-sparc64_push_arguments (nargs, args, sp, struct_return, struct_retaddr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_retaddr;
+sparc64_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_retaddr)
{
int i, j, register_counter = 0;
CORE_ADDR tempsp;
returned in f0-f3). */
void
-sp64_extract_return_value (type, regbuf, valbuf, bitoffset)
- struct type *type;
- char *regbuf;
- char *valbuf;
- int bitoffset;
+sp64_extract_return_value (struct type *type, char *regbuf, char *valbuf,
+ int bitoffset)
{
int typelen = TYPE_LENGTH (type);
int regsize = REGISTER_RAW_SIZE (O0_REGNUM);
/* Convert ch from a hex digit to an int */
static int
-hex(ch)
- unsigned char ch;
+hex (unsigned char ch)
{
if (ch >= 'a' && ch <= 'f')
return ch-'a'+10;
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
/* send the packet in buffer. */
static void
-putpacket(buffer)
- unsigned char *buffer;
+putpacket (unsigned char *buffer)
{
unsigned char checksum;
int count;
*/
static unsigned char *
-mem2hex(mem, buf, count, may_fault)
- unsigned char *mem;
- unsigned char *buf;
- int count;
- int may_fault;
+mem2hex (unsigned char *mem, unsigned char *buf, int count, int may_fault)
{
unsigned char ch;
* return a pointer to the character AFTER the last byte written */
static char *
-hex2mem(buf, mem, count, may_fault)
- unsigned char *buf;
- unsigned char *mem;
- int count;
- int may_fault;
+hex2mem (unsigned char *buf, unsigned char *mem, int count, int may_fault)
{
int i;
unsigned char ch;
/* Set up exception handlers for tracing and breakpoints */
void
-set_debug_traps()
+set_debug_traps (void)
{
struct hard_trap_info *ht;
");
static void
-set_mem_fault_trap(enable)
- int enable;
+set_mem_fault_trap (int enable)
{
extern void fltr_set_mem_err();
mem_err = 0;
");
static void
-get_in_break_mode()
+get_in_break_mode (void)
{
extern void dummy_hw_breakpoint();
/* Convert the SPARC hardware trap type code to a unix signal number. */
static int
-computeSignal(tt)
- int tt;
+computeSignal (int tt)
{
struct hard_trap_info *ht;
*/
static void
-handle_exception (registers)
- unsigned long *registers;
+handle_exception (unsigned long *registers)
{
int tt; /* Trap type */
int sigval;
the debugger. */
void
-breakpoint()
+breakpoint (void)
{
if (!initialized)
return;
#define DDV_MASK 0x1
int
-sparclite_insert_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+sparclite_insert_watchpoint (CORE_ADDR addr, int len, int type)
{
CORE_ADDR dcr;
}
int
-sparclite_remove_watchpoint (addr, len, type)
- CORE_ADDR addr;
- int len;
- int type;
+sparclite_remove_watchpoint (CORE_ADDR addr, int len, int type)
{
CORE_ADDR dcr, dda1, dda2;
}
int
-sparclite_insert_hw_breakpoint (addr, len)
- CORE_ADDR addr;
- int len;
+sparclite_insert_hw_breakpoint (CORE_ADDR addr, int len)
{
CORE_ADDR dcr;
}
int
-sparclite_remove_hw_breakpoint (addr, shadow)
- CORE_ADDR addr;
- int shadow;
+sparclite_remove_hw_breakpoint (CORE_ADDR addr, int shadow)
{
CORE_ADDR dcr, dia1, dia2;
}
int
-sparclite_check_watch_resources (type, cnt, ot)
- int type;
- int cnt;
- int ot;
+sparclite_check_watch_resources (int type, int cnt, int ot)
{
/* Watchpoints not supported on simulator. */
if (strcmp (target_shortname, "sim") == 0)
}
CORE_ADDR
-sparclite_stopped_data_address ()
+sparclite_stopped_data_address (void)
{
CORE_ADDR dsr, dda1, dda2;
}
\f
static serial_t
-open_tty (name)
- char *name;
+open_tty (char *name)
{
serial_t desc;
/* Read a single character from the remote end, masking it down to 7 bits. */
static int
-readchar (desc, timeout)
- serial_t desc;
- int timeout;
+readchar (serial_t desc, int timeout)
{
int ch;
char s[10];
}
static void
-debug_serial_write (desc, buf, len)
- serial_t desc;
- char *buf;
- int len;
+debug_serial_write (serial_t desc, char *buf, int len)
{
char s[10];
static int
-send_resp (desc, c)
- serial_t desc;
- char c;
+send_resp (serial_t desc, char c)
{
debug_serial_write (desc, &c, 1);
return readchar (desc, remote_timeout);
#ifdef HAVE_SOCKETS
static int
-recv_udp_buf (fd, buf, len, timeout)
- int fd, len;
- unsigned char *buf;
- int timeout;
+recv_udp_buf (int fd, unsigned char *buf, int len, int timeout)
{
int cc;
fd_set readfds;
}
static int
-send_udp_buf (fd, buf, len)
- int fd, len;
- unsigned char *buf;
+send_udp_buf (int fd, unsigned char *buf, int len)
{
int cc;
#endif /* HAVE_SOCKETS */
static void
-sparclite_open (name, from_tty)
- char *name;
- int from_tty;
+sparclite_open (char *name, int from_tty)
{
struct cleanup *old_chain;
int c;
}
static void
-sparclite_close (quitting)
- int quitting;
+sparclite_close (int quitting)
{
if (serial_flag)
close_tty (0);
}
static void
-sparclite_serial_start (entry)
- bfd_vma entry;
+sparclite_serial_start (bfd_vma entry)
{
char buffer[5];
int i;
}
static void
-sparclite_serial_write (from_bfd, from_sec, from_addr, to_addr, len)
- bfd *from_bfd;
- asection *from_sec;
- file_ptr from_addr;
- bfd_vma to_addr;
- int len;
+sparclite_serial_write (bfd *from_bfd, asection *from_sec, file_ptr from_addr,
+ bfd_vma to_addr, int len)
{
char buffer[4 + 4 + WRITESIZE]; /* addr + len + data */
unsigned char checksum;
#ifdef HAVE_SOCKETS
static unsigned short
-calc_checksum (buffer, count)
- unsigned char *buffer;
- int count;
+calc_checksum (unsigned char *buffer, int count)
{
unsigned short checksum;
}
static void
-sparclite_udp_start (entry)
- bfd_vma entry;
+sparclite_udp_start (bfd_vma entry)
{
unsigned char buffer[6];
int i;
}
static void
-sparclite_udp_write (from_bfd, from_sec, from_addr, to_addr, len)
- bfd *from_bfd;
- asection *from_sec;
- file_ptr from_addr;
- bfd_vma to_addr;
- int len;
+sparclite_udp_write (bfd *from_bfd, asection *from_sec, file_ptr from_addr,
+ bfd_vma to_addr, int len)
{
unsigned char buffer[2000];
unsigned short checksum;
#endif /* HAVE_SOCKETS */
static void
-sparclite_download (filename, from_tty)
- char *filename;
- int from_tty;
+sparclite_download (char *filename, int from_tty)
{
if (!serial_flag)
#ifdef HAVE_SOCKETS
}
void
-_initialize_sparcl_tdep ()
+_initialize_sparcl_tdep (void)
{
init_sparclite_ops ();
add_target (&sparclite_ops);
actually do anything, GDB will request the registers individually. */
static void
-sparclet_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+sparclet_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
return;
}
static void
-sparclet_load (desc, file, hashmark)
- serial_t desc;
- char *file;
- int hashmark;
+sparclet_load (serial_t desc, char *file, int hashmark)
{
bfd *abfd;
asection *s;
};
static void
-sparclet_open (args, from_tty)
- char *args;
- int from_tty;
+sparclet_open (char *args, int from_tty)
{
monitor_open (args, &sparclet_cmds, from_tty);
}
void
-_initialize_sparclet ()
+_initialize_sparclet (void)
{
int i;
init_sparclet_cmds ();
/* Convert ch from a hex digit to an int */
static int
-hex(ch)
- unsigned char ch;
+hex (unsigned char ch)
{
if (ch >= 'a' && ch <= 'f')
return ch-'a'+10;
/* scan for the sequence $<data>#<checksum> */
unsigned char *
-getpacket ()
+getpacket (void)
{
unsigned char *buffer = &remcomInBuffer[0];
unsigned char checksum;
/* send the packet in buffer. */
static void
-putpacket(buffer)
- unsigned char *buffer;
+putpacket (unsigned char *buffer)
{
unsigned char checksum;
int count;
*/
static unsigned char *
-mem2hex(mem, buf, count, may_fault)
- unsigned char *mem;
- unsigned char *buf;
- int count;
- int may_fault;
+mem2hex (unsigned char *mem, unsigned char *buf, int count, int may_fault)
{
unsigned char ch;
* return a pointer to the character AFTER the last byte written */
static char *
-hex2mem(buf, mem, count, may_fault)
- unsigned char *buf;
- unsigned char *mem;
- int count;
- int may_fault;
+hex2mem (unsigned char *buf, unsigned char *mem, int count, int may_fault)
{
int i;
unsigned char ch;
/* Set up exception handlers for tracing and breakpoints */
void
-set_debug_traps()
+set_debug_traps (void)
{
struct hard_trap_info *ht;
");
static void
-set_mem_fault_trap(enable)
- int enable;
+set_mem_fault_trap (int enable)
{
extern void fltr_set_mem_err();
mem_err = 0;
");
static void
-set_hw_breakpoint_trap(enable)
- int enable;
+set_hw_breakpoint_trap (int enable)
{
extern void dummy_hw_breakpoint();
}
static void
-get_in_break_mode()
+get_in_break_mode (void)
{
#if 0
int x;
/* Convert the SPARC hardware trap type code to a unix signal number. */
static int
-computeSignal(tt)
- int tt;
+computeSignal (int tt)
{
struct hard_trap_info *ht;
*/
static void
-handle_exception (registers)
- unsigned long *registers;
+handle_exception (unsigned long *registers)
{
int tt; /* Trap type */
int sigval;
the debugger. */
void
-breakpoint()
+breakpoint (void)
{
if (!initialized)
return;
}
static void
-hw_breakpoint()
+hw_breakpoint (void)
{
asm("
ta 127
static void os9k_init_type_vector (struct type **);
static void
-os9k_init_type_vector (tv)
- struct type **tv;
+os9k_init_type_vector (struct type **tv)
{
unsigned int i;
for (i = 0; i < sizeof (os9k_type_vector) / sizeof (struct type **); i++)
and fix their symbols in given symbol vector. */
static void
-patch_block_stabs (symbols, stabs, objfile)
- struct pending *symbols;
- struct pending_stabs *stabs;
- struct objfile *objfile;
+patch_block_stabs (struct pending *symbols, struct pending_stabs *stabs,
+ struct objfile *objfile)
{
int ii;
char *name;
Returns 0 for success, -1 for error. */
static int
-read_type_number (pp, typenums)
- register char **pp;
- register int *typenums;
+read_type_number (register char **pp, register int *typenums)
{
int nbits;
if (**pp == '(')
suibstring. */
static char *
-get_substring (p, c)
- char **p;
- int c;
+get_substring (char **p, int c)
{
char *str;
str = *p;
eg: for sname="a" and fname="foo__1aFPFs_i" return "FPFs_i" */
static char *
-get_cfront_method_physname (fname)
- char *fname;
+get_cfront_method_physname (char *fname)
{
int len = 0;
/* FIXME would like to make this generic for g++ too, but
*/
static int
-read_cfront_baseclasses (fip, pp, type, objfile)
- struct field_info *fip;
- struct objfile *objfile;
- char **pp;
- struct type *type;
+read_cfront_baseclasses (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
static struct complaint msg_unknown =
{"\
*/
static int
-read_cfront_member_functions (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_cfront_member_functions (struct field_info *fip, char **pp,
+ struct type *type, struct objfile *objfile)
{
/* This code extracted from read_member_functions
so as to do the similar thing for our funcs */
to add information such as methods to classes.
Examples of "p": "sA;;__ct__1AFv foo__1AFv ;;;" */
int
-resolve_cfront_continuation (objfile, sym, p)
- struct objfile *objfile;
- struct symbol *sym;
- char *p;
+resolve_cfront_continuation (struct objfile *objfile, struct symbol *sym,
+ char *p)
{
struct symbol *ref_sym = 0;
char *sname;
symbol definition. Returns 0 on failure, non-zero on success. */
static int
-resolve_symbol_reference (objfile, sym, p)
- struct objfile *objfile;
- struct symbol *sym;
- char *p;
+resolve_symbol_reference (struct objfile *objfile, struct symbol *sym, char *p)
{
int refnum;
struct symbol *ref_sym = 0;
table. If the symbol table changes, this cache must be cleared
or we are left holding onto data in invalid obstacks. */
void
-stabsread_clear_cache ()
+stabsread_clear_cache (void)
{
ref_count = 0;
ref_chunk = 0;
find them, using their reference numbers as our index.
These will be used later when we resolve references. */
void
-ref_add (refnum, sym, stabs, value)
- int refnum;
- struct symbol *sym;
- char *stabs;
- CORE_ADDR value;
+ref_add (int refnum, struct symbol *sym, char *stabs, CORE_ADDR value)
{
if (ref_count == 0)
ref_chunk = 0;
/* Return defined sym for the reference REFNUM. */
struct symbol *
-ref_search (refnum)
- int refnum;
+ref_search (int refnum)
{
if (refnum < 0 || refnum > ref_count)
return 0;
/* Return value for the reference REFNUM. */
static CORE_ADDR
-ref_search_value (refnum)
- int refnum;
+ref_search_value (int refnum)
{
if (refnum < 0 || refnum > ref_count)
return 0;
reference number. Move STRING beyond the reference id. */
static int
-process_reference (string)
- char **string;
+process_reference (char **string)
{
char *p;
int refnum = 0;
definition for later use. Return the reference number. */
int
-symbol_reference_defined (string)
- char **string;
+symbol_reference_defined (char **string)
{
char *p = *string;
int refnum = 0;
/* ARGSUSED */
struct symbol *
-define_symbol (valu, string, desc, type, objfile)
- CORE_ADDR valu;
- char *string;
- int desc;
- int type;
- struct objfile *objfile;
+define_symbol (CORE_ADDR valu, char *string, int desc, int type,
+ struct objfile *objfile)
{
register struct symbol *sym;
char *p = (char *) strchr (string, ':');
non-zero on success, zero otherwise. */
static int
-resolve_live_range (objfile, sym, p)
- struct objfile *objfile;
- struct symbol *sym;
- char *p;
+resolve_live_range (struct objfile *objfile, struct symbol *sym, char *p)
{
int refnum;
CORE_ADDR start, end;
in objfile OBJFILE. */
static void
-add_live_range (objfile, sym, start, end)
- struct objfile *objfile;
- struct symbol *sym;
- CORE_ADDR start, end;
+add_live_range (struct objfile *objfile, struct symbol *sym, CORE_ADDR start,
+ CORE_ADDR end)
{
struct range_list *r, *rs;
debugger will be able to read the new symbol tables. */
static struct type *
-error_type (pp, objfile)
- char **pp;
- struct objfile *objfile;
+error_type (char **pp, struct objfile *objfile)
{
complain (&error_type_complaint);
while (1)
deciding whether to call read_type. */
struct type *
-read_type (pp, objfile)
- register char **pp;
- struct objfile *objfile;
+read_type (register char **pp, struct objfile *objfile)
{
register struct type *type = 0;
struct type *type1;
Return the proper type node for a given builtin type number. */
static struct type *
-rs6000_builtin_type (typenum)
- int typenum;
+rs6000_builtin_type (int typenum)
{
/* We recognize types numbered from -NUMBER_RECOGNIZED to -1. */
#define NUMBER_RECOGNIZED 34
Returns 1 for success, 0 for failure. */
static int
-read_member_functions (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_member_functions (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
int nfn_fields = 0;
int length = 0;
keep parsing and it's time for error_type(). */
static int
-read_cpp_abbrev (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_cpp_abbrev (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
register char *p;
char *name;
}
static void
-read_one_struct_field (fip, pp, p, type, objfile)
- struct field_info *fip;
- char **pp;
- char *p;
- struct type *type;
- struct objfile *objfile;
+read_one_struct_field (struct field_info *fip, char **pp, char *p,
+ struct type *type, struct objfile *objfile)
{
/* The following is code to work around cfront generated stabs.
The stabs contains full mangled name for each field.
Returns 1 for success, 0 for failure. */
static int
-read_struct_fields (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_struct_fields (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
register char *p;
struct nextfield *new;
static int
-read_baseclasses (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_baseclasses (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
int i;
struct nextfield *new;
so we can look for the vptr base class info. */
static int
-read_tilde_fields (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_tilde_fields (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
register char *p;
}
static int
-attach_fn_fields_to_type (fip, type)
- struct field_info *fip;
- register struct type *type;
+attach_fn_fields_to_type (struct field_info *fip, register struct type *type)
{
register int n;
*/
static int
-read_cfront_static_fields (fip, pp, type, objfile)
- struct field_info *fip;
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_cfront_static_fields (struct field_info *fip, char **pp, struct type *type,
+ struct objfile *objfile)
{
struct nextfield *new;
struct type *stype;
once we have collected all the class members. */
static int
-copy_cfront_struct_fields (fip, type, objfile)
- struct field_info *fip;
- struct type *type;
- struct objfile *objfile;
+copy_cfront_struct_fields (struct field_info *fip, struct type *type,
+ struct objfile *objfile)
{
int nfields = TYPE_NFIELDS (type);
int i;
for this class's virtual functions. */
static int
-attach_fields_to_type (fip, type, objfile)
- struct field_info *fip;
- register struct type *type;
- struct objfile *objfile;
+attach_fields_to_type (struct field_info *fip, register struct type *type,
+ struct objfile *objfile)
{
register int nfields = 0;
register int non_public_fields = 0;
*/
static struct type *
-read_struct_type (pp, type, objfile)
- char **pp;
- struct type *type;
- struct objfile *objfile;
+read_struct_type (char **pp, struct type *type, struct objfile *objfile)
{
struct cleanup *back_to;
struct field_info fi;
array. */
static struct type *
-read_array_type (pp, type, objfile)
- register char **pp;
- register struct type *type;
- struct objfile *objfile;
+read_array_type (register char **pp, register struct type *type,
+ struct objfile *objfile)
{
struct type *index_type, *element_type, *range_type;
int lower, upper;
Also defines the symbols that represent the values of the type. */
static struct type *
-read_enum_type (pp, type, objfile)
- register char **pp;
- register struct type *type;
- struct objfile *objfile;
+read_enum_type (register char **pp, register struct type *type,
+ struct objfile *objfile)
{
register char *p;
char *name;
If encounter garbage, set *BITS to -1 and return 0. */
static long
-read_huge_number (pp, end, bits)
- char **pp;
- int end;
- int *bits;
+read_huge_number (char **pp, int end, int *bits)
{
char *p = *pp;
int sign = 1;
**)-1 if there is an error. */
static struct type **
-read_args (pp, end, objfile)
- char **pp;
- int end;
- struct objfile *objfile;
+read_args (char **pp, int end, struct objfile *objfile)
{
/* FIXME! Remove this arbitrary limit! */
struct type *types[1024], **rval; /* allow for fns of 1023 parameters */
to remain after this function returns. */
void
-common_block_start (name, objfile)
- char *name;
- struct objfile *objfile;
+common_block_start (char *name, struct objfile *objfile)
{
if (common_block_name != NULL)
{
/* Process a N_ECOMM symbol. */
void
-common_block_end (objfile)
- struct objfile *objfile;
+common_block_end (struct objfile *objfile)
{
/* Symbols declared since the BCOMM are to have the common block
start address added in when we know it. common_block and
the common block name). */
static void
-fix_common_block (sym, valu)
- struct symbol *sym;
- int valu;
+fix_common_block (struct symbol *sym, int valu)
{
struct pending *next = (struct pending *) SYMBOL_TYPE (sym);
for (; next; next = next->next)
once this file has been read in. */
void
-add_undefined_type (type)
- struct type *type;
+add_undefined_type (struct type *type)
{
if (undef_types_length == undef_types_allocated)
{
yet defined at the time a pointer to it was made.
Fix: Do a full lookup on the struct/union tag. */
void
-cleanup_undefined_types ()
+cleanup_undefined_types (void)
{
struct type **type;
to. Get these symbols from the minimal symbol table. */
void
-scan_file_globals (objfile)
- struct objfile *objfile;
+scan_file_globals (struct objfile *objfile)
{
int hash;
struct minimal_symbol *msymbol;
to a psymtab. */
void
-stabsread_init ()
+stabsread_init (void)
{
}
file, e.g. a shared library). */
void
-stabsread_new_init ()
+stabsread_new_init (void)
{
/* Empty the hash table of global syms looking for values. */
memset (global_sym_chain, 0, sizeof (global_sym_chain));
start_symtab() is called. */
void
-start_stabs ()
+start_stabs (void)
{
global_stabs = NULL; /* AIX COFF */
/* Leave FILENUM of 0 free for builtin types and this file's types. */
/* Call after end_symtab() */
void
-end_stabs ()
+end_stabs (void)
{
if (type_vector)
{
}
void
-finish_global_stabs (objfile)
- struct objfile *objfile;
+finish_global_stabs (struct objfile *objfile)
{
if (global_stabs)
{
/* Initializer for this module */
void
-_initialize_stabsread ()
+_initialize_stabsread (void)
{
undef_types_allocated = 20;
undef_types_length = 0;
Pass the args the way catch_errors wants them. */
static int show_and_print_stack_frame_stub (void *args);
static int
-show_and_print_stack_frame_stub (args)
- void *args;
+show_and_print_stack_frame_stub (void *args)
{
struct print_stack_frame_args *p = (struct print_stack_frame_args *) args;
Pass the args the way catch_errors wants them. */
static int print_stack_frame_stub (void *args);
static int
-print_stack_frame_stub (args)
- void *args;
+print_stack_frame_stub (void *args)
{
struct print_stack_frame_args *p = (struct print_stack_frame_args *) args;
/* Pass the args the way catch_errors wants them. */
static int
-print_stack_frame_base_stub (args)
- char *args;
+print_stack_frame_base_stub (char *args)
{
struct print_stack_frame_args *p = (struct print_stack_frame_args *) args;
Pass the args the way catch_errors wants them. */
static int print_only_stack_frame_stub (void *);
static int
-print_only_stack_frame_stub (args)
- void *args;
+print_only_stack_frame_stub (void *args)
{
struct print_stack_frame_args *p = (struct print_stack_frame_args *) args;
If SOURCE is -1, print ONLY the source line. */
static void
-print_stack_frame_base (fi, level, source)
- struct frame_info *fi;
- int level;
- int source;
+print_stack_frame_base (struct frame_info *fi, int level, int source)
{
struct print_stack_frame_args args;
If SOURCE is -1, print ONLY the source line. */
void
-show_and_print_stack_frame (fi, level, source)
- struct frame_info *fi;
- int level;
- int source;
+show_and_print_stack_frame (struct frame_info *fi, int level, int source)
{
struct print_stack_frame_args args;
If SOURCE is -1, print ONLY the source line. */
void
-print_stack_frame (fi, level, source)
- struct frame_info *fi;
- int level;
- int source;
+print_stack_frame (struct frame_info *fi, int level, int source)
{
struct print_stack_frame_args args;
If SOURCE is -1, print ONLY the source line. */
void
-print_only_stack_frame (fi, level, source)
- struct frame_info *fi;
- int level;
- int source;
+print_only_stack_frame (struct frame_info *fi, int level, int source)
{
struct print_stack_frame_args args;
/* Pass the args the way catch_errors wants them. */
static int
-print_args_stub (args)
- PTR args;
+print_args_stub (PTR args)
{
int numargs;
struct print_args_args *p = (struct print_args_args *) args;
LOC_AND_SRC: Print location and source line. */
static void
-print_frame_info_base (fi, level, source, args)
- struct frame_info *fi;
- int level;
- int source;
- int args;
+print_frame_info_base (struct frame_info *fi, int level, int source, int args)
{
struct symtab_and_line sal;
int source_print;
#if 0
void
-stack_publish_stopped_with_no_frame ()
+stack_publish_stopped_with_no_frame (void)
{
TUIDO (((TuiOpaqueFuncPtr) tuiUpdateOnEnd));
/* Show or print the frame info. If this is the tui, it will be shown in
the source display */
void
-print_frame_info (fi, level, source, args)
- struct frame_info *fi;
- register int level;
- int source;
- int args;
+print_frame_info (struct frame_info *fi, register int level, int source,
+ int args)
{
if (!tui_version)
print_frame_info_base (fi, level, source, args);
/* Show the frame info. If this is the tui, it will be shown in
the source display otherwise, nothing is done */
void
-show_stack_frame (fi)
- struct frame_info *fi;
+show_stack_frame (struct frame_info *fi)
{
TUIDO (((TuiOpaqueFuncPtr) tui_vShowFrameInfo, fi));
}
this function never returns NULL). */
struct frame_info *
-parse_frame_specification (frame_exp)
- char *frame_exp;
+parse_frame_specification (char *frame_exp)
{
int numargs = 0;
#define MAXARGS 4
This means absolutely all information in the frame is printed. */
static void
-frame_info (addr_exp, from_tty)
- char *addr_exp;
- int from_tty;
+frame_info (char *addr_exp, int from_tty)
{
struct frame_info *fi;
struct symtab_and_line sal;
static int backtrace_limit;
static void
-set_backtrace_limit_command (count_exp, from_tty)
- char *count_exp;
- int from_tty;
+set_backtrace_limit_command (char *count_exp, int from_tty)
{
int count = parse_and_eval_address (count_exp);
}
static void
-backtrace_limit_info (arg, from_tty)
- char *arg;
- int from_tty;
+backtrace_limit_info (char *arg, int from_tty)
{
if (arg)
error ("\"Info backtrace-limit\" takes no arguments.");
static void backtrace_command_1 (char *count_exp, int show_locals,
int from_tty);
static void
-backtrace_command_1 (count_exp, show_locals, from_tty)
- char *count_exp;
- int show_locals;
- int from_tty;
+backtrace_command_1 (char *count_exp, int show_locals, int from_tty)
{
struct frame_info *fi;
register int count;
}
static void
-backtrace_command (arg, from_tty)
- char *arg;
- int from_tty;
+backtrace_command (char *arg, int from_tty)
{
struct cleanup *old_chain = (struct cleanup *) NULL;
char **argv = (char **) NULL;
static void backtrace_full_command (char *arg, int from_tty);
static void
-backtrace_full_command (arg, from_tty)
- char *arg;
- int from_tty;
+backtrace_full_command (char *arg, int from_tty)
{
backtrace_command_1 (arg, 1, from_tty);
}
Return 1 if any variables were printed; 0 otherwise. */
static int
-print_block_frame_locals (b, fi, num_tabs, stream)
- struct block *b;
- register struct frame_info *fi;
- int num_tabs;
- register struct ui_file *stream;
+print_block_frame_locals (struct block *b, register struct frame_info *fi,
+ int num_tabs, register struct ui_file *stream)
{
int nsyms;
register int i, j;
/* Same, but print labels. */
static int
-print_block_frame_labels (b, have_default, stream)
- struct block *b;
- int *have_default;
- register struct ui_file *stream;
+print_block_frame_labels (struct block *b, int *have_default,
+ register struct ui_file *stream)
{
int nsyms;
register int i;
on the function running in FRAME. */
static void
-print_frame_local_vars (fi, num_tabs, stream)
- register struct frame_info *fi;
- register int num_tabs;
- register struct ui_file *stream;
+print_frame_local_vars (register struct frame_info *fi, register int num_tabs,
+ register struct ui_file *stream)
{
register struct block *block = get_frame_block (fi);
register int values_printed = 0;
/* Same, but print labels. */
static void
-print_frame_label_vars (fi, this_level_only, stream)
- register struct frame_info *fi;
- int this_level_only;
- register struct ui_file *stream;
+print_frame_label_vars (register struct frame_info *fi, int this_level_only,
+ register struct ui_file *stream)
{
register struct blockvector *bl;
register struct block *block = get_frame_block (fi);
/* ARGSUSED */
void
-locals_info (args, from_tty)
- char *args;
- int from_tty;
+locals_info (char *args, int from_tty)
{
if (!selected_frame)
error ("No frame selected.");
}
static void
-catch_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+catch_info (char *ignore, int from_tty)
{
struct symtab_and_line *sal;
}
static void
-print_frame_arg_vars (fi, stream)
- register struct frame_info *fi;
- register struct ui_file *stream;
+print_frame_arg_vars (register struct frame_info *fi,
+ register struct ui_file *stream)
{
struct symbol *func = get_frame_function (fi);
register struct block *b;
}
void
-args_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+args_info (char *ignore, int from_tty)
{
if (!selected_frame)
error ("No frame selected.");
static void
-args_plus_locals_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+args_plus_locals_info (char *ignore, int from_tty)
{
args_info (ignore, from_tty);
locals_info (ignore, from_tty);
LEVEL may be -1 if an actual level number is not known. */
void
-select_frame (fi, level)
- struct frame_info *fi;
- int level;
+select_frame (struct frame_info *fi, int level)
{
register struct symtab *s;
/* Select frame FI, noting that its stack level is LEVEL. Also print
the stack frame and show the source if this is the tui version. */
void
-select_and_print_frame (fi, level)
- struct frame_info *fi;
- int level;
+select_and_print_frame (struct frame_info *fi, int level)
{
select_frame (fi, level);
if (fi)
not the TUI */
#if 0
void
-select_and_maybe_print_frame (fi, level)
- struct frame_info *fi;
- int level;
+select_and_maybe_print_frame (struct frame_info *fi, int level)
{
if (!tui_version)
select_frame (fi, level);
If there is no selected frame, *FRAMEP is set to NULL. */
void
-record_selected_frame (frameaddrp, levelp)
- CORE_ADDR *frameaddrp;
- int *levelp;
+record_selected_frame (CORE_ADDR *frameaddrp, int *levelp)
{
*frameaddrp = selected_frame ? selected_frame->frame : 0;
*levelp = selected_frame_level;
Can return zero under various legitimate circumstances. */
struct block *
-get_selected_block ()
+get_selected_block (void)
{
if (!target_has_stack)
return 0;
how much farther the original request asked to go. */
struct frame_info *
-find_relative_frame (frame, level_offset_ptr)
- register struct frame_info *frame;
- register int *level_offset_ptr;
+find_relative_frame (register struct frame_info *frame,
+ register int *level_offset_ptr)
{
register struct frame_info *prev;
register struct frame_info *frame1;
/* ARGSUSED */
#ifdef UI_OUT
void
-select_frame_command_wrapper (level_exp, from_tty)
- char *level_exp;
- int from_tty;
+select_frame_command_wrapper (char *level_exp, int from_tty)
{
select_frame_command (level_exp, from_tty);
}
#endif
static void
-select_frame_command (level_exp, from_tty)
- char *level_exp;
- int from_tty;
+select_frame_command (char *level_exp, int from_tty)
{
register struct frame_info *frame, *frame1;
unsigned int level = 0;
frame. */
void
-frame_command (level_exp, from_tty)
- char *level_exp;
- int from_tty;
+frame_command (char *level_exp, int from_tty)
{
select_frame_command (level_exp, from_tty);
show_and_print_stack_frame (selected_frame, selected_frame_level, 1);
/* The XDB Compatibility command to print the current frame. */
static void
-current_frame_command (level_exp, from_tty)
- char *level_exp;
- int from_tty;
+current_frame_command (char *level_exp, int from_tty)
{
if (target_has_stack == 0 || selected_frame == 0)
error ("No stack.");
/* ARGSUSED */
static void
-up_silently_base (count_exp)
- char *count_exp;
+up_silently_base (char *count_exp)
{
register struct frame_info *fi;
int count = 1, count1;
}
static void
-up_silently_command (count_exp, from_tty)
- char *count_exp;
- int from_tty;
+up_silently_command (char *count_exp, int from_tty)
{
up_silently_base (count_exp);
if (tui_version)
}
static void
-up_command (count_exp, from_tty)
- char *count_exp;
- int from_tty;
+up_command (char *count_exp, int from_tty)
{
up_silently_base (count_exp);
show_and_print_stack_frame (selected_frame, selected_frame_level, 1);
/* ARGSUSED */
static void
-down_silently_base (count_exp)
- char *count_exp;
+down_silently_base (char *count_exp)
{
register struct frame_info *frame;
int count = -1, count1;
/* ARGSUSED */
static void
-down_silently_command (count_exp, from_tty)
- char *count_exp;
- int from_tty;
+down_silently_command (char *count_exp, int from_tty)
{
down_silently_base (count_exp);
if (tui_version)
}
static void
-down_command (count_exp, from_tty)
- char *count_exp;
- int from_tty;
+down_command (char *count_exp, int from_tty)
{
down_silently_base (count_exp);
show_and_print_stack_frame (selected_frame, selected_frame_level, 1);
\f
#ifdef UI_OUT
void
-return_command_wrapper (retval_exp, from_tty)
- char *retval_exp;
- int from_tty;
+return_command_wrapper (char *retval_exp, int from_tty)
{
return_command (retval_exp, from_tty);
}
#endif
static void
-return_command (retval_exp, from_tty)
- char *retval_exp;
- int from_tty;
+return_command (char *retval_exp, int from_tty)
{
struct symbol *thisfun;
CORE_ADDR selected_frame_addr;
static void func_command (char *arg, int from_tty);
static void
-func_command (arg, from_tty)
- char *arg;
- int from_tty;
+func_command (char *arg, int from_tty)
{
struct frame_info *fp;
int found = 0;
/* Gets the language of the current frame. */
enum language
-get_frame_language ()
+get_frame_language (void)
{
register struct symtab *s;
enum language flang; /* The language of the current frame */
}
\f
void
-_initialize_stack ()
+_initialize_stack (void)
{
#if 0
backtrace_limit = 30;
/* Random system calls, mostly no-ops to prevent link problems */
-ioctl (desc, code, arg)
+ioctl (int desc, int code, int arg)
{
}
{
}
-kill ()
+kill (void)
{
}
-getpid ()
+getpid (void)
{
return 0;
}
-sigsetmask ()
+sigsetmask (void)
{
}
-chdir ()
+chdir (void)
{
}
char *
-getcwd (buf, len)
- char *buf;
- unsigned int len;
+getcwd (char *buf, unsigned int len)
{
buf[0] = '/';
buf[1] = 0;
/* Used to check for existence of .gdbinit. Say no. */
-access ()
+access (void)
{
return -1;
}
-exit ()
+exit (void)
{
error ("Fatal error; restarting.");
}
int sourcedesc;
-open (filename, modes)
- char *filename;
- int modes;
+open (char *filename, int modes)
{
register char *next;
return 0;
}
-close (desc)
- int desc;
+close (int desc)
{
sourceptr = 0;
sourcedesc++;
}
FILE *
-fopen (filename, modes)
- char *filename;
- char *modes;
+fopen (char *filename, char *modes)
{
return (FILE *) open (filename, *modes == 'w');
}
FILE *
-fdopen (desc)
- int desc;
+fdopen (int desc)
{
return (FILE *) desc;
}
-fclose (desc)
- int desc;
+fclose (int desc)
{
close (desc);
}
-fstat (desc, statbuf)
- struct stat *statbuf;
+fstat (int desc, struct stat *statbuf)
{
if (desc != sourcedesc)
{
statbuf->st_size = sourcesize;
}
-myread (desc, destptr, size, filename)
- int desc;
- char *destptr;
- int size;
- char *filename;
+myread (int desc, char *destptr, int size, char *filename)
{
int len = min (sourceleft, size);
}
int
-fread (bufp, numelts, eltsize, stream)
+fread (int bufp, int numelts, int eltsize, int stream)
{
register int elts = min (numelts, sourceleft / eltsize);
register int len = elts * eltsize;
}
int
-fgetc (desc)
- int desc;
+fgetc (int desc)
{
if (desc == (int) stdin)
return *sourceptr++;
}
-lseek (desc, pos)
- int desc;
- int pos;
+lseek (int desc, int pos)
{
if (desc != sourcedesc)
/* Output in kdb can go only to the terminal, so the stream
specified may be ignored. */
-printf (a1, a2, a3, a4, a5, a6, a7, a8, a9)
+printf (int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8, int a9)
{
char buffer[1024];
sprintf (buffer, a1, a2, a3, a4, a5, a6, a7, a8, a9);
display_string (buffer);
}
-fprintf (ign, a1, a2, a3, a4, a5, a6, a7, a8, a9)
+fprintf (int ign, int a1, int a2, int a3, int a4, int a5, int a6, int a7,
+ int a8, int a9)
{
char buffer[1024];
sprintf (buffer, a1, a2, a3, a4, a5, a6, a7, a8, a9);
display_string (buffer);
}
-fwrite (buf, numelts, size, stream)
- register char *buf;
- int numelts, size;
+fwrite (register char *buf, int numelts, int size, int stream)
{
register int i = numelts * size;
while (i-- > 0)
fputc (*buf++, stream);
}
-fputc (c, ign)
+fputc (int c, int ign)
{
char buf[2];
buf[0] = c;
library would cause fflush to be loaded from it too.
In fact there should be no need to call this (I hope). */
-_flsbuf ()
+_flsbuf (void)
{
error ("_flsbuf was actually called.");
}
-fflush (ign)
+fflush (int ign)
{
}
\f
/* Entries into core and inflow, needed only to make things link ok. */
-exec_file_command ()
+exec_file_command (void)
{
}
-core_file_command ()
+core_file_command (void)
{
}
char *
-get_exec_file (err)
- int err;
+get_exec_file (int err)
{
/* Makes one printout look reasonable; value does not matter otherwise. */
return "run";
/* Nonzero if there is a core file. */
-have_core_file_p ()
+have_core_file_p (void)
{
return 0;
}
-kill_command ()
+kill_command (void)
{
inferior_pid = 0;
}
-terminal_inferior ()
+terminal_inferior (void)
{
}
-terminal_ours ()
+terminal_ours (void)
{
}
-terminal_init_inferior ()
+terminal_init_inferior (void)
{
}
-write_inferior_register ()
+write_inferior_register (void)
{
}
-read_inferior_register ()
+read_inferior_register (void)
{
}
-read_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+read_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
memcpy (myaddr, memaddr, len);
}
/* Always return 0 indicating success. */
-write_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+write_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
memcpy (memaddr, myaddr, len);
return 0;
static REGISTER_TYPE saved_regs[NUM_REGS];
REGISTER_TYPE
-read_register (regno)
- int regno;
+read_register (int regno)
{
if (regno < 0 || regno >= NUM_REGS)
error ("Register number %d out of range.", regno);
}
void
-write_register (regno, value)
- int regno;
- REGISTER_TYPE value;
+write_register (int regno, REGISTER_TYPE value)
{
if (regno < 0 || regno >= NUM_REGS)
error ("Register number %d out of range.", regno);
\f
/* System calls needed in relation to running the "inferior". */
-vfork ()
+vfork (void)
{
/* Just appear to "succeed". Say the inferior's pid is 1. */
return 1;
that has just been forked. That code never runs, when standalone,
and these definitions are so it will link without errors. */
-ptrace ()
+ptrace (void)
{
}
-setpgrp ()
+setpgrp (void)
{
}
-execle ()
+execle (void)
{
}
-_exit ()
+_exit (void)
{
}
\f
/* Malloc calls these. */
-malloc_warning (str)
- char *str;
+malloc_warning (char *str)
{
printf ("\n%s.\n\n", str);
}
char *memory_limit;
char *
-sbrk (amount)
- int amount;
+sbrk (int amount)
{
if (next_free + amount > memory_limit)
return (char *) -1;
/* Various ways malloc might ask where end of memory is. */
char *
-ulimit ()
+ulimit (void)
{
return memory_limit;
}
int
-vlimit ()
+vlimit (void)
{
return memory_limit - next_free;
}
-getrlimit (addr)
- struct rlimit *addr;
+getrlimit (struct rlimit *addr)
{
addr->rlim_cur = memory_limit - next_free;
}
static int fault_code;
static REGISTER_TYPE gdb_stack;
-resume ()
+resume (void)
{
REGISTER_TYPE restore[NUM_REGS];
/* Control does not drop through here! */
}
-save_frame_pointer (val)
- CORE_ADDR val;
+save_frame_pointer (CORE_ADDR val)
{
gdb_stack = val;
}
The exact format is machine-dependent and is known only
in the definition of PUSH_REGISTERS. */
-fault ()
+fault (void)
{
/* Transfer all registers and fault code to the stack
in canonical order: registers in order of GDB register number,
/* Control does not reach here */
}
-restore_gdb ()
+restore_gdb (void)
{
CORE_ADDR new_fp = gdb_stack;
/* Switch to GDB's stack */
arguments to this function, copy them into the standard place
for the program's registers while GDB is running. */
-save_registers (firstreg)
- int firstreg;
+save_registers (int firstreg)
{
memcpy (saved_regs, &firstreg, sizeof saved_regs);
fault_code = (&firstreg)[NUM_REGS];
static int fault_table[] = FAULT_TABLE;
int
-wait (w)
- WAITTYPE *w;
+wait (WAITTYPE *w)
{
WSETSTOP (*w, fault_table[fault_code / FAULT_CODE_UNITS]);
return inferior_pid;
int kdb_stack_beg[STACK_SIZE / sizeof (int)];
int kdb_stack_end;
-_initialize_standalone ()
+_initialize_standalone (void)
{
register char *next;
#include <servers/netname_defs.h>
void
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
kern_return_t kr;
mach_msg_header_t msg;
/* Read symbol table from file and returns the offset into the file
* where symbol sym_name is located. If error, print message and
* exit. */
-get_offset (file, sym_name)
- char *file;
- char *sym_name;
+get_offset (char *file, char *sym_name)
{
int f;
struct exec file_hdr;
return (N_TXTOFF (file_hdr) + core_addr - origin);
}
-find_symbol (sym_name, symbol_table, length, strings)
- char *sym_name;
- struct nlist *symbol_table;
- int length;
- char *strings;
+find_symbol (char *sym_name, struct nlist *symbol_table, int length,
+ char *strings)
{
register struct nlist *sym;
static void fetch_core_registers (char *, unsigned, int, CORE_ADDR);
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_status inferior_fp_registers;
};
void
-_initialize_core_sun3 ()
+_initialize_core_sun3 (void)
{
add_core_fns (&sun3_core_fns);
}
\f
void
-core_file_command (filename, from_tty)
- char *filename;
- int from_tty;
+core_file_command (char *filename, int from_tty)
{
int val;
printf_unfiltered ("No core file now.\n");
}
-i387_to_double (from, to)
- char *from;
- char *to;
+i387_to_double (char *from, char *to)
{
long *lp;
/* push extended mode on 387 stack, then pop in double mode
asm ("popl %eax"); /* flush saved copy */
}
-double_to_i387 (from, to)
- char *from;
- char *to;
+double_to_i387 (char *from, char *to)
{
/* push double mode on 387 stack, then pop in extended mode
* no errors are possible because every 64-bit pattern
}
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_state inferior_fp_registers;
Otherwise, REGNO specifies which register (so we can save time). */
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct regs inferior_registers;
struct fp_state inferior_fp_registers;
comparison function takes two "void *" pointers. */
static int
-compare_symbols (s1p, s2p)
- const PTR s1p;
- const PTR s2p;
+compare_symbols (const PTR s1p, const PTR s2p)
{
register struct symbol **s1, **s2;
*/
static int
-compare_psymbols (s1p, s2p)
- const PTR s1p;
- const PTR s2p;
+compare_psymbols (const PTR s1p, const PTR s2p)
{
register char *st1 = SYMBOL_NAME (*(struct partial_symbol **) s1p);
register char *st2 = SYMBOL_NAME (*(struct partial_symbol **) s2p);
}
void
-sort_pst_symbols (pst)
- struct partial_symtab *pst;
+sort_pst_symbols (struct partial_symtab *pst)
{
/* Sort the global list; don't sort the static list */
/* Call sort_block_syms to sort alphabetically the symbols of one block. */
void
-sort_block_syms (b)
- register struct block *b;
+sort_block_syms (register struct block *b)
{
qsort (&BLOCK_SYM (b, 0), BLOCK_NSYMS (b),
sizeof (struct symbol *), compare_symbols);
the symbols of each block of one symtab. */
void
-sort_symtab_syms (s)
- register struct symtab *s;
+sort_symtab_syms (register struct symtab *s)
{
register struct blockvector *bv;
int nbl;
may be part of a larger string and we are only saving a substring. */
char *
-obsavestring (ptr, size, obstackp)
- char *ptr;
- int size;
- struct obstack *obstackp;
+obsavestring (char *ptr, int size, struct obstack *obstackp)
{
register char *p = (char *) obstack_alloc (obstackp, size + 1);
/* Open-coded memcpy--saves function call time. These strings are usually
in the obstack pointed to by OBSTACKP. */
char *
-obconcat (obstackp, s1, s2, s3)
- struct obstack *obstackp;
- const char *s1, *s2, *s3;
+obconcat (struct obstack *obstackp, const char *s1, const char *s2,
+ const char *s3)
{
register int len = strlen (s1) + strlen (s2) + strlen (s3) + 1;
register char *val = (char *) obstack_alloc (obstackp, len);
int currently_reading_symtab = 0;
static void
-decrement_reading_symtab (dummy)
- void *dummy;
+decrement_reading_symtab (void *dummy)
{
currently_reading_symtab--;
}
case inline. */
struct symtab *
-psymtab_to_symtab (pst)
- register struct partial_symtab *pst;
+psymtab_to_symtab (register struct partial_symtab *pst)
{
/* If it's been looked up before, return it. */
if (pst->symtab)
/* Initialize entry point information for this objfile. */
void
-init_entry_point_info (objfile)
- struct objfile *objfile;
+init_entry_point_info (struct objfile *objfile)
{
/* Save startup file's range of PC addresses to help blockframe.c
decide where the bottom of the stack is. */
/* Get current entry point address. */
CORE_ADDR
-entry_point_address ()
+entry_point_address (void)
{
return symfile_objfile ? symfile_objfile->ei.entry_point : 0;
}
lowest-addressed loadable section. */
void
-find_lowest_section (abfd, sect, obj)
- bfd *abfd;
- asection *sect;
- PTR obj;
+find_lowest_section (bfd *abfd, asection *sect, PTR obj)
{
asection **lowest = (asection **) obj;
for the objectfile OBJFILE and stuffs ADDR into all of the offsets. */
void
-default_symfile_offsets (objfile, addrs)
- struct objfile *objfile;
- struct section_addr_info *addrs;
+default_symfile_offsets (struct objfile *objfile,
+ struct section_addr_info *addrs)
{
int i;
asection *sect = NULL;
the symbol reading (and complaints can be more terse about it). */
void
-syms_from_objfile (objfile, addrs, mainline, verbo)
- struct objfile *objfile;
- struct section_addr_info *addrs;
- int mainline;
- int verbo;
+syms_from_objfile (struct objfile *objfile, struct section_addr_info *addrs,
+ int mainline, int verbo)
{
asection *lower_sect;
asection *sect;
objfile. */
void
-new_symfile_objfile (objfile, mainline, verbo)
- struct objfile *objfile;
- int mainline;
- int verbo;
+new_symfile_objfile (struct objfile *objfile, int mainline, int verbo)
{
/* If this is the main symbol file we have to clean up all users of the
Upon failure, jumps back to command level (never returns). */
struct objfile *
-symbol_file_add (name, from_tty, addrs, mainline, flags)
- char *name;
- int from_tty;
- struct section_addr_info *addrs;
- int mainline;
- int flags;
+symbol_file_add (char *name, int from_tty, struct section_addr_info *addrs,
+ int mainline, int flags)
{
struct objfile *objfile;
struct partial_symtab *psymtab;
and pass that to symbol_file_add(). This is no longer supported. */
void
-symbol_file_command (args, from_tty)
- char *args;
- int from_tty;
+symbol_file_command (char *args, int from_tty)
{
char **argv;
char *name = NULL;
FIXME. */
static void
-set_initial_language ()
+set_initial_language (void)
{
struct partial_symtab *pst;
enum language lang = language_unknown;
In case of trouble, error() is called. */
bfd *
-symfile_bfd_open (name)
- char *name;
+symfile_bfd_open (char *name)
{
bfd *sym_bfd;
int desc;
to handle. */
void
-add_symtab_fns (sf)
- struct sym_fns *sf;
+add_symtab_fns (struct sym_fns *sf)
{
sf->next = symtab_fns;
symtab_fns = sf;
symbol file. */
static void
-find_sym_fns (objfile)
- struct objfile *objfile;
+find_sym_fns (struct objfile *objfile)
{
struct sym_fns *sf;
enum bfd_flavour our_flavour = bfd_get_flavour (objfile->obfd);
/* This function runs the load command of our current target. */
static void
-load_command (arg, from_tty)
- char *arg;
- int from_tty;
+load_command (char *arg, int from_tty)
{
if (arg == NULL)
arg = get_exec_file (1);
function signature). */
void
-report_transfer_performance (data_count, start_time, end_time)
- unsigned long data_count;
- time_t start_time, end_time;
+report_transfer_performance (unsigned long data_count, time_t start_time,
+ time_t end_time)
{
print_transfer_performance (gdb_stdout, data_count, end_time - start_time, 0);
}
/* ARGSUSED */
static void
-add_symbol_file_command (args, from_tty)
- char *args;
- int from_tty;
+add_symbol_file_command (char *args, int from_tty)
{
char *filename = NULL;
int flags = OBJF_USERLOADED;
}
\f
static void
-add_shared_symbol_files_command (args, from_tty)
- char *args;
- int from_tty;
+add_shared_symbol_files_command (char *args, int from_tty)
{
#ifdef ADD_SHARED_SYMBOL_FILES
ADD_SHARED_SYMBOL_FILES (args, from_tty);
\f
/* Re-read symbols if a symbol-file has changed. */
void
-reread_symbols ()
+reread_symbols (void)
{
struct objfile *objfile;
long new_modtime;
static int fl_table_size, fl_table_next;
static void
-add_filename_language (ext, lang)
- char *ext;
- enum language lang;
+add_filename_language (char *ext, enum language lang)
{
if (fl_table_next >= fl_table_size)
{
static char *ext_args;
static void
-set_ext_lang_command (args, from_tty)
- char *args;
- int from_tty;
+set_ext_lang_command (char *args, int from_tty)
{
int i;
char *cp = ext_args;
}
static void
-info_ext_lang_command (args, from_tty)
- char *args;
- int from_tty;
+info_ext_lang_command (char *args, int from_tty)
{
int i;
}
static void
-init_filename_language_table ()
+init_filename_language_table (void)
{
if (fl_table_size == 0) /* protect against repetition */
{
}
enum language
-deduce_language_from_filename (filename)
- char *filename;
+deduce_language_from_filename (char *filename)
{
int i;
char *cp;
*/
struct symtab *
-allocate_symtab (filename, objfile)
- char *filename;
- struct objfile *objfile;
+allocate_symtab (char *filename, struct objfile *objfile)
{
register struct symtab *symtab;
}
struct partial_symtab *
-allocate_psymtab (filename, objfile)
- char *filename;
- struct objfile *objfile;
+allocate_psymtab (char *filename, struct objfile *objfile)
{
struct partial_symtab *psymtab;
}
void
-discard_psymtab (pst)
- struct partial_symtab *pst;
+discard_psymtab (struct partial_symtab *pst)
{
struct partial_symtab **prev_pst;
table data. */
void
-clear_symtab_users ()
+clear_symtab_users (void)
{
/* Someday, we should do better than this, by only blowing away
the things that really need to be blown. */
static int clear_symtab_users_done;
static void
-clear_symtab_users_once ()
+clear_symtab_users_once (void)
{
/* Enforce once-per-`do_cleanups'-semantics */
if (clear_symtab_users_queued <= clear_symtab_users_done)
/* Delete the specified psymtab, and any others that reference it. */
static void
-cashier_psymtab (pst)
- struct partial_symtab *pst;
+cashier_psymtab (struct partial_symtab *pst)
{
struct partial_symtab *ps, *pprev = NULL;
int i;
all stray pointers into the freed symtab. */
int
-free_named_symtabs (name)
- char *name;
+free_named_symtabs (char *name)
{
#if 0
/* FIXME: With the new method of each objfile having it's own
FILENAME is the name of the symbol-file we are reading from. */
struct partial_symtab *
-start_psymtab_common (objfile, section_offsets,
- filename, textlow, global_syms, static_syms)
- struct objfile *objfile;
- struct section_offsets *section_offsets;
- char *filename;
- CORE_ADDR textlow;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+start_psymtab_common (struct objfile *objfile,
+ struct section_offsets *section_offsets, char *filename,
+ CORE_ADDR textlow, struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
struct partial_symtab *psymtab;
Since one arg is a struct, we pass in a ptr and deref it (sigh). */
void
-add_psymbol_to_list (name, namelength, namespace, class, list, val, coreaddr,
- language, objfile)
- char *name;
- int namelength;
- namespace_enum namespace;
- enum address_class class;
- struct psymbol_allocation_list *list;
- long val; /* Value as a long */
- CORE_ADDR coreaddr; /* Value as a CORE_ADDR */
- enum language language;
- struct objfile *objfile;
+add_psymbol_to_list (char *name, int namelength, namespace_enum namespace,
+ enum address_class class,
+ struct psymbol_allocation_list *list, long val, /* Value as a long */
+ CORE_ADDR coreaddr, /* Value as a CORE_ADDR */
+ enum language language, struct objfile *objfile)
{
register struct partial_symbol *psym;
char *buf = alloca (namelength + 1);
* name. */
void
-add_psymbol_with_dem_name_to_list (name, namelength, dem_name, dem_namelength,
- namespace, class, list, val, coreaddr, language, objfile)
- char *name;
- int namelength;
- char *dem_name;
- int dem_namelength;
- namespace_enum namespace;
- enum address_class class;
- struct psymbol_allocation_list *list;
- long val; /* Value as a long */
- CORE_ADDR coreaddr; /* Value as a CORE_ADDR */
- enum language language;
- struct objfile *objfile;
+add_psymbol_with_dem_name_to_list (char *name, int namelength, char *dem_name,
+ int dem_namelength, namespace_enum namespace,
+ enum address_class class,
+ struct psymbol_allocation_list *list, long val, /* Value as a long */
+ CORE_ADDR coreaddr, /* Value as a CORE_ADDR */
+ enum language language,
+ struct objfile *objfile)
{
register struct partial_symbol *psym;
char *buf = alloca (namelength + 1);
/* Initialize storage for partial symbols. */
void
-init_psymbol_list (objfile, total_symbols)
- struct objfile *objfile;
- int total_symbols;
+init_psymbol_list (struct objfile *objfile, int total_symbols)
{
/* Free any previously allocated psymbol lists. */
SECTION is loaded at an address different from where it will "run". */
int
-section_is_overlay (section)
- asection *section;
+section_is_overlay (asection *section)
{
if (overlay_debugging)
if (section && section->lma != 0 &&
Invalidate the mapped state of all overlay sections (mark it as stale). */
static void
-overlay_invalidate_all ()
+overlay_invalidate_all (void)
{
struct objfile *objfile;
struct obj_section *sect;
section is stale, then call TARGET_OVERLAY_UPDATE to refresh it. */
static int
-overlay_is_mapped (osect)
- struct obj_section *osect;
+overlay_is_mapped (struct obj_section *osect)
{
if (osect == 0 || !section_is_overlay (osect->the_bfd_section))
return 0;
Returns true if section is an overlay, and is currently mapped. */
int
-section_is_mapped (section)
- asection *section;
+section_is_mapped (asection *section)
{
struct objfile *objfile;
struct obj_section *osect;
If PC falls into the lma range of SECTION, return true, else false. */
CORE_ADDR
-pc_in_unmapped_range (pc, section)
- CORE_ADDR pc;
- asection *section;
+pc_in_unmapped_range (CORE_ADDR pc, asection *section)
{
int size;
If PC falls into the vma range of SECTION, return true, else false. */
CORE_ADDR
-pc_in_mapped_range (pc, section)
- CORE_ADDR pc;
- asection *section;
+pc_in_mapped_range (CORE_ADDR pc, asection *section)
{
int size;
May be the same as PC. */
CORE_ADDR
-overlay_unmapped_address (pc, section)
- CORE_ADDR pc;
- asection *section;
+overlay_unmapped_address (CORE_ADDR pc, asection *section)
{
if (overlay_debugging)
if (section && section_is_overlay (section) &&
May be the same as PC. */
CORE_ADDR
-overlay_mapped_address (pc, section)
- CORE_ADDR pc;
- asection *section;
+overlay_mapped_address (CORE_ADDR pc, asection *section)
{
if (overlay_debugging)
if (section && section_is_overlay (section) &&
depending on whether the section is mapped or not. */
CORE_ADDR
-symbol_overlayed_address (address, section)
- CORE_ADDR address;
- asection *section;
+symbol_overlayed_address (CORE_ADDR address, asection *section)
{
if (overlay_debugging)
{
Else if PC matches an unmapped section's LMA, return that section. */
asection *
-find_pc_overlay (pc)
- CORE_ADDR pc;
+find_pc_overlay (CORE_ADDR pc)
{
struct objfile *objfile;
struct obj_section *osect, *best_match = NULL;
currently marked as MAPPED, return that section. Else return NULL. */
asection *
-find_pc_mapped_section (pc)
- CORE_ADDR pc;
+find_pc_mapped_section (CORE_ADDR pc)
{
struct objfile *objfile;
struct obj_section *osect;
Print a list of mapped sections and their PC ranges */
void
-list_overlays_command (args, from_tty)
- char *args;
- int from_tty;
+list_overlays_command (char *args, int from_tty)
{
int nmapped = 0;
struct objfile *objfile;
Mark the named section as mapped (ie. residing at its VMA address). */
void
-map_overlay_command (args, from_tty)
- char *args;
- int from_tty;
+map_overlay_command (char *args, int from_tty)
{
struct objfile *objfile, *objfile2;
struct obj_section *sec, *sec2;
(ie. resident in its LMA address range, rather than the VMA range). */
void
-unmap_overlay_command (args, from_tty)
- char *args;
- int from_tty;
+unmap_overlay_command (char *args, int from_tty)
{
struct objfile *objfile;
struct obj_section *sec;
Possibly this should be done via a set/show command. */
static void
-overlay_auto_command (args, from_tty)
- char *args;
- int from_tty;
+overlay_auto_command (char *args, int from_tty)
{
overlay_debugging = -1;
if (info_verbose)
Possibly this should be done via a set/show command. */
static void
-overlay_manual_command (args, from_tty)
- char *args;
- int from_tty;
+overlay_manual_command (char *args, int from_tty)
{
overlay_debugging = 1;
if (info_verbose)
Possibly this should be done via a set/show command. */
static void
-overlay_off_command (args, from_tty)
- char *args;
- int from_tty;
+overlay_off_command (char *args, int from_tty)
{
overlay_debugging = 0;
if (info_verbose)
}
static void
-overlay_load_command (args, from_tty)
- char *args;
- int from_tty;
+overlay_load_command (char *args, int from_tty)
{
if (target_overlay_update)
(*target_overlay_update) (NULL);
struct cmd_list_element *overlaylist;
static void
-overlay_command (args, from_tty)
- char *args;
- int from_tty;
+overlay_command (char *args, int from_tty)
{
printf_unfiltered
("\"overlay\" must be followed by the name of an overlay command.\n");
/* Throw away the cached copy of _ovly_table */
static void
-simple_free_overlay_table ()
+simple_free_overlay_table (void)
{
if (cache_ovly_table)
free (cache_ovly_table);
#if 0
/* Throw away the cached copy of _ovly_region_table */
static void
-simple_free_overlay_region_table ()
+simple_free_overlay_region_table (void)
{
if (cache_ovly_region_table)
free (cache_ovly_region_table);
/* Read an array of ints from the target into a local buffer.
Convert to host order. int LEN is number of ints */
static void
-read_target_long_array (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- unsigned int *myaddr;
- int len;
+read_target_long_array (CORE_ADDR memaddr, unsigned int *myaddr, int len)
{
char *buf = alloca (len * TARGET_LONG_BYTES);
int i;
/* Find and grab a copy of the target _ovly_table
(and _novlys, which is needed for the table's size) */
static int
-simple_read_overlay_table ()
+simple_read_overlay_table (void)
{
struct minimal_symbol *msym;
/* Find and grab a copy of the target _ovly_region_table
(and _novly_regions, which is needed for the table's size) */
static int
-simple_read_overlay_region_table ()
+simple_read_overlay_region_table (void)
{
struct minimal_symbol *msym;
success, 0 for failure. */
static int
-simple_overlay_update_1 (osect)
- struct obj_section *osect;
+simple_overlay_update_1 (struct obj_section *osect)
{
int i, size;
re-read the entire cache, and go ahead and update all sections. */
static void
-simple_overlay_update (osect)
- struct obj_section *osect;
+simple_overlay_update (struct obj_section *osect)
{
struct objfile *objfile;
void
-_initialize_symfile ()
+_initialize_symfile (void)
{
struct cmd_list_element *c;
#include "gdbcore.h"
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
struct pt_regset regs;
int i;
}
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
int i;
struct pt_regset regs;
\f
/* FIXME: This should be merged with i387-tdep.c as well. */
static
-print_fpu_status (ep)
- struct pt_regset ep;
+print_fpu_status (struct pt_regset ep)
{
int i;
int bothstatus;
}
-print_1167_control_word (pcr)
- unsigned int pcr;
-
+print_1167_control_word (unsigned int pcr)
{
int pcr_tmp;
}
}
-print_fpa_status (ep)
- struct pt_regset ep;
-
+print_fpa_status (struct pt_regset ep)
{
printf_unfiltered ("WTL 1167:");
}
#if 0 /* disabled because it doesn't go through the target vector. */
-i386_float_info ()
+i386_float_info (void)
{
char ubuf[UPAGES * NBPG];
struct pt_regset regset;
/*ARGSUSED */
/* This will eventually be more interesting. */
void
-sigchld_handler (signo)
- int signo;
+sigchld_handler (int signo)
{
got_sigchld++;
}
* Thanks to XPT_MPDEBUGGER, we have to mange child_wait().
*/
int
-child_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+child_wait (int pid, struct target_waitstatus *status)
{
int save_errno, rv, xvaloff, saoff, sa_hand;
struct pt_stop pt;
* the MPDEBUGGER child_wait() works properly. This will go away when
* that is fixed.
*/
-child_wait (pid, ourstatus)
- int pid;
- struct target_waitstatus *ourstatus;
+child_wait (int pid, struct target_waitstatus *ourstatus)
{
int save_errno;
int status;
It exists so that all calls to ptrace are isolated in this
machine-dependent file. */
int
-call_ptrace (request, pid, addr, data)
- int request, pid;
- PTRACE_ARG3_TYPE addr;
- int data;
+call_ptrace (int request, int pid, PTRACE_ARG3_TYPE addr, int data)
{
return ptrace (request, pid, addr, data);
}
int
-call_mptrace (request, pid, addr, data)
- int request, pid;
- PTRACE_ARG3_TYPE addr;
- int data;
+call_mptrace (int request, int pid, PTRACE_ARG3_TYPE addr, int data)
{
return mptrace (request, pid, addr, data);
}
#endif
void
-kill_inferior ()
+kill_inferior (void)
{
if (inferior_pid == 0)
return;
If SIGNAL is nonzero, give it that signal. */
void
-child_resume (pid, step, signal)
- int pid;
- int step;
- enum target_signal signal;
+child_resume (int pid, int step, enum target_signal signal)
{
errno = 0;
#ifdef ATTACH_DETACH
/* Start debugging the process whose number is PID. */
int
-attach (pid)
- int pid;
+attach (int pid)
{
sigset_t set;
int rv;
}
void
-detach (signo)
- int signo;
+detach (int signo)
{
int rv;
void
-_initialize_symm_nat ()
+_initialize_symm_nat (void)
{
#ifdef ATTACH_DETACH
/*
#include <fcntl.h>
void
-symmetry_extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+symmetry_extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
union
{
/* Free a struct block <- B and all the symbols defined in that block. */
static void
-free_symtab_block (objfile, b)
- struct objfile *objfile;
- struct block *b;
+free_symtab_block (struct objfile *objfile, struct block *b)
{
register int i, n;
n = BLOCK_NSYMS (b);
It is s->free_code that says which alternative to use. */
void
-free_symtab (s)
- register struct symtab *s;
+free_symtab (register struct symtab *s)
{
register int i, n;
register struct blockvector *bv;
}
void
-print_symbol_bcache_statistics ()
+print_symbol_bcache_statistics (void)
{
struct objfile *objfile;
}
void
-print_objfile_statistics ()
+print_objfile_statistics (void)
{
struct objfile *objfile;
}
static void
-dump_objfile (objfile)
- struct objfile *objfile;
+dump_objfile (struct objfile *objfile)
{
struct symtab *symtab;
struct partial_symtab *psymtab;
/* Print minimal symbols from this objfile. */
static void
-dump_msymbols (objfile, outfile)
- struct objfile *objfile;
- struct ui_file *outfile;
+dump_msymbols (struct objfile *objfile, struct ui_file *outfile)
{
struct minimal_symbol *msymbol;
int index;
}
static void
-dump_psymtab (objfile, psymtab, outfile)
- struct objfile *objfile;
- struct partial_symtab *psymtab;
- struct ui_file *outfile;
+dump_psymtab (struct objfile *objfile, struct partial_symtab *psymtab,
+ struct ui_file *outfile)
{
int i;
}
static void
-dump_symtab (objfile, symtab, outfile)
- struct objfile *objfile;
- struct symtab *symtab;
- struct ui_file *outfile;
+dump_symtab (struct objfile *objfile, struct symtab *symtab,
+ struct ui_file *outfile)
{
register int i, j;
int len, blen;
}
void
-maintenance_print_symbols (args, from_tty)
- char *args;
- int from_tty;
+maintenance_print_symbols (char *args, int from_tty)
{
char **argv;
struct ui_file *outfile;
1 for success. */
static int
-print_symbol (args)
- PTR args;
+print_symbol (PTR args)
{
struct symbol *symbol = ((struct print_symbol_args *) args)->symbol;
int depth = ((struct print_symbol_args *) args)->depth;
}
void
-maintenance_print_psymbols (args, from_tty)
- char *args;
- int from_tty;
+maintenance_print_psymbols (char *args, int from_tty)
{
char **argv;
struct ui_file *outfile;
}
static void
-print_partial_symbols (p, count, what, outfile)
- struct partial_symbol **p;
- int count;
- char *what;
- struct ui_file *outfile;
+print_partial_symbols (struct partial_symbol **p, int count, char *what,
+ struct ui_file *outfile)
{
fprintf_filtered (outfile, " %s partial symbols:\n", what);
while (count-- > 0)
}
void
-maintenance_print_msymbols (args, from_tty)
- char *args;
- int from_tty;
+maintenance_print_msymbols (char *args, int from_tty)
{
char **argv;
struct ui_file *outfile;
}
void
-maintenance_print_objfiles (ignore, from_tty)
- char *ignore;
- int from_tty;
+maintenance_print_objfiles (char *ignore, int from_tty)
{
struct objfile *objfile;
/* Check consistency of psymtabs and symtabs. */
void
-maintenance_check_symtabs (ignore, from_tty)
- char *ignore;
- int from_tty;
+maintenance_check_symtabs (char *ignore, int from_tty)
{
register struct symbol *sym;
register struct partial_symbol **psym;
/* Return the nexting depth of a block within other blocks in its symtab. */
static int
-block_depth (block)
- struct block *block;
+block_depth (struct block *block)
{
register int i = 0;
while ((block = BLOCK_SUPERBLOCK (block)) != NULL)
be freed in free_objfile(). */
void
-extend_psymbol_list (listp, objfile)
- register struct psymbol_allocation_list *listp;
- struct objfile *objfile;
+extend_psymbol_list (register struct psymbol_allocation_list *listp,
+ struct objfile *objfile)
{
int new_size;
if (listp->size == 0)
/* Do early runtime initializations. */
void
-_initialize_symmisc ()
+_initialize_symmisc (void)
{
std_in = stdin;
std_out = stdout;
symbols. Remove when loose ends are cleaned up. FIXME -fnf */
static void
-cplusplus_hint (name)
- char *name;
+cplusplus_hint (char *name)
{
while (*name == '\'')
name++;
in the symtab filename will also work. */
static struct symtab *
-lookup_symtab_1 (name)
- char *name;
+lookup_symtab_1 (char *name)
{
register struct symtab *s;
register struct partial_symtab *ps;
of variations if the first lookup doesn't work. */
struct symtab *
-lookup_symtab (name)
- char *name;
+lookup_symtab (char *name)
{
register struct symtab *s;
#if 0
in the psymtab filename will also work. */
struct partial_symtab *
-lookup_partial_symtab (name)
- char *name;
+lookup_partial_symtab (char *name)
{
register struct partial_symtab *pst;
register struct objfile *objfile;
specified by SIGNATURE_ID. Note that this function is g++ specific. */
char *
-gdb_mangle_name (type, method_id, signature_id)
- struct type *type;
- int method_id, signature_id;
+gdb_mangle_name (struct type *type, int method_id, int signature_id)
{
int mangled_name_len;
char *mangled_name;
/* Find which partial symtab on contains PC and SECTION. Return 0 if none. */
struct partial_symtab *
-find_pc_sect_psymtab (pc, section)
- CORE_ADDR pc;
- asection *section;
+find_pc_sect_psymtab (CORE_ADDR pc, asection *section)
{
register struct partial_symtab *pst;
register struct objfile *objfile;
Backward compatibility, no section */
struct partial_symtab *
-find_pc_psymtab (pc)
- CORE_ADDR pc;
+find_pc_psymtab (CORE_ADDR pc)
{
return find_pc_sect_psymtab (pc, find_pc_mapped_section (pc));
}
Return 0 if none. Check all psymtabs if PSYMTAB is 0. */
struct partial_symbol *
-find_pc_sect_psymbol (psymtab, pc, section)
- struct partial_symtab *psymtab;
- CORE_ADDR pc;
- asection *section;
+find_pc_sect_psymbol (struct partial_symtab *psymtab, CORE_ADDR pc,
+ asection *section)
{
struct partial_symbol *best = NULL, *p, **pp;
CORE_ADDR best_pc;
Check all psymtabs if PSYMTAB is 0. Backwards compatibility, no section. */
struct partial_symbol *
-find_pc_psymbol (psymtab, pc)
- struct partial_symtab *psymtab;
- CORE_ADDR pc;
+find_pc_psymbol (struct partial_symtab *psymtab, CORE_ADDR pc)
{
return find_pc_sect_psymbol (psymtab, pc, find_pc_mapped_section (pc));
}
out of the minimal symbols and stash that in the debug symbol. */
static void
-fixup_section (ginfo, objfile)
- struct general_symbol_info *ginfo;
- struct objfile *objfile;
+fixup_section (struct general_symbol_info *ginfo, struct objfile *objfile)
{
struct minimal_symbol *msym;
msym = lookup_minimal_symbol (ginfo->name, NULL, objfile);
}
struct symbol *
-fixup_symbol_section (sym, objfile)
- struct symbol *sym;
- struct objfile *objfile;
+fixup_symbol_section (struct symbol *sym, struct objfile *objfile)
{
if (!sym)
return NULL;
}
static struct partial_symbol *
-fixup_psymbol_section (psym, objfile)
- struct partial_symbol *psym;
- struct objfile *objfile;
+fixup_psymbol_section (struct partial_symbol *psym, struct objfile *objfile)
{
if (!psym)
return NULL;
can probably assume it will never hit the C++ code). */
struct symbol *
-lookup_symbol (name, block, namespace, is_a_field_of_this, symtab)
- const char *name;
- register const struct block *block;
- const namespace_enum namespace;
- int *is_a_field_of_this;
- struct symtab **symtab;
+lookup_symbol (const char *name, register const struct block *block,
+ const namespace_enum namespace, int *is_a_field_of_this,
+ struct symtab **symtab)
{
register struct symbol *sym;
register struct symtab *s = NULL;
symbols if GLOBAL, the static symbols if not */
static struct partial_symbol *
-lookup_partial_symbol (pst, name, global, namespace)
- struct partial_symtab *pst;
- const char *name;
- int global;
- namespace_enum namespace;
+lookup_partial_symbol (struct partial_symtab *pst, const char *name, int global,
+ namespace_enum namespace)
{
struct partial_symbol *temp;
struct partial_symbol **start, **psym;
struct type *
-lookup_transparent_type (name)
- const char *name;
+lookup_transparent_type (const char *name)
{
register struct symbol *sym;
register struct symtab *s = NULL;
executables that have no main() ? */
struct partial_symtab *
-find_main_psymtab ()
+find_main_psymtab (void)
{
register struct partial_symtab *pst;
register struct objfile *objfile;
tested for a match. */
struct symbol *
-lookup_block_symbol (block, name, namespace)
- register const struct block *block;
- const char *name;
- const namespace_enum namespace;
+lookup_block_symbol (register const struct block *block, const char *name,
+ const namespace_enum namespace)
{
register int bot, top, inc;
register struct symbol *sym;
If no alias is active, then return SYM. */
static struct symbol *
-find_active_alias (sym, addr)
- struct symbol *sym;
- CORE_ADDR addr;
+find_active_alias (struct symbol *sym, CORE_ADDR addr)
{
struct range_list *r;
struct alias_list *aliases;
lexical block, described by a struct block BL. */
struct symbol *
-block_function (bl)
- struct block *bl;
+block_function (struct block *bl)
{
while (BLOCK_FUNCTION (bl) == 0 && BLOCK_SUPERBLOCK (bl) != 0)
bl = BLOCK_SUPERBLOCK (bl);
psymtabs and read in another symtab if necessary. */
struct symtab *
-find_pc_sect_symtab (pc, section)
- CORE_ADDR pc;
- asection *section;
+find_pc_sect_symtab (CORE_ADDR pc, asection *section)
{
register struct block *b;
struct blockvector *bv;
read in another symtab if necessary. Backward compatibility, no section */
struct symtab *
-find_pc_symtab (pc)
- CORE_ADDR pc;
+find_pc_symtab (CORE_ADDR pc)
{
return find_pc_sect_symtab (pc, find_pc_mapped_section (pc));
}
line *0x2345" cause psymtabs to be converted to symtabs). */
struct symbol *
-find_addr_symbol (addr, symtabp, symaddrp)
- CORE_ADDR addr;
- struct symtab **symtabp;
- CORE_ADDR *symaddrp;
+find_addr_symbol (CORE_ADDR addr, struct symtab **symtabp, CORE_ADDR *symaddrp)
{
struct symtab *symtab, *best_symtab;
struct objfile *objfile;
/* If it's worth the effort, we could be using a binary search. */
struct symtab_and_line
-find_pc_sect_line (pc, section, notcurrent)
- CORE_ADDR pc;
- struct sec *section;
- int notcurrent;
+find_pc_sect_line (CORE_ADDR pc, struct sec *section, int notcurrent)
{
struct symtab *s;
register struct linetable *l;
/* Backward compatibility (no section) */
struct symtab_and_line
-find_pc_line (pc, notcurrent)
- CORE_ADDR pc;
- int notcurrent;
+find_pc_line (CORE_ADDR pc, int notcurrent)
{
asection *section;
If not found, return NULL. */
static struct symtab *
-find_line_symtab (symtab, line, index, exact_match)
- struct symtab *symtab;
- int line;
- int *index;
- int *exact_match;
+find_line_symtab (struct symtab *symtab, int line, int *index, int *exact_match)
{
int exact;
The source file is specified with a struct symtab. */
int
-find_line_pc (symtab, line, pc)
- struct symtab *symtab;
- int line;
- CORE_ADDR *pc;
+find_line_pc (struct symtab *symtab, int line, CORE_ADDR *pc)
{
struct linetable *l;
int ind;
Returns 0 if could not find the specified line. */
int
-find_line_pc_range (sal, startptr, endptr)
- struct symtab_and_line sal;
- CORE_ADDR *startptr, *endptr;
+find_line_pc_range (struct symtab_and_line sal, CORE_ADDR *startptr,
+ CORE_ADDR *endptr)
{
CORE_ADDR startaddr;
struct symtab_and_line found_sal;
Set *EXACT_MATCH nonzero if the value returned is an exact match. */
static int
-find_line_common (l, lineno, exact_match)
- register struct linetable *l;
- register int lineno;
- int *exact_match;
+find_line_common (register struct linetable *l, register int lineno,
+ int *exact_match)
{
register int i;
register int len;
}
int
-find_pc_line_pc_range (pc, startptr, endptr)
- CORE_ADDR pc;
- CORE_ADDR *startptr, *endptr;
+find_pc_line_pc_range (CORE_ADDR pc, CORE_ADDR *startptr, CORE_ADDR *endptr)
{
struct symtab_and_line sal;
sal = find_pc_line (pc, 0);
find_function_start_sal (struct symbol *sym, int);
static struct symtab_and_line
-find_function_start_sal (sym, funfirstline)
- struct symbol *sym;
- int funfirstline;
+find_function_start_sal (struct symbol *sym, int funfirstline)
{
CORE_ADDR pc;
struct symtab_and_line sal;
beginning of the substring of the operator text.
Otherwise, return "". */
char *
-operator_chars (p, end)
- char *p;
- char **end;
+operator_chars (char *p, char **end)
{
*end = "";
if (strncmp (p, "operator", 8))
static int total_number_of_methods (struct type *type);
static int
-total_number_of_methods (type)
- struct type *type;
+total_number_of_methods (struct type *type)
{
int n;
int count;
Note that this function is g++ specific. */
static int
-find_methods (t, name, sym_arr)
- struct type *t;
- char *name;
- struct symbol **sym_arr;
+find_methods (struct type *t, char *name, struct symbol **sym_arr)
{
int i1 = 0;
int ibase;
line spec is `filename:linenum'. */
static void
-build_canonical_line_spec (sal, symname, canonical)
- struct symtab_and_line *sal;
- char *symname;
- char ***canonical;
+build_canonical_line_spec (struct symtab_and_line *sal, char *symname,
+ char ***canonical)
{
char **canonical_arr;
char *canonical_name;
can use as appropriate instead of make_symbol_completion_list. */
struct symtabs_and_lines
-decode_line_1 (argptr, funfirstline, default_symtab, default_line, canonical)
- char **argptr;
- int funfirstline;
- struct symtab *default_symtab;
- int default_line;
- char ***canonical;
+decode_line_1 (char **argptr, int funfirstline, struct symtab *default_symtab,
+ int default_line, char ***canonical)
{
struct symtabs_and_lines values;
#ifdef HPPA_COMPILER_BUG
}
struct symtabs_and_lines
-decode_line_spec (string, funfirstline)
- char *string;
- int funfirstline;
+decode_line_spec (char *string, int funfirstline)
{
struct symtabs_and_lines sals;
if (string == 0)
NAME is the name to print and *FIRST is nonzero if this is the first
name printed. Set *FIRST to zero. */
static void
-output_source_filename (name, first)
- char *name;
- int *first;
+output_source_filename (char *name, int *first)
{
/* Table of files printed so far. Since a single source file can
result in several partial symbol tables, we need to avoid printing
}
static void
-sources_info (ignore, from_tty)
- char *ignore;
- int from_tty;
+sources_info (char *ignore, int from_tty)
{
register struct symtab *s;
register struct partial_symtab *ps;
/* Free any memory associated with a search. */
void
-free_search_symbols (symbols)
- struct symbol_search *symbols;
+free_search_symbols (struct symbol_search *symbols)
{
struct symbol_search *p;
struct symbol_search *next;
regarding the match to gdb_stdout.
*/
static void
-print_symbol_info (kind, s, sym, block, last)
- namespace_enum kind;
- struct symtab *s;
- struct symbol *sym;
- int block;
- char *last;
+print_symbol_info (namespace_enum kind, struct symtab *s, struct symbol *sym,
+ int block, char *last)
{
if (last == NULL || strcmp (last, s->filename) != 0)
{
for non-debugging symbols to gdb_stdout.
*/
static void
-print_msymbol_info (msymbol)
- struct minimal_symbol *msymbol;
+print_msymbol_info (struct minimal_symbol *msymbol)
{
printf_filtered (" %08lx %s\n",
(unsigned long) SYMBOL_VALUE_ADDRESS (msymbol),
matches.
*/
static void
-symtab_symbol_info (regexp, kind, from_tty)
- char *regexp;
- namespace_enum kind;
- int from_tty;
+symtab_symbol_info (char *regexp, namespace_enum kind, int from_tty)
{
static char *classnames[]
=
}
static void
-variables_info (regexp, from_tty)
- char *regexp;
- int from_tty;
+variables_info (char *regexp, int from_tty)
{
symtab_symbol_info (regexp, VARIABLES_NAMESPACE, from_tty);
}
static void
-functions_info (regexp, from_tty)
- char *regexp;
- int from_tty;
+functions_info (char *regexp, int from_tty)
{
symtab_symbol_info (regexp, FUNCTIONS_NAMESPACE, from_tty);
}
static void
-types_info (regexp, from_tty)
- char *regexp;
- int from_tty;
+types_info (char *regexp, int from_tty)
{
symtab_symbol_info (regexp, TYPES_NAMESPACE, from_tty);
}
#if 0
/* Tiemann says: "info methods was never implemented." */
static void
-methods_info (regexp)
- char *regexp;
+methods_info (char *regexp)
{
symtab_symbol_info (regexp, METHODS_NAMESPACE, 0, from_tty);
}
/* Breakpoint all functions matching regular expression. */
#ifdef UI_OUT
void
-rbreak_command_wrapper (regexp, from_tty)
- char *regexp;
- int from_tty;
+rbreak_command_wrapper (char *regexp, int from_tty)
{
rbreak_command (regexp, from_tty);
}
#endif
static void
-rbreak_command (regexp, from_tty)
- char *regexp;
- int from_tty;
+rbreak_command (char *regexp, int from_tty)
{
struct symbol_search *ss;
struct symbol_search *p;
or if a and b have the same pc range.
Return zero otherwise. */
int
-contained_in (a, b)
- struct block *a, *b;
+contained_in (struct block *a, struct block *b)
{
if (!a || !b)
return 0;
characters. If so, add it to the current completion list. */
static void
-completion_list_add_name (symname, sym_text, sym_text_len, text, word)
- char *symname;
- char *sym_text;
- int sym_text_len;
- char *text;
- char *word;
+completion_list_add_name (char *symname, char *sym_text, int sym_text_len,
+ char *text, char *word)
{
int newsize;
int i;
I'm not going to worry about this; hopefully there won't be that many. */
char **
-make_symbol_completion_list (text, word)
- char *text;
- char *word;
+make_symbol_completion_list (char *text, char *word)
{
register struct symbol *sym;
register struct symtab *s;
*/
int
-in_prologue (pc, func_start)
- CORE_ADDR pc;
- CORE_ADDR func_start;
+in_prologue (CORE_ADDR pc, CORE_ADDR func_start)
{
struct symtab_and_line sal;
CORE_ADDR func_addr, func_end;
characters. If so, add it to the current completion list. */
static void
-overload_list_add_symbol (sym, oload_name)
- struct symbol *sym;
- char *oload_name;
+overload_list_add_symbol (struct symbol *sym, char *oload_name)
{
int newsize;
int i;
struct symbol **
-make_symbol_overload_list (fsym)
- struct symbol *fsym;
+make_symbol_overload_list (struct symbol *fsym)
{
register struct symbol *sym;
register struct symtab *s;
\f
void
-_initialize_symtab ()
+_initialize_symtab (void)
{
add_info ("variables", variables_info,
"All global and static variable names, or those matching REGEXP.");
/* ARGSUSED */
static void
-target_command (arg, from_tty)
- char *arg;
- int from_tty;
+target_command (char *arg, int from_tty)
{
fputs_filtered ("Argument required (target name). Try `help target'\n",
gdb_stdout);
/* Add a possible target architecture to the list. */
void
-add_target (t)
- struct target_ops *t;
+add_target (struct target_ops *t)
{
if (!target_structs)
{
/* Stub functions */
void
-target_ignore ()
+target_ignore (void)
{
}
/* ARGSUSED */
static int
-nomemory (memaddr, myaddr, len, write, t)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
- struct target_ops *t;
+nomemory (CORE_ADDR memaddr, char *myaddr, int len, int write,
+ struct target_ops *t)
{
errno = EIO; /* Can't read/write this location */
return 0; /* No bytes handled */
}
static void
-tcomplain ()
+tcomplain (void)
{
error ("You can't do that when your target is `%s'",
current_target.to_shortname);
}
void
-noprocess ()
+noprocess (void)
{
error ("You can't do that without a process to debug.");
}
/* ARGSUSED */
static int
-nosymbol (name, addrp)
- char *name;
- CORE_ADDR *addrp;
+nosymbol (char *name, CORE_ADDR *addrp)
{
return 1; /* Symbol does not exist in target env */
}
/* ARGSUSED */
static void
-nosupport_runtime ()
+nosupport_runtime (void)
{
if (!inferior_pid)
noprocess ();
/* ARGSUSED */
static void
-default_terminal_info (args, from_tty)
- char *args;
- int from_tty;
+default_terminal_info (char *args, int from_tty)
{
printf_unfiltered ("No saved terminal information.\n");
}
the target, and the operation should be attempted. */
static void
-kill_or_be_killed (from_tty)
- int from_tty;
+kill_or_be_killed (int from_tty)
{
if (target_has_execution)
{
}
static void
-maybe_kill_then_attach (args, from_tty)
- char *args;
- int from_tty;
+maybe_kill_then_attach (char *args, int from_tty)
{
kill_or_be_killed (from_tty);
target_attach (args, from_tty);
}
static void
-maybe_kill_then_create_inferior (exec, args, env)
- char *exec;
- char *args;
- char **env;
+maybe_kill_then_create_inferior (char *exec, char *args, char **env)
{
kill_or_be_killed (0);
target_create_inferior (exec, args, env);
}
static void
-default_clone_and_follow_inferior (child_pid, followed_child)
- int child_pid;
- int *followed_child;
+default_clone_and_follow_inferior (int child_pid, int *followed_child)
{
target_clone_and_follow_inferior (child_pid, followed_child);
}
We default entries, at least to stubs that print error messages. */
static void
-cleanup_target (t)
- struct target_ops *t;
+cleanup_target (struct target_ops *t)
{
#define de_fault(field, value) \
pushed target vectors. */
static void
-update_current_target ()
+update_current_target (void)
{
struct target_stack_item *item;
struct target_ops *t;
checking them. */
int
-push_target (t)
- struct target_ops *t;
+push_target (struct target_ops *t)
{
struct target_stack_item *cur, *prev, *tmp;
Return how many times it was removed (0 or 1). */
int
-unpush_target (t)
- struct target_ops *t;
+unpush_target (struct target_ops *t)
{
struct target_stack_item *cur, *prev;
}
void
-pop_target ()
+pop_target (void)
{
(current_target.to_close) (0); /* Let it clean up */
if (unpush_target (target_stack->target_ops) == 1)
read. */
int
-target_read_string (memaddr, string, len, errnop)
- CORE_ADDR memaddr;
- char **string;
- int len;
- int *errnop;
+target_read_string (CORE_ADDR memaddr, char **string, int len, int *errnop)
{
int tlen, origlen, offset, i;
char buf[4];
deal with partial reads should call target_read_memory_partial. */
int
-target_read_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+target_read_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
return target_xfer_memory (memaddr, myaddr, len, 0);
}
int
-target_write_memory (memaddr, myaddr, len)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
+target_write_memory (CORE_ADDR memaddr, char *myaddr, int len)
{
return target_xfer_memory (memaddr, myaddr, len, 1);
}
Result is 0 or errno value. */
static int
-target_xfer_memory (memaddr, myaddr, len, write)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
+target_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int write)
{
int curlen;
int res;
/* ARGSUSED */
static void
-target_info (args, from_tty)
- char *args;
- int from_tty;
+target_info (char *args, int from_tty)
{
struct target_ops *t;
struct target_stack_item *item;
anything. */
void
-target_preopen (from_tty)
- int from_tty;
+target_preopen (int from_tty)
{
dont_repeat ();
/* Detach a target after doing deferred register stores. */
void
-target_detach (args, from_tty)
- char *args;
- int from_tty;
+target_detach (char *args, int from_tty)
{
/* Handle any optimized stores to the inferior. */
#ifdef DO_DEFERRED_STORES
}
void
-target_link (modname, t_reloc)
- char *modname;
- CORE_ADDR *t_reloc;
+target_link (char *modname, CORE_ADDR *t_reloc)
{
if (STREQ (current_target.to_shortname, "rombug"))
{
Result is always valid (error() is called for errors). */
static struct target_ops *
-find_default_run_target (do_mesg)
- char *do_mesg;
+find_default_run_target (char *do_mesg)
{
struct target_ops **t;
struct target_ops *runable = NULL;
}
void
-find_default_attach (args, from_tty)
- char *args;
- int from_tty;
+find_default_attach (char *args, int from_tty)
{
struct target_ops *t;
}
void
-find_default_require_attach (args, from_tty)
- char *args;
- int from_tty;
+find_default_require_attach (char *args, int from_tty)
{
struct target_ops *t;
}
void
-find_default_require_detach (pid, args, from_tty)
- int pid;
- char *args;
- int from_tty;
+find_default_require_detach (int pid, char *args, int from_tty)
{
struct target_ops *t;
}
void
-find_default_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+find_default_create_inferior (char *exec_file, char *allargs, char **env)
{
struct target_ops *t;
}
void
-find_default_clone_and_follow_inferior (child_pid, followed_child)
- int child_pid;
- int *followed_child;
+find_default_clone_and_follow_inferior (int child_pid, int *followed_child)
{
struct target_ops *t;
}
static int
-return_zero ()
+return_zero (void)
{
return 0;
}
static int
-return_one ()
+return_one (void)
{
return 1;
}
some reason there is more than one, return NULL. */
struct target_ops *
-find_run_target ()
+find_run_target (void)
{
struct target_ops **t;
struct target_ops *runable = NULL;
If for some reason there is more than one, return NULL. */
struct target_ops *
-find_core_target ()
+find_core_target (void)
{
struct target_ops **t;
struct target_ops *runable = NULL;
*/
struct target_ops *
-find_target_beneath (t)
- struct target_ops *t;
+find_target_beneath (struct target_ops *t)
{
struct target_stack_item *cur;
/* The inferior process has died. Long live the inferior! */
void
-generic_mourn_inferior ()
+generic_mourn_inferior (void)
{
extern int show_breakpoint_hit_counts;
/* Return the string for a signal. */
char *
-target_signal_to_string (sig)
- enum target_signal sig;
+target_signal_to_string (enum target_signal sig)
{
if ((sig >= TARGET_SIGNAL_FIRST) && (sig <= TARGET_SIGNAL_LAST))
return signals[sig].string;
/* Return the name for a signal. */
char *
-target_signal_to_name (sig)
- enum target_signal sig;
+target_signal_to_name (enum target_signal sig)
{
if (sig == TARGET_SIGNAL_UNKNOWN)
/* I think the code which prints this will always print it along with
/* Given a name, return its signal. */
enum target_signal
-target_signal_from_name (name)
- char *name;
+target_signal_from_name (char *name)
{
enum target_signal sig;
/* Convert host signal to our signals. */
enum target_signal
-target_signal_from_host (hostsig)
- int hostsig;
+target_signal_from_host (int hostsig)
{
/* A switch statement would make sense but would require special kludges
to deal with the cases where more than one signal has the same number. */
HOSTSTATUS is the waitstatus from wait() or the equivalent; store our
translation of that in OURSTATUS. */
void
-store_waitstatus (ourstatus, hoststatus)
- struct target_waitstatus *ourstatus;
- int hoststatus;
+store_waitstatus (struct target_waitstatus *ourstatus, int hoststatus)
{
#ifdef CHILD_SPECIAL_WAITSTATUS
/* CHILD_SPECIAL_WAITSTATUS should return nonzero and set *OURSTATUS
most systems. Use of symbolic signal names is strongly encouraged. */
enum target_signal
-target_signal_from_command (num)
- int num;
+target_signal_from_command (int num)
{
if (num >= 1 && num <= 15)
return (enum target_signal) num;
buffer. */
char *
-normal_pid_to_str (pid)
- int pid;
+normal_pid_to_str (int pid)
{
static char buf[30];
target_acknowledge_forked_child.
*/
static void
-normal_target_post_startup_inferior (pid)
- int pid;
+normal_target_post_startup_inferior (int pid)
{
/* This space intentionally left blank. */
}
vector. */
static void
-init_dummy_target ()
+init_dummy_target (void)
{
dummy_target.to_shortname = "None";
dummy_target.to_longname = "None";
static struct target_ops debug_target;
static void
-debug_to_open (args, from_tty)
- char *args;
- int from_tty;
+debug_to_open (char *args, int from_tty)
{
debug_target.to_open (args, from_tty);
}
static void
-debug_to_close (quitting)
- int quitting;
+debug_to_close (int quitting)
{
debug_target.to_close (quitting);
}
static void
-debug_to_attach (args, from_tty)
- char *args;
- int from_tty;
+debug_to_attach (char *args, int from_tty)
{
debug_target.to_attach (args, from_tty);
static void
-debug_to_post_attach (pid)
- int pid;
+debug_to_post_attach (int pid)
{
debug_target.to_post_attach (pid);
}
static void
-debug_to_require_attach (args, from_tty)
- char *args;
- int from_tty;
+debug_to_require_attach (char *args, int from_tty)
{
debug_target.to_require_attach (args, from_tty);
}
static void
-debug_to_detach (args, from_tty)
- char *args;
- int from_tty;
+debug_to_detach (char *args, int from_tty)
{
debug_target.to_detach (args, from_tty);
}
static void
-debug_to_require_detach (pid, args, from_tty)
- int pid;
- char *args;
- int from_tty;
+debug_to_require_detach (int pid, char *args, int from_tty)
{
debug_target.to_require_detach (pid, args, from_tty);
}
static void
-debug_to_resume (pid, step, siggnal)
- int pid;
- int step;
- enum target_signal siggnal;
+debug_to_resume (int pid, int step, enum target_signal siggnal)
{
debug_target.to_resume (pid, step, siggnal);
}
static int
-debug_to_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+debug_to_wait (int pid, struct target_waitstatus *status)
{
int retval;
}
static void
-debug_to_post_wait (pid, status)
- int pid;
- int status;
+debug_to_post_wait (int pid, int status)
{
debug_target.to_post_wait (pid, status);
}
static void
-debug_to_fetch_registers (regno)
- int regno;
+debug_to_fetch_registers (int regno)
{
debug_target.to_fetch_registers (regno);
}
static void
-debug_to_store_registers (regno)
- int regno;
+debug_to_store_registers (int regno)
{
debug_target.to_store_registers (regno);
}
static void
-debug_to_prepare_to_store ()
+debug_to_prepare_to_store (void)
{
debug_target.to_prepare_to_store ();
}
static int
-debug_to_xfer_memory (memaddr, myaddr, len, write, target)
- CORE_ADDR memaddr;
- char *myaddr;
- int len;
- int write;
- struct target_ops *target;
+debug_to_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int write,
+ struct target_ops *target)
{
int retval;
}
static void
-debug_to_files_info (target)
- struct target_ops *target;
+debug_to_files_info (struct target_ops *target)
{
debug_target.to_files_info (target);
}
static int
-debug_to_insert_breakpoint (addr, save)
- CORE_ADDR addr;
- char *save;
+debug_to_insert_breakpoint (CORE_ADDR addr, char *save)
{
int retval;
}
static int
-debug_to_remove_breakpoint (addr, save)
- CORE_ADDR addr;
- char *save;
+debug_to_remove_breakpoint (CORE_ADDR addr, char *save)
{
int retval;
}
static void
-debug_to_terminal_init ()
+debug_to_terminal_init (void)
{
debug_target.to_terminal_init ();
}
static void
-debug_to_terminal_inferior ()
+debug_to_terminal_inferior (void)
{
debug_target.to_terminal_inferior ();
}
static void
-debug_to_terminal_ours_for_output ()
+debug_to_terminal_ours_for_output (void)
{
debug_target.to_terminal_ours_for_output ();
}
static void
-debug_to_terminal_ours ()
+debug_to_terminal_ours (void)
{
debug_target.to_terminal_ours ();
}
static void
-debug_to_terminal_info (arg, from_tty)
- char *arg;
- int from_tty;
+debug_to_terminal_info (char *arg, int from_tty)
{
debug_target.to_terminal_info (arg, from_tty);
}
static void
-debug_to_kill ()
+debug_to_kill (void)
{
debug_target.to_kill ();
}
static void
-debug_to_load (args, from_tty)
- char *args;
- int from_tty;
+debug_to_load (char *args, int from_tty)
{
debug_target.to_load (args, from_tty);
}
static int
-debug_to_lookup_symbol (name, addrp)
- char *name;
- CORE_ADDR *addrp;
+debug_to_lookup_symbol (char *name, CORE_ADDR *addrp)
{
int retval;
}
static void
-debug_to_create_inferior (exec_file, args, env)
- char *exec_file;
- char *args;
- char **env;
+debug_to_create_inferior (char *exec_file, char *args, char **env)
{
debug_target.to_create_inferior (exec_file, args, env);
}
static void
-debug_to_post_startup_inferior (pid)
- int pid;
+debug_to_post_startup_inferior (int pid)
{
debug_target.to_post_startup_inferior (pid);
}
static void
-debug_to_acknowledge_created_inferior (pid)
- int pid;
+debug_to_acknowledge_created_inferior (int pid)
{
debug_target.to_acknowledge_created_inferior (pid);
}
static void
-debug_to_clone_and_follow_inferior (child_pid, followed_child)
- int child_pid;
- int *followed_child;
+debug_to_clone_and_follow_inferior (int child_pid, int *followed_child)
{
debug_target.to_clone_and_follow_inferior (child_pid, followed_child);
}
static void
-debug_to_post_follow_inferior_by_clone ()
+debug_to_post_follow_inferior_by_clone (void)
{
debug_target.to_post_follow_inferior_by_clone ();
}
static int
-debug_to_insert_fork_catchpoint (pid)
- int pid;
+debug_to_insert_fork_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_remove_fork_catchpoint (pid)
- int pid;
+debug_to_remove_fork_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_insert_vfork_catchpoint (pid)
- int pid;
+debug_to_insert_vfork_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_remove_vfork_catchpoint (pid)
- int pid;
+debug_to_remove_vfork_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_has_forked (pid, child_pid)
- int pid;
- int *child_pid;
+debug_to_has_forked (int pid, int *child_pid)
{
int has_forked;
}
static int
-debug_to_has_vforked (pid, child_pid)
- int pid;
- int *child_pid;
+debug_to_has_vforked (int pid, int *child_pid)
{
int has_vforked;
}
static int
-debug_to_can_follow_vfork_prior_to_exec ()
+debug_to_can_follow_vfork_prior_to_exec (void)
{
int can_immediately_follow_vfork;
}
static void
-debug_to_post_follow_vfork (parent_pid, followed_parent, child_pid, followed_child)
- int parent_pid;
- int followed_parent;
- int child_pid;
- int followed_child;
+debug_to_post_follow_vfork (int parent_pid, int followed_parent, int child_pid,
+ int followed_child)
{
debug_target.to_post_follow_vfork (parent_pid, followed_parent, child_pid, followed_child);
}
static int
-debug_to_insert_exec_catchpoint (pid)
- int pid;
+debug_to_insert_exec_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_remove_exec_catchpoint (pid)
- int pid;
+debug_to_remove_exec_catchpoint (int pid)
{
int retval;
}
static int
-debug_to_has_execd (pid, execd_pathname)
- int pid;
- char **execd_pathname;
+debug_to_has_execd (int pid, char **execd_pathname)
{
int has_execd;
}
static int
-debug_to_reported_exec_events_per_exec_call ()
+debug_to_reported_exec_events_per_exec_call (void)
{
int reported_exec_events;
}
static int
-debug_to_has_syscall_event (pid, kind, syscall_id)
- int pid;
- enum target_waitkind *kind;
- int *syscall_id;
+debug_to_has_syscall_event (int pid, enum target_waitkind *kind,
+ int *syscall_id)
{
int has_syscall_event;
char *kind_spelling = "??";
}
static int
-debug_to_has_exited (pid, wait_status, exit_status)
- int pid;
- int wait_status;
- int *exit_status;
+debug_to_has_exited (int pid, int wait_status, int *exit_status)
{
int has_exited;
}
static void
-debug_to_mourn_inferior ()
+debug_to_mourn_inferior (void)
{
debug_target.to_mourn_inferior ();
}
static int
-debug_to_can_run ()
+debug_to_can_run (void)
{
int retval;
}
static void
-debug_to_notice_signals (pid)
- int pid;
+debug_to_notice_signals (int pid)
{
debug_target.to_notice_signals (pid);
}
static int
-debug_to_thread_alive (pid)
- int pid;
+debug_to_thread_alive (int pid)
{
int retval;
}
static void
-debug_to_find_new_threads ()
+debug_to_find_new_threads (void)
{
debug_target.to_find_new_threads ();
}
static void
-debug_to_stop ()
+debug_to_stop (void)
{
debug_target.to_stop ();
}
static int
-debug_to_query (type, req, resp, siz)
- int type;
- char *req;
- char *resp;
- int *siz;
+debug_to_query (int type, char *req, char *resp, int *siz)
{
int retval;
}
static struct symtab_and_line *
-debug_to_enable_exception_callback (kind, enable)
- enum exception_event_kind kind;
- int enable;
+debug_to_enable_exception_callback (enum exception_event_kind kind, int enable)
{
struct symtab_and_line *result;
result = debug_target.to_enable_exception_callback (kind, enable);
}
static struct exception_event_record *
-debug_to_get_current_exception_event ()
+debug_to_get_current_exception_event (void)
{
struct exception_event_record *result;
result = debug_target.to_get_current_exception_event ();
}
static char *
-debug_to_pid_to_exec_file (pid)
- int pid;
+debug_to_pid_to_exec_file (int pid)
{
char *exec_file;
}
static char *
-debug_to_core_file_to_sym_file (core)
- char *core;
+debug_to_core_file_to_sym_file (char *core)
{
char *sym_file;
}
static void
-setup_target_debug ()
+setup_target_debug (void)
{
memcpy (&debug_target, ¤t_target, sizeof debug_target);
}
void
-initialize_targets ()
+initialize_targets (void)
{
init_dummy_target ();
push_target (&dummy_target);
}
void
-init_thread_list ()
+init_thread_list (void)
{
struct thread_info *tp, *tpnext;
so that back_ends can initialize their private data. */
struct thread_info *
-add_thread (pid)
- int pid;
+add_thread (int pid)
{
struct thread_info *tp;
}
void
-delete_thread (pid)
- int pid;
+delete_thread (int pid)
{
struct thread_info *tp, *tpprev;
}
static struct thread_info *
-find_thread_id (num)
- int num;
+find_thread_id (int num)
{
struct thread_info *tp;
/* Find a thread_info by matching 'pid'. */
struct thread_info *
-find_thread_pid (pid)
- int pid;
+find_thread_pid (int pid)
{
struct thread_info *tp;
}
int
-valid_thread_id (num)
- int num;
+valid_thread_id (int num)
{
struct thread_info *tp;
}
int
-pid_to_thread_id (pid)
- int pid;
+pid_to_thread_id (int pid)
{
struct thread_info *tp;
}
int
-thread_id_to_pid (num)
- int num;
+thread_id_to_pid (int num)
{
struct thread_info *thread = find_thread_id (num);
if (thread)
}
int
-in_thread_list (pid)
- int pid;
+in_thread_list (int pid)
{
struct thread_info *tp;
/* Load infrun state for the thread PID. */
void
-load_infrun_state (pid, prev_pc, prev_func_start, prev_func_name,
- trap_expected, step_resume_breakpoint,
- through_sigtramp_breakpoint, step_range_start,
- step_range_end, step_frame_address,
- handling_longjmp, another_trap,
- stepping_through_solib_after_catch,
- stepping_through_solib_catchpoints,
- stepping_through_sigtramp)
- int pid;
- CORE_ADDR *prev_pc;
- CORE_ADDR *prev_func_start;
- char **prev_func_name;
- int *trap_expected;
- struct breakpoint **step_resume_breakpoint;
- struct breakpoint **through_sigtramp_breakpoint;
- CORE_ADDR *step_range_start;
- CORE_ADDR *step_range_end;
- CORE_ADDR *step_frame_address;
- int *handling_longjmp;
- int *another_trap;
- int *stepping_through_solib_after_catch;
- bpstat *stepping_through_solib_catchpoints;
- int *stepping_through_sigtramp;
+load_infrun_state (int pid, CORE_ADDR *prev_pc, CORE_ADDR *prev_func_start,
+ char **prev_func_name, int *trap_expected,
+ struct breakpoint **step_resume_breakpoint,
+ struct breakpoint **through_sigtramp_breakpoint,
+ CORE_ADDR *step_range_start, CORE_ADDR *step_range_end,
+ CORE_ADDR *step_frame_address, int *handling_longjmp,
+ int *another_trap, int *stepping_through_solib_after_catch,
+ bpstat *stepping_through_solib_catchpoints,
+ int *stepping_through_sigtramp)
{
struct thread_info *tp;
/* Save infrun state for the thread PID. */
void
-save_infrun_state (pid, prev_pc, prev_func_start, prev_func_name,
- trap_expected, step_resume_breakpoint,
- through_sigtramp_breakpoint, step_range_start,
- step_range_end, step_frame_address,
- handling_longjmp, another_trap,
- stepping_through_solib_after_catch,
- stepping_through_solib_catchpoints,
- stepping_through_sigtramp)
- int pid;
- CORE_ADDR prev_pc;
- CORE_ADDR prev_func_start;
- char *prev_func_name;
- int trap_expected;
- struct breakpoint *step_resume_breakpoint;
- struct breakpoint *through_sigtramp_breakpoint;
- CORE_ADDR step_range_start;
- CORE_ADDR step_range_end;
- CORE_ADDR step_frame_address;
- int handling_longjmp;
- int another_trap;
- int stepping_through_solib_after_catch;
- bpstat stepping_through_solib_catchpoints;
- int stepping_through_sigtramp;
+save_infrun_state (int pid, CORE_ADDR prev_pc, CORE_ADDR prev_func_start,
+ char *prev_func_name, int trap_expected,
+ struct breakpoint *step_resume_breakpoint,
+ struct breakpoint *through_sigtramp_breakpoint,
+ CORE_ADDR step_range_start, CORE_ADDR step_range_end,
+ CORE_ADDR step_frame_address, int handling_longjmp,
+ int another_trap, int stepping_through_solib_after_catch,
+ bpstat stepping_through_solib_catchpoints,
+ int stepping_through_sigtramp)
{
struct thread_info *tp;
/* Return true if TP is an active thread. */
static int
-thread_alive (tp)
- struct thread_info *tp;
+thread_alive (struct thread_info *tp)
{
if (tp->pid == -1)
return 0;
}
static void
-prune_threads ()
+prune_threads (void)
{
struct thread_info *tp, *next;
*/
static void
-info_threads_command (arg, from_tty)
- char *arg;
- int from_tty;
+info_threads_command (char *arg, int from_tty)
{
struct thread_info *tp;
int current_pid;
/* Switch from one thread to another. */
static void
-switch_to_thread (pid)
- int pid;
+switch_to_thread (int pid)
{
if (pid == inferior_pid)
return;
}
static void
-restore_current_thread (pid)
- int pid;
+restore_current_thread (int pid)
{
if (pid != inferior_pid)
{
*/
static void
-thread_apply_all_command (cmd, from_tty)
- char *cmd;
- int from_tty;
+thread_apply_all_command (char *cmd, int from_tty)
{
struct thread_info *tp;
struct cleanup *old_chain;
}
static void
-thread_apply_command (tidlist, from_tty)
- char *tidlist;
- int from_tty;
+thread_apply_command (char *tidlist, int from_tty)
{
char *cmd;
char *p;
if prefix of arg is `apply'. */
static void
-thread_command (tidstr, from_tty)
- char *tidstr;
- int from_tty;
+thread_command (char *tidstr, int from_tty)
{
if (!tidstr)
{
struct cmd_list_element *thread_cmd_list = NULL;
void
-_initialize_thread ()
+_initialize_thread (void)
{
static struct cmd_list_element *thread_apply_list = NULL;
an empty frame_saved_regs, so I guess that's better than total failure */
void
-tic80_frame_find_saved_regs (fi, regaddr)
- struct frame_info *fi;
- struct frame_saved_regs *regaddr;
+tic80_frame_find_saved_regs (struct frame_info *fi,
+ struct frame_saved_regs *regaddr)
{
memcpy (regaddr, &fi->fsr, sizeof (struct frame_saved_regs));
}
Find end of function prologue. */
CORE_ADDR
-tic80_skip_prologue (pc)
- CORE_ADDR pc;
+tic80_skip_prologue (CORE_ADDR pc)
{
CORE_ADDR func_addr, func_end;
struct symtab_and_line sal;
This information is stored in the "extra" fields of the frame_info. */
static void
-tic80_scan_prologue (fi)
- struct frame_info *fi;
+tic80_scan_prologue (struct frame_info *fi)
{
struct symtab_and_line sal;
CORE_ADDR prologue_start, prologue_end, current_pc;
examine the prologue. */
void
-tic80_init_extra_frame_info (fi)
- struct frame_info *fi;
+tic80_init_extra_frame_info (struct frame_info *fi)
{
int reg;
caller-saves registers for an inner frame. */
CORE_ADDR
-tic80_find_callers_reg (fi, regnum)
- struct frame_info *fi;
- int regnum;
+tic80_find_callers_reg (struct frame_info *fi, int regnum)
{
for (; fi; fi = fi->next)
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
For c80, we save the frame size when we initialize the frame_info. */
CORE_ADDR
-tic80_frame_chain (fi)
- struct frame_info *fi;
+tic80_frame_chain (struct frame_info *fi)
{
CORE_ADDR fn_start, callers_pc, fp;
restoring all saved registers. */
struct frame_info *
-tic80_pop_frame (frame)
- struct frame_info *frame;
+tic80_pop_frame (struct frame_info *frame)
{
int regnum;
in the stack anywhere, otherwise we get it from the registers. */
CORE_ADDR
-tic80_frame_saved_pc (fi)
- struct frame_info *fi;
+tic80_frame_saved_pc (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
(ie. when using an empty CALL_DUMMY) */
CORE_ADDR
-tic80_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+tic80_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
write_register (LR_REGNUM, CALL_DUMMY_ADDRESS ());
return sp;
passed as an implicit first argument, always in R0. */
CORE_ADDR
-tic80_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+tic80_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int stack_offset, stack_alloc;
int argreg;
we must actually write one of those two as well, depending on PSW. */
void
-tic80_write_sp (val)
- CORE_ADDR val;
+tic80_write_sp (CORE_ADDR val)
{
#if 0
unsigned long psw = read_register (PSW_REGNUM);
}
void
-_initialize_tic80_tdep ()
+_initialize_tic80_tdep (void)
{
tm_print_insn = print_insn_tic80;
}
/* Return for reason REASON to the nearest containing catch_errors(). */
NORETURN void
-return_to_top_level (reason)
- enum return_reason reason;
+return_to_top_level (enum return_reason reason)
{
quit_flag = 0;
immediate_quit = 0;
between utils.c and top.c? */
int
-catch_errors (func, args, errstring, mask)
- catch_errors_ftype *func;
- PTR args;
- char *errstring;
- return_mask mask;
+catch_errors (catch_errors_ftype *func, PTR args, char *errstring,
+ return_mask mask)
{
SIGJMP_BUF *saved_catch;
SIGJMP_BUF catch;
#ifdef SIGHUP
static void
-disconnect (signo)
- int signo;
+disconnect (int signo)
{
catch_errors (quit_cover, NULL,
"Could not kill the program being debugged", RETURN_MASK_ALL);
gdb to use the event loop as the default command loop and we merge
event-top.c into this file, top.c */
/* static */ int
-quit_cover (s)
- PTR s;
+quit_cover (PTR s)
{
caution = 0; /* Throw caution to the wind -- we're exiting.
This prevents asking the user dumb questions. */
/* Read commands from STREAM. */
void
-read_command_file (stream)
- FILE *stream;
+read_command_file (FILE *stream)
{
struct cleanup *cleanups;
#endif
void
-gdb_init (argv0)
- char *argv0;
+gdb_init (char *argv0)
{
if (pre_init_ui_hook)
pre_init_ui_hook ();
control commands (if/while). */
static struct command_line *
-build_command_line (type, args)
- enum command_control_type type;
- char *args;
+build_command_line (enum command_control_type type, char *args)
{
struct command_line *cmd;
such as "if" and "while". */
static struct command_line *
-get_command_line (type, arg)
- enum command_control_type type;
- char *arg;
+get_command_line (enum command_control_type type, char *arg)
{
struct command_line *cmd;
struct cleanup *old_chain = NULL;
/* Recursively print a command (including full control structures). */
#ifdef UI_OUT
void
-print_command_lines (uiout, cmd, depth)
- struct ui_out *uiout;
- struct command_line *cmd;
- unsigned int depth;
+print_command_lines (struct ui_out *uiout, struct command_line *cmd,
+ unsigned int depth)
{
struct command_line *list;
}
#else
void
-print_command_line (cmd, depth, stream)
- struct command_line *cmd;
- unsigned int depth;
- struct ui_file *stream;
+print_command_line (struct command_line *cmd, unsigned int depth,
+ struct ui_file *stream)
{
unsigned int i;
/* Execute the command in CMD. */
enum command_control_type
-execute_control_command (cmd)
- struct command_line *cmd;
+execute_control_command (struct command_line *cmd)
{
struct expression *expr;
struct command_line *current;
loop condition is nonzero. */
static void
-while_command (arg, from_tty)
- char *arg;
- int from_tty;
+while_command (char *arg, int from_tty)
{
struct command_line *command = NULL;
on the value of the if conditional. */
static void
-if_command (arg, from_tty)
- char *arg;
- int from_tty;
+if_command (char *arg, int from_tty)
{
struct command_line *command = NULL;
$arg0, $arg1 ... $argMAXUSERARGS. */
static struct cleanup *
-setup_user_args (p)
- char *p;
+setup_user_args (char *p)
{
struct user_args *args;
struct cleanup *old_chain;
or NULL if P contains no arguments. */
static char *
-locate_arg (p)
- char *p;
+locate_arg (char *p)
{
while ((p = strchr (p, '$')))
{
arguments found in line, with the updated copy being placed into nline. */
static char *
-insert_args (line)
- char *line;
+insert_args (char *line)
{
char *p, *save_line, *new_line;
unsigned len, i;
}
void
-execute_user_command (c, args)
- struct cmd_list_element *c;
- char *args;
+execute_user_command (struct cmd_list_element *c, char *args)
{
register struct command_line *cmdlines;
struct cleanup *old_chain;
Pass FROM_TTY as second argument to the defining function. */
void
-execute_command (p, from_tty)
- char *p;
- int from_tty;
+execute_command (char *p, int from_tty)
{
register struct cmd_list_element *c;
register enum language flang;
until end of file or error reading instream. */
void
-command_loop ()
+command_loop (void)
{
struct cleanup *old_chain;
char *command;
/* Commands call this if they do not want to be repeated by null lines. */
void
-dont_repeat ()
+dont_repeat (void)
{
if (server_command)
return;
A NULL return means end of file. */
char *
-gdb_readline (prompt_arg)
- char *prompt_arg;
+gdb_readline (char *prompt_arg)
{
int c;
char *result;
but don't want to complete on anything else either. */
/* ARGSUSED */
char **
-noop_completer (text, prefix)
- char *text;
- char *prefix;
+noop_completer (char *text, char *prefix)
{
return NULL;
}
/* Complete on filenames. */
char **
-filename_completer (text, word)
- char *text;
- char *word;
+filename_completer (char *text, char *word)
{
/* From readline. */
extern char *filename_completion_function (char *, int);
free the string. */
static char *
-line_completion_function (text, matches, line_buffer, point)
- char *text;
- int matches;
- char *line_buffer;
- int point;
+line_completion_function (char *text, int matches, char *line_buffer, int point)
{
static char **list = (char **) NULL; /* Cache of completions */
static int index; /* Next cached completion */
/* Line completion interface function for readline. */
static char *
-readline_line_completion_function (text, matches)
- char *text;
- int matches;
+readline_line_completion_function (char *text, int matches)
{
return line_completion_function (text, matches, rl_line_buffer, rl_point);
}
location after the "word". */
char *
-skip_quoted (str)
- char *str;
+skip_quoted (char *str)
{
char quote_char = '\0';
char *scan;
#ifdef STOP_SIGNAL
static void
-stop_sig (signo)
- int signo;
+stop_sig (int signo)
{
#if STOP_SIGNAL == SIGTSTP
signal (SIGTSTP, SIG_DFL);
/* Initialize signal handlers. */
static void
-do_nothing (signo)
- int signo;
+do_nothing (int signo)
{
/* Under System V the default disposition of a signal is reinstated after
the signal is caught and delivered to an application process. On such
}
static void
-init_signals ()
+init_signals (void)
{
signal (SIGINT, request_quit);
simple input as the user has requested. */
char *
-command_line_input (prompt_arg, repeat, annotation_suffix)
- char *prompt_arg;
- int repeat;
- char *annotation_suffix;
+command_line_input (char *prompt_arg, int repeat, char *annotation_suffix)
{
static char *linebuffer = 0;
static unsigned linelength = 0;
clause for an "if" command. */
static void
-realloc_body_list (command, new_length)
- struct command_line *command;
- int new_length;
+realloc_body_list (struct command_line *command, int new_length)
{
int n;
struct command_line **body_list;
"end", return such an indication to the caller. */
static enum misc_command_type
-read_next_line (command)
- struct command_line **command;
+read_next_line (struct command_line **command)
{
char *p, *p1, *prompt_ptr, control_prompt[256];
int i = 0;
following commands are nested. */
static enum command_control_type
-recurse_read_control_structure (current_cmd)
- struct command_line *current_cmd;
+recurse_read_control_structure (struct command_line *current_cmd)
{
int current_body, i;
enum misc_command_type val;
#define END_MESSAGE "End with a line saying just \"end\"."
struct command_line *
-read_command_lines (prompt_arg, from_tty)
- char *prompt_arg;
- int from_tty;
+read_command_lines (char *prompt_arg, int from_tty)
{
struct command_line *head, *tail, *next;
struct cleanup *old_chain;
/* Free a chain of struct command_line's. */
void
-free_command_lines (lptr)
- struct command_line **lptr;
+free_command_lines (struct command_line **lptr)
{
register struct command_line *l = *lptr;
register struct command_line *next;
/* Add an alias to the list of info subcommands. */
struct cmd_list_element *
-add_info_alias (name, oldname, abbrev_flag)
- char *name;
- char *oldname;
- int abbrev_flag;
+add_info_alias (char *name, char *oldname, int abbrev_flag)
{
return add_alias_cmd (name, oldname, 0, abbrev_flag, &infolist);
}
/* ARGSUSED */
static void
-info_command (arg, from_tty)
- char *arg;
- int from_tty;
+info_command (char *arg, int from_tty)
{
printf_unfiltered ("\"info\" must be followed by the name of an info command.\n");
help_list (infolist, "info ", -1, gdb_stdout);
/* ARGSUSED */
static void
-complete_command (arg, from_tty)
- char *arg;
- int from_tty;
+complete_command (char *arg, int from_tty)
{
int i;
int argpoint;
/* ARGSUSED */
static void
-show_command (arg, from_tty)
- char *arg;
- int from_tty;
+show_command (char *arg, int from_tty)
{
cmd_show_list (showlist, from_tty, "");
}
/* Add an alias or abbreviation command to the list of commands. */
struct cmd_list_element *
-add_com_alias (name, oldname, class, abbrev_flag)
- char *name;
- char *oldname;
- enum command_class class;
- int abbrev_flag;
+add_com_alias (char *name, char *oldname, enum command_class class,
+ int abbrev_flag)
{
return add_alias_cmd (name, oldname, class, abbrev_flag, &cmdlist);
}
void
-error_no_arg (why)
- char *why;
+error_no_arg (char *why)
{
error ("Argument required (%s).", why);
}
}
\f
static void
-validate_comname (comname)
- char *comname;
+validate_comname (char *comname)
{
register char *p;
/* This is just a placeholder in the command data structures. */
static void
-user_defined_command (ignore, from_tty)
- char *ignore;
- int from_tty;
+user_defined_command (char *ignore, int from_tty)
{
}
static void
-define_command (comname, from_tty)
- char *comname;
- int from_tty;
+define_command (char *comname, int from_tty)
{
register struct command_line *cmds;
register struct cmd_list_element *c, *newc, *hookc = 0;
}
static void
-document_command (comname, from_tty)
- char *comname;
- int from_tty;
+document_command (char *comname, int from_tty)
{
struct command_line *doclines;
register struct cmd_list_element *c;
\f
/* Print the GDB banner. */
void
-print_gdb_version (stream)
- struct ui_file *stream;
+print_gdb_version (struct ui_file *stream)
{
/* From GNU coding standards, first line is meant to be easy for a
program to parse, and is just canonical program name and version
/* ARGSUSED */
static void
-show_version (args, from_tty)
- char *args;
- int from_tty;
+show_version (char *args, int from_tty)
{
immediate_quit++;
print_gdb_version (gdb_stdout);
static int gdb_prompt_escape;
static int
-get_prompt_1 (formatted_prompt)
- char *formatted_prompt;
+get_prompt_1 (char *formatted_prompt)
{
char *local_prompt;
}
char *
-get_prompt ()
+get_prompt (void)
{
static char buf[MAX_PROMPT_SIZE];
}
void
-set_prompt (s)
- char *s;
+set_prompt (char *s)
{
/* ??rehrauer: I don't know why this fails, since it looks as though
assignments to prompt are wrapped in calls to savestring...
non-zero if we should quit, zero if we shouldn't. */
int
-quit_confirm ()
+quit_confirm (void)
{
if (inferior_pid != 0 && target_has_execution)
{
/* Quit without asking for confirmation. */
void
-quit_force (args, from_tty)
- char *args;
- int from_tty;
+quit_force (char *args, int from_tty)
{
int exit_code = 0;
/* Handle the quit command. */
void
-quit_command (args, from_tty)
- char *args;
- int from_tty;
+quit_command (char *args, int from_tty)
{
if (!quit_confirm ())
error ("Not confirmed.");
desires that questions be asked of them on that terminal. */
int
-input_from_terminal_p ()
+input_from_terminal_p (void)
{
return gdb_has_a_terminal () && (instream == stdin) & caution;
}
\f
/* ARGSUSED */
static void
-pwd_command (args, from_tty)
- char *args;
- int from_tty;
+pwd_command (char *args, int from_tty)
{
if (args)
error ("The \"pwd\" command does not take an argument: %s", args);
}
void
-cd_command (dir, from_tty)
- char *dir;
- int from_tty;
+cd_command (char *dir, int from_tty)
{
int len;
/* Found something other than leading repetitions of "/..". */
};
static void
-source_cleanup_lines (args)
- PTR args;
+source_cleanup_lines (PTR args)
{
struct source_cleanup_lines_args *p =
(struct source_cleanup_lines_args *) args;
}
void
-source_command (args, from_tty)
- char *args;
- int from_tty;
+source_command (char *args, int from_tty)
{
FILE *stream;
struct cleanup *old_cleanups;
/* ARGSUSED */
static void
-echo_command (text, from_tty)
- char *text;
- int from_tty;
+echo_command (char *text, int from_tty)
{
char *p = text;
register int c;
/* ARGSUSED */
static void
-dont_repeat_command (ignored, from_tty)
- char *ignored;
- int from_tty;
+dont_repeat_command (char *ignored, int from_tty)
{
*line = 0; /* Can't call dont_repeat here because we're not
necessarily reading from stdin. */
/* Number of commands to print in each call to show_commands. */
#define Hist_print 10
static void
-show_commands (args, from_tty)
- char *args;
- int from_tty;
+show_commands (char *args, int from_tty)
{
/* Index for history commands. Relative to history_base. */
int offset;
/* Called by do_setshow_command. */
/* ARGSUSED */
static void
-set_history_size_command (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_history_size_command (char *args, int from_tty, struct cmd_list_element *c)
{
if (history_size == INT_MAX)
unstifle_history ();
/* ARGSUSED */
static void
-set_history (args, from_tty)
- char *args;
- int from_tty;
+set_history (char *args, int from_tty)
{
printf_unfiltered ("\"set history\" must be followed by the name of a history subcommand.\n");
help_list (sethistlist, "set history ", -1, gdb_stdout);
/* ARGSUSED */
static void
-show_history (args, from_tty)
- char *args;
- int from_tty;
+show_history (char *args, int from_tty)
{
cmd_show_list (showhistlist, from_tty, "");
}
/* Called by do_setshow_command. An elaborate joke. */
/* ARGSUSED */
static void
-set_verbose (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_verbose (char *args, int from_tty, struct cmd_list_element *c)
{
char *cmdname = "verbose";
struct cmd_list_element *showcmd;
}
static void
-float_handler (signo)
- int signo;
+float_handler (int signo)
{
/* This message is based on ANSI C, section 4.7. Note that integer
divide by zero causes this, so "float" is a misnomer. */
}
static void
-set_debug (arg, from_tty)
- char *arg;
- int from_tty;
+set_debug (char *arg, int from_tty)
{
printf_unfiltered ("\"set debug\" must be followed by the name of a print subcommand.\n");
help_list (setdebuglist, "set debug ", -1, gdb_stdout);
}
static void
-show_debug (args, from_tty)
- char *args;
- int from_tty;
+show_debug (char *args, int from_tty)
{
cmd_show_list (showdebuglist, from_tty, "");
}
static void
-init_cmd_lists ()
+init_cmd_lists (void)
{
cmdlist = NULL;
infolist = NULL;
*/
void
-init_history ()
+init_history (void)
{
char *tmpenv;
}
static void
-init_main ()
+init_main (void)
{
struct cmd_list_element *c;
/* Utility: returns true if "target remote" */
static int
-target_is_remote ()
+target_is_remote (void)
{
if (current_target.to_shortname &&
strcmp (current_target.to_shortname, "remote") == 0)
/* Utility: generate error from an incoming stub packet. */
static void
-trace_error (buf)
- char *buf;
+trace_error (char *buf)
{
if (*buf++ != 'E')
return; /* not an error msg */
/* Set tracepoint count to NUM. */
static void
-set_tracepoint_count (num)
- int num;
+set_tracepoint_count (int num)
{
tracepoint_count = num;
set_internalvar (lookup_internalvar ("tpnum"),
/* Set traceframe number to NUM. */
static void
-set_traceframe_num (num)
- int num;
+set_traceframe_num (int num)
{
traceframe_number = num;
set_internalvar (lookup_internalvar ("trace_frame"),
/* Set tracepoint number to NUM. */
static void
-set_tracepoint_num (num)
- int num;
+set_tracepoint_num (int num)
{
tracepoint_number = num;
set_internalvar (lookup_internalvar ("tracepoint"),
the traceframe context (line, function, file) */
static void
-set_traceframe_context (trace_pc)
- CORE_ADDR trace_pc;
+set_traceframe_context (CORE_ADDR trace_pc)
{
static struct type *func_string, *file_string;
static struct type *func_range, *file_range;
your arguments BEFORE calling this routine! */
static struct tracepoint *
-set_raw_tracepoint (sal)
- struct symtab_and_line sal;
+set_raw_tracepoint (struct symtab_and_line sal)
{
register struct tracepoint *t, *tc;
struct cleanup *old_chain;
/* Set a tracepoint according to ARG (function, linenum or *address) */
static void
-trace_command (arg, from_tty)
- char *arg;
- int from_tty;
+trace_command (char *arg, int from_tty)
{
char **canonical = (char **) NULL;
struct symtabs_and_lines sals;
/* Tell the user we have just set a tracepoint TP. */
static void
-trace_mention (tp)
- struct tracepoint *tp;
+trace_mention (struct tracepoint *tp)
{
printf_filtered ("Tracepoint %d", tp->number);
/* Print information on tracepoint number TPNUM_EXP, or all if omitted. */
static void
-tracepoints_info (tpnum_exp, from_tty)
- char *tpnum_exp;
- int from_tty;
+tracepoints_info (char *tpnum_exp, int from_tty)
{
struct tracepoint *t;
struct action_line *action;
/* This function implements enable, disable and delete commands. */
static void
-tracepoint_operation (t, from_tty, opcode)
- struct tracepoint *t;
- int from_tty;
- enum tracepoint_opcode opcode;
+tracepoint_operation (struct tracepoint *t, int from_tty,
+ enum tracepoint_opcode opcode)
{
struct tracepoint *t2;
if OPTIONAL_P is true, then if the argument is missing, the most
recent tracepoint (tracepoint_count) is returned. */
struct tracepoint *
-get_tracepoint_by_number (arg, multi_p, optional_p)
- char **arg;
- int multi_p, optional_p;
+get_tracepoint_by_number (char **arg, int multi_p, int optional_p)
{
struct tracepoint *t;
int tpnum;
/* Utility: parse a list of tracepoint numbers, and call a func for each. */
static void
-map_args_over_tracepoints (args, from_tty, opcode)
- char *args;
- int from_tty;
- enum tracepoint_opcode opcode;
+map_args_over_tracepoints (char *args, int from_tty,
+ enum tracepoint_opcode opcode)
{
struct tracepoint *t, *tmp;
/* The 'enable trace' command enables tracepoints. Not supported by all targets. */
static void
-enable_trace_command (args, from_tty)
- char *args;
- int from_tty;
+enable_trace_command (char *args, int from_tty)
{
dont_repeat ();
map_args_over_tracepoints (args, from_tty, enable_op);
/* The 'disable trace' command enables tracepoints. Not supported by all targets. */
static void
-disable_trace_command (args, from_tty)
- char *args;
- int from_tty;
+disable_trace_command (char *args, int from_tty)
{
dont_repeat ();
map_args_over_tracepoints (args, from_tty, disable_op);
/* Remove a tracepoint (or all if no argument) */
static void
-delete_trace_command (args, from_tty)
- char *args;
- int from_tty;
+delete_trace_command (char *args, int from_tty)
{
dont_repeat ();
if (!args || !*args) /* No args implies all tracepoints; */
Also accepts special argument "all". */
static void
-trace_pass_command (args, from_tty)
- char *args;
- int from_tty;
+trace_pass_command (char *args, int from_tty)
{
struct tracepoint *t1 = (struct tracepoint *) -1, *t2;
unsigned int count;
which is always an error. */
static void
-end_actions_pseudocommand (args, from_tty)
- char *args;
- int from_tty;
+end_actions_pseudocommand (char *args, int from_tty)
{
error ("This command cannot be used at the top level.");
}
static void
-while_stepping_pseudocommand (args, from_tty)
- char *args;
- int from_tty;
+while_stepping_pseudocommand (char *args, int from_tty)
{
error ("This command can only be used in a tracepoint actions list.");
}
static void
-collect_pseudocommand (args, from_tty)
- char *args;
- int from_tty;
+collect_pseudocommand (char *args, int from_tty)
{
error ("This command can only be used in a tracepoint actions list.");
}
/* Enter a list of actions for a tracepoint. */
static void
-trace_actions_command (args, from_tty)
- char *args;
- int from_tty;
+trace_actions_command (char *args, int from_tty)
{
struct tracepoint *t;
char tmpbuf[128];
/* worker function */
static void
-read_actions (t)
- struct tracepoint *t;
+read_actions (struct tracepoint *t)
{
char *line;
char *prompt1 = "> ", *prompt2 = " > ";
/* worker function */
enum actionline_type
-validate_actionline (line, t)
- char **line;
- struct tracepoint *t;
+validate_actionline (char **line, struct tracepoint *t)
{
struct cmd_list_element *c;
struct expression *exp = NULL;
/* worker function */
void
-free_actions (t)
- struct tracepoint *t;
+free_actions (struct tracepoint *t)
{
struct action_line *line, *next;
/* compare memranges for qsort */
static int
-memrange_cmp (va, vb)
- const void *va;
- const void *vb;
+memrange_cmp (const void *va, const void *vb)
{
const struct memrange *a = va, *b = vb;
/* Sort the memrange list using qsort, and merge adjacent memranges */
static void
-memrange_sortmerge (memranges)
- struct collection_list *memranges;
+memrange_sortmerge (struct collection_list *memranges)
{
int a, b;
/* Add a register to a collection list */
static void
-add_register (collection, regno)
- struct collection_list *collection;
- unsigned int regno;
+add_register (struct collection_list *collection, unsigned int regno)
{
if (info_verbose)
printf_filtered ("collect register %d\n", regno);
/* Add a memrange to a collection list */
static void
-add_memrange (memranges, type, base, len)
- struct collection_list *memranges;
- int type;
- bfd_signed_vma base;
- unsigned long len;
+add_memrange (struct collection_list *memranges, int type, bfd_signed_vma base,
+ unsigned long len)
{
if (info_verbose)
{
/* Add a symbol to a collection list */
static void
-collect_symbol (collect, sym, frame_regno, frame_offset)
- struct collection_list *collect;
- struct symbol *sym;
- long frame_regno;
- long frame_offset;
+collect_symbol (struct collection_list *collect, struct symbol *sym,
+ long frame_regno, long frame_offset)
{
unsigned long len;
unsigned int reg;
/* Add all locals (or args) symbols to collection list */
static void
-add_local_symbols (collect, pc, frame_regno, frame_offset, type)
- struct collection_list *collect;
- CORE_ADDR pc;
- long frame_regno;
- long frame_offset;
- int type;
+add_local_symbols (struct collection_list *collect, CORE_ADDR pc,
+ long frame_regno, long frame_offset, int type)
{
struct symbol *sym;
struct block *block;
/* worker function */
static void
-clear_collection_list (list)
- struct collection_list *list;
+clear_collection_list (struct collection_list *list)
{
int ndx;
/* reduce a collection list to string form (for gdb protocol) */
static char **
-stringify_collection_list (list, string)
- struct collection_list *list;
- char *string;
+stringify_collection_list (struct collection_list *list, char *string)
{
char temp_buf[2048];
char tmp2[40];
}
static void
-free_actions_list_cleanup_wrapper (al)
- void *al;
+free_actions_list_cleanup_wrapper (void *al)
{
free_actions_list (al);
}
static void
-free_actions_list (actions_list)
- char **actions_list;
+free_actions_list (char **actions_list)
{
int ndx;
/* render all actions into gdb protocol */
static void
-encode_actions (t, tdp_actions, stepping_actions)
- struct tracepoint *t;
- char ***tdp_actions;
- char ***stepping_actions;
+encode_actions (struct tracepoint *t, char ***tdp_actions,
+ char ***stepping_actions)
{
static char tdp_buff[2048], step_buff[2048];
char *action_exp;
}
static void
-add_aexpr (collect, aexpr)
- struct collection_list *collect;
- struct agent_expr *aexpr;
+add_aexpr (struct collection_list *collect, struct agent_expr *aexpr)
{
if (collect->next_aexpr_elt >= collect->aexpr_listsize)
{
Tell target to start a new trace experiment. */
static void
-trace_start_command (args, from_tty)
- char *args;
- int from_tty;
+trace_start_command (char *args, int from_tty)
{ /* STUB_COMM MOSTLY_IMPLEMENTED */
struct tracepoint *t;
char buf[2048];
/* tstop command */
static void
-trace_stop_command (args, from_tty)
- char *args;
- int from_tty;
+trace_stop_command (char *args, int from_tty)
{ /* STUB_COMM IS_IMPLEMENTED */
if (target_is_remote ())
{
/* tstatus command */
static void
-trace_status_command (args, from_tty)
- char *args;
- int from_tty;
+trace_status_command (char *args, int from_tty)
{ /* STUB_COMM IS_IMPLEMENTED */
if (target_is_remote ())
{
/* tfind command */
static void
-trace_find_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_command (char *args, int from_tty)
{ /* STUB_COMM PART_IMPLEMENTED */
/* this should only be called with a numeric argument */
int frameno = -1;
/* tfind end */
static void
-trace_find_end_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_end_command (char *args, int from_tty)
{
trace_find_command ("-1", from_tty);
}
/* tfind none */
static void
-trace_find_none_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_none_command (char *args, int from_tty)
{
trace_find_command ("-1", from_tty);
}
/* tfind start */
static void
-trace_find_start_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_start_command (char *args, int from_tty)
{
trace_find_command ("0", from_tty);
}
/* tfind pc command */
static void
-trace_find_pc_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_pc_command (char *args, int from_tty)
{ /* STUB_COMM PART_IMPLEMENTED */
CORE_ADDR pc;
char tmp[40];
/* tfind tracepoint command */
static void
-trace_find_tracepoint_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_tracepoint_command (char *args, int from_tty)
{ /* STUB_COMM PART_IMPLEMENTED */
int tdp;
corresponding to a source line OTHER THAN THE CURRENT ONE. */
static void
-trace_find_line_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_line_command (char *args, int from_tty)
{ /* STUB_COMM PART_IMPLEMENTED */
static CORE_ADDR start_pc, end_pc;
struct symtabs_and_lines sals;
/* tfind range command */
static void
-trace_find_range_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_range_command (char *args, int from_tty)
{
static CORE_ADDR start, stop;
char start_str[40], stop_str[40];
/* tfind outside command */
static void
-trace_find_outside_command (args, from_tty)
- char *args;
- int from_tty;
+trace_find_outside_command (char *args, int from_tty)
{
CORE_ADDR start, stop;
char start_str[40], stop_str[40];
/* save-tracepoints command */
static void
-tracepoint_save_command (args, from_tty)
- char *args;
- int from_tty;
+tracepoint_save_command (char *args, int from_tty)
{
struct tracepoint *tp;
struct action_line *line;
/* info scope command: list the locals for a scope. */
static void
-scope_info (args, from_tty)
- char *args;
- int from_tty;
+scope_info (char *args, int from_tty)
{
struct symtabs_and_lines sals;
struct symbol *sym;
/* worker function (cleanup) */
static void
-replace_comma (comma)
- char *comma;
+replace_comma (char *comma)
{
*comma = ',';
}
/* tdump command */
static void
-trace_dump_command (args, from_tty)
- char *args;
- int from_tty;
+trace_dump_command (char *args, int from_tty)
{
struct tracepoint *t;
struct action_line *action;
static const char hexchars[] = "0123456789abcdef";
static unsigned char *
-mem2hex (mem, buf, count)
- unsigned char *mem;
- unsigned char *buf;
- int count;
+mem2hex (unsigned char *mem, unsigned char *buf, int count)
{
unsigned char ch;
}
int
-get_traceframe_number ()
+get_traceframe_number (void)
{
return traceframe_number;
}
/* module initialization */
void
-_initialize_tracepoint ()
+_initialize_tracepoint (void)
{
tracepoint_chain = 0;
tracepoint_count = 0;
static int tui_file_magic;
static struct ui_file *
-tui_file_new ()
+tui_file_new (void)
{
struct tui_stream *tui = xmalloc (sizeof (struct tui_stream));
struct ui_file *file = ui_file_new ();
}
static void
-tui_file_delete (file)
- struct ui_file *file;
+tui_file_delete (struct ui_file *file)
{
struct tui_stream *tmpstream = ui_file_data (file);
if (tmpstream->ts_magic != &tui_file_magic)
}
struct ui_file *
-tui_fileopen (stream)
- FILE *stream;
+tui_fileopen (FILE *stream)
{
struct ui_file *file = tui_file_new ();
struct tui_stream *tmpstream = ui_file_data (file);
}
struct ui_file *
-tui_sfileopen (n)
- int n;
+tui_sfileopen (int n)
{
struct ui_file *file = tui_file_new ();
struct tui_stream *tmpstream = ui_file_data (file);
}
static int
-tui_file_isatty (file)
- struct ui_file *file;
+tui_file_isatty (struct ui_file *file)
{
struct tui_stream *stream = ui_file_data (file);
if (stream->ts_magic != &tui_file_magic)
}
static void
-tui_file_rewind (file)
- struct ui_file *file;
+tui_file_rewind (struct ui_file *file)
{
struct tui_stream *stream = ui_file_data (file);
if (stream->ts_magic != &tui_file_magic)
/* FIXME: Should be broken up and moved to a TUI specific file. */
void
-tui_file_fputs (linebuffer, file)
- const char *linebuffer;
- struct ui_file *file;
+tui_file_fputs (const char *linebuffer, struct ui_file *file)
{
struct tui_stream *stream = ui_file_data (file);
#if defined(TUI)
}
static void
-tui_file_flush (file)
- struct ui_file *file;
+tui_file_flush (struct ui_file *file)
{
struct tui_stream *stream = ui_file_data (file);
if (stream->ts_magic != &tui_file_magic)
** Function to initialize gdb commands, for tui window manipulation.
*/
void
-_initialize_tui ()
+_initialize_tui (void)
{
#if 0
if (tui_version)
** manipulation.
*/
void
-_initialize_tuiLayout ()
+_initialize_tuiLayout (void)
{
if (tui_version)
{
void
-_initialize_tuiRegs ()
+_initialize_tuiRegs (void)
{
if (tui_version && xdb_commands)
{
** Function to initialize gdb commands, for tui window stack manipulation.
*/
void
-_initialize_tuiStack ()
+_initialize_tuiStack (void)
{
if (tui_version)
{
** Function to initialize gdb commands, for tui window manipulation.
*/
void
-_initialize_tuiWin ()
+_initialize_tuiWin (void)
{
if (tui_version)
{
If SHOW is negative, we never show the details of elements' types. */
void
-type_print (type, varstring, stream, show)
- struct type *type;
- char *varstring;
- struct ui_file *stream;
- int show;
+type_print (struct type *type, char *varstring, struct ui_file *stream,
+ int show)
{
LA_PRINT_TYPE (type, varstring, stream, show, 0);
}
show is passed to type_print. */
static void
-whatis_exp (exp, show)
- char *exp;
- int show;
+whatis_exp (char *exp, int show)
{
struct expression *expr;
register value_ptr val;
/* ARGSUSED */
static void
-whatis_command (exp, from_tty)
- char *exp;
- int from_tty;
+whatis_command (char *exp, int from_tty)
{
/* Most of the time users do not want to see all the fields
in a structure. If they do they can use the "ptype" command.
/* Simple subroutine for ptype_command. */
static struct type *
-ptype_eval (exp)
- struct expression *exp;
+ptype_eval (struct expression *exp)
{
if (exp->elts[0].opcode == OP_TYPE)
{
/* ARGSUSED */
static void
-ptype_command (typename, from_tty)
- char *typename;
- int from_tty;
+ptype_command (char *typename, int from_tty)
{
register struct type *type;
struct expression *expr;
that come from the inferior in target byte order and target size. */
void
-print_type_scalar (type, val, stream)
- struct type *type;
- LONGEST val;
- struct ui_file *stream;
+print_type_scalar (struct type *type, LONGEST val, struct ui_file *stream)
{
unsigned int i;
unsigned len;
and whatis_command(). */
void
-maintenance_print_type (typename, from_tty)
- char *typename;
- int from_tty;
+maintenance_print_type (char *typename, int from_tty)
{
register value_ptr val;
register struct type *type;
\f
void
-_initialize_typeprint ()
+_initialize_typeprint (void)
{
add_com ("ptype", class_vars, ptype_command,
int ui_file_magic;
struct ui_file *
-ui_file_new ()
+ui_file_new (void)
{
struct ui_file *file = xmalloc (sizeof (struct ui_file));
file->magic = &ui_file_magic;
}
void
-ui_file_delete (file)
- struct ui_file *file;
+ui_file_delete (struct ui_file *file)
{
file->to_delete (file);
free (file);
}
static int
-null_file_isatty (file)
- struct ui_file *file;
+null_file_isatty (struct ui_file *file)
{
return 0;
}
static void
-null_file_rewind (file)
- struct ui_file *file;
+null_file_rewind (struct ui_file *file)
{
return;
}
}
static void
-null_file_flush (file)
- struct ui_file *file;
+null_file_flush (struct ui_file *file)
{
return;
}
}
static void
-null_file_fputs (buf, file)
- const char *buf;
- struct ui_file *file;
+null_file_fputs (const char *buf, struct ui_file *file)
{
if (file->to_write == null_file_write)
/* Both the write and fputs methods are null. Discard the
}
static void
-null_file_delete (file)
- struct ui_file *file;
+null_file_delete (struct ui_file *file)
{
return;
}
void *
-ui_file_data (file)
- struct ui_file *file;
+ui_file_data (struct ui_file *file)
{
if (file->magic != &ui_file_magic)
internal_error ("ui_file_data: bad magic number");
}
void
-gdb_flush (file)
- struct ui_file *file;
+gdb_flush (struct ui_file *file)
{
file->to_flush (file);
}
int
-ui_file_isatty (file)
- struct ui_file *file;
+ui_file_isatty (struct ui_file *file)
{
return file->to_isatty (file);
}
void
-ui_file_rewind (file)
- struct ui_file *file;
+ui_file_rewind (struct ui_file *file)
{
file->to_rewind (file);
}
}
void
-fputs_unfiltered (buf, file)
- const char *buf;
- struct ui_file *file;
+fputs_unfiltered (const char *buf, struct ui_file *file)
{
file->to_fputs (buf, file);
}
void
-set_ui_file_flush (file, flush)
- struct ui_file *file;
- ui_file_flush_ftype *flush;
+set_ui_file_flush (struct ui_file *file, ui_file_flush_ftype *flush)
{
file->to_flush = flush;
}
void
-set_ui_file_isatty (file, isatty)
- struct ui_file *file;
- ui_file_isatty_ftype *isatty;
+set_ui_file_isatty (struct ui_file *file, ui_file_isatty_ftype *isatty)
{
file->to_isatty = isatty;
}
void
-set_ui_file_rewind (file, rewind)
- struct ui_file *file;
- ui_file_rewind_ftype *rewind;
+set_ui_file_rewind (struct ui_file *file, ui_file_rewind_ftype *rewind)
{
file->to_rewind = rewind;
}
void
-set_ui_file_put (file, put)
- struct ui_file *file;
- ui_file_put_ftype *put;
+set_ui_file_put (struct ui_file *file, ui_file_put_ftype *put)
{
file->to_put = put;
}
}
void
-set_ui_file_fputs (file, fputs)
- struct ui_file *file;
- ui_file_fputs_ftype *fputs;
+set_ui_file_fputs (struct ui_file *file, ui_file_fputs_ftype *fputs)
{
file->to_fputs = fputs;
}
void
-set_ui_file_data (file, data, delete)
- struct ui_file *file;
- void *data;
- ui_file_delete_ftype *delete;
+set_ui_file_data (struct ui_file *file, void *data,
+ ui_file_delete_ftype *delete)
{
file->to_data = data;
file->to_delete = delete;
};
static struct ui_file *
-stdio_file_new (file, close_p)
- FILE *file;
- int close_p;
+stdio_file_new (FILE *file, int close_p)
{
struct ui_file *ui_file = ui_file_new ();
struct stdio_file *stdio = xmalloc (sizeof (struct stdio_file));
}
static void
-stdio_file_delete (file)
- struct ui_file *file;
+stdio_file_delete (struct ui_file *file)
{
struct stdio_file *stdio = ui_file_data (file);
if (stdio->magic != &stdio_file_magic)
}
static void
-stdio_file_flush (file)
- struct ui_file *file;
+stdio_file_flush (struct ui_file *file)
{
struct stdio_file *stdio = ui_file_data (file);
if (stdio->magic != &stdio_file_magic)
}
static void
-stdio_file_fputs (linebuffer, file)
- const char *linebuffer;
- struct ui_file *file;
+stdio_file_fputs (const char *linebuffer, struct ui_file *file)
{
struct stdio_file *stdio = ui_file_data (file);
if (stdio->magic != &stdio_file_magic)
}
static int
-stdio_file_isatty (file)
- struct ui_file *file;
+stdio_file_isatty (struct ui_file *file)
{
struct stdio_file *stdio = ui_file_data (file);
if (stdio->magic != &stdio_file_magic)
/* Like fdopen(). Create a ui_file from a previously opened FILE. */
struct ui_file *
-stdio_fileopen (file)
- FILE *file;
+stdio_fileopen (FILE *file)
{
return stdio_file_new (file, 0);
}
struct ui_file *
-gdb_fopen (name, mode)
- char *name;
- char *mode;
+gdb_fopen (char *name, char *mode)
{
FILE *f = fopen (name, mode);
if (f == NULL)
/* Mark beginning of a table */
void
-ui_out_table_begin (uiout, nbrofcols, tblid)
- struct ui_out *uiout;
- int nbrofcols;
- char *tblid;
+ui_out_table_begin (struct ui_out *uiout, int nbrofcols, char *tblid)
{
if (uiout->table_flag)
internal_error ("gdb/ui_out.c: tables cannot be nested; table_begin found before \
}
void
-ui_out_table_body (uiout)
- struct ui_out *uiout;
+ui_out_table_body (struct ui_out *uiout)
{
if (!uiout->table_flag)
internal_error ("gdb/ui_out.c: table_body outside a table is not valid; it must be \
}
void
-ui_out_table_end (uiout)
- struct ui_out *uiout;
+ui_out_table_end (struct ui_out *uiout)
{
if (!uiout->table_flag)
internal_error ("gdb/ui_out.c: misplaced table_end or missing table_begin.");
}
void
-ui_out_table_header (uiout, width, alignment, colhdr)
- struct ui_out *uiout;
- int width;
- enum ui_align alignment;
- char *colhdr;
+ui_out_table_header (struct ui_out *uiout, int width, enum ui_align alignment,
+ char *colhdr)
{
if (!uiout->table_flag || uiout->body_flag)
internal_error ("ui_out: table header must be specified after table_begin \
}
void
-ui_out_list_begin (uiout, lstid)
- struct ui_out *uiout;
- char *lstid;
+ui_out_list_begin (struct ui_out *uiout, char *lstid)
{
if (uiout->table_flag && !uiout->body_flag)
internal_error ("ui_out: table header or table_body expected; lists must be \
}
void
-ui_out_list_end (uiout)
- struct ui_out *uiout;
+ui_out_list_end (struct ui_out *uiout)
{
if (!uiout->list_flag)
internal_error ("ui_out: misplaced list_end; there is no list to be closed.");
}
void
-ui_out_field_int (uiout, fldname, value)
- struct ui_out *uiout;
- char *fldname;
- int value;
+ui_out_field_int (struct ui_out *uiout, char *fldname, int value)
{
int fldno;
int width;
}
void
-ui_out_field_core_addr (uiout, fldname, address)
- struct ui_out *uiout;
- char *fldname;
- CORE_ADDR address;
+ui_out_field_core_addr (struct ui_out *uiout, char *fldname, CORE_ADDR address)
{
char addstr[20];
}
void
-ui_out_field_stream (uiout, fldname, buf)
- struct ui_out *uiout;
- char *fldname;
- struct ui_stream *buf;
+ui_out_field_stream (struct ui_out *uiout, char *fldname, struct ui_stream *buf)
{
long length;
char *buffer = ui_file_xstrdup (buf->stream, &length);
/* used to ommit a field */
void
-ui_out_field_skip (uiout, fldname)
- struct ui_out *uiout;
- char *fldname;
+ui_out_field_skip (struct ui_out *uiout, char *fldname)
{
int fldno;
int width;
}
void
-ui_out_spaces (uiout, numspaces)
- struct ui_out *uiout;
- int numspaces;
+ui_out_spaces (struct ui_out *uiout, int numspaces)
{
uo_spaces (uiout, numspaces);
}
void
-ui_out_text (uiout, string)
- struct ui_out *uiout;
- char *string;
+ui_out_text (struct ui_out *uiout, char *string)
{
uo_text (uiout, string);
}
}
struct ui_stream *
-ui_out_stream_new (uiout)
- struct ui_out *uiout;
+ui_out_stream_new (struct ui_out *uiout)
{
struct ui_stream *tempbuf;
}
void
-ui_out_stream_delete (buf)
- struct ui_stream *buf;
+ui_out_stream_delete (struct ui_stream *buf)
{
ui_file_delete (buf->stream);
free (buf);
void
-ui_out_wrap_hint (uiout, identstring)
- struct ui_out *uiout;
- char *identstring;
+ui_out_wrap_hint (struct ui_out *uiout, char *identstring)
{
uo_wrap_hint (uiout, identstring);
}
void
-ui_out_flush (uiout)
- struct ui_out *uiout;
+ui_out_flush (struct ui_out *uiout)
{
uo_flush (uiout);
}
/* set the flags specified by the mask given */
int
-ui_out_set_flags (uiout, mask)
- struct ui_out *uiout;
- int mask;
+ui_out_set_flags (struct ui_out *uiout, int mask)
{
int oldflags = uiout->flags;
/* clear the flags specified by the mask given */
int
-ui_out_clear_flags (uiout, mask)
- struct ui_out *uiout;
- int mask;
+ui_out_clear_flags (struct ui_out *uiout, int mask)
{
int oldflags = uiout->flags;
/* test the flags against the mask given */
int
-ui_out_test_flags (uiout, mask)
- struct ui_out *uiout;
- int mask;
+ui_out_test_flags (struct ui_out *uiout, int mask)
{
return (uiout->flags & mask);
}
'set verbositylevel' command */
int
-ui_out_get_verblvl (uiout)
- struct ui_out *uiout;
+ui_out_get_verblvl (struct ui_out *uiout)
{
/* FIXME: not implemented yet */
return 0;
#if 0
void
-ui_out_result_begin (uiout, class)
- struct ui_out *uiout;
- char *class;
+ui_out_result_begin (struct ui_out *uiout, char *class)
{
}
void
-ui_out_result_end (uiout)
- struct ui_out *uiout;
+ui_out_result_end (struct ui_out *uiout)
{
}
void
-ui_out_info_begin (uiout, class)
- struct ui_out *uiout;
- char *class;
+ui_out_info_begin (struct ui_out *uiout, char *class)
{
}
void
-ui_out_info_end (uiout)
- struct ui_out *uiout;
+ui_out_info_end (struct ui_out *uiout)
{
}
void
-ui_out_notify_begin (uiout, class)
- struct ui_out *uiout;
- char *class;
+ui_out_notify_begin (struct ui_out *uiout, char *class)
{
}
void
-ui_out_notify_end (uiout)
- struct ui_out *uiout;
+ui_out_notify_end (struct ui_out *uiout)
{
}
void
-ui_out_error_begin (uiout, class)
- struct ui_out *uiout;
- char *class;
+ui_out_error_begin (struct ui_out *uiout, char *class)
{
}
void
-ui_out_error_end (uiout)
- struct ui_out *uiout;
+ui_out_error_end (struct ui_out *uiout)
{
}
#endif
/* default gdb-out hook functions */
static void
-default_table_begin (uiout, nbrofcols, tblid)
- struct ui_out *uiout;
- int nbrofcols;
- char *tblid;
+default_table_begin (struct ui_out *uiout, int nbrofcols, char *tblid)
{
}
static void
-default_table_body (uiout)
- struct ui_out *uiout;
+default_table_body (struct ui_out *uiout)
{
}
static void
-default_table_end (uiout)
- struct ui_out *uiout;
+default_table_end (struct ui_out *uiout)
{
}
static void
-default_table_header (uiout, width, alignment, colhdr)
- struct ui_out *uiout;
- int width;
- enum ui_align alignment;
- char *colhdr;
+default_table_header (struct ui_out *uiout, int width, enum ui_align alignment,
+ char *colhdr)
{
}
static void
-default_list_begin (uiout, list_flag, lstid)
- struct ui_out *uiout;
- int list_flag;
- char *lstid;
+default_list_begin (struct ui_out *uiout, int list_flag, char *lstid)
{
}
static void
-default_list_end (uiout, list_flag)
- struct ui_out *uiout;
- int list_flag;
+default_list_end (struct ui_out *uiout, int list_flag)
{
}
static void
-default_field_int (uiout, fldno, width, align, fldname, value)
- struct ui_out *uiout;
- int fldno;
- int width;
- enum ui_align align;
- char *fldname;
- int value;
+default_field_int (struct ui_out *uiout, int fldno, int width,
+ enum ui_align align, char *fldname, int value)
{
}
static void
-default_field_skip (uiout, fldno, width, align, fldname)
- struct ui_out *uiout;
- int fldno;
- int width;
- enum ui_align align;
- char *fldname;
+default_field_skip (struct ui_out *uiout, int fldno, int width,
+ enum ui_align align, char *fldname)
{
}
}
static void
-default_field_fmt (uiout, fldno, width, align, fldname, format, args)
- struct ui_out *uiout;
- int fldno;
- int width;
- enum ui_align align;
- char *fldname;
- char *format;
- va_list args;
+default_field_fmt (struct ui_out *uiout, int fldno, int width,
+ enum ui_align align, char *fldname, char *format,
+ va_list args)
{
}
static void
-default_spaces (uiout, numspaces)
- struct ui_out *uiout;
- int numspaces;
+default_spaces (struct ui_out *uiout, int numspaces)
{
}
static void
-default_text (uiout, string)
- struct ui_out *uiout;
- char *string;
+default_text (struct ui_out *uiout, char *string)
{
}
static void
-default_message (uiout, verbosity, format, args)
- struct ui_out *uiout;
- int verbosity;
- char *format;
- va_list args;
+default_message (struct ui_out *uiout, int verbosity, char *format,
+ va_list args)
{
}
static void
-default_wrap_hint (uiout, identstring)
- struct ui_out *uiout;
- char *identstring;
+default_wrap_hint (struct ui_out *uiout, char *identstring)
{
}
static void
-default_flush (uiout)
- struct ui_out *uiout;
+default_flush (struct ui_out *uiout)
{
}
/* list of column headers manipulation routines */
static void
-clear_header_list (uiout)
- struct ui_out *uiout;
+clear_header_list (struct ui_out *uiout)
{
while (uiout->headerfirst != NULL)
{
/* access to ui_out format private members */
void
-ui_out_get_field_separator (uiout)
- struct ui_out *uiout;
+ui_out_get_field_separator (struct ui_out *uiout)
{
}
/* standard gdb initialization hook */
void
-_initialize_ui_out ()
+_initialize_ui_out (void)
{
/* nothing needs to be done */
}
*/
void
-fetch_inferior_registers (regno)
- int regno;
+fetch_inferior_registers (int regno)
{
register int i, j, ret_val = 0;
char buf[128];
*/
void
-store_inferior_registers (regno)
- int regno;
+store_inferior_registers (int regno)
{
register unsigned int regaddr;
char buf[80];
* NOTE: Assumes AMD's Binary Compatibility Standard for ptrace().
*/
static void
-fetch_register (regno)
- int regno;
+fetch_register (int regno)
{
char buf[128];
int val;
* will cause ptrace() to fail is returned.
*/
CORE_ADDR
-register_addr (regno, blockend)
- int regno;
- CORE_ADDR blockend;
+register_addr (int regno, CORE_ADDR blockend)
{
if ((regno >= LR0_REGNUM) && (regno < LR0_REGNUM + 128))
{
};
void
-_initialize_core_ultra3 ()
+_initialize_core_ultra3 (void)
{
add_core_fns (&ultra3_core_fns);
}
/* FIXME: Kludge this for now. It really should be system call. */
int
-getpagesize ()
+getpagesize (void)
{
return (8192);
}
/* FIXME: Fake out the fcntl() call, which we don't have. */
-fcntl (fd, cmd, arg)
- int fd, cmd, arg;
+fcntl (int fd, int cmd, int arg)
{
switch (cmd)
static int _SigMask;
#define sigbit(s) (1L << ((s)-1))
-init_SigMask ()
+init_SigMask (void)
{
/* Taken from the sym1 kernel in machdep.c:startup() */
_SigMask = sigbit (SIGTSTP) | sigbit (SIGTTOU) | sigbit (SIGTTIN) |
sigbit (SIGCHLD) | sigbit (SIGTINT);
}
-sigmask (signo)
- int signo;
+sigmask (int signo)
{
return (1 << (signo - 1));
}
-sigsetmask (sigmask)
- unsigned int sigmask;
+sigsetmask (unsigned int sigmask)
{
int i, mask = 1;
int lastmask = _SigMask;
return (lastmask);
}
-sigblock (sigmask)
- unsigned int sigmask;
+sigblock (unsigned int sigmask)
{
int i, mask = 1;
int lastmask = _SigMask;
/* Initialization code for this module. */
void
-_initialize_ultra3 ()
+_initialize_ultra3 (void)
{
#ifdef SYM1
init_SigMask ();
This code would be in corefile.c if it weren't machine-dependent. */
void
-core_file_command (filename, from_tty)
- char *filename;
- int from_tty;
+core_file_command (char *filename, int from_tty)
{
int val;
}
static void
-do_freeargv (arg)
- void *arg;
+do_freeargv (void *arg)
{
freeargv ((char **) arg);
}
struct cleanup *
-make_cleanup_freeargv (arg)
- char **arg;
+make_cleanup_freeargv (char **arg)
{
return make_my_cleanup (&cleanup_chain, do_freeargv, arg);
}
until we get back to the point OLD_CHAIN in the cleanup_chain. */
void
-do_cleanups (old_chain)
- register struct cleanup *old_chain;
+do_cleanups (register struct cleanup *old_chain)
{
do_my_cleanups (&cleanup_chain, old_chain);
}
void
-do_final_cleanups (old_chain)
- register struct cleanup *old_chain;
+do_final_cleanups (register struct cleanup *old_chain)
{
do_my_cleanups (&final_cleanup_chain, old_chain);
}
void
-do_run_cleanups (old_chain)
- register struct cleanup *old_chain;
+do_run_cleanups (register struct cleanup *old_chain)
{
do_my_cleanups (&run_cleanup_chain, old_chain);
}
void
-do_exec_cleanups (old_chain)
- register struct cleanup *old_chain;
+do_exec_cleanups (register struct cleanup *old_chain)
{
do_my_cleanups (&exec_cleanup_chain, old_chain);
}
void
-do_exec_error_cleanups (old_chain)
- register struct cleanup *old_chain;
+do_exec_error_cleanups (register struct cleanup *old_chain)
{
do_my_cleanups (&exec_error_cleanup_chain, old_chain);
}
void
-do_my_cleanups (pmy_chain, old_chain)
- register struct cleanup **pmy_chain;
- register struct cleanup *old_chain;
+do_my_cleanups (register struct cleanup **pmy_chain,
+ register struct cleanup *old_chain)
{
register struct cleanup *ptr;
while ((ptr = *pmy_chain) != old_chain)
until we get back to the point OLD_CHAIN in the cleanup_chain. */
void
-discard_cleanups (old_chain)
- register struct cleanup *old_chain;
+discard_cleanups (register struct cleanup *old_chain)
{
discard_my_cleanups (&cleanup_chain, old_chain);
}
void
-discard_final_cleanups (old_chain)
- register struct cleanup *old_chain;
+discard_final_cleanups (register struct cleanup *old_chain)
{
discard_my_cleanups (&final_cleanup_chain, old_chain);
}
void
-discard_exec_error_cleanups (old_chain)
- register struct cleanup *old_chain;
+discard_exec_error_cleanups (register struct cleanup *old_chain)
{
discard_my_cleanups (&exec_error_cleanup_chain, old_chain);
}
void
-discard_my_cleanups (pmy_chain, old_chain)
- register struct cleanup **pmy_chain;
- register struct cleanup *old_chain;
+discard_my_cleanups (register struct cleanup **pmy_chain,
+ register struct cleanup *old_chain)
{
register struct cleanup *ptr;
while ((ptr = *pmy_chain) != old_chain)
/* Set the cleanup_chain to 0, and return the old cleanup chain. */
struct cleanup *
-save_cleanups ()
+save_cleanups (void)
{
return save_my_cleanups (&cleanup_chain);
}
struct cleanup *
-save_final_cleanups ()
+save_final_cleanups (void)
{
return save_my_cleanups (&final_cleanup_chain);
}
struct cleanup *
-save_my_cleanups (pmy_chain)
- struct cleanup **pmy_chain;
+save_my_cleanups (struct cleanup **pmy_chain)
{
struct cleanup *old_chain = *pmy_chain;
/* Restore the cleanup chain from a previously saved chain. */
void
-restore_cleanups (chain)
- struct cleanup *chain;
+restore_cleanups (struct cleanup *chain)
{
restore_my_cleanups (&cleanup_chain, chain);
}
void
-restore_final_cleanups (chain)
- struct cleanup *chain;
+restore_final_cleanups (struct cleanup *chain)
{
restore_my_cleanups (&final_cleanup_chain, chain);
}
void
-restore_my_cleanups (pmy_chain, chain)
- struct cleanup **pmy_chain;
- struct cleanup *chain;
+restore_my_cleanups (struct cleanup **pmy_chain, struct cleanup *chain)
{
*pmy_chain = chain;
}
and do the continuations from there on, instead of using the
global beginning of list as our iteration pointer.*/
void
-do_all_continuations ()
+do_all_continuations (void)
{
struct continuation *continuation_ptr;
struct continuation *saved_continuation;
/* Walk down the cmd_continuation list, and get rid of all the
continuations. */
void
-discard_all_continuations ()
+discard_all_continuations (void)
{
struct continuation *continuation_ptr;
and do the continuations from there on, instead of using the
global beginning of list as our iteration pointer.*/
void
-do_all_intermediate_continuations ()
+do_all_intermediate_continuations (void)
{
struct continuation *continuation_ptr;
struct continuation *saved_continuation;
/* Walk down the cmd_continuation list, and get rid of all the
continuations. */
void
-discard_all_intermediate_continuations ()
+discard_all_intermediate_continuations (void)
{
struct continuation *continuation_ptr;
Is this anything other than a historical accident? */
void
-warning_begin ()
+warning_begin (void)
{
target_terminal_ours ();
wrap_here (""); /* Force out any buffered output */
that the error message can be formatted with a single printf call,
but this is more general. */
void
-error_begin ()
+error_begin (void)
{
if (error_begin_hook)
error_begin_hook ();
printable string. */
char *
-safe_strerror (errnum)
- int errnum;
+safe_strerror (int errnum)
{
char *msg;
static char buf[32];
Then return to command level. */
NORETURN void
-perror_with_name (string)
- char *string;
+perror_with_name (char *string)
{
char *err;
char *combined;
as the file name for which the error was encountered. */
void
-print_sys_errmsg (string, errcode)
- char *string;
- int errcode;
+print_sys_errmsg (char *string, int errcode)
{
char *err;
char *combined;
/* Control C eventually causes this to be called, at a convenient time. */
void
-quit ()
+quit (void)
{
serial_t gdb_stdout_serial = serial_fdopen (1);
*/
void
-notice_quit ()
+notice_quit (void)
{
int k = win32pollquit ();
if (k == 1)
#else /* !defined(_MSC_VER) */
void
-notice_quit ()
+notice_quit (void)
{
/* Done by signals */
}
/* Control C comes here */
void
-request_quit (signo)
- int signo;
+request_quit (int signo)
{
quit_flag = 1;
/* Restore the signal handler. Harmless with BSD-style signals, needed
}
PTR
-mmalloc (md, size)
- PTR md;
- size_t size;
+mmalloc (PTR md, size_t size)
{
return malloc (size);
}
PTR
-mrealloc (md, ptr, size)
- PTR md;
- PTR ptr;
- size_t size;
+mrealloc (PTR md, PTR ptr, size_t size)
{
if (ptr == 0) /* Guard against old realloc's */
return malloc (size);
}
void
-mfree (md, ptr)
- PTR md;
- PTR ptr;
+mfree (PTR md, PTR ptr)
{
free (ptr);
}
#else /* Have mmalloc and want corruption checking */
static void
-malloc_botch ()
+malloc_botch (void)
{
fprintf_unfiltered (gdb_stderr, "Memory corruption\n");
abort ();
memory requested in SIZE. */
NORETURN void
-nomem (size)
- long size;
+nomem (long size)
{
if (size > 0)
{
byte of zero'd storage, is a religious issue. */
PTR
-xmmalloc (md, size)
- PTR md;
- long size;
+xmmalloc (PTR md, long size)
{
register PTR val;
/* Like mrealloc but get error if no storage available. */
PTR
-xmrealloc (md, ptr, size)
- PTR md;
- PTR ptr;
- long size;
+xmrealloc (PTR md, PTR ptr, long size)
{
register PTR val;
the caller wanting to allocate zero bytes. */
PTR
-xmalloc (size)
- size_t size;
+xmalloc (size_t size)
{
return (xmmalloc ((PTR) NULL, size));
}
/* Like mrealloc but get error if no storage available. */
PTR
-xrealloc (ptr, size)
- PTR ptr;
- size_t size;
+xrealloc (PTR ptr, size_t size)
{
return (xmrealloc ((PTR) NULL, ptr, size));
}
Used like `read' but keeps going if `read' returns too soon. */
int
-myread (desc, addr, len)
- int desc;
- char *addr;
- int len;
+myread (int desc, char *addr, int len)
{
register int val;
int orglen = len;
Uses malloc to get the space. Returns the address of the copy. */
char *
-savestring (ptr, size)
- const char *ptr;
- int size;
+savestring (const char *ptr, int size)
{
register char *p = (char *) xmalloc (size + 1);
memcpy (p, ptr, size);
in <string.h>. FIXME: This should be named "xstrsave", shouldn't it?
Doesn't real strsave return NULL if out of memory? */
char *
-strsave (ptr)
- const char *ptr;
+strsave (const char *ptr)
{
return savestring (ptr, strlen (ptr));
}
}
void
-print_spaces (n, file)
- register int n;
- register struct ui_file *file;
+print_spaces (register int n, register struct ui_file *file)
{
fputs_unfiltered (n_spaces (n), file);
}
after the zeros. A value of 0 does not mean end of string. */
int
-parse_escape (string_ptr)
- char **string_ptr;
+parse_escape (char **string_ptr)
{
register int c = *(*string_ptr)++;
switch (c)
the language of the program being debugged. */
void
-fputstr_filtered (str, quoter, stream)
- const char *str;
- int quoter;
- struct ui_file *stream;
+fputstr_filtered (const char *str, int quoter, struct ui_file *stream)
{
while (*str)
printchar (*str++, fputs_filtered, fprintf_filtered, stream, quoter);
}
void
-fputstr_unfiltered (str, quoter, stream)
- const char *str;
- int quoter;
- struct ui_file *stream;
+fputstr_unfiltered (const char *str, int quoter, struct ui_file *stream)
{
while (*str)
printchar (*str++, fputs_unfiltered, fprintf_unfiltered, stream, quoter);
}
void
-fputstrn_unfiltered (str, n, quoter, stream)
- const char *str;
- int n;
- int quoter;
- struct ui_file *stream;
+fputstrn_unfiltered (const char *str, int n, int quoter, struct ui_file *stream)
{
int i;
for (i = 0; i < n; i++)
/* Inialize the lines and chars per page */
void
-init_page_info ()
+init_page_info (void)
{
#if defined(TUI)
if (tui_version && m_winPtrNotNull (cmdWin))
}
static void
-set_width ()
+set_width (void)
{
if (chars_per_line == 0)
init_page_info ();
/* ARGSUSED */
static void
-set_width_command (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_width_command (char *args, int from_tty, struct cmd_list_element *c)
{
set_width ();
}
to continue by pressing RETURN. */
static void
-prompt_for_continue ()
+prompt_for_continue (void)
{
char *ignore;
char cont_prompt[120];
/* Reinitialize filter; ie. tell it to reset to original values. */
void
-reinitialize_more_filter ()
+reinitialize_more_filter (void)
{
lines_printed = 0;
chars_printed = 0;
used to force out output from the wrap_buffer. */
void
-wrap_here (indent)
- char *indent;
+wrap_here (char *indent)
{
/* This should have been allocated, but be paranoid anyway. */
if (!wrap_buffer)
line. Otherwise do nothing. */
void
-begin_line ()
+begin_line (void)
{
if (chars_printed > 0)
{
routine should not be called when cleanups are not in place. */
static void
-fputs_maybe_filtered (linebuffer, stream, filter)
- const char *linebuffer;
- struct ui_file *stream;
- int filter;
+fputs_maybe_filtered (const char *linebuffer, struct ui_file *stream,
+ int filter)
{
const char *lineptr;
}
void
-fputs_filtered (linebuffer, stream)
- const char *linebuffer;
- struct ui_file *stream;
+fputs_filtered (const char *linebuffer, struct ui_file *stream)
{
fputs_maybe_filtered (linebuffer, stream, 1);
}
int
-putchar_unfiltered (c)
- int c;
+putchar_unfiltered (int c)
{
char buf = c;
ui_file_write (gdb_stdout, &buf, 1);
}
int
-fputc_unfiltered (c, stream)
- int c;
- struct ui_file *stream;
+fputc_unfiltered (int c, struct ui_file *stream)
{
char buf = c;
ui_file_write (stream, &buf, 1);
}
int
-fputc_filtered (c, stream)
- int c;
- struct ui_file *stream;
+fputc_filtered (int c, struct ui_file *stream)
{
char buf[2];
characters in printable fashion. */
void
-puts_debug (prefix, string, suffix)
- char *prefix;
- char *string;
- char *suffix;
+puts_debug (char *prefix, char *string, char *suffix)
{
int ch;
called when cleanups are not in place. */
static void
-vfprintf_maybe_filtered (stream, format, args, filter)
- struct ui_file *stream;
- const char *format;
- va_list args;
- int filter;
+vfprintf_maybe_filtered (struct ui_file *stream, const char *format,
+ va_list args, int filter)
{
char *linebuffer;
struct cleanup *old_cleanups;
void
-vfprintf_filtered (stream, format, args)
- struct ui_file *stream;
- const char *format;
- va_list args;
+vfprintf_filtered (struct ui_file *stream, const char *format, va_list args)
{
vfprintf_maybe_filtered (stream, format, args, 1);
}
void
-vfprintf_unfiltered (stream, format, args)
- struct ui_file *stream;
- const char *format;
- va_list args;
+vfprintf_unfiltered (struct ui_file *stream, const char *format, va_list args)
{
char *linebuffer;
struct cleanup *old_cleanups;
}
void
-vprintf_filtered (format, args)
- const char *format;
- va_list args;
+vprintf_filtered (const char *format, va_list args)
{
vfprintf_maybe_filtered (gdb_stdout, format, args, 1);
}
void
-vprintf_unfiltered (format, args)
- const char *format;
- va_list args;
+vprintf_unfiltered (const char *format, va_list args)
{
vfprintf_unfiltered (gdb_stdout, format, args);
}
This one doesn't, and had better not! */
void
-puts_filtered (string)
- const char *string;
+puts_filtered (const char *string)
{
fputs_filtered (string, gdb_stdout);
}
void
-puts_unfiltered (string)
- const char *string;
+puts_unfiltered (const char *string)
{
fputs_unfiltered (string, gdb_stdout);
}
/* Return a pointer to N spaces and a null. The pointer is good
until the next call to here. */
char *
-n_spaces (n)
- int n;
+n_spaces (int n)
{
char *t;
static char *spaces = 0;
/* Print N spaces. */
void
-print_spaces_filtered (n, stream)
- int n;
- struct ui_file *stream;
+print_spaces_filtered (int n, struct ui_file *stream)
{
fputs_filtered (n_spaces (n), stream);
}
demangling is off, the name is printed in its "raw" form. */
void
-fprintf_symbol_filtered (stream, name, lang, arg_mode)
- struct ui_file *stream;
- char *name;
- enum language lang;
- int arg_mode;
+fprintf_symbol_filtered (struct ui_file *stream, char *name, enum language lang,
+ int arg_mode)
{
char *demangled;
function). */
int
-strcmp_iw (string1, string2)
- const char *string1;
- const char *string2;
+strcmp_iw (const char *string1, const char *string2)
{
while ((*string1 != '\0') && (*string2 != '\0'))
{
** at index 0.
*/
int
-subset_compare (string_to_compare, template_string)
- char *string_to_compare;
- char *template_string;
+subset_compare (char *string_to_compare, char *template_string)
{
int match;
if (template_string != (char *) NULL && string_to_compare != (char *) NULL &&
static void pagination_on_command (char *arg, int from_tty);
static void
-pagination_on_command (arg, from_tty)
- char *arg;
- int from_tty;
+pagination_on_command (char *arg, int from_tty)
{
pagination_enabled = 1;
}
static void pagination_on_command (char *arg, int from_tty);
static void
-pagination_off_command (arg, from_tty)
- char *arg;
- int from_tty;
+pagination_off_command (char *arg, int from_tty)
{
pagination_enabled = 0;
}
\f
void
-initialize_utils ()
+initialize_utils (void)
{
struct cmd_list_element *c;
/* Extract a field which starts at START and is LEN bytes long. DATA and
TOTAL_LEN are the thing we are extracting it from, in byteorder ORDER. */
static unsigned long
-get_field (data, order, total_len, start, len)
- unsigned char *data;
- enum floatformat_byteorders order;
- unsigned int total_len;
- unsigned int start;
- unsigned int len;
+get_field (unsigned char *data, enum floatformat_byteorders order,
+ unsigned int total_len, unsigned int start, unsigned int len)
{
unsigned long result;
unsigned int cur_byte;
Store the DOUBLEST in *TO. */
void
-floatformat_to_doublest (fmt, from, to)
- const struct floatformat *fmt;
- char *from;
- DOUBLEST *to;
+floatformat_to_doublest (const struct floatformat *fmt, char *from,
+ DOUBLEST *to)
{
unsigned char *ufrom = (unsigned char *) from;
DOUBLEST dto;
/* Set a field which starts at START and is LEN bytes long. DATA and
TOTAL_LEN are the thing we are extracting it from, in byteorder ORDER. */
static void
-put_field (data, order, total_len, start, len, stuff_to_put)
- unsigned char *data;
- enum floatformat_byteorders order;
- unsigned int total_len;
- unsigned int start;
- unsigned int len;
- unsigned long stuff_to_put;
+put_field (unsigned char *data, enum floatformat_byteorders order,
+ unsigned int total_len, unsigned int start, unsigned int len,
+ unsigned long stuff_to_put)
{
unsigned int cur_byte;
int cur_bitshift;
static long double ldfrexp (long double value, int *eptr);
static long double
-ldfrexp (value, eptr)
- long double value;
- int *eptr;
+ldfrexp (long double value, int *eptr)
{
long double tmp;
int exp;
restrictions. */
void
-floatformat_from_doublest (fmt, from, to)
- CONST struct floatformat *fmt;
- DOUBLEST *from;
- char *to;
+floatformat_from_doublest (CONST struct floatformat *fmt, DOUBLEST *from,
+ char *to)
{
DOUBLEST dfrom;
int exponent;
#define NUMCELLS 16
#define CELLSIZE 32
static char *
-get_cell ()
+get_cell (void)
{
static char buf[NUMCELLS][CELLSIZE];
static int cell = 0;
/* Should call_function allocate stack space for a struct return? */
int
-v850_use_struct_convention (gcc_p, type)
- int gcc_p;
- struct type *type;
+v850_use_struct_convention (int gcc_p, struct type *type)
{
return (TYPE_NFIELDS (type) > 1 || TYPE_LENGTH (type) > 4);
}
be determined till after we have scanned the prologue. */
static CORE_ADDR
-v850_scan_prologue (pc, pi)
- CORE_ADDR pc;
- struct prologue_info *pi;
+v850_scan_prologue (CORE_ADDR pc, struct prologue_info *pi)
{
CORE_ADDR func_addr, prologue_end, current_pc;
struct pifsr *pifsr, *pifsr_tmp;
pointer just prior to calling the target function (see run_stack_dummy). */
void
-v850_init_extra_frame_info (fi)
- struct frame_info *fi;
+v850_init_extra_frame_info (struct frame_info *fi)
{
struct prologue_info pi;
struct pifsr pifsrs[NUM_REGS + 1], *pifsr;
function call was made. */
CORE_ADDR
-v850_frame_chain (fi)
- struct frame_info *fi;
+v850_frame_chain (struct frame_info *fi)
{
struct prologue_info pi;
CORE_ADDR callers_pc, fp;
frame. */
CORE_ADDR
-v850_find_callers_reg (fi, regnum)
- struct frame_info *fi;
- int regnum;
+v850_find_callers_reg (struct frame_info *fi, int regnum)
{
for (; fi; fi = fi->next)
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
Return the address of the first code past the prologue of the function. */
CORE_ADDR
-v850_skip_prologue (pc)
- CORE_ADDR pc;
+v850_skip_prologue (CORE_ADDR pc)
{
CORE_ADDR func_addr, func_end;
command, or the call dummy breakpoint gets hit. */
void
-v850_pop_frame (frame)
- struct frame_info *frame;
+v850_pop_frame (struct frame_info *frame)
{
int regnum;
*/
CORE_ADDR
-v850_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- unsigned char struct_return;
- CORE_ADDR struct_addr;
+v850_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ unsigned char struct_return, CORE_ADDR struct_addr)
{
int argreg;
int argnum;
Needed for targets where we don't actually execute a JSR/BSR instruction */
CORE_ADDR
-v850_push_return_address (pc, sp)
- CORE_ADDR pc;
- CORE_ADDR sp;
+v850_push_return_address (CORE_ADDR pc, CORE_ADDR sp)
{
write_register (RP_REGNUM, CALL_DUMMY_ADDRESS ());
return sp;
will be found. */
CORE_ADDR
-v850_frame_saved_pc (fi)
- struct frame_info *fi;
+v850_frame_saved_pc (struct frame_info *fi)
{
if (PC_IN_CALL_DUMMY (fi->pc, fi->frame, fi->frame))
return generic_read_register_dummy (fi->pc, fi->frame, PC_REGNUM);
*/
int
-v850_fix_call_dummy (dummy, sp, fun, nargs, args, type, gcc_p)
- char *dummy;
- CORE_ADDR sp;
- CORE_ADDR fun;
- int nargs;
- value_ptr *args;
- struct type *type;
- int gcc_p;
+v850_fix_call_dummy (char *dummy, CORE_ADDR sp, CORE_ADDR fun, int nargs,
+ value_ptr *args, struct type *type, int gcc_p)
{
long offset24;
/* Change the register names based on the current machine type. */
static int
-v850_target_architecture_hook (ap)
- const bfd_arch_info_type *ap;
+v850_target_architecture_hook (const bfd_arch_info_type *ap)
{
int i, j;
}
void
-_initialize_v850_tdep ()
+_initialize_v850_tdep (void)
{
tm_print_insn = print_insn_v850;
target_architecture_hook = v850_target_architecture_hook;
/* This function creates a hidden window */
static int
-init_hidden_window ()
+init_hidden_window (void)
{
WNDCLASS class;
WM_STATE_CHANGE - tells us that a state change has occured in the ICE
*/
static LRESULT CALLBACK
-v850ice_wndproc (hwnd, message, wParam, lParam)
- HWND hwnd;
- UINT message;
- WPARAM wParam;
- LPARAM lParam;
+v850ice_wndproc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
{
LRESULT result = FALSE;
/* Code for opening a connection to the ICE. */
static void
-v850ice_open (name, from_tty)
- char *name;
- int from_tty;
+v850ice_open (char *name, int from_tty)
{
HINSTANCE handle;
/* ARGSUSED */
static void
-v850ice_close (quitting)
- int quitting;
+v850ice_close (int quitting)
{
if (ice_open)
{
/* Stop the process on the ice. */
static void
-v850ice_stop ()
+v850ice_stop (void)
{
/* This is silly, but it works... */
v850ice_command ("stop", 0);
}
static void
-v850ice_detach (args, from_tty)
- char *args;
- int from_tty;
+v850ice_detach (char *args, int from_tty)
{
if (args)
error ("Argument given to \"detach\" when remotely debugging.");
/* Tell the remote machine to resume. */
static void
-v850ice_resume (pid, step, siggnal)
- int pid, step;
- enum target_signal siggnal;
+v850ice_resume (int pid, int step, enum target_signal siggnal)
{
long retval;
char buf[256];
means in the case of this target). */
static int
-v850ice_wait (pid, status)
- int pid;
- struct target_waitstatus *status;
+v850ice_wait (int pid, struct target_waitstatus *status)
{
long v850_status;
char buf[256];
}
static int
-convert_register (regno, buf)
- int regno;
- char *buf;
+convert_register (int regno, char *buf)
{
if (regno <= 31)
sprintf (buf, "r%d", regno);
convert it to target byte-order if necessary. */
static void
-v850ice_fetch_registers (regno)
- int regno;
+v850ice_fetch_registers (int regno)
{
long retval;
char cmd[100];
of REGISTERS. */
static void
-v850ice_store_registers (regno)
- int regno;
+v850ice_store_registers (int regno)
{
long retval;
char cmd[100];
register at a time. */
static void
-v850ice_prepare_to_store ()
+v850ice_prepare_to_store (void)
{
}
}
static void
-v850ice_files_info (ignore)
- struct target_ops *ignore;
+v850ice_files_info (struct target_ops *ignore)
{
puts_filtered ("Debugging a target via the NEC V850 ICE.\n");
}
static int
-v850ice_insert_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+v850ice_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
{
long retval;
char cmd[100];
}
static int
-v850ice_remove_breakpoint (addr, contents_cache)
- CORE_ADDR addr;
- char *contents_cache;
+v850ice_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
{
long retval;
char cmd[100];
}
static void
-v850ice_kill ()
+v850ice_kill (void)
{
target_mourn_inferior ();
inferior_pid = 0;
}
static void
-v850ice_mourn ()
+v850ice_mourn (void)
{
}
static void
-v850ice_load (filename, from_tty)
- char *filename;
- int from_tty;
+v850ice_load (char *filename, int from_tty)
{
struct MessageIO iob;
char buf[256];
}
static int
-ice_file (arg)
- char *arg;
+ice_file (char *arg)
{
char *s;
}
static int
-ice_cont (c)
- char *c;
+ice_cont (char *c)
{
printf_filtered ("continue (ice)\n");
ReplyMessage ((LRESULT) 1);
static int
-ice_stepi (c)
- char *c;
+ice_stepi (char *c)
{
int count = (int) c;
}
static int
-ice_nexti (c)
- char *c;
+ice_nexti (char *c)
{
int count = (int) c;
}
static void
-v850ice_command (arg, from_tty)
- char *arg;
- int from_tty;
+v850ice_command (char *arg, int from_tty)
{
struct MessageIO iob;
char buf[256];
}
static void
-view_source (addr)
- CORE_ADDR addr;
+view_source (CORE_ADDR addr)
{
char c[256];
}
void
-_initialize_v850ice ()
+_initialize_v850ice (void)
{
init_850ice_ops ();
add_target (&v850ice_ops);
\f
value_ptr
-value_add (arg1, arg2)
- value_ptr arg1, arg2;
+value_add (value_ptr arg1, value_ptr arg2)
{
register value_ptr valint, valptr;
register int len;
}
value_ptr
-value_sub (arg1, arg2)
- value_ptr arg1, arg2;
+value_sub (value_ptr arg1, value_ptr arg2)
{
struct type *type1, *type2;
COERCE_NUMBER (arg1);
verbosity is set, warn about invalid indices (but still use them). */
value_ptr
-value_subscript (array, idx)
- value_ptr array, idx;
+value_subscript (value_ptr array, value_ptr idx)
{
value_ptr bound;
int c_style = current_language->c_style_arrays;
to doubles, but no longer does. */
static value_ptr
-value_subscripted_rvalue (array, idx, lowerbound)
- value_ptr array, idx;
- int lowerbound;
+value_subscripted_rvalue (value_ptr array, value_ptr idx, int lowerbound)
{
struct type *array_type = check_typedef (VALUE_TYPE (array));
struct type *elt_type = check_typedef (TYPE_TARGET_TYPE (array_type));
For now, we do not overload the `=' operator. */
int
-binop_user_defined_p (op, arg1, arg2)
- enum exp_opcode op;
- value_ptr arg1, arg2;
+binop_user_defined_p (enum exp_opcode op, value_ptr arg1, value_ptr arg2)
{
struct type *type1, *type2;
if (op == BINOP_ASSIGN || op == BINOP_CONCAT)
For now, we do not overload the `&' operator. */
int
-unop_user_defined_p (op, arg1)
- enum exp_opcode op;
- value_ptr arg1;
+unop_user_defined_p (enum exp_opcode op, value_ptr arg1)
{
struct type *type1;
if (op == UNOP_ADDR)
unused. */
value_ptr
-value_x_binop (arg1, arg2, op, otherop, noside)
- value_ptr arg1, arg2;
- enum exp_opcode op, otherop;
- enum noside noside;
+value_x_binop (value_ptr arg1, value_ptr arg2, enum exp_opcode op,
+ enum exp_opcode otherop, enum noside noside)
{
value_ptr *argvec;
char *ptr;
is legal for GNU C++). */
value_ptr
-value_x_unop (arg1, op, noside)
- value_ptr arg1;
- enum exp_opcode op;
- enum noside noside;
+value_x_unop (value_ptr arg1, enum exp_opcode op, enum noside noside)
{
value_ptr *argvec;
char *ptr, *mangle_ptr;
*/
value_ptr
-value_concat (arg1, arg2)
- value_ptr arg1, arg2;
+value_concat (value_ptr arg1, value_ptr arg2)
{
register value_ptr inval1, inval2, outval = NULL;
int inval1len, inval2len;
use value_add or value_sub if you want to handle those possibilities. */
value_ptr
-value_binop (arg1, arg2, op)
- value_ptr arg1, arg2;
- enum exp_opcode op;
+value_binop (value_ptr arg1, value_ptr arg2, enum exp_opcode op)
{
register value_ptr val;
struct type *type1, *type2;
/* Simulate the C operator ! -- return 1 if ARG1 contains zero. */
int
-value_logical_not (arg1)
- value_ptr arg1;
+value_logical_not (value_ptr arg1)
{
register int len;
register char *p;
necessarily null terminated) based on their length */
static int
-value_strcmp (arg1, arg2)
- register value_ptr arg1, arg2;
+value_strcmp (register value_ptr arg1, register value_ptr arg2)
{
int len1 = TYPE_LENGTH (VALUE_TYPE (arg1));
int len2 = TYPE_LENGTH (VALUE_TYPE (arg2));
iff ARG1 and ARG2 have equal contents. */
int
-value_equal (arg1, arg2)
- register value_ptr arg1, arg2;
-
+value_equal (register value_ptr arg1, register value_ptr arg2)
{
register int len;
register char *p1, *p2;
iff ARG1's contents are less than ARG2's. */
int
-value_less (arg1, arg2)
- register value_ptr arg1, arg2;
+value_less (register value_ptr arg1, register value_ptr arg2)
{
register enum type_code code1;
register enum type_code code2;
/* The unary operators - and ~. Both free the argument ARG1. */
value_ptr
-value_neg (arg1)
- register value_ptr arg1;
+value_neg (register value_ptr arg1)
{
register struct type *type;
register struct type *result_type = VALUE_TYPE (arg1);
}
value_ptr
-value_complement (arg1)
- register value_ptr arg1;
+value_complement (register value_ptr arg1)
{
register struct type *type;
register struct type *result_type = VALUE_TYPE (arg1);
Return -1 if out of range, -2 other error. */
int
-value_bit_index (type, valaddr, index)
- struct type *type;
- char *valaddr;
- int index;
+value_bit_index (struct type *type, char *valaddr, int index)
{
LONGEST low_bound, high_bound;
LONGEST word;
}
value_ptr
-value_in (element, set)
- value_ptr element, set;
+value_in (value_ptr element, value_ptr set)
{
int member;
struct type *settype = check_typedef (VALUE_TYPE (set));
}
void
-_initialize_valarith ()
+_initialize_valarith (void)
{
}
/* Find the address of function name NAME in the inferior. */
value_ptr
-find_function_in_inferior (name)
- char *name;
+find_function_in_inferior (char *name)
{
register struct symbol *sym;
sym = lookup_symbol (name, 0, VAR_NAMESPACE, 0, NULL);
and return a value that is a pointer to the allocated space. */
value_ptr
-value_allocate_space_in_inferior (len)
- int len;
+value_allocate_space_in_inferior (int len)
{
value_ptr blocklen;
register value_ptr val = find_function_in_inferior ("malloc");
}
static CORE_ADDR
-allocate_space_in_inferior (len)
- int len;
+allocate_space_in_inferior (int len)
{
return value_as_long (value_allocate_space_in_inferior (len));
}
/* In C++, casts may change pointer or object representations. */
value_ptr
-value_cast (type, arg2)
- struct type *type;
- register value_ptr arg2;
+value_cast (struct type *type, register value_ptr arg2)
{
register enum type_code code1;
register enum type_code code2;
/* Create a value of type TYPE that is zero, and return it. */
value_ptr
-value_zero (type, lv)
- struct type *type;
- enum lval_type lv;
+value_zero (struct type *type, enum lval_type lv)
{
register value_ptr val = allocate_value (type);
adjustments before or after calling it. */
value_ptr
-value_at (type, addr, sect)
- struct type *type;
- CORE_ADDR addr;
- asection *sect;
+value_at (struct type *type, CORE_ADDR addr, asection *sect)
{
register value_ptr val;
/* Return a lazy value with type TYPE located at ADDR (cf. value_at). */
value_ptr
-value_at_lazy (type, addr, sect)
- struct type *type;
- CORE_ADDR addr;
- asection *sect;
+value_at_lazy (struct type *type, CORE_ADDR addr, asection *sect)
{
register value_ptr val;
value is ignored. */
int
-value_fetch_lazy (val)
- register value_ptr val;
+value_fetch_lazy (register value_ptr val)
{
CORE_ADDR addr = VALUE_ADDRESS (val) + VALUE_OFFSET (val);
int length = TYPE_LENGTH (VALUE_ENCLOSING_TYPE (val));
Return a new value with the location of TOVAL and contents of FROMVAL. */
value_ptr
-value_assign (toval, fromval)
- register value_ptr toval, fromval;
+value_assign (register value_ptr toval, register value_ptr fromval)
{
register struct type *type;
register value_ptr val;
/* Extend a value VAL to COUNT repetitions of its type. */
value_ptr
-value_repeat (arg1, count)
- value_ptr arg1;
- int count;
+value_repeat (value_ptr arg1, int count)
{
register value_ptr val;
}
value_ptr
-value_of_variable (var, b)
- struct symbol *var;
- struct block *b;
+value_of_variable (struct symbol *var, struct block *b)
{
value_ptr val;
struct frame_info *frame = NULL;
*/
value_ptr
-value_coerce_array (arg1)
- value_ptr arg1;
+value_coerce_array (value_ptr arg1)
{
register struct type *type = check_typedef (VALUE_TYPE (arg1));
to it. */
value_ptr
-value_coerce_function (arg1)
- value_ptr arg1;
+value_coerce_function (value_ptr arg1)
{
value_ptr retval;
/* Return a pointer value for the object for which ARG1 is the contents. */
value_ptr
-value_addr (arg1)
- value_ptr arg1;
+value_addr (value_ptr arg1)
{
value_ptr arg2;
/* Given a value of a pointer type, apply the C unary * operator to it. */
value_ptr
-value_ind (arg1)
- value_ptr arg1;
+value_ind (value_ptr arg1)
{
struct type *base_type;
value_ptr arg2;
/* Push one word (the size of object that a register holds). */
CORE_ADDR
-push_word (sp, word)
- CORE_ADDR sp;
- ULONGEST word;
+push_word (CORE_ADDR sp, ULONGEST word)
{
register int len = REGISTER_SIZE;
char buffer[MAX_REGISTER_RAW_SIZE];
/* Push LEN bytes with data at BUFFER. */
CORE_ADDR
-push_bytes (sp, buffer, len)
- CORE_ADDR sp;
- char *buffer;
- int len;
+push_bytes (CORE_ADDR sp, char *buffer, int len)
{
if (INNER_THAN (1, 2))
{
it to be an argument to a function. */
static CORE_ADDR
-value_push (sp, arg)
- register CORE_ADDR sp;
- value_ptr arg;
+value_push (register CORE_ADDR sp, value_ptr arg)
{
register int len = TYPE_LENGTH (VALUE_ENCLOSING_TYPE (arg));
register int container_len = len;
#endif
CORE_ADDR
-default_push_arguments (nargs, args, sp, struct_return, struct_addr)
- int nargs;
- value_ptr *args;
- CORE_ADDR sp;
- int struct_return;
- CORE_ADDR struct_addr;
+default_push_arguments (int nargs, value_ptr *args, CORE_ADDR sp,
+ int struct_return, CORE_ADDR struct_addr)
{
/* ASSERT ( !struct_return); */
int i;
IS_PROTOTYPED is non-zero if the function declaration is prototyped. */
static value_ptr
-value_arg_coerce (arg, param_type, is_prototyped)
- value_ptr arg;
- struct type *param_type;
- int is_prototyped;
+value_arg_coerce (value_ptr arg, struct type *param_type, int is_prototyped)
{
register struct type *arg_type = check_typedef (VALUE_TYPE (arg));
register struct type *type
Calls error() if the function is not valid for calling. */
static CORE_ADDR
-find_function_addr (function, retval_type)
- value_ptr function;
- struct type **retval_type;
+find_function_addr (value_ptr function, struct type **retval_type)
{
register struct type *ftype = check_typedef (VALUE_TYPE (function));
register enum type_code code = TYPE_CODE (ftype);
static value_ptr hand_function_call (value_ptr function, int nargs,
value_ptr * args);
static value_ptr
-hand_function_call (function, nargs, args)
- value_ptr function;
- int nargs;
- value_ptr *args;
+hand_function_call (value_ptr function, int nargs, value_ptr *args)
{
register CORE_ADDR sp;
register int i;
}
value_ptr
-call_function_by_hand (function, nargs, args)
- value_ptr function;
- int nargs;
- value_ptr *args;
+call_function_by_hand (value_ptr function, int nargs, value_ptr *args)
{
if (CALL_DUMMY_P)
{
don't currently enforce any restriction on their types). */
value_ptr
-value_array (lowbound, highbound, elemvec)
- int lowbound;
- int highbound;
- value_ptr *elemvec;
+value_array (int lowbound, int highbound, value_ptr *elemvec)
{
int nelem;
int idx;
embedded null bytes. */
value_ptr
-value_string (ptr, len)
- char *ptr;
- int len;
+value_string (char *ptr, int len)
{
value_ptr val;
int lowbound = current_language->string_lower_bound;
}
value_ptr
-value_bitstring (ptr, len)
- char *ptr;
- int len;
+value_bitstring (char *ptr, int len)
{
value_ptr val;
struct type *domain_type = create_range_type (NULL, builtin_type_int,
look for a baseclass named NAME. */
static value_ptr
-search_struct_field (name, arg1, offset, type, looking_for_baseclass)
- char *name;
- register value_ptr arg1;
- int offset;
- register struct type *type;
- int looking_for_baseclass;
+search_struct_field (char *name, register value_ptr arg1, int offset,
+ register struct type *type, int looking_for_baseclass)
{
int i;
int nbases = TYPE_N_BASECLASSES (type);
* conventions. */
void
-find_rt_vbase_offset (type, basetype, valaddr, offset, boffset_p, skip_p)
- struct type *type;
- struct type *basetype;
- char *valaddr;
- int offset;
- int *boffset_p;
- int *skip_p;
+find_rt_vbase_offset (struct type *type, struct type *basetype, char *valaddr,
+ int offset, int *boffset_p, int *skip_p)
{
int boffset; /* offset of virtual base */
int index; /* displacement to use in virtual table */
else return NULL. */
static value_ptr
-search_struct_method (name, arg1p, args, offset, static_memfuncp, type)
- char *name;
- register value_ptr *arg1p, *args;
- int offset, *static_memfuncp;
- register struct type *type;
+search_struct_method (char *name, register value_ptr *arg1p,
+ register value_ptr *args, int offset,
+ int *static_memfuncp, register struct type *type)
{
int i;
value_ptr v;
ERR is an error message to be printed in case the field is not found. */
value_ptr
-value_struct_elt (argp, args, name, static_memfuncp, err)
- register value_ptr *argp, *args;
- char *name;
- int *static_memfuncp;
- char *err;
+value_struct_elt (register value_ptr *argp, register value_ptr *args,
+ char *name, int *static_memfuncp, char *err)
{
register struct type *t;
value_ptr v;
* BOFFSET is the offset of the base subobject where the method is found */
static struct fn_field *
-find_method_list (argp, method, offset, static_memfuncp, type, num_fns, basetype, boffset)
- value_ptr *argp;
- char *method;
- int offset;
- int *static_memfuncp;
- struct type *type;
- int *num_fns;
- struct type **basetype;
- int *boffset;
+find_method_list (value_ptr *argp, char *method, int offset,
+ int *static_memfuncp, struct type *type, int *num_fns,
+ struct type **basetype, int *boffset)
{
int i;
struct fn_field *f;
* BOFFSET is the offset of the base subobject which defines the method */
struct fn_field *
-value_find_oload_method_list (argp, method, offset, static_memfuncp, num_fns, basetype, boffset)
- value_ptr *argp;
- char *method;
- int offset;
- int *static_memfuncp;
- int *num_fns;
- struct type **basetype;
- int *boffset;
+value_find_oload_method_list (value_ptr *argp, char *method, int offset,
+ int *static_memfuncp, int *num_fns,
+ struct type **basetype, int *boffset)
{
struct type *t;
*/
int
-find_overload_match (arg_types, nargs, name, method, lax, obj, fsym, valp, symp, staticp)
- struct type **arg_types;
- int nargs;
- char *name;
- int method;
- int lax;
- value_ptr obj;
- struct symbol *fsym;
- value_ptr *valp;
- struct symbol **symp;
- int *staticp;
+find_overload_match (struct type **arg_types, int nargs, char *name, int method,
+ int lax, value_ptr obj, struct symbol *fsym,
+ value_ptr *valp, struct symbol **symp, int *staticp)
{
int nparms;
struct type **parm_types;
of type TYPE. If TYPE does not have a destructor, or
if NAME is inappropriate for TYPE, an error is signaled. */
int
-destructor_name_p (name, type)
- const char *name;
- const struct type *type;
+destructor_name_p (const char *name, const struct type *type)
{
/* destructors are a special case. */
target structure/union is defined, otherwise, return 0. */
static int
-check_field_in (type, name)
- register struct type *type;
- const char *name;
+check_field_in (register struct type *type, const char *name)
{
register int i;
target structure/union is defined, otherwise, return 0. */
int
-check_field (arg1, name)
- register value_ptr arg1;
- const char *name;
+check_field (register value_ptr arg1, const char *name)
{
register struct type *t;
to resolve user expressions of the form "DOMAIN::NAME". */
value_ptr
-value_struct_elt_for_reference (domain, offset, curtype, name, intype)
- struct type *domain, *curtype, *intype;
- int offset;
- char *name;
+value_struct_elt_for_reference (struct type *domain, int offset,
+ struct type *curtype, char *name,
+ struct type *intype)
{
register struct type *t = curtype;
register int i;
*/
struct type *
-value_rtti_type (v, full, top, using_enc)
- value_ptr v;
- int *full;
- int *top;
- int *using_enc;
+value_rtti_type (value_ptr v, int *full, int *top, int *using_enc)
{
struct type *known_type;
struct type *rtti_type;
and refer to the values computed for the object pointed to. */
struct type *
-value_rtti_target_type (v, full, top, using_enc)
- value_ptr v;
- int *full;
- int *top;
- int *using_enc;
+value_rtti_target_type (value_ptr v, int *full, int *top, int *using_enc)
{
value_ptr target;
(Pass RTYPE == NULL if they're not available */
value_ptr
-value_full_object (argp, rtype, xfull, xtop, xusing_enc)
- value_ptr argp;
- struct type *rtype;
- int xfull;
- int xtop;
- int xusing_enc;
-
+value_full_object (value_ptr argp, struct type *rtype, int xfull, int xtop,
+ int xusing_enc)
{
struct type *real_type;
int full = 0;
inappropriate context. */
value_ptr
-value_of_this (complain)
- int complain;
+value_of_this (int complain)
{
struct symbol *func, *sym;
struct block *b;
the original ARRAY. */
value_ptr
-value_slice (array, lowbound, length)
- value_ptr array;
- int lowbound, length;
+value_slice (value_ptr array, int lowbound, int length)
{
struct type *slice_range_type, *slice_type, *range_type;
LONGEST lowerbound, upperbound, offset;
value as a fixed-length array. */
value_ptr
-varying_to_slice (varray)
- value_ptr varray;
+varying_to_slice (value_ptr varray)
{
struct type *vtype = check_typedef (VALUE_TYPE (varray));
LONGEST length = unpack_long (TYPE_FIELD_TYPE (vtype, 0),
doubles. FIXME: fmb */
value_ptr
-value_literal_complex (arg1, arg2, type)
- value_ptr arg1;
- value_ptr arg2;
- struct type *type;
+value_literal_complex (value_ptr arg1, value_ptr arg2, struct type *type)
{
register value_ptr val;
struct type *real_type = TYPE_TARGET_TYPE (type);
/* Cast a value into the appropriate complex data type. */
static value_ptr
-cast_into_complex (type, val)
- struct type *type;
- register value_ptr val;
+cast_into_complex (struct type *type, register value_ptr val)
{
struct type *real_type = TYPE_TARGET_TYPE (type);
if (TYPE_CODE (VALUE_TYPE (val)) == TYPE_CODE_COMPLEX)
}
void
-_initialize_valops ()
+_initialize_valops (void)
{
#if 0
add_show_from_set
int
-val_print (type, valaddr, embedded_offset, address,
- stream, format, deref_ref, recurse, pretty)
- struct type *type;
- char *valaddr;
- int embedded_offset;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
+val_print (struct type *type, char *valaddr, int embedded_offset,
+ CORE_ADDR address, struct ui_file *stream, int format, int deref_ref,
+ int recurse, enum val_prettyprint pretty)
{
struct type *real_type = check_typedef (type);
if (pretty == Val_pretty_default)
the number of string bytes printed. */
int
-value_print (val, stream, format, pretty)
- value_ptr val;
- struct ui_file *stream;
- int format;
- enum val_prettyprint pretty;
+value_print (value_ptr val, struct ui_file *stream, int format,
+ enum val_prettyprint pretty)
{
if (val == 0)
{
value. STREAM is where to print the value. */
void
-val_print_type_code_int (type, valaddr, stream)
- struct type *type;
- char *valaddr;
- struct ui_file *stream;
+val_print_type_code_int (struct type *type, char *valaddr,
+ struct ui_file *stream)
{
if (TYPE_LENGTH (type) > sizeof (LONGEST))
{
static void print_decimal (struct ui_file * stream, char *sign,
int use_local, ULONGEST val_ulong);
static void
-print_decimal (stream, sign, use_local, val_ulong)
- struct ui_file *stream;
- char *sign;
- int use_local;
- ULONGEST val_ulong;
+print_decimal (struct ui_file *stream, char *sign, int use_local,
+ ULONGEST val_ulong)
{
unsigned long temp[3];
int i = 0;
#endif
void
-print_longest (stream, format, use_local, val_long)
- struct ui_file *stream;
- int format;
- int use_local;
- LONGEST val_long;
+print_longest (struct ui_file *stream, int format, int use_local,
+ LONGEST val_long)
{
#if defined (CC_HAS_LONG_LONG) && !defined (PRINTF_HAS_LONG_LONG)
if (sizeof (long) < sizeof (LONGEST))
where the value must not be larger than can fit in an int. */
int
-longest_to_int (arg)
- LONGEST arg;
+longest_to_int (LONGEST arg)
{
/* Let the compiler do the work */
int rtnval = (int) arg;
on STREAM. */
void
-print_floating (valaddr, type, stream)
- char *valaddr;
- struct type *type;
- struct ui_file *stream;
+print_floating (char *valaddr, struct type *type, struct ui_file *stream)
{
DOUBLEST doub;
int inv;
}
void
-print_binary_chars (stream, valaddr, len)
- struct ui_file *stream;
- unsigned char *valaddr;
- unsigned len;
+print_binary_chars (struct ui_file *stream, unsigned char *valaddr,
+ unsigned len)
{
#define BITS_IN_BYTES 8
* Print it in octal on stream or format it in buf.
*/
void
-print_octal_chars (stream, valaddr, len)
- struct ui_file *stream;
- unsigned char *valaddr;
- unsigned len;
+print_octal_chars (struct ui_file *stream, unsigned char *valaddr, unsigned len)
{
unsigned char *p;
unsigned char octa1, octa2, octa3, carry;
* Print it in decimal on stream or format it in buf.
*/
void
-print_decimal_chars (stream, valaddr, len)
- struct ui_file *stream;
- unsigned char *valaddr;
- unsigned len;
+print_decimal_chars (struct ui_file *stream, unsigned char *valaddr,
+ unsigned len)
{
#define TEN 10
#define TWO_TO_FOURTH 16
/* VALADDR points to an integer of LEN bytes. Print it in hex on stream. */
static void
-print_hex_chars (stream, valaddr, len)
- struct ui_file *stream;
- unsigned char *valaddr;
- unsigned len;
+print_hex_chars (struct ui_file *stream, unsigned char *valaddr, unsigned len)
{
unsigned char *p;
*/
void
-val_print_array_elements (type, valaddr, address, stream, format, deref_ref,
- recurse, pretty, i)
- struct type *type;
- char *valaddr;
- CORE_ADDR address;
- struct ui_file *stream;
- int format;
- int deref_ref;
- int recurse;
- enum val_prettyprint pretty;
- unsigned int i;
+val_print_array_elements (struct type *type, char *valaddr, CORE_ADDR address,
+ struct ui_file *stream, int format, int deref_ref,
+ int recurse, enum val_prettyprint pretty,
+ unsigned int i)
{
unsigned int things_printed = 0;
unsigned len;
/* FIXME: Use target_read_string. */
int
-val_print_string (addr, len, width, stream)
- CORE_ADDR addr;
- int len;
- int width;
- struct ui_file *stream;
+val_print_string (CORE_ADDR addr, int len, int width, struct ui_file *stream)
{
int force_ellipsis = 0; /* Force ellipsis to be printed if nonzero. */
int errcode; /* Errno returned from bad reads. */
/* ARGSUSED */
static void
-set_input_radix (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_input_radix (char *args, int from_tty, struct cmd_list_element *c)
{
set_input_radix_1 (from_tty, *(unsigned *) c->var);
}
/* ARGSUSED */
static void
-set_input_radix_1 (from_tty, radix)
- int from_tty;
- unsigned radix;
+set_input_radix_1 (int from_tty, unsigned radix)
{
/* We don't currently disallow any input radix except 0 or 1, which don't
make any mathematical sense. In theory, we can deal with any input
/* ARGSUSED */
static void
-set_output_radix (args, from_tty, c)
- char *args;
- int from_tty;
- struct cmd_list_element *c;
+set_output_radix (char *args, int from_tty, struct cmd_list_element *c)
{
set_output_radix_1 (from_tty, *(unsigned *) c->var);
}
static void
-set_output_radix_1 (from_tty, radix)
- int from_tty;
- unsigned radix;
+set_output_radix_1 (int from_tty, unsigned radix)
{
/* Validate the radix and disallow ones that we aren't prepared to
handle correctly, leaving the radix unchanged. */
the 'set input-radix' command. */
static void
-set_radix (arg, from_tty)
- char *arg;
- int from_tty;
+set_radix (char *arg, int from_tty)
{
unsigned radix;
/*ARGSUSED */
static void
-show_radix (arg, from_tty)
- char *arg;
- int from_tty;
+show_radix (char *arg, int from_tty)
{
if (from_tty)
{
/*ARGSUSED */
static void
-set_print (arg, from_tty)
- char *arg;
- int from_tty;
+set_print (char *arg, int from_tty)
{
printf_unfiltered (
"\"set print\" must be followed by the name of a print subcommand.\n");
/*ARGSUSED */
static void
-show_print (args, from_tty)
- char *args;
- int from_tty;
+show_print (char *args, int from_tty)
{
cmd_show_list (showprintlist, from_tty, "");
}
\f
void
-_initialize_valprint ()
+_initialize_valprint (void)
{
struct cmd_list_element *c;
/* Allocate a value that has the correct length for type TYPE. */
value_ptr
-allocate_value (type)
- struct type *type;
+allocate_value (struct type *type)
{
register value_ptr val;
struct type *atype = check_typedef (type);
for COUNT repetitions type TYPE. */
value_ptr
-allocate_repeat_value (type, count)
- struct type *type;
- int count;
+allocate_repeat_value (struct type *type, int count)
{
int low_bound = current_language->string_lower_bound; /* ??? */
/* FIXME-type-allocation: need a way to free this type when we are
mark is obtained (except for those released) are subject to being freed
if a subsequent value_free_to_mark is passed the mark. */
value_ptr
-value_mark ()
+value_mark (void)
{
return all_values;
}
/* Free all values allocated since MARK was obtained by value_mark
(except for those released). */
void
-value_free_to_mark (mark)
- value_ptr mark;
+value_free_to_mark (value_ptr mark)
{
value_ptr val, next;
Called after each command, successful or not. */
void
-free_all_values ()
+free_all_values (void)
{
register value_ptr val, next;
so it will not be freed automatically. */
void
-release_value (val)
- register value_ptr val;
+release_value (register value_ptr val)
{
register value_ptr v;
/* Release all values up to mark */
value_ptr
-value_release_to_mark (mark)
- value_ptr mark;
+value_release_to_mark (value_ptr mark)
{
value_ptr val, next;
but it's a different block of storage. */
value_ptr
-value_copy (arg)
- value_ptr arg;
+value_copy (value_ptr arg)
{
register struct type *encl_type = VALUE_ENCLOSING_TYPE (arg);
register value_ptr val = allocate_value (encl_type);
value history index of this new item. */
int
-record_latest_value (val)
- value_ptr val;
+record_latest_value (value_ptr val)
{
int i;
/* Return a copy of the value in the history with sequence number NUM. */
value_ptr
-access_value_history (num)
- int num;
+access_value_history (int num)
{
register struct value_history_chunk *chunk;
register int i;
because the type pointers become invalid. */
void
-clear_value_history ()
+clear_value_history (void)
{
register struct value_history_chunk *next;
register int i;
}
static void
-show_values (num_exp, from_tty)
- char *num_exp;
- int from_tty;
+show_values (char *num_exp, int from_tty)
{
register int i;
register value_ptr val;
one is created, with a void value. */
struct internalvar *
-lookup_internalvar (name)
- char *name;
+lookup_internalvar (char *name)
{
register struct internalvar *var;
}
value_ptr
-value_of_internalvar (var)
- struct internalvar *var;
+value_of_internalvar (struct internalvar *var)
{
register value_ptr val;
}
void
-set_internalvar_component (var, offset, bitpos, bitsize, newval)
- struct internalvar *var;
- int offset, bitpos, bitsize;
- value_ptr newval;
+set_internalvar_component (struct internalvar *var, int offset, int bitpos,
+ int bitsize, value_ptr newval)
{
register char *addr = VALUE_CONTENTS (var->value) + offset;
}
void
-set_internalvar (var, val)
- struct internalvar *var;
- value_ptr val;
+set_internalvar (struct internalvar *var, value_ptr val)
{
value_ptr newval;
}
char *
-internalvar_name (var)
- struct internalvar *var;
+internalvar_name (struct internalvar *var)
{
return var->name;
}
because that makes the values invalid. */
void
-clear_internalvars ()
+clear_internalvars (void)
{
register struct internalvar *var;
}
static void
-show_convenience (ignore, from_tty)
- char *ignore;
- int from_tty;
+show_convenience (char *ignore, int from_tty)
{
register struct internalvar *var;
int varseen = 0;
Does not deallocate the value. */
LONGEST
-value_as_long (val)
- register value_ptr val;
+value_as_long (register value_ptr val)
{
/* This coerces arrays and functions, which is necessary (e.g.
in disassemble_command). It also dereferences references, which
}
DOUBLEST
-value_as_double (val)
- register value_ptr val;
+value_as_double (register value_ptr val)
{
DOUBLEST foo;
int inv;
Note that val's type may not actually be a pointer; value_as_long
handles all the cases. */
CORE_ADDR
-value_as_pointer (val)
- value_ptr val;
+value_as_pointer (value_ptr val)
{
/* Assume a CORE_ADDR can fit in a LONGEST (for now). Not sure
whether we want this to be true eventually. */
to an INT (or some size). After all, it is only an offset. */
LONGEST
-unpack_long (type, valaddr)
- struct type *type;
- char *valaddr;
+unpack_long (struct type *type, char *valaddr)
{
register enum type_code code = TYPE_CODE (type);
register int len = TYPE_LENGTH (type);
format, result is in host format. */
DOUBLEST
-unpack_double (type, valaddr, invp)
- struct type *type;
- char *valaddr;
- int *invp;
+unpack_double (struct type *type, char *valaddr, int *invp)
{
enum type_code code;
int len;
to an INT (or some size). After all, it is only an offset. */
CORE_ADDR
-unpack_pointer (type, valaddr)
- struct type *type;
- char *valaddr;
+unpack_pointer (struct type *type, char *valaddr)
{
/* Assume a CORE_ADDR can fit in a LONGEST (for now). Not sure
whether we want this to be true eventually. */
/* Get the value of the FIELDN'th field (which must be static) of TYPE. */
value_ptr
-value_static_field (type, fieldno)
- struct type *type;
- int fieldno;
+value_static_field (struct type *type, int fieldno)
{
CORE_ADDR addr;
asection *sect;
FIELDNO says which field. */
value_ptr
-value_primitive_field (arg1, offset, fieldno, arg_type)
- register value_ptr arg1;
- int offset;
- register int fieldno;
- register struct type *arg_type;
+value_primitive_field (register value_ptr arg1, int offset,
+ register int fieldno, register struct type *arg_type)
{
register value_ptr v;
register struct type *type;
FIELDNO says which field. */
value_ptr
-value_field (arg1, fieldno)
- register value_ptr arg1;
- register int fieldno;
+value_field (register value_ptr arg1, register int fieldno)
{
return value_primitive_field (arg1, 0, fieldno, VALUE_TYPE (arg1));
}
J is an index into F which provides the desired method. */
value_ptr
-value_fn_field (arg1p, f, j, type, offset)
- value_ptr *arg1p;
- struct fn_field *f;
- int j;
- struct type *type;
- int offset;
+value_fn_field (value_ptr *arg1p, struct fn_field *f, int j, struct type *type,
+ int offset)
{
register value_ptr v;
register struct type *ftype = TYPE_FN_FIELD_TYPE (f, j);
TYPE is the type in which F is located. */
value_ptr
-value_virtual_fn_field (arg1p, f, j, type, offset)
- value_ptr *arg1p;
- struct fn_field *f;
- int j;
- struct type *type;
- int offset;
+value_virtual_fn_field (value_ptr *arg1p, struct fn_field *f, int j,
+ struct type *type, int offset)
{
value_ptr arg1 = *arg1p;
struct type *type1 = check_typedef (VALUE_TYPE (arg1));
Consider it gone for 5.1. */
static value_ptr
-value_headof (in_arg, btype, dtype)
- value_ptr in_arg;
- struct type *btype, *dtype;
+value_headof (value_ptr in_arg, struct type *btype, struct type *dtype)
{
/* First collect the vtables we must look at for this object. */
value_ptr arg, vtbl;
could actually be a pointer to. */
value_ptr
-value_from_vtable_info (arg, type)
- value_ptr arg;
- struct type *type;
+value_from_vtable_info (value_ptr arg, struct type *type)
{
/* Take care of preliminaries. */
if (TYPE_VPTR_FIELDNO (type) < 0)
pointer which is for the base class whose type is BASECLASS. */
static int
-vb_match (type, index, basetype)
- struct type *type;
- int index;
- struct type *basetype;
+vb_match (struct type *type, int index, struct type *basetype)
{
struct type *fieldtype;
char *name = TYPE_FIELD_NAME (type, index);
-1 is returned on error. */
int
-baseclass_offset (type, index, valaddr, address)
- struct type *type;
- int index;
- char *valaddr;
- CORE_ADDR address;
+baseclass_offset (struct type *type, int index, char *valaddr,
+ CORE_ADDR address)
{
struct type *basetype = TYPE_BASECLASS (type, index);
If the field is signed, we also do sign extension. */
LONGEST
-unpack_field_as_long (type, valaddr, fieldno)
- struct type *type;
- char *valaddr;
- int fieldno;
+unpack_field_as_long (struct type *type, char *valaddr, int fieldno)
{
ULONGEST val;
ULONGEST valmask;
indicate which bits (in target bit order) comprise the bitfield. */
void
-modify_field (addr, fieldval, bitpos, bitsize)
- char *addr;
- LONGEST fieldval;
- int bitpos, bitsize;
+modify_field (char *addr, LONGEST fieldval, int bitpos, int bitsize)
{
LONGEST oword;
/* Convert C numbers into newly allocated values */
value_ptr
-value_from_longest (type, num)
- struct type *type;
- register LONGEST num;
+value_from_longest (struct type *type, register LONGEST num)
{
register value_ptr val = allocate_value (type);
register enum type_code code;
use inferior memory. String shall NOT contain embedded nulls. */
value_ptr
-value_from_string (ptr)
- char *ptr;
+value_from_string (char *ptr)
{
value_ptr val;
int len = strlen (ptr);
}
value_ptr
-value_from_double (type, num)
- struct type *type;
- DOUBLEST num;
+value_from_double (struct type *type, DOUBLEST num)
{
register value_ptr val = allocate_value (type);
struct type *base_type = check_typedef (type);
handled wrong. */
int
-generic_use_struct_convention (gcc_p, value_type)
- int gcc_p;
- struct type *value_type;
+generic_use_struct_convention (int gcc_p, struct type *value_type)
{
return !((gcc_p == 1)
&& (TYPE_LENGTH (value_type) == 1
function wants to return. */
void
-set_return_value (val)
- value_ptr val;
+set_return_value (value_ptr val)
{
struct type *type = check_typedef (VALUE_TYPE (val));
register enum type_code code = TYPE_CODE (type);
}
\f
void
-_initialize_values ()
+_initialize_values (void)
{
add_cmd ("convenience", no_class, show_convenience,
"Debugger convenience (\"$foo\") variables.\n\
*/
static int
-delete_variable (resultp, var, only_children_p)
- struct cpstack **resultp;
- struct varobj *var;
- int only_children_p;
+delete_variable (struct cpstack **resultp, struct varobj *var,
+ int only_children_p)
{
int delcount = 0;
and the parent is not removed we dump core. It must be always
initially called with remove_from_parent_p set */
static void
-delete_variable_1 (resultp, delcountp, var,
- only_children_p, remove_from_parent_p)
- struct cpstack **resultp;
- int *delcountp;
- struct varobj *var;
- int only_children_p;
- int remove_from_parent_p;
+delete_variable_1 (struct cpstack **resultp, int *delcountp, struct varobj *var,
+ int only_children_p, int remove_from_parent_p)
{
struct varobj_child *vc;
struct varobj_child *next;
/* Install the given variable VAR with the object name VAR->OBJ_NAME. */
static int
-install_variable (var)
- struct varobj *var;
+install_variable (struct varobj *var)
{
struct vlist *cv;
struct vlist *newvl;
/* Unistall the object VAR. */
static void
-uninstall_variable (var)
- struct varobj *var;
+uninstall_variable (struct varobj *var)
{
struct vlist *cv;
struct vlist *prev;
/* Create and install a child of the parent of the given name */
static struct varobj *
-create_child (parent, index, name)
- struct varobj *parent;
- int index;
- char *name;
+create_child (struct varobj *parent, int index, char *name)
{
struct varobj *child;
char *childs_name;
/* FIXME: This should be a generic add to list */
/* Save CHILD in the PARENT's data. */
static void
-save_child_in_parent (parent, child)
- struct varobj *parent;
- struct varobj *child;
+save_child_in_parent (struct varobj *parent, struct varobj *child)
{
struct varobj_child *vc;
/* FIXME: This should be a generic remove from list */
/* Remove the CHILD from the PARENT's list of children. */
static void
-remove_child_from_parent (parent, child)
- struct varobj *parent;
- struct varobj *child;
+remove_child_from_parent (struct varobj *parent, struct varobj *child)
{
struct varobj_child *vc, *prev;
/* Free any allocated memory associated with VAR. */
static void
-free_variable (var)
- struct varobj *var;
+free_variable (struct varobj *var)
{
/* Free the expression if this is a root variable. */
if (var->root->rootvar == var)
and returns the real type of the variable. It also dereferences
pointers and references. */
static struct type *
-get_type (var)
- struct varobj *var;
+get_type (struct varobj *var)
{
struct type *type;
type = var->type;
/* This returns the type of the variable, dereferencing pointers, too. */
static struct type *
-get_type_deref (var)
- struct varobj *var;
+get_type_deref (struct varobj *var)
{
struct type *type;
/* This returns the target type (or NULL) of TYPE, also skipping
past typedefs, just like get_type (). */
static struct type *
-get_target_type (type)
- struct type *type;
+get_target_type (struct type *type)
{
if (type != NULL)
{
/* What is the default display for this variable? We assume that
everything is "natural". Any exceptions? */
static enum varobj_display_formats
-variable_default_display (var)
- struct varobj *var;
+variable_default_display (struct varobj *var)
{
return FORMAT_NATURAL;
}
one is "safe" -- it NEVER longjmps. It determines if the VAR's
value is the same as VAL2. */
static int
-my_value_equal (val1, val2, error2)
- value_ptr val1;
- value_ptr val2;
- int *error2;
+my_value_equal (value_ptr val1, value_ptr val2, int *error2)
{
int r, err1, err2;
/* FIXME: The following should be generic for any pointer */
static void
-vpush (pstack, var)
- struct vstack **pstack;
- struct varobj *var;
+vpush (struct vstack **pstack, struct varobj *var)
{
struct vstack *s;
/* FIXME: The following should be generic for any pointer */
static struct varobj *
-vpop (pstack)
- struct vstack **pstack;
+vpop (struct vstack **pstack)
{
struct vstack *s;
struct varobj *v;
/* FIXME: The following should be generic for any pointer */
static void
-cppush (pstack, name)
- struct cpstack **pstack;
- char *name;
+cppush (struct cpstack **pstack, char *name)
{
struct cpstack *s;
/* FIXME: The following should be generic for any pointer */
static char *
-cppop (pstack)
- struct cpstack **pstack;
+cppop (struct cpstack **pstack)
{
struct cpstack *s;
char *v;
/* Get the language of variable VAR. */
static enum varobj_languages
-variable_language (var)
- struct varobj *var;
+variable_language (struct varobj *var)
{
enum varobj_languages lang;
is the number of children that the user will see in the variable
display. */
static int
-number_of_children (var)
- struct varobj *var;
+number_of_children (struct varobj *var)
{
return (*var->root->lang->number_of_children) (var);;
}
/* What is the expression for the root varobj VAR? Returns a malloc'd string. */
static char *
-name_of_variable (var)
- struct varobj *var;
+name_of_variable (struct varobj *var)
{
return (*var->root->lang->name_of_variable) (var);
}
/* What is the name of the INDEX'th child of VAR? Returns a malloc'd string. */
static char *
-name_of_child (var, index)
- struct varobj *var;
- int index;
+name_of_child (struct varobj *var, int index)
{
return (*var->root->lang->name_of_child) (var, index);
}
On return, TYPE_CHANGED will be 1 if the type has changed, and
0 otherwise. */
static value_ptr
-value_of_root (var_handle, type_changed)
- struct varobj ** var_handle;
- int *type_changed;
+value_of_root (struct varobj **var_handle, int *type_changed)
{
struct varobj *var;
/* What is the value_ptr for the INDEX'th child of PARENT? */
static value_ptr
-value_of_child (parent, index)
- struct varobj *parent;
- int index;
+value_of_child (struct varobj *parent, int index)
{
value_ptr value;
/* What is the type of VAR? */
static struct type *
-type_of_child (var)
- struct varobj *var;
+type_of_child (struct varobj *var)
{
/* If the child had no evaluation errors, var->value
/* Is this variable editable? Use the variable's type to make
this determination. */
static int
-variable_editable (var)
- struct varobj *var;
+variable_editable (struct varobj *var)
{
return (*var->root->lang->variable_editable) (var);
}
/* GDB already has a command called "value_of_variable". Sigh. */
static char *
-my_value_of_variable (var)
- struct varobj *var;
+my_value_of_variable (struct varobj *var)
{
return (*var->root->lang->value_of_variable) (var);
}
some variable's values never change. For example,
struct and unions never change values. */
static int
-type_changeable (var)
- struct varobj *var;
+type_changeable (struct varobj *var)
{
int r;
struct type *type;
/* C */
static int
-c_number_of_children (var)
- struct varobj *var;
+c_number_of_children (struct varobj *var)
{
struct type *type;
struct type *target;
}
static char *
-c_name_of_variable (parent)
- struct varobj *parent;
+c_name_of_variable (struct varobj *parent)
{
return savestring (parent->name, strlen (parent->name));
}
static char *
-c_name_of_child (parent, index)
- struct varobj *parent;
- int index;
+c_name_of_child (struct varobj *parent, int index)
{
struct type *type;
struct type *target;
}
static value_ptr
-c_value_of_root (var_handle)
- struct varobj **var_handle;
+c_value_of_root (struct varobj **var_handle)
{
value_ptr new_val;
struct varobj *var = *var_handle;
}
static value_ptr
-c_value_of_child (parent, index)
- struct varobj *parent;
- int index;
+c_value_of_child (struct varobj *parent, int index)
{
value_ptr value, temp, indval;
struct type *type, *target;
}
static struct type *
-c_type_of_child (parent, index)
- struct varobj *parent;
- int index;
+c_type_of_child (struct varobj *parent, int index)
{
struct type *type;
char *name = name_of_child (parent, index);
}
static int
-c_variable_editable (var)
- struct varobj *var;
+c_variable_editable (struct varobj *var)
{
switch (TYPE_CODE (get_type (var)))
{
}
static char *
-c_value_of_variable (var)
- struct varobj *var;
+c_value_of_variable (struct varobj *var)
{
struct type *type;
value_ptr val;
/* C++ */
static int
-cplus_number_of_children (var)
- struct varobj *var;
+cplus_number_of_children (struct varobj *var)
{
struct type *type;
int children, dont_know;
}
static char *
-cplus_name_of_variable (parent)
- struct varobj *parent;
+cplus_name_of_variable (struct varobj *parent)
{
return c_name_of_variable (parent);
}
static char *
-cplus_name_of_child (parent, index)
- struct varobj *parent;
- int index;
+cplus_name_of_child (struct varobj *parent, int index)
{
char *name;
struct type *type;
}
static value_ptr
-cplus_value_of_root (var_handle)
- struct varobj **var_handle;
+cplus_value_of_root (struct varobj **var_handle)
{
return c_value_of_root (var_handle);
}
static value_ptr
-cplus_value_of_child (parent, index)
- struct varobj *parent;
- int index;
+cplus_value_of_child (struct varobj *parent, int index)
{
struct type *type;
value_ptr value;
}
static struct type *
-cplus_type_of_child (parent, index)
- struct varobj *parent;
- int index;
+cplus_type_of_child (struct varobj *parent, int index)
{
struct type *type, *t;
}
static int
-cplus_variable_editable (var)
- struct varobj *var;
+cplus_variable_editable (struct varobj *var)
{
if (CPLUS_FAKE_CHILD (var))
return 0;
}
static char *
-cplus_value_of_variable (var)
- struct varobj *var;
+cplus_value_of_variable (struct varobj *var)
{
/* If we have one of our special types, don't print out
/* Java */
static int
-java_number_of_children (var)
- struct varobj *var;
+java_number_of_children (struct varobj *var)
{
return cplus_number_of_children (var);
}
static char *
-java_name_of_variable (parent)
- struct varobj *parent;
+java_name_of_variable (struct varobj *parent)
{
char *p, *name;
}
static char *
-java_name_of_child (parent, index)
- struct varobj *parent;
- int index;
+java_name_of_child (struct varobj *parent, int index)
{
char *name, *p;
}
static value_ptr
-java_value_of_root (var_handle)
- struct varobj **var_handle;
+java_value_of_root (struct varobj **var_handle)
{
return cplus_value_of_root (var_handle);
}
static value_ptr
-java_value_of_child (parent, index)
- struct varobj *parent;
- int index;
+java_value_of_child (struct varobj *parent, int index)
{
return cplus_value_of_child (parent, index);
}
static struct type *
-java_type_of_child (parent, index)
- struct varobj *parent;
- int index;
+java_type_of_child (struct varobj *parent, int index)
{
return cplus_type_of_child (parent, index);
}
static int
-java_variable_editable (var)
- struct varobj *var;
+java_variable_editable (struct varobj *var)
{
return cplus_variable_editable (var);
}
static char *
-java_value_of_variable (var)
- struct varobj *var;
+java_value_of_variable (struct varobj *var)
{
return cplus_value_of_variable (var);
}
to reach some "real" code. */
CORE_ADDR
-vax_skip_prologue (pc)
- CORE_ADDR pc;
+vax_skip_prologue (CORE_ADDR pc)
{
register int op = (unsigned char) read_memory_integer (pc, 1);
if (op == 0x11)
Can return -1, meaning no way to tell. */
int
-vax_frame_num_args (fi)
- struct frame_info *fi;
+vax_frame_num_args (struct frame_info *fi)
{
return (0xff & read_memory_integer (FRAME_ARGS_ADDRESS (fi), 1));
}
Returns length of the instruction, in bytes. */
static int
-vax_print_insn (memaddr, info)
- CORE_ADDR memaddr;
- disassemble_info *info;
+vax_print_insn (CORE_ADDR memaddr, disassemble_info *info)
{
unsigned char buffer[MAXLEN];
register int i;
}
static unsigned char *
-print_insn_arg (d, p, addr, info)
- char *d;
- register char *p;
- CORE_ADDR addr;
- disassemble_info *info;
+print_insn_arg (char *d, register char *p, CORE_ADDR addr,
+ disassemble_info *info)
{
register int regnum = *p & 0xf;
float floatlitbuf;
}
void
-_initialize_vax_tdep ()
+_initialize_vax_tdep (void)
{
tm_print_insn = vax_print_insn;
}
CORE_ADDR
-w65_frame_saved_pc (frame)
- struct frame_info *frame;
+w65_frame_saved_pc (struct frame_info *frame)
{
return (read_memory_integer (frame->frame + 2, 4) & 0xffffff);
}
CORE_ADDR
-w65_addr_bits_remove (addr)
- CORE_ADDR addr;
+w65_addr_bits_remove (CORE_ADDR addr)
{
return ((addr) & 0xffffff);
}
-read_memory_pointer (x)
- CORE_ADDR x;
+read_memory_pointer (CORE_ADDR x)
{
return read_memory_integer (ADDR_BITS_REMOVE (x), 4);
}
-init_frame_pc ()
+init_frame_pc (void)
{
abort ();
}
void
-w65_push_dummy_frame ()
+w65_push_dummy_frame (void)
{
abort ();
}
it is fairly expensive. */
void
-frame_find_saved_regs (fip, fsrp)
- struct frame_info *fip;
- struct frame_saved_regs *fsrp;
+frame_find_saved_regs (struct frame_info *fip, struct frame_saved_regs *fsrp)
{
int locals;
CORE_ADDR pc;
}
int
-saved_pc_after_call ()
+saved_pc_after_call (void)
{
int sp = read_register (SP_REGNUM);
int val = read_memory_integer (sp + 1, 4);
}
-extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
int b;
int len = TYPE_LENGTH (type);
}
void
-write_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+write_return_value (struct type *type, char *valbuf)
{
int reg;
int len;
}
void
-store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
write_register (2, addr);
}
void
-w65_pop_frame ()
+w65_pop_frame (void)
{
}
-init_extra_frame_info ()
+init_extra_frame_info (void)
{
}
-pop_frame ()
+pop_frame (void)
{
}
-w65_frame_chain (thisframe)
- struct frame_info *thisframe;
+w65_frame_chain (struct frame_info *thisframe)
{
return 0xffff & read_memory_integer ((thisframe)->frame, 2);
}
static int
-gb (x)
+gb (int x)
{
return read_memory_integer (x, 1) & 0xff;
}
extern CORE_ADDR
-w65_skip_prologue (pc)
- CORE_ADDR pc;
+w65_skip_prologue (CORE_ADDR pc)
{
CORE_ADDR too_far = pc + 20;
}
-register_raw_size (n)
+register_raw_size (int n)
{
return sim_reg_size (n);
}
void
-print_register_hook (regno)
+print_register_hook (int regno)
{
if (regno == P_REGNUM)
{
}
void
-_initialize_w65_tdep ()
+_initialize_w65_tdep (void)
{
tm_print_insn = print_insn_w65;
}
};
static void
-w89k_supply_register (regname, regnamelen, val, vallen)
- char *regname;
- int regnamelen;
- char *val;
- int vallen;
+w89k_supply_register (char *regname, int regnamelen, char *val, int vallen)
{
int numregs;
int regno;
extern struct monitor_ops w89k_cmds; /* fwd decl */
static void
-w89k_load (desc, file, hashmark)
- serial_t desc;
- char *file;
- int hashmark;
+w89k_load (serial_t desc, char *file, int hashmark)
{
bfd *abfd;
asection *s;
} /* init_w89k_cmds */
static void
-w89k_open (args, from_tty)
- char *args;
- int from_tty;
+w89k_open (char *args, int from_tty)
{
monitor_open (args, &w89k_cmds, from_tty);
}
void
-_initialize_w89k ()
+_initialize_w89k (void)
{
init_w89k_cmds ();
init_monitor_ops (&w89k_ops);
/* Clear out any old thread list and reintialize it to a
pristine state. */
static void
-child_init_thread_list ()
+child_init_thread_list (void)
{
thread_info *th = &thread_head;
/* Attach to process PID, then initialize for debugging it. */
static void
-child_attach (args, from_tty)
- char *args;
- int from_tty;
+child_attach (char *args, int from_tty)
{
BOOL ok;
ENV is the environment vector to pass. Errors reported with error(). */
static void
-child_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+child_create_inferior (char *exec_file, char *allargs, char **env)
{
char real_path[MAXPATHLEN];
char *winenv;
}
static void
-child_mourn_inferior ()
+child_mourn_inferior (void)
{
(void) child_continue (DBG_CONTINUE, -1);
unpush_target (&child_ops);
^C on the controlling terminal. */
static void
-child_stop ()
+child_stop (void)
{
DEBUG_EVENTS (("gdb: GenerateConsoleCtrlEvent (CTRLC_EVENT, 0)\n"));
CHECK (GenerateConsoleCtrlEvent (CTRL_C_EVENT, current_event.dwProcessId));
}
static void
-child_prepare_to_store ()
+child_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static int
-child_can_run ()
+child_can_run (void)
{
return 1;
}
static void
-child_close ()
+child_close (void)
{
DEBUG_EVENTS (("gdb: child_close, inferior_pid=%d\n", inferior_pid));
}
}
void
-_initialize_inftarg ()
+_initialize_inftarg (void)
{
init_child_ops ();
to terminate.
*/
static void
-stop_stub ()
+stop_stub (void)
{
if (s < 0)
return;
/* Clear out any old thread list and reintialize it to a
pristine state. */
static void
-child_init_thread_list ()
+child_init_thread_list (void)
{
thread_info *th = &thread_head;
/* Print status information about what we're accessing. */
static void
-child_files_info (ignore)
- struct target_ops *ignore;
+child_files_info (struct target_ops *ignore)
{
printf_unfiltered ("\tUsing the running image of child %s.\n",
target_pid_to_str (inferior_pid));
/* ARGSUSED */
static void
-child_open (arg, from_tty)
- char *arg;
- int from_tty;
+child_open (char *arg, int from_tty)
{
error ("Use the \"run\" command to start a child process.");
}
/* Initialize the connection to the remote device. */
static void
-wince_initialize ()
+wince_initialize (void)
{
int tmp;
char args[256];
/* Chile has gone bye-bye. */
static void
-child_mourn_inferior ()
+child_mourn_inferior (void)
{
(void) child_continue (DBG_CONTINUE, -1);
unpush_target (&child_ops);
}
static void
-child_prepare_to_store ()
+child_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static int
-child_can_run ()
+child_can_run (void)
{
return 1;
}
static void
-child_close ()
+child_close (void)
{
DEBUG_EVENTS (("gdb: child_close, inferior_pid=%d\n", inferior_pid));
}
}
void
-_initialize_inftarg ()
+_initialize_inftarg (void)
{
struct cmd_list_element *set;
init_child_ops ();
/* Clear out any old thread list and reintialize it to a
pristine state. */
static void
-child_init_thread_list ()
+child_init_thread_list (void)
{
thread_info *th = &thread_head;
/* Attach to process PID, then initialize for debugging it. */
static void
-child_attach (args, from_tty)
- char *args;
- int from_tty;
+child_attach (char *args, int from_tty)
{
BOOL ok;
ENV is the environment vector to pass. Errors reported with error(). */
static void
-child_create_inferior (exec_file, allargs, env)
- char *exec_file;
- char *allargs;
- char **env;
+child_create_inferior (char *exec_file, char *allargs, char **env)
{
char real_path[MAXPATHLEN];
char *winenv;
}
static void
-child_mourn_inferior ()
+child_mourn_inferior (void)
{
(void) child_continue (DBG_CONTINUE, -1);
unpush_target (&child_ops);
^C on the controlling terminal. */
static void
-child_stop ()
+child_stop (void)
{
DEBUG_EVENTS (("gdb: GenerateConsoleCtrlEvent (CTRLC_EVENT, 0)\n"));
CHECK (GenerateConsoleCtrlEvent (CTRL_C_EVENT, current_event.dwProcessId));
}
static void
-child_prepare_to_store ()
+child_prepare_to_store (void)
{
/* Do nothing, since we can store individual regs */
}
static int
-child_can_run ()
+child_can_run (void)
{
return 1;
}
static void
-child_close ()
+child_close (void)
{
DEBUG_EVENTS (("gdb: child_close, inferior_pid=%d\n", inferior_pid));
}
}
void
-_initialize_inftarg ()
+_initialize_inftarg (void)
{
init_child_ops ();
static int wrap_parse_and_eval_type (char *);
int
-gdb_parse_exp_1 (stringptr, block, comma, expression)
- char **stringptr;
- struct block *block;
- int comma;
- struct expression **expression;
+gdb_parse_exp_1 (char **stringptr, struct block *block, int comma,
+ struct expression **expression)
{
struct gdb_wrapper_arguments args;
args.args[0].pointer = stringptr;
}
static int
-wrap_parse_exp_1 (argptr)
- char *argptr;
+wrap_parse_exp_1 (char *argptr)
{
struct gdb_wrapper_arguments *args
= (struct gdb_wrapper_arguments *) argptr;
}
int
-gdb_evaluate_expression (exp, value)
- struct expression *exp;
- value_ptr *value;
+gdb_evaluate_expression (struct expression *exp, value_ptr *value)
{
struct gdb_wrapper_arguments args;
args.args[0].pointer = exp;
}
static int
-wrap_evaluate_expression (a)
- char *a;
+wrap_evaluate_expression (char *a)
{
struct gdb_wrapper_arguments *args = (struct gdb_wrapper_arguments *) a;
}
int
-gdb_value_fetch_lazy (value)
- value_ptr value;
+gdb_value_fetch_lazy (value_ptr value)
{
struct gdb_wrapper_arguments args;
}
static int
-wrap_value_fetch_lazy (a)
- char *a;
+wrap_value_fetch_lazy (char *a)
{
struct gdb_wrapper_arguments *args = (struct gdb_wrapper_arguments *) a;
}
int
-gdb_value_equal (val1, val2, result)
- value_ptr val1;
- value_ptr val2;
- int *result;
+gdb_value_equal (value_ptr val1, value_ptr val2, int *result)
{
struct gdb_wrapper_arguments args;
}
static int
-wrap_value_equal (a)
- char *a;
+wrap_value_equal (char *a)
{
struct gdb_wrapper_arguments *args = (struct gdb_wrapper_arguments *) a;
value_ptr val1, val2;
}
int
-gdb_value_subscript (val1, val2, rval)
- value_ptr val1;
- value_ptr val2;
- value_ptr * rval;
+gdb_value_subscript (value_ptr val1, value_ptr val2, value_ptr *rval)
{
struct gdb_wrapper_arguments args;
}
static int
-wrap_value_subscript (a)
- char *a;
+wrap_value_subscript (char *a)
{
struct gdb_wrapper_arguments *args = (struct gdb_wrapper_arguments *) a;
value_ptr val1, val2;
}
int
-gdb_value_ind (val, rval)
- value_ptr val;
- value_ptr *rval;
+gdb_value_ind (value_ptr val, value_ptr *rval)
{
struct gdb_wrapper_arguments args;
}
static int
-wrap_value_ind (opaque_arg)
- char *opaque_arg;
+wrap_value_ind (char *opaque_arg)
{
struct gdb_wrapper_arguments *args = (struct gdb_wrapper_arguments *) opaque_arg;
value_ptr val;
static void find_targ_sec (bfd *, asection *, void *);
static void
-find_targ_sec (abfd, sect, obj)
- bfd *abfd;
- asection *sect;
- PTR obj;
+find_targ_sec (bfd *abfd, asection *sect, PTR obj)
{
struct find_targ_sec_arg *args = (struct find_targ_sec_arg *) obj;
struct objfile *objfile = args->objfile;
/* Return the section number (SECT_OFF_*) that CS points to. */
static int
-secnum_to_section (secnum, objfile)
- int secnum;
- struct objfile *objfile;
+secnum_to_section (int secnum, struct objfile *objfile)
{
int off = SECT_OFF_TEXT (objfile);
asection *sect = NULL;
/* Return the BFD section that CS points to. */
static asection *
-secnum_to_bfd_section (secnum, objfile)
- int secnum;
- struct objfile *objfile;
+secnum_to_bfd_section (int secnum, struct objfile *objfile)
{
int off = SECT_OFF_TEXT (objfile);
asection *sect = NULL;
#if 0
static void
-add_stab_to_list (stabname, stabvector)
- char *stabname;
- struct pending_stabs **stabvector;
+add_stab_to_list (char *stabname, struct pending_stabs **stabvector)
{
if (*stabvector == NULL)
{
/* compare line table entry addresses. */
static int
-compare_lte (lte1p, lte2p)
- const void *lte1p;
- const void *lte2p;
+compare_lte (const void *lte1p, const void *lte2p)
{
struct linetable_entry *lte1 = (struct linetable_entry *) lte1p;
struct linetable_entry *lte2 = (struct linetable_entry *) lte2p;
static void allocate_include_entry (void);
static void
-record_include_begin (cs)
- struct coff_symbol *cs;
+record_include_begin (struct coff_symbol *cs)
{
if (inclDepth)
{
}
static void
-record_include_end (cs)
- struct coff_symbol *cs;
+record_include_end (struct coff_symbol *cs)
{
InclTable *pTbl;
}
static void
-allocate_include_entry ()
+allocate_include_entry (void)
{
if (inclTable == NULL)
{
at times) process its lines and create appropriate line vectors. */
static void
-process_linenos (start, end)
- CORE_ADDR start, end;
+process_linenos (CORE_ADDR start, CORE_ADDR end)
{
int offset, ii;
file_ptr max_offset =
}
void
-aix_process_linenos ()
+aix_process_linenos (void)
{
/* process line numbers and enter them into line vector */
process_linenos (last_source_start_addr, cur_src_end_addr);
attention to. */
static void
-enter_line_range (subfile, beginoffset, endoffset, startaddr, endaddr,
- firstLine)
- struct subfile *subfile;
- unsigned beginoffset, endoffset; /* offsets to line table */
- CORE_ADDR startaddr, endaddr;
- unsigned *firstLine;
+enter_line_range (struct subfile *subfile, unsigned beginoffset, unsigned endoffset, /* offsets to line table */
+ CORE_ADDR startaddr, /* offsets to line table */
+ CORE_ADDR endaddr, unsigned *firstLine)
{
unsigned int curoffset;
CORE_ADDR addr;
continuations. */
static char *
-xcoff_next_symbol_text (objfile)
- struct objfile *objfile;
+xcoff_next_symbol_text (struct objfile *objfile)
{
struct internal_syment symbol;
static struct complaint msg =
/* Read symbols for a given partial symbol table. */
static void
-read_xcoff_symtab (pst)
- struct partial_symtab *pst;
+read_xcoff_symtab (struct partial_symtab *pst)
{
struct objfile *objfile = pst->objfile;
bfd *abfd = objfile->obfd;
/* process one xcoff symbol. */
static struct symbol *
-process_xcoff_symbol (cs, objfile)
- register struct coff_symbol *cs;
- struct objfile *objfile;
+process_xcoff_symbol (register struct coff_symbol *cs, struct objfile *objfile)
{
struct symbol onesymbol;
register struct symbol *sym = &onesymbol;
Result is in static storage and is only good for temporary use. */
static char *
-coff_getfilename (aux_entry, objfile)
- union internal_auxent *aux_entry;
- struct objfile *objfile;
+coff_getfilename (union internal_auxent *aux_entry, struct objfile *objfile)
{
static char buffer[BUFSIZ];
/* Set *SYMBOL to symbol number symno in symtbl. */
static void
-read_symbol (symbol, symno)
- struct internal_syment *symbol;
- int symno;
+read_symbol (struct internal_syment *symbol, int symno)
{
int nsyms =
((struct coff_symfile_info *) this_symtab_psymtab->objfile->sym_private)
/* Get value corresponding to symbol number symno in symtbl. */
static CORE_ADDR
-read_symbol_nvalue (symno)
- int symno;
+read_symbol_nvalue (int symno)
{
struct internal_syment symbol[1];
symno is the symbol pointed to by the linetable. */
static int
-read_symbol_lineno (symno)
- int symno;
+read_symbol_lineno (int symno)
{
struct objfile *objfile = this_symtab_psymtab->objfile;
boolean xcoff64 = xcoff_data (objfile->obfd)->xcoff64;
* mainline code can read the whole thing for efficiency.
*/
static void
-find_linenos (abfd, asect, vpinfo)
- bfd *abfd;
- sec_ptr asect;
- PTR vpinfo;
+find_linenos (bfd *abfd, sec_ptr asect, PTR vpinfo)
{
struct coff_symfile_info *info;
int size, count;
static void xcoff_psymtab_to_symtab_1 (struct partial_symtab *);
static void
-xcoff_psymtab_to_symtab_1 (pst)
- struct partial_symtab *pst;
+xcoff_psymtab_to_symtab_1 (struct partial_symtab *pst)
{
struct cleanup *old_chain;
int i;
Be verbose about it if the user wants that. */
static void
-xcoff_psymtab_to_symtab (pst)
- struct partial_symtab *pst;
+xcoff_psymtab_to_symtab (struct partial_symtab *pst)
{
bfd *sym_bfd;
}
\f
static void
-xcoff_new_init (objfile)
- struct objfile *objfile;
+xcoff_new_init (struct objfile *objfile)
{
stabsread_new_init ();
buildsym_new_init ();
uses BFD's determination to vector to us. */
static void
-xcoff_symfile_init (objfile)
- struct objfile *objfile;
+xcoff_symfile_init (struct objfile *objfile)
{
/* Allocate struct to keep track of the symfile */
objfile->sym_private = xmmalloc (objfile->md,
objfile struct from the global list of known objfiles. */
static void
-xcoff_symfile_finish (objfile)
- struct objfile *objfile;
+xcoff_symfile_finish (struct objfile *objfile)
{
if (objfile->sym_private != NULL)
{
static void
-init_stringtab (abfd, offset, objfile)
- bfd *abfd;
- file_ptr offset;
- struct objfile *objfile;
+init_stringtab (bfd *abfd, file_ptr offset, struct objfile *objfile)
{
long length;
int val;
(normal). */
static struct partial_symtab *
-xcoff_start_psymtab (objfile, filename, first_symnum, global_syms,
- static_syms)
- struct objfile *objfile;
- char *filename;
- int first_symnum;
- struct partial_symbol **global_syms;
- struct partial_symbol **static_syms;
+xcoff_start_psymtab (struct objfile *objfile, char *filename, int first_symnum,
+ struct partial_symbol **global_syms,
+ struct partial_symbol **static_syms)
{
struct partial_symtab *result =
start_psymtab_common (objfile, objfile->section_offsets,
are the information for includes and dependencies. */
static struct partial_symtab *
-xcoff_end_psymtab (pst, include_list, num_includes, capping_symbol_number,
- dependency_list, number_dependencies, textlow_not_set)
- struct partial_symtab *pst;
- char **include_list;
- int num_includes;
- int capping_symbol_number;
- struct partial_symtab **dependency_list;
- int number_dependencies;
- int textlow_not_set;
+xcoff_end_psymtab (struct partial_symtab *pst, char **include_list,
+ int num_includes, int capping_symbol_number,
+ struct partial_symtab **dependency_list,
+ int number_dependencies, int textlow_not_set)
{
int i;
struct objfile *objfile = pst->objfile;
the symbol and its auxents. */
static void
-swap_sym (symbol, aux, name, raw, symnump, objfile)
- struct internal_syment *symbol;
- union internal_auxent *aux;
- char **name;
- char **raw;
- unsigned int *symnump;
- struct objfile *objfile;
+swap_sym (struct internal_syment *symbol, union internal_auxent *aux,
+ char **name, char **raw, unsigned int *symnump,
+ struct objfile *objfile)
{
bfd_coff_swap_sym_in (objfile->obfd, *raw, symbol);
if (symbol->n_zeroes)
}
static void
-scan_xcoff_symtab (objfile)
- struct objfile *objfile;
+scan_xcoff_symtab (struct objfile *objfile)
{
CORE_ADDR toc_offset = 0; /* toc offset value in data section. */
char *filestring = NULL;
/* Return the toc offset value for a given objfile. */
CORE_ADDR
-get_toc_offset (objfile)
- struct objfile *objfile;
+get_toc_offset (struct objfile *objfile)
{
if (objfile)
return ((struct coff_symfile_info *) objfile->sym_private)->toc_offset;
}
\f
static void
-xcoff_symfile_offsets (objfile, addrs)
- struct objfile *objfile;
- struct section_addr_info *addrs;
+xcoff_symfile_offsets (struct objfile *objfile, struct section_addr_info *addrs)
{
asection *sect = NULL;
int i;
};
void
-_initialize_xcoffread ()
+_initialize_xcoffread (void)
{
add_symtab_fns (&xcoff_sym_fns);
the section list. */
void
-solib_add (arg_string, from_tty, target)
- char *arg_string;
- int from_tty;
- struct target_ops *target;
+solib_add (char *arg_string, int from_tty, struct target_ops *target)
{
char *val;
struct vmap *vp = vmap;
is not persistent. */
char *
-pc_load_segment_name (addr)
- CORE_ADDR addr;
+pc_load_segment_name (CORE_ADDR addr)
{
static char buffer[BUFSIZ];
struct vmap *vp = vmap;
static void solib_info (char *, int);
static void
-solib_info (args, from_tty)
- char *args;
- int from_tty;
+solib_info (char *args, int from_tty)
{
struct vmap *vp = vmap;
}
void
-sharedlibrary_command (args, from_tty)
- char *args;
- int from_tty;
+sharedlibrary_command (char *args, int from_tty)
{
dont_repeat ();
}
void
-_initialize_solib ()
+_initialize_solib (void)
{
add_com ("sharedlibrary", class_files, sharedlibrary_command,
"Load shared object library symbols for files matching REGEXP.");
static int crcflag; /* Sez we are using CRC's instead of cksums */
static int
-readchar (desc, timeout)
- serial_t desc;
- int timeout;
+readchar (serial_t desc, int timeout)
{
int c;
/* Call this to init the fast CRC-16 calculation table. */
static void
-crcinit ()
+crcinit (void)
{
static int crctab_inited = 0;
int val;
/* Calculate a CRC-16 for the LEN byte message pointed at by P. */
static unsigned short
-docrc (p, len)
- unsigned char *p;
- int len;
+docrc (unsigned char *p, int len)
{
unsigned short crc = 0;
send NAK or CRC request. */
int
-xmodem_init_xfer (desc)
- serial_t desc;
+xmodem_init_xfer (serial_t desc)
{
int c;
int i;
*/
void
-xmodem_send_packet (desc, packet, len, hashmark)
- serial_t desc;
- unsigned char *packet;
- int len;
- int hashmark;
+xmodem_send_packet (serial_t desc, unsigned char *packet, int len, int hashmark)
{
int i;
int retries;
/* Finish off the transfer. Send out the EOT, and wait for an ACK. */
void
-xmodem_finish_xfer (desc)
- serial_t desc;
+xmodem_finish_xfer (serial_t desc)
{
int retries;
just use the register SRP_REGNUM itself. */
CORE_ADDR
-z8k_frame_saved_pc (frame)
- struct frame_info *frame;
+z8k_frame_saved_pc (struct frame_info *frame)
{
return read_memory_pointer (frame->frame + (BIG ? 4 : 2));
}
return the pc pointing to the first push */
static CORE_ADDR
-skip_adjust (pc, size)
- CORE_ADDR pc;
- int *size;
+skip_adjust (CORE_ADDR pc, int *size)
{
*size = 0;
static CORE_ADDR examine_frame (CORE_ADDR, CORE_ADDR * regs, CORE_ADDR);
static CORE_ADDR
-examine_frame (pc, regs, sp)
- CORE_ADDR pc;
- CORE_ADDR *regs;
- CORE_ADDR sp;
+examine_frame (CORE_ADDR pc, CORE_ADDR *regs, CORE_ADDR sp)
{
int w = read_memory_short (pc);
int offset = 0;
}
CORE_ADDR
-z8k_skip_prologue (start_pc)
- CORE_ADDR start_pc;
+z8k_skip_prologue (CORE_ADDR start_pc)
{
CORE_ADDR dummy[NUM_REGS];
}
CORE_ADDR
-z8k_addr_bits_remove (addr)
- CORE_ADDR addr;
+z8k_addr_bits_remove (CORE_ADDR addr)
{
return (addr & PTR_MASK);
}
}
CORE_ADDR
-z8k_frame_chain (thisframe)
- struct frame_info *thisframe;
+z8k_frame_chain (struct frame_info *thisframe)
{
if (thisframe->prev == 0)
{
}
void
-init_frame_pc ()
+init_frame_pc (void)
{
abort ();
}
the address we return for it IS the sp for the next frame. */
void
-z8k_frame_init_saved_regs (frame_info)
- struct frame_info *frame_info;
+z8k_frame_init_saved_regs (struct frame_info *frame_info)
{
CORE_ADDR pc;
int w;
}
void
-z8k_push_dummy_frame ()
+z8k_push_dummy_frame (void)
{
abort ();
}
int
-gdb_print_insn_z8k (memaddr, info)
- bfd_vma memaddr;
- disassemble_info *info;
+gdb_print_insn_z8k (bfd_vma memaddr, disassemble_info *info)
{
if (BIG)
return print_insn_z8001 (memaddr, info);
of the instruction. */
CORE_ADDR
-NEXT_PROLOGUE_INSN (addr, lim, pword1)
- CORE_ADDR addr;
- CORE_ADDR lim;
- short *pword1;
+NEXT_PROLOGUE_INSN (CORE_ADDR addr, CORE_ADDR lim, short *pword1)
{
char buf[2];
if (addr < lim + 8)
it is fairly expensive. */
void
-frame_find_saved_regs (fip, fsrp)
- struct frame_info *fip;
- struct frame_saved_regs *fsrp;
+frame_find_saved_regs (struct frame_info *fip, struct frame_saved_regs *fsrp)
{
int locals;
CORE_ADDR pc;
void
-extract_return_value (type, regbuf, valbuf)
- struct type *type;
- char *regbuf;
- char *valbuf;
+extract_return_value (struct type *type, char *regbuf, char *valbuf)
{
int b;
int len = TYPE_LENGTH (type);
}
void
-write_return_value (type, valbuf)
- struct type *type;
- char *valbuf;
+write_return_value (struct type *type, char *valbuf)
{
int reg;
int len;
}
void
-store_struct_return (addr, sp)
- CORE_ADDR addr;
- CORE_ADDR sp;
+store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
{
write_register (2, addr);
}
void
-z8k_print_register_hook (regno)
- int regno;
+z8k_print_register_hook (int regno)
{
if ((regno & 1) == 0 && regno < 16)
{
}
void
-z8k_pop_frame ()
+z8k_pop_frame (void)
{
}
struct cmd_list_element *setmemorylist;
void
-z8k_set_pointer_size (newsize)
- int newsize;
+z8k_set_pointer_size (int newsize)
{
static int oldsize = 0;
}
static void
-segmented_command (args, from_tty)
- char *args;
- int from_tty;
+segmented_command (char *args, int from_tty)
{
z8k_set_pointer_size (32);
}
static void
-unsegmented_command (args, from_tty)
- char *args;
- int from_tty;
+unsegmented_command (char *args, int from_tty)
{
z8k_set_pointer_size (16);
}
static void
-set_memory (args, from_tty)
- char *args;
- int from_tty;
+set_memory (char *args, int from_tty)
{
printf_unfiltered ("\"set memory\" must be followed by the name of a memory subcommand.\n");
help_list (setmemorylist, "set memory ", -1, gdb_stdout);
}
void
-_initialize_z8ktdep ()
+_initialize_z8ktdep (void)
{
tm_print_insn = gdb_print_insn_z8k;