mirror of
https://github.com/darlinghq/darling-gdb.git
synced 2025-02-02 06:54:54 +00:00
import gdb-1999-10-25 snapshot
This commit is contained in:
parent
4c1102fd19
commit
e514a9d642
@ -1,3 +1,74 @@
|
|||||||
|
Mon Oct 25 18:22:06 1999 Andrew Cagney <cagney@b1.cygnus.com>
|
||||||
|
|
||||||
|
* remote.c: Document future of compare_sections_command.
|
||||||
|
(remote_insert_breakpoint, remote_remove_breakpoint,
|
||||||
|
remote_insert_watchpoint, remote_insert_watchpoint,
|
||||||
|
remote_remove_watchpoint, remote_insert_hw_breakpoint,
|
||||||
|
remote_remove_hw_breakpoint): Use alloca instead of GCC's dynamic
|
||||||
|
array feature.
|
||||||
|
|
||||||
|
Mon Oct 25 18:08:31 1999 Andrew Cagney <cagney@b1.cygnus.com>
|
||||||
|
|
||||||
|
* gdbarch.h (REGISTER_GDBARCH_SWAP): Define.
|
||||||
|
* gdbarch.sh: Update.
|
||||||
|
|
||||||
|
Sat Oct 23 16:39:34 1999 Andrew Cagney <cagney@b1.cygnus.com>
|
||||||
|
|
||||||
|
* gdbarch.c (initialize_current_architecture): Make ``choice''
|
||||||
|
const.
|
||||||
|
|
||||||
|
1999-10-22 Tom Tromey <tromey@cygnus.com>
|
||||||
|
|
||||||
|
* gdbarch.sh: Updated for gdbarch.[ch] changes.
|
||||||
|
* top.c (gdb_init): Call initialize_current_architecture.
|
||||||
|
* gdbarch.h (initialize_current_architecture): Declare.
|
||||||
|
* gdbarch.c (initialize_current_architecture): New function.
|
||||||
|
|
||||||
|
1999-10-21 Michael Snyder <msnyder@cleaver.cygnus.com>
|
||||||
|
|
||||||
|
* utils.c (chars_per_line): fix typo in comment.
|
||||||
|
|
||||||
|
1999-10-21 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
|
||||||
|
|
||||||
|
* breakpoint.h (bp_print_how): New enum, used for deciding how to
|
||||||
|
print bpstat information when we stop, instead of having 3
|
||||||
|
different functions.
|
||||||
|
(struct bpstat): Change print_it field to be an enum instead of a
|
||||||
|
function pointer.
|
||||||
|
|
||||||
|
* breakpoint.c (print_it_typical): New name for print_it_normal().
|
||||||
|
(print_bp_stop_message): New function. High level routine for
|
||||||
|
printing of why we stopped.
|
||||||
|
(bpstat_print): Call print_bp_stop_message instead of using the
|
||||||
|
print_it function pointer.
|
||||||
|
(print_it_done, print_it_noop): Delete these functions.
|
||||||
|
|
||||||
|
1999-10-21 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
|
||||||
|
|
||||||
|
* breakpoint.c (print_it_normal): Reorganize into a switch
|
||||||
|
statement.
|
||||||
|
|
||||||
|
1999-10-21 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
|
||||||
|
|
||||||
|
* Makefile.in (event-top.o): Add dependency on target.h.
|
||||||
|
* event-top.c: Make dependency on target.h explicit.
|
||||||
|
|
||||||
|
* breakpoint.c (bpstat_print): Clean up logic. Remove recursion.
|
||||||
|
(catch_exec_command_1): Surround with appropriate ifdef's,
|
||||||
|
to avoid compiler warnings.
|
||||||
|
(catch_fork_command_1): Ditto.
|
||||||
|
|
||||||
|
1999-10-20 Jim Blandy <jimb@cris.red-bean.com>
|
||||||
|
|
||||||
|
* Makefile.in (dwarf2read.o): Note that this depends on bfd/elf-bfd.h.
|
||||||
|
(elf_bfd_h): New variable.
|
||||||
|
|
||||||
|
1999-10-19 Jim Blandy <jimb@zenia.red-bean.com>
|
||||||
|
|
||||||
|
* config/i386/tm-i386.h (REGISTER_NAMES): Change names of FPU
|
||||||
|
instruction and operand pointer registers to improve consistency,
|
||||||
|
following J. T. Conklin's suggestions.
|
||||||
|
|
||||||
1999-10-18 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
|
1999-10-18 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
|
||||||
|
|
||||||
* breakpoint.h: Change return type of field print_it of struct
|
* breakpoint.h: Change return type of field print_it of struct
|
||||||
|
@ -229,7 +229,7 @@ CDEPS = $(XM_CDEPS) $(TM_CDEPS) $(NAT_CDEPS) $(SIM) $(BFD) $(READLINE) \
|
|||||||
ADD_FILES = $(REGEX) $(XM_ADD_FILES) $(TM_ADD_FILES) $(NAT_ADD_FILES)
|
ADD_FILES = $(REGEX) $(XM_ADD_FILES) $(TM_ADD_FILES) $(NAT_ADD_FILES)
|
||||||
ADD_DEPS = $(REGEX1) $(XM_ADD_FILES) $(TM_ADD_FILES) $(NAT_ADD_FILES)
|
ADD_DEPS = $(REGEX1) $(XM_ADD_FILES) $(TM_ADD_FILES) $(NAT_ADD_FILES)
|
||||||
|
|
||||||
VERSION = 19991018
|
VERSION = 19991025
|
||||||
DIST=gdb
|
DIST=gdb
|
||||||
|
|
||||||
LINT=/usr/5bin/lint
|
LINT=/usr/5bin/lint
|
||||||
@ -414,6 +414,7 @@ LINTFILES = $(SFILES) $(YYFILES) @CONFIG_SRCS@ init.c
|
|||||||
getopt_h = $(INCLUDE_DIR)/getopt.h
|
getopt_h = $(INCLUDE_DIR)/getopt.h
|
||||||
floatformat_h = $(INCLUDE_DIR)/floatformat.h
|
floatformat_h = $(INCLUDE_DIR)/floatformat.h
|
||||||
bfd_h = $(BFD_DIR)/bfd.h
|
bfd_h = $(BFD_DIR)/bfd.h
|
||||||
|
elf_bfd_h = $(BFD_DIR)/elf-bfd.h
|
||||||
wait_h = $(INCLUDE_DIR)/wait.h
|
wait_h = $(INCLUDE_DIR)/wait.h
|
||||||
dis-asm_h = $(INCLUDE_DIR)/dis-asm.h
|
dis-asm_h = $(INCLUDE_DIR)/dis-asm.h
|
||||||
remote-sim_h = $(INCLUDE_DIR)/remote-sim.h
|
remote-sim_h = $(INCLUDE_DIR)/remote-sim.h
|
||||||
@ -1121,7 +1122,7 @@ dwarfread.o: dwarfread.c $(bfd_h) buildsym.h complaints.h $(defs_h) \
|
|||||||
$(expression_h) $(gdbtypes_h) language.h objfiles.h symfile.h \
|
$(expression_h) $(gdbtypes_h) language.h objfiles.h symfile.h \
|
||||||
$(symtab_h) gdb_string.h
|
$(symtab_h) gdb_string.h
|
||||||
|
|
||||||
dwarf2read.o: dwarf2read.c $(bfd_h) buildsym.h $(defs_h) \
|
dwarf2read.o: dwarf2read.c $(bfd_h) $(elf_bfd_h) buildsym.h $(defs_h) \
|
||||||
$(expression_h) $(gdbtypes_h) language.h objfiles.h symfile.h \
|
$(expression_h) $(gdbtypes_h) language.h objfiles.h symfile.h \
|
||||||
$(symtab_h) gdb_string.h
|
$(symtab_h) gdb_string.h
|
||||||
|
|
||||||
@ -1139,7 +1140,7 @@ event-loop.o: event-loop.c $(defs_h) $(top_h) $(event_loop_h) $(event_top_h)
|
|||||||
|
|
||||||
event-top.o: event-top.c top.h $(readline_headers) \
|
event-top.o: event-top.c top.h $(readline_headers) \
|
||||||
$(defs_h) $(inferior_h) $(event_loop_h) $(event_top_h) terminal.h \
|
$(defs_h) $(inferior_h) $(event_loop_h) $(event_top_h) terminal.h \
|
||||||
$(gdbcmd_h)
|
$(gdbcmd_h) target.h
|
||||||
|
|
||||||
inf-loop.o: inf-loop.c $(defs_h) $(inferior_h) $(inf_loop_h) $(event_loop_h) \
|
inf-loop.o: inf-loop.c $(defs_h) $(inferior_h) $(inf_loop_h) $(event_loop_h) \
|
||||||
$(event_top_h)
|
$(event_top_h)
|
||||||
|
347
gdb/breakpoint.c
347
gdb/breakpoint.c
@ -157,7 +157,9 @@ insertion_state_t;
|
|||||||
static int
|
static int
|
||||||
remove_breakpoint PARAMS ((struct breakpoint *, insertion_state_t));
|
remove_breakpoint PARAMS ((struct breakpoint *, insertion_state_t));
|
||||||
|
|
||||||
static enum print_stop_action print_it_normal PARAMS ((bpstat));
|
static enum print_stop_action print_it_typical PARAMS ((bpstat));
|
||||||
|
|
||||||
|
static enum print_stop_action print_bp_stop_message (bpstat bs);
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
@ -170,10 +172,6 @@ static int watchpoint_check PARAMS ((PTR));
|
|||||||
|
|
||||||
static int cover_target_enable_exception_callback PARAMS ((PTR));
|
static int cover_target_enable_exception_callback PARAMS ((PTR));
|
||||||
|
|
||||||
static enum print_stop_action print_it_done PARAMS ((bpstat));
|
|
||||||
|
|
||||||
static enum print_stop_action print_it_noop PARAMS ((bpstat));
|
|
||||||
|
|
||||||
static void maintenance_info_breakpoints PARAMS ((char *, int));
|
static void maintenance_info_breakpoints PARAMS ((char *, int));
|
||||||
|
|
||||||
#ifdef GET_LONGJMP_TARGET
|
#ifdef GET_LONGJMP_TARGET
|
||||||
@ -226,8 +224,10 @@ static char *ep_parse_optional_if_clause PARAMS ((char **arg));
|
|||||||
|
|
||||||
static char *ep_parse_optional_filename PARAMS ((char **arg));
|
static char *ep_parse_optional_filename PARAMS ((char **arg));
|
||||||
|
|
||||||
|
#if defined(CHILD_INSERT_EXEC_CATCHPOINT)
|
||||||
static void catch_exec_command_1 PARAMS ((char *arg, int tempflag,
|
static void catch_exec_command_1 PARAMS ((char *arg, int tempflag,
|
||||||
int from_tty));
|
int from_tty));
|
||||||
|
#endif
|
||||||
|
|
||||||
static void create_exception_catchpoint
|
static void create_exception_catchpoint
|
||||||
PARAMS ((int tempflag, char *cond_string,
|
PARAMS ((int tempflag, char *cond_string,
|
||||||
@ -1740,91 +1740,98 @@ top:
|
|||||||
discard_cleanups (old_chain);
|
discard_cleanups (old_chain);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This is the normal print_it function for a bpstat. In the future,
|
/* This is the normal print function for a bpstat. In the future,
|
||||||
much of this logic could (should?) be moved to bpstat_stop_status,
|
much of this logic could (should?) be moved to bpstat_stop_status,
|
||||||
by having it set different print_it functions.
|
by having it set different print_it values.
|
||||||
|
|
||||||
Current scheme: When we stop, bpstat_print() is called.
|
Current scheme: When we stop, bpstat_print() is called. It loops
|
||||||
It loops through the bpstat list of things causing this stop,
|
through the bpstat list of things causing this stop, calling the
|
||||||
calling the print_it function for each one. The default
|
print_bp_stop_message function on each one. The behavior of the
|
||||||
print_it function, used for breakpoints, is print_it_normal().
|
print_bp_stop_message function depends on the print_it field of
|
||||||
(Also see print_it_noop() and print_it_done()).
|
bpstat. If such field so indicates, call this function here.
|
||||||
|
|
||||||
Return values from this routine (used by bpstat_print() to
|
Return values from this routine (ultimately used by bpstat_print()
|
||||||
decide what to do):
|
and normal_stop() to decide what to do):
|
||||||
PRINT_NOTHING: Means we already printed all we needed to print, don't
|
PRINT_NOTHING: Means we already printed all we needed to print,
|
||||||
print anything else.
|
don't print anything else.
|
||||||
PRINT_SRC_ONLY: Means we printed something, and we do *not* desire that
|
PRINT_SRC_ONLY: Means we printed something, and we do *not* desire
|
||||||
something to be followed by a location.
|
that something to be followed by a location.
|
||||||
PRINT_SCR_AND_LOC: Means we printed something, and we *do* desire that
|
PRINT_SCR_AND_LOC: Means we printed something, and we *do* desire
|
||||||
something to be followed by a location.
|
that something to be followed by a location.
|
||||||
PRINT_UNKNOWN: Means we printed nothing or we need to do some more analysis. */
|
PRINT_UNKNOWN: Means we printed nothing or we need to do some more
|
||||||
|
analysis. */
|
||||||
|
|
||||||
static enum print_stop_action
|
static enum print_stop_action
|
||||||
print_it_normal (bs)
|
print_it_typical (bs)
|
||||||
bpstat bs;
|
bpstat bs;
|
||||||
{
|
{
|
||||||
/* bs->breakpoint_at can be NULL if it was a momentary breakpoint
|
/* bs->breakpoint_at can be NULL if it was a momentary breakpoint
|
||||||
which has since been deleted. */
|
which has since been deleted. */
|
||||||
if (bs->breakpoint_at == NULL
|
if (bs->breakpoint_at == NULL)
|
||||||
|| (bs->breakpoint_at->type != bp_breakpoint
|
|
||||||
&& bs->breakpoint_at->type != bp_shlib_event
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_load
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_unload
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_fork
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_vfork
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_exec
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_catch
|
|
||||||
&& bs->breakpoint_at->type != bp_catch_throw
|
|
||||||
&& bs->breakpoint_at->type != bp_hardware_breakpoint
|
|
||||||
&& bs->breakpoint_at->type != bp_watchpoint
|
|
||||||
&& bs->breakpoint_at->type != bp_read_watchpoint
|
|
||||||
&& bs->breakpoint_at->type != bp_access_watchpoint
|
|
||||||
&& bs->breakpoint_at->type != bp_hardware_watchpoint))
|
|
||||||
return PRINT_UNKNOWN;
|
return PRINT_UNKNOWN;
|
||||||
|
|
||||||
if (ep_is_shlib_catchpoint (bs->breakpoint_at))
|
switch (bs->breakpoint_at->type)
|
||||||
{
|
{
|
||||||
annotate_catchpoint (bs->breakpoint_at->number);
|
case bp_breakpoint:
|
||||||
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
case bp_hardware_breakpoint:
|
||||||
if (bs->breakpoint_at->type == bp_catch_load)
|
/* I think the user probably only wants to see one breakpoint
|
||||||
printf_filtered ("loaded");
|
number, not all of them. */
|
||||||
else if (bs->breakpoint_at->type == bp_catch_unload)
|
annotate_breakpoint (bs->breakpoint_at->number);
|
||||||
printf_filtered ("unloaded");
|
printf_filtered ("\nBreakpoint %d, ", bs->breakpoint_at->number);
|
||||||
printf_filtered (" %s), ", bs->breakpoint_at->triggered_dll_pathname);
|
|
||||||
return PRINT_SRC_AND_LOC;
|
return PRINT_SRC_AND_LOC;
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_shlib_event)
|
|
||||||
{
|
case bp_shlib_event:
|
||||||
/* Did we stop because the user set the stop_on_solib_events
|
/* Did we stop because the user set the stop_on_solib_events
|
||||||
variable? (If so, we report this as a generic, "Stopped due
|
variable? (If so, we report this as a generic, "Stopped due
|
||||||
to shlib event" message.) */
|
to shlib event" message.) */
|
||||||
printf_filtered ("Stopped due to shared library event\n");
|
printf_filtered ("Stopped due to shared library event\n");
|
||||||
return PRINT_NOTHING;
|
return PRINT_NOTHING;
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_catch_fork ||
|
|
||||||
bs->breakpoint_at->type == bp_catch_vfork)
|
case bp_catch_load:
|
||||||
{
|
|
||||||
annotate_catchpoint (bs->breakpoint_at->number);
|
annotate_catchpoint (bs->breakpoint_at->number);
|
||||||
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
||||||
if (bs->breakpoint_at->type == bp_catch_fork)
|
printf_filtered ("loaded");
|
||||||
printf_filtered ("forked");
|
printf_filtered (" %s), ", bs->breakpoint_at->triggered_dll_pathname);
|
||||||
else if (bs->breakpoint_at->type == bp_catch_vfork)
|
return PRINT_SRC_AND_LOC;
|
||||||
printf_filtered ("vforked");
|
break;
|
||||||
|
|
||||||
|
case bp_catch_unload:
|
||||||
|
annotate_catchpoint (bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("unloaded");
|
||||||
|
printf_filtered (" %s), ", bs->breakpoint_at->triggered_dll_pathname);
|
||||||
|
return PRINT_SRC_AND_LOC;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case bp_catch_fork:
|
||||||
|
annotate_catchpoint (bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("forked");
|
||||||
printf_filtered (" process %d), ",
|
printf_filtered (" process %d), ",
|
||||||
bs->breakpoint_at->forked_inferior_pid);
|
bs->breakpoint_at->forked_inferior_pid);
|
||||||
return PRINT_SRC_AND_LOC;
|
return PRINT_SRC_AND_LOC;
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_catch_exec)
|
|
||||||
{
|
case bp_catch_vfork:
|
||||||
|
annotate_catchpoint (bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("\nCatchpoint %d (", bs->breakpoint_at->number);
|
||||||
|
printf_filtered ("vforked");
|
||||||
|
printf_filtered (" process %d), ",
|
||||||
|
bs->breakpoint_at->forked_inferior_pid);
|
||||||
|
return PRINT_SRC_AND_LOC;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case bp_catch_exec:
|
||||||
annotate_catchpoint (bs->breakpoint_at->number);
|
annotate_catchpoint (bs->breakpoint_at->number);
|
||||||
printf_filtered ("\nCatchpoint %d (exec'd %s), ",
|
printf_filtered ("\nCatchpoint %d (exec'd %s), ",
|
||||||
bs->breakpoint_at->number,
|
bs->breakpoint_at->number,
|
||||||
bs->breakpoint_at->exec_pathname);
|
bs->breakpoint_at->exec_pathname);
|
||||||
return PRINT_SRC_AND_LOC;
|
return PRINT_SRC_AND_LOC;
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_catch_catch)
|
|
||||||
{
|
case bp_catch_catch:
|
||||||
if (current_exception_event &&
|
if (current_exception_event &&
|
||||||
(CURRENT_EXCEPTION_KIND == EX_EVENT_CATCH))
|
(CURRENT_EXCEPTION_KIND == EX_EVENT_CATCH))
|
||||||
{
|
{
|
||||||
@ -1848,15 +1855,17 @@ print_it_normal (bs)
|
|||||||
printf_filtered ("unknown");
|
printf_filtered ("unknown");
|
||||||
|
|
||||||
printf_filtered ("\n");
|
printf_filtered ("\n");
|
||||||
return PRINT_SRC_ONLY; /* don't bother to print location frame info */
|
/* don't bother to print location frame info */
|
||||||
|
return PRINT_SRC_ONLY;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return PRINT_UNKNOWN; /* really throw, some other bpstat will handle it */
|
/* really throw, some other bpstat will handle it */
|
||||||
|
return PRINT_UNKNOWN;
|
||||||
}
|
}
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_catch_throw)
|
|
||||||
{
|
case bp_catch_throw:
|
||||||
if (current_exception_event &&
|
if (current_exception_event &&
|
||||||
(CURRENT_EXCEPTION_KIND == EX_EVENT_THROW))
|
(CURRENT_EXCEPTION_KIND == EX_EVENT_THROW))
|
||||||
{
|
{
|
||||||
@ -1880,64 +1889,122 @@ print_it_normal (bs)
|
|||||||
printf_filtered ("unknown");
|
printf_filtered ("unknown");
|
||||||
|
|
||||||
printf_filtered ("\n");
|
printf_filtered ("\n");
|
||||||
return PRINT_SRC_ONLY; /* don't bother to print location frame info */
|
/* don't bother to print location frame info */
|
||||||
|
return PRINT_SRC_ONLY;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return PRINT_UNKNOWN; /* really catch, some other bpstat willhandle it */
|
/* really catch, some other bpstat will handle it */
|
||||||
|
return PRINT_UNKNOWN;
|
||||||
}
|
}
|
||||||
}
|
break;
|
||||||
|
|
||||||
else if (bs->breakpoint_at->type == bp_breakpoint ||
|
case bp_watchpoint:
|
||||||
bs->breakpoint_at->type == bp_hardware_breakpoint)
|
case bp_hardware_watchpoint:
|
||||||
{
|
if (bs->old_val != NULL)
|
||||||
/* I think the user probably only wants to see one breakpoint
|
{
|
||||||
number, not all of them. */
|
annotate_watchpoint (bs->breakpoint_at->number);
|
||||||
annotate_breakpoint (bs->breakpoint_at->number);
|
mention (bs->breakpoint_at);
|
||||||
printf_filtered ("\nBreakpoint %d, ", bs->breakpoint_at->number);
|
printf_filtered ("\nOld value = ");
|
||||||
return PRINT_SRC_AND_LOC;
|
value_print (bs->old_val, gdb_stdout, 0, Val_pretty_default);
|
||||||
}
|
printf_filtered ("\nNew value = ");
|
||||||
else if ((bs->old_val != NULL) &&
|
value_print (bs->breakpoint_at->val, gdb_stdout, 0,
|
||||||
(bs->breakpoint_at->type == bp_watchpoint ||
|
Val_pretty_default);
|
||||||
bs->breakpoint_at->type == bp_access_watchpoint ||
|
printf_filtered ("\n");
|
||||||
bs->breakpoint_at->type == bp_hardware_watchpoint))
|
value_free (bs->old_val);
|
||||||
{
|
bs->old_val = NULL;
|
||||||
annotate_watchpoint (bs->breakpoint_at->number);
|
}
|
||||||
mention (bs->breakpoint_at);
|
|
||||||
printf_filtered ("\nOld value = ");
|
|
||||||
value_print (bs->old_val, gdb_stdout, 0, Val_pretty_default);
|
|
||||||
printf_filtered ("\nNew value = ");
|
|
||||||
value_print (bs->breakpoint_at->val, gdb_stdout, 0,
|
|
||||||
Val_pretty_default);
|
|
||||||
printf_filtered ("\n");
|
|
||||||
value_free (bs->old_val);
|
|
||||||
bs->old_val = NULL;
|
|
||||||
/* More than one watchpoint may have been triggered. */
|
/* More than one watchpoint may have been triggered. */
|
||||||
return PRINT_UNKNOWN;
|
return PRINT_UNKNOWN;
|
||||||
}
|
break;
|
||||||
else if (bs->breakpoint_at->type == bp_access_watchpoint ||
|
|
||||||
bs->breakpoint_at->type == bp_read_watchpoint)
|
case bp_read_watchpoint:
|
||||||
{
|
|
||||||
mention (bs->breakpoint_at);
|
mention (bs->breakpoint_at);
|
||||||
printf_filtered ("\nValue = ");
|
printf_filtered ("\nValue = ");
|
||||||
value_print (bs->breakpoint_at->val, gdb_stdout, 0,
|
value_print (bs->breakpoint_at->val, gdb_stdout, 0,
|
||||||
Val_pretty_default);
|
Val_pretty_default);
|
||||||
printf_filtered ("\n");
|
printf_filtered ("\n");
|
||||||
return PRINT_UNKNOWN;
|
return PRINT_UNKNOWN;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case bp_access_watchpoint:
|
||||||
|
if (bs->old_val != NULL)
|
||||||
|
{
|
||||||
|
annotate_watchpoint (bs->breakpoint_at->number);
|
||||||
|
mention (bs->breakpoint_at);
|
||||||
|
printf_filtered ("\nOld value = ");
|
||||||
|
value_print (bs->old_val, gdb_stdout, 0, Val_pretty_default);
|
||||||
|
value_free (bs->old_val);
|
||||||
|
bs->old_val = NULL;
|
||||||
|
printf_filtered ("\nNew value = ");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
mention (bs->breakpoint_at);
|
||||||
|
printf_filtered ("\nValue = ");
|
||||||
|
}
|
||||||
|
value_print (bs->breakpoint_at->val, gdb_stdout, 0,
|
||||||
|
Val_pretty_default);
|
||||||
|
printf_filtered ("\n");
|
||||||
|
return PRINT_UNKNOWN;
|
||||||
|
break;
|
||||||
|
/* Fall through, we don't deal with these types of breakpoints
|
||||||
|
here. */
|
||||||
|
|
||||||
|
case bp_none:
|
||||||
|
case bp_until:
|
||||||
|
case bp_finish:
|
||||||
|
case bp_longjmp:
|
||||||
|
case bp_longjmp_resume:
|
||||||
|
case bp_step_resume:
|
||||||
|
case bp_through_sigtramp:
|
||||||
|
case bp_watchpoint_scope:
|
||||||
|
case bp_call_dummy:
|
||||||
|
default:
|
||||||
|
return PRINT_UNKNOWN;
|
||||||
}
|
}
|
||||||
/* We can't deal with it.
|
|
||||||
Maybe another member of the bpstat chain can. */
|
|
||||||
return PRINT_UNKNOWN;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Print a message indicating what happened.
|
/* Generic routine for printing messages indicating why we
|
||||||
This is called from normal_stop().
|
stopped. The behavior of this function depends on the value
|
||||||
The input to this routine is the head of the bpstat list - a list
|
'print_it' in the bpstat structure. Under some circumstances we
|
||||||
of the eventpoints that caused this stop.
|
may decide not to print anything here and delegate the task to
|
||||||
This routine calls the "print_it" routine(s) associated
|
normal_stop(). */
|
||||||
with these eventpoints. This will print (for example)
|
|
||||||
the "Breakpoint n," part of the output.
|
static enum print_stop_action
|
||||||
The return value of this routine is one of:
|
print_bp_stop_message (bpstat bs)
|
||||||
|
{
|
||||||
|
switch (bs->print_it)
|
||||||
|
{
|
||||||
|
case print_it_noop:
|
||||||
|
/* Nothing should be printed for this bpstat entry. */
|
||||||
|
return PRINT_UNKNOWN;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case print_it_done:
|
||||||
|
/* We still want to print the frame, but we already printed the
|
||||||
|
relevant messages. */
|
||||||
|
return PRINT_SRC_AND_LOC;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case print_it_normal:
|
||||||
|
/* Normal case, we handle everything in print_it_typical. */
|
||||||
|
return print_it_typical (bs);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
internal_error ("print_bp_stop_message: unrecognized enum value");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Print a message indicating what happened. This is called from
|
||||||
|
normal_stop(). The input to this routine is the head of the bpstat
|
||||||
|
list - a list of the eventpoints that caused this stop. This
|
||||||
|
routine calls the generic print routine for printing a message
|
||||||
|
about reasons for stopping. This will print (for example) the
|
||||||
|
"Breakpoint n," part of the output. The return value of this
|
||||||
|
routine is one of:
|
||||||
|
|
||||||
PRINT_UNKNOWN: Means we printed nothing
|
PRINT_UNKNOWN: Means we printed nothing
|
||||||
PRINT_SRC_AND_LOC: Means we printed something, and expect subsequent
|
PRINT_SRC_AND_LOC: Means we printed something, and expect subsequent
|
||||||
@ -1957,21 +2024,21 @@ bpstat_print (bs)
|
|||||||
{
|
{
|
||||||
int val;
|
int val;
|
||||||
|
|
||||||
if (bs == NULL)
|
|
||||||
return PRINT_UNKNOWN;
|
|
||||||
|
|
||||||
val = (*bs->print_it) (bs);
|
|
||||||
if (val == PRINT_SRC_ONLY || val == PRINT_SRC_AND_LOC || val == PRINT_NOTHING)
|
|
||||||
return val;
|
|
||||||
|
|
||||||
/* Maybe another breakpoint in the chain caused us to stop.
|
/* Maybe another breakpoint in the chain caused us to stop.
|
||||||
(Currently all watchpoints go on the bpstat whether hit or not.
|
(Currently all watchpoints go on the bpstat whether hit or not.
|
||||||
That probably could (should) be changed, provided care is taken
|
That probably could (should) be changed, provided care is taken
|
||||||
with respect to bpstat_explains_signal). */
|
with respect to bpstat_explains_signal). */
|
||||||
if (bs->next)
|
for (; bs; bs = bs->next)
|
||||||
return bpstat_print (bs->next);
|
{
|
||||||
|
val = print_bp_stop_message (bs);
|
||||||
|
if (val == PRINT_SRC_ONLY
|
||||||
|
|| val == PRINT_SRC_AND_LOC
|
||||||
|
|| val == PRINT_NOTHING)
|
||||||
|
return val;
|
||||||
|
}
|
||||||
|
|
||||||
/* We reached the end of the chain without printing anything. */
|
/* We reached the end of the chain, or we got a null BS to start
|
||||||
|
with and nothing was printed. */
|
||||||
return PRINT_UNKNOWN;
|
return PRINT_UNKNOWN;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2098,40 +2165,6 @@ which its expression is valid.\n", bs->breakpoint_at->number);
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This is used when everything which needs to be printed has
|
|
||||||
already been printed. But we still want to print the frame. */
|
|
||||||
|
|
||||||
/* Background: When we stop, bpstat_print() is called.
|
|
||||||
It loops through the bpstat list of things causing this stop,
|
|
||||||
calling the print_it function for each one. The default
|
|
||||||
print_it function, used for breakpoints, is print_it_normal().
|
|
||||||
Also see print_it_noop() and print_it_done() are the other
|
|
||||||
two possibilities. See comments in bpstat_print() and
|
|
||||||
in header of print_it_normal() for more detail. */
|
|
||||||
|
|
||||||
static enum print_stop_action
|
|
||||||
print_it_done (bs)
|
|
||||||
bpstat bs;
|
|
||||||
{
|
|
||||||
return PRINT_SRC_AND_LOC;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This is used when nothing should be printed for this bpstat entry. */
|
|
||||||
/* Background: When we stop, bpstat_print() is called.
|
|
||||||
It loops through the bpstat list of things causing this stop,
|
|
||||||
calling the print_it function for each one. The default
|
|
||||||
print_it function, used for breakpoints, is print_it_normal().
|
|
||||||
Also see print_it_noop() and print_it_done() are the other
|
|
||||||
two possibilities. See comments in bpstat_print() and
|
|
||||||
in header of print_it_normal() for more detail. */
|
|
||||||
|
|
||||||
static enum print_stop_action
|
|
||||||
print_it_noop (bs)
|
|
||||||
bpstat bs;
|
|
||||||
{
|
|
||||||
return PRINT_UNKNOWN;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Get a bpstat associated with having just stopped at address *PC
|
/* Get a bpstat associated with having just stopped at address *PC
|
||||||
and frame address CORE_ADDRESS. Update *PC to point at the
|
and frame address CORE_ADDRESS. Update *PC to point at the
|
||||||
breakpoint (if we hit a breakpoint). NOT_A_BREAKPOINT is nonzero
|
breakpoint (if we hit a breakpoint). NOT_A_BREAKPOINT is nonzero
|
||||||
@ -5139,6 +5172,7 @@ typedef enum
|
|||||||
}
|
}
|
||||||
catch_fork_kind;
|
catch_fork_kind;
|
||||||
|
|
||||||
|
#if defined(CHILD_INSERT_FORK_CATCHPOINT) || defined(CHILD_INSERT_VFORK_CATCHPOINT)
|
||||||
static void catch_fork_command_1 PARAMS ((catch_fork_kind fork_kind,
|
static void catch_fork_command_1 PARAMS ((catch_fork_kind fork_kind,
|
||||||
char *arg,
|
char *arg,
|
||||||
int tempflag,
|
int tempflag,
|
||||||
@ -5180,7 +5214,9 @@ catch_fork_command_1 (fork_kind, arg, tempflag, from_tty)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(CHILD_INSERT_EXEC_CATCHPOINT)
|
||||||
static void
|
static void
|
||||||
catch_exec_command_1 (arg, tempflag, from_tty)
|
catch_exec_command_1 (arg, tempflag, from_tty)
|
||||||
char *arg;
|
char *arg;
|
||||||
@ -5205,6 +5241,7 @@ catch_exec_command_1 (arg, tempflag, from_tty)
|
|||||||
and enable reporting of such events. */
|
and enable reporting of such events. */
|
||||||
create_exec_event_catchpoint (tempflag, cond_string);
|
create_exec_event_catchpoint (tempflag, cond_string);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(SOLIB_ADD)
|
#if defined(SOLIB_ADD)
|
||||||
static void
|
static void
|
||||||
|
@ -434,6 +434,22 @@ extern void bpstat_clear_actions PARAMS ((bpstat));
|
|||||||
extern void bpstat_get_triggered_catchpoints PARAMS ((bpstat, bpstat *));
|
extern void bpstat_get_triggered_catchpoints PARAMS ((bpstat, bpstat *));
|
||||||
|
|
||||||
/* Implementation: */
|
/* Implementation: */
|
||||||
|
|
||||||
|
/* Values used to tell the printing routine how to behave for this bpstat. */
|
||||||
|
enum bp_print_how
|
||||||
|
{
|
||||||
|
/* This is used when we want to do a normal printing of the reason
|
||||||
|
for stopping. The output will depend on the type of eventpoint
|
||||||
|
we are dealing with. This is the default value, most commonly
|
||||||
|
used. */
|
||||||
|
print_it_normal,
|
||||||
|
/* This is used when nothing should be printed for this bpstat entry. */
|
||||||
|
print_it_noop,
|
||||||
|
/* This is used when everything which needs to be printed has
|
||||||
|
already been printed. But we still want to print the frame. */
|
||||||
|
print_it_done
|
||||||
|
};
|
||||||
|
|
||||||
struct bpstats
|
struct bpstats
|
||||||
{
|
{
|
||||||
/* Linked list because there can be two breakpoints at the same
|
/* Linked list because there can be two breakpoints at the same
|
||||||
@ -452,10 +468,9 @@ struct bpstats
|
|||||||
/* Nonzero if this breakpoint tells us to stop. */
|
/* Nonzero if this breakpoint tells us to stop. */
|
||||||
char stop;
|
char stop;
|
||||||
|
|
||||||
/* Function called by bpstat_print to print stuff associated with
|
/* Tell bpstat_print and print_bp_stop_message how to print stuff
|
||||||
this element of the bpstat chain. Returns 0 or 1 just like
|
associated with this element of the bpstat chain. */
|
||||||
bpstat_print, or -1 if it can't deal with it. */
|
enum bp_print_how print_it;
|
||||||
enum print_stop_action (*print_it) PARAMS ((bpstat bs));
|
|
||||||
};
|
};
|
||||||
|
|
||||||
enum inf_context
|
enum inf_context
|
||||||
|
@ -123,8 +123,8 @@ extern int i386_skip_prologue PARAMS ((int));
|
|||||||
"ds", "es", "fs", "gs", \
|
"ds", "es", "fs", "gs", \
|
||||||
"st0", "st1", "st2", "st3", \
|
"st0", "st1", "st2", "st3", \
|
||||||
"st4", "st5", "st6", "st7", \
|
"st4", "st5", "st6", "st7", \
|
||||||
"fctrl", "fstat", "ftag", "fcs", \
|
"fctrl", "fstat", "ftag", "fiseg", \
|
||||||
"fcoff", "fds", "fdoff", "fop", \
|
"fioff", "foseg", "fooff", "fop", \
|
||||||
"xmm0", "xmm1", "xmm2", "xmm3", \
|
"xmm0", "xmm1", "xmm2", "xmm3", \
|
||||||
"xmm4", "xmm5", "xmm6", "xmm7", \
|
"xmm4", "xmm5", "xmm6", "xmm7", \
|
||||||
"mxcsr" \
|
"mxcsr" \
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
#include "defs.h"
|
#include "defs.h"
|
||||||
#include "top.h"
|
#include "top.h"
|
||||||
#include "inferior.h"
|
#include "inferior.h"
|
||||||
|
#include "target.h"
|
||||||
#include "terminal.h" /* for job_control */
|
#include "terminal.h" /* for job_control */
|
||||||
#include "signals.h"
|
#include "signals.h"
|
||||||
#include "event-loop.h"
|
#include "event-loop.h"
|
||||||
|
@ -3161,6 +3161,35 @@ int sizeof_call_dummy_words = sizeof (call_dummy_words);
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* Initialize the current architecture. */
|
||||||
|
void
|
||||||
|
initialize_current_architecture ()
|
||||||
|
{
|
||||||
|
if (GDB_MULTI_ARCH)
|
||||||
|
{
|
||||||
|
struct gdbarch_init_registration *rego;
|
||||||
|
const struct bfd_arch_info *chosen = NULL;
|
||||||
|
for (rego = gdbarch_init_registrary; rego != NULL; rego = rego->next)
|
||||||
|
{
|
||||||
|
const struct bfd_arch_info *ap
|
||||||
|
= bfd_lookup_arch (rego->bfd_architecture, 0);
|
||||||
|
|
||||||
|
/* Choose the first architecture alphabetically. */
|
||||||
|
if (chosen == NULL
|
||||||
|
|| strcmp (ap->printable_name, chosen->printable_name) < 0)
|
||||||
|
chosen = ap;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (chosen != NULL)
|
||||||
|
{
|
||||||
|
struct gdbarch_info info;
|
||||||
|
memset (&info, 0, sizeof info);
|
||||||
|
info.bfd_arch_info = chosen;
|
||||||
|
gdbarch_update (info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
extern void _initialize_gdbarch (void);
|
extern void _initialize_gdbarch (void);
|
||||||
void
|
void
|
||||||
_initialize_gdbarch ()
|
_initialize_gdbarch ()
|
||||||
|
@ -948,6 +948,7 @@ extern void *gdbarch_data (struct gdbarch_data*);
|
|||||||
|
|
||||||
typedef void (gdbarch_swap_ftype) (void);
|
typedef void (gdbarch_swap_ftype) (void);
|
||||||
extern void register_gdbarch_swap (void *data, unsigned long size, gdbarch_swap_ftype *init);
|
extern void register_gdbarch_swap (void *data, unsigned long size, gdbarch_swap_ftype *init);
|
||||||
|
#define REGISTER_GDBARCH_SWAP(VAR) register_gdbarch_swap (&(VAR), sizeof ((VAR)), NULL)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -1097,6 +1098,11 @@ extern void set_gdbarch_from_file (bfd *);
|
|||||||
extern void set_architecture_from_arch_mach (enum bfd_architecture, unsigned long);
|
extern void set_architecture_from_arch_mach (enum bfd_architecture, unsigned long);
|
||||||
|
|
||||||
|
|
||||||
|
/* Initialize the current architecture to the "first" one we find on
|
||||||
|
our list. */
|
||||||
|
|
||||||
|
extern void initialize_current_architecture (void);
|
||||||
|
|
||||||
/* Helper function for targets that don't know how my arguments are
|
/* Helper function for targets that don't know how my arguments are
|
||||||
being passed */
|
being passed */
|
||||||
|
|
||||||
|
@ -564,6 +564,7 @@ extern void *gdbarch_data (struct gdbarch_data*);
|
|||||||
|
|
||||||
typedef void (gdbarch_swap_ftype) (void);
|
typedef void (gdbarch_swap_ftype) (void);
|
||||||
extern void register_gdbarch_swap (void *data, unsigned long size, gdbarch_swap_ftype *init);
|
extern void register_gdbarch_swap (void *data, unsigned long size, gdbarch_swap_ftype *init);
|
||||||
|
#define REGISTER_GDBARCH_SWAP(VAR) register_gdbarch_swap (&(VAR), sizeof ((VAR)), NULL)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -713,6 +714,11 @@ extern void set_gdbarch_from_file (bfd *);
|
|||||||
extern void set_architecture_from_arch_mach (enum bfd_architecture, unsigned long);
|
extern void set_architecture_from_arch_mach (enum bfd_architecture, unsigned long);
|
||||||
|
|
||||||
|
|
||||||
|
/* Initialize the current architecture to the "first" one we find on
|
||||||
|
our list. */
|
||||||
|
|
||||||
|
extern void initialize_current_architecture (void);
|
||||||
|
|
||||||
/* Helper function for targets that don't know how my arguments are
|
/* Helper function for targets that don't know how my arguments are
|
||||||
being passed */
|
being passed */
|
||||||
|
|
||||||
@ -1889,6 +1895,35 @@ int sizeof_call_dummy_words = sizeof (call_dummy_words);
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* Initialize the current architecture. */
|
||||||
|
void
|
||||||
|
initialize_current_architecture ()
|
||||||
|
{
|
||||||
|
if (GDB_MULTI_ARCH)
|
||||||
|
{
|
||||||
|
struct gdbarch_init_registration *rego;
|
||||||
|
const struct bfd_arch_info *chosen = NULL;
|
||||||
|
for (rego = gdbarch_init_registrary; rego != NULL; rego = rego->next)
|
||||||
|
{
|
||||||
|
const struct bfd_arch_info *ap
|
||||||
|
= bfd_lookup_arch (rego->bfd_architecture, 0);
|
||||||
|
|
||||||
|
/* Choose the first architecture alphabetically. */
|
||||||
|
if (chosen == NULL
|
||||||
|
|| strcmp (ap->printable_name, chosen->printable_name) < 0)
|
||||||
|
chosen = ap;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (chosen != NULL)
|
||||||
|
{
|
||||||
|
struct gdbarch_info info;
|
||||||
|
memset (&info, 0, sizeof info);
|
||||||
|
info.bfd_arch_info = chosen;
|
||||||
|
gdbarch_update (info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
extern void _initialize_gdbarch (void);
|
extern void _initialize_gdbarch (void);
|
||||||
void
|
void
|
||||||
_initialize_gdbarch ()
|
_initialize_gdbarch ()
|
||||||
|
23
gdb/remote.c
23
gdb/remote.c
@ -3977,7 +3977,8 @@ remote_insert_breakpoint (addr, contents_cache)
|
|||||||
if ((remote_protocol_Z.support == PACKET_ENABLE)
|
if ((remote_protocol_Z.support == PACKET_ENABLE)
|
||||||
|| (remote_protocol_Z.support == PACKET_SUPPORT_UNKNOWN))
|
|| (remote_protocol_Z.support == PACKET_SUPPORT_UNKNOWN))
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p = buf;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p = buf;
|
||||||
|
|
||||||
addr = remote_address_masked (addr);
|
addr = remote_address_masked (addr);
|
||||||
*(p++) = 'Z';
|
*(p++) = 'Z';
|
||||||
@ -4040,7 +4041,8 @@ remote_remove_breakpoint (addr, contents_cache)
|
|||||||
if ((remote_protocol_Z.support == PACKET_ENABLE)
|
if ((remote_protocol_Z.support == PACKET_ENABLE)
|
||||||
|| (remote_protocol_Z.support == PACKET_SUPPORT_UNKNOWN))
|
|| (remote_protocol_Z.support == PACKET_SUPPORT_UNKNOWN))
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p = buf;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p = buf;
|
||||||
|
|
||||||
*(p++) = 'z';
|
*(p++) = 'z';
|
||||||
*(p++) = '0';
|
*(p++) = '0';
|
||||||
@ -4071,7 +4073,8 @@ remote_insert_watchpoint (addr, len, type)
|
|||||||
int len;
|
int len;
|
||||||
int type;
|
int type;
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p;
|
||||||
|
|
||||||
if (remote_protocol_Z.support == PACKET_DISABLE)
|
if (remote_protocol_Z.support == PACKET_DISABLE)
|
||||||
error ("Can't set hardware watchpoints without the 'Z' packet\n");
|
error ("Can't set hardware watchpoints without the 'Z' packet\n");
|
||||||
@ -4097,7 +4100,8 @@ remote_remove_watchpoint (addr, len, type)
|
|||||||
int len;
|
int len;
|
||||||
int type;
|
int type;
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p;
|
||||||
|
|
||||||
sprintf (buf, "z%x,", type + 2 );
|
sprintf (buf, "z%x,", type + 2 );
|
||||||
p = strchr (buf, '\0');
|
p = strchr (buf, '\0');
|
||||||
@ -4118,7 +4122,8 @@ remote_insert_hw_breakpoint (addr, len)
|
|||||||
CORE_ADDR addr;
|
CORE_ADDR addr;
|
||||||
int len;
|
int len;
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p = buf;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p = buf;
|
||||||
|
|
||||||
if (remote_protocol_Z.support == PACKET_DISABLE)
|
if (remote_protocol_Z.support == PACKET_DISABLE)
|
||||||
error ("Can't set hardware breakpoints without the 'Z' packet\n");
|
error ("Can't set hardware breakpoints without the 'Z' packet\n");
|
||||||
@ -4145,7 +4150,8 @@ remote_remove_hw_breakpoint (addr, len)
|
|||||||
CORE_ADDR addr;
|
CORE_ADDR addr;
|
||||||
int len;
|
int len;
|
||||||
{
|
{
|
||||||
char buf[PBUFSIZ], *p = buf;
|
char *buf = alloca (PBUFSIZ);
|
||||||
|
char *p = buf;
|
||||||
|
|
||||||
*(p++) = 'z';
|
*(p++) = 'z';
|
||||||
*(p++) = '1';
|
*(p++) = '1';
|
||||||
@ -4239,6 +4245,11 @@ crc32 (buf, len, crc)
|
|||||||
Useful for verifying the image on the target against the exec file.
|
Useful for verifying the image on the target against the exec file.
|
||||||
Depends on the target understanding the new "qCRC:" request. */
|
Depends on the target understanding the new "qCRC:" request. */
|
||||||
|
|
||||||
|
/* FIXME: cagney/1999-10-26: This command should be broken down into a
|
||||||
|
target method (target verify memory) and generic version of the
|
||||||
|
actual command. This will allow other high-level code (especially
|
||||||
|
generic_load()) to make use of this target functionality. */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
compare_sections_command (args, from_tty)
|
compare_sections_command (args, from_tty)
|
||||||
char *args;
|
char *args;
|
||||||
|
@ -575,6 +575,7 @@ print_frame_info_base (fi, level, source, args)
|
|||||||
}
|
}
|
||||||
current_source_line = max (sal.line - lines_to_list / 2, 1);
|
current_source_line = max (sal.line - lines_to_list / 2, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (source != 0)
|
if (source != 0)
|
||||||
set_default_breakpoint (1, fi->pc, sal.symtab, sal.line);
|
set_default_breakpoint (1, fi->pc, sal.symtab, sal.line);
|
||||||
|
|
||||||
|
@ -686,6 +686,7 @@ gdb_init (argv0)
|
|||||||
initialize_targets (); /* Setup target_terminal macros for utils.c */
|
initialize_targets (); /* Setup target_terminal macros for utils.c */
|
||||||
initialize_utils (); /* Make errors and warnings possible */
|
initialize_utils (); /* Make errors and warnings possible */
|
||||||
initialize_all_files ();
|
initialize_all_files ();
|
||||||
|
initialize_current_architecture ();
|
||||||
init_main (); /* But that omits this file! Do it now */
|
init_main (); /* But that omits this file! Do it now */
|
||||||
|
|
||||||
/* The signal handling mechanism is different depending whether or
|
/* The signal handling mechanism is different depending whether or
|
||||||
|
@ -1367,7 +1367,7 @@ fputstrn_unfiltered (str, n, quoter, stream)
|
|||||||
|
|
||||||
/* Number of lines per page or UINT_MAX if paging is disabled. */
|
/* Number of lines per page or UINT_MAX if paging is disabled. */
|
||||||
static unsigned int lines_per_page;
|
static unsigned int lines_per_page;
|
||||||
/* Number of chars per line or UNIT_MAX is line folding is disabled. */
|
/* Number of chars per line or UNIT_MAX if line folding is disabled. */
|
||||||
static unsigned int chars_per_line;
|
static unsigned int chars_per_line;
|
||||||
/* Current count of lines printed on this page, chars on this line. */
|
/* Current count of lines printed on this page, chars on this line. */
|
||||||
static unsigned int lines_printed, chars_printed;
|
static unsigned int lines_printed, chars_printed;
|
||||||
|
@ -1,3 +1,18 @@
|
|||||||
|
1999-10-22 Dave Brolley <brolley@cygnus.com>
|
||||||
|
|
||||||
|
* cgen-par.h (insn_address): New field in CGEN_WRITE_QUEUE_ELEMENT.
|
||||||
|
(CGEN_WRITE_QUEUE_ELEMENT_IADDR): New macro.
|
||||||
|
* cgen-par.c: Set insn_address for each queued write. Get pc from
|
||||||
|
cpu when executing queued writes.
|
||||||
|
|
||||||
|
1999-10-19 Dave Brolley <brolley@cygnus.com>
|
||||||
|
|
||||||
|
* cgen-par.h (sim_queue_fn_pc_write): New function.
|
||||||
|
(CGEN_FN_PC_WRITE): New enumerator.
|
||||||
|
(fn_pc_write): New union member.
|
||||||
|
* cgen-par.c (sim_queue_fn_pc_write): New function.
|
||||||
|
(cgen_write_queue_element_execute): Handle CGEN_FN_PC_WRITE.
|
||||||
|
|
||||||
1999-10-18 Dave Brolley <brolley@cygnus.com>
|
1999-10-18 Dave Brolley <brolley@cygnus.com>
|
||||||
|
|
||||||
* cgen-par.h (CGEN_MEM_DI_WRITE): New enumerator.
|
* cgen-par.h (CGEN_MEM_DI_WRITE): New enumerator.
|
||||||
|
@ -29,6 +29,7 @@ void sim_queue_bi_write (SIM_CPU *cpu, BI *target, BI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_BI_WRITE;
|
element->kind = CGEN_BI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.bi_write.target = target;
|
element->kinds.bi_write.target = target;
|
||||||
element->kinds.bi_write.value = value;
|
element->kinds.bi_write.value = value;
|
||||||
}
|
}
|
||||||
@ -38,6 +39,7 @@ void sim_queue_qi_write (SIM_CPU *cpu, UQI *target, UQI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_QI_WRITE;
|
element->kind = CGEN_QI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.qi_write.target = target;
|
element->kinds.qi_write.target = target;
|
||||||
element->kinds.qi_write.value = value;
|
element->kinds.qi_write.value = value;
|
||||||
}
|
}
|
||||||
@ -47,6 +49,7 @@ void sim_queue_si_write (SIM_CPU *cpu, SI *target, SI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_SI_WRITE;
|
element->kind = CGEN_SI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.si_write.target = target;
|
element->kinds.si_write.target = target;
|
||||||
element->kinds.si_write.value = value;
|
element->kinds.si_write.value = value;
|
||||||
}
|
}
|
||||||
@ -56,6 +59,7 @@ void sim_queue_sf_write (SIM_CPU *cpu, SI *target, SF value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_SF_WRITE;
|
element->kind = CGEN_SF_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.sf_write.target = target;
|
element->kinds.sf_write.target = target;
|
||||||
element->kinds.sf_write.value = value;
|
element->kinds.sf_write.value = value;
|
||||||
}
|
}
|
||||||
@ -65,6 +69,7 @@ void sim_queue_pc_write (SIM_CPU *cpu, USI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_PC_WRITE;
|
element->kind = CGEN_PC_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.pc_write.value = value;
|
element->kinds.pc_write.value = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -78,6 +83,7 @@ void sim_queue_fn_hi_write (
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_FN_HI_WRITE;
|
element->kind = CGEN_FN_HI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.fn_hi_write.function = write_function;
|
element->kinds.fn_hi_write.function = write_function;
|
||||||
element->kinds.fn_hi_write.regno = regno;
|
element->kinds.fn_hi_write.regno = regno;
|
||||||
element->kinds.fn_hi_write.value = value;
|
element->kinds.fn_hi_write.value = value;
|
||||||
@ -93,6 +99,7 @@ void sim_queue_fn_si_write (
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_FN_SI_WRITE;
|
element->kind = CGEN_FN_SI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.fn_si_write.function = write_function;
|
element->kinds.fn_si_write.function = write_function;
|
||||||
element->kinds.fn_si_write.regno = regno;
|
element->kinds.fn_si_write.regno = regno;
|
||||||
element->kinds.fn_si_write.value = value;
|
element->kinds.fn_si_write.value = value;
|
||||||
@ -108,6 +115,7 @@ void sim_queue_fn_di_write (
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_FN_DI_WRITE;
|
element->kind = CGEN_FN_DI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.fn_di_write.function = write_function;
|
element->kinds.fn_di_write.function = write_function;
|
||||||
element->kinds.fn_di_write.regno = regno;
|
element->kinds.fn_di_write.regno = regno;
|
||||||
element->kinds.fn_di_write.value = value;
|
element->kinds.fn_di_write.value = value;
|
||||||
@ -123,16 +131,32 @@ void sim_queue_fn_df_write (
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_FN_DF_WRITE;
|
element->kind = CGEN_FN_DF_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.fn_df_write.function = write_function;
|
element->kinds.fn_df_write.function = write_function;
|
||||||
element->kinds.fn_df_write.regno = regno;
|
element->kinds.fn_df_write.regno = regno;
|
||||||
element->kinds.fn_df_write.value = value;
|
element->kinds.fn_df_write.value = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void sim_queue_fn_pc_write (
|
||||||
|
SIM_CPU *cpu,
|
||||||
|
void (*write_function)(SIM_CPU *cpu, USI),
|
||||||
|
USI value
|
||||||
|
)
|
||||||
|
{
|
||||||
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
|
element->kind = CGEN_FN_PC_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
|
element->kinds.fn_pc_write.function = write_function;
|
||||||
|
element->kinds.fn_pc_write.value = value;
|
||||||
|
}
|
||||||
|
|
||||||
void sim_queue_mem_qi_write (SIM_CPU *cpu, SI address, QI value)
|
void sim_queue_mem_qi_write (SIM_CPU *cpu, SI address, QI value)
|
||||||
{
|
{
|
||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_MEM_QI_WRITE;
|
element->kind = CGEN_MEM_QI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.mem_qi_write.address = address;
|
element->kinds.mem_qi_write.address = address;
|
||||||
element->kinds.mem_qi_write.value = value;
|
element->kinds.mem_qi_write.value = value;
|
||||||
}
|
}
|
||||||
@ -142,6 +166,7 @@ void sim_queue_mem_hi_write (SIM_CPU *cpu, SI address, HI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_MEM_HI_WRITE;
|
element->kind = CGEN_MEM_HI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.mem_hi_write.address = address;
|
element->kinds.mem_hi_write.address = address;
|
||||||
element->kinds.mem_hi_write.value = value;
|
element->kinds.mem_hi_write.value = value;
|
||||||
}
|
}
|
||||||
@ -151,6 +176,7 @@ void sim_queue_mem_si_write (SIM_CPU *cpu, SI address, SI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_MEM_SI_WRITE;
|
element->kind = CGEN_MEM_SI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.mem_si_write.address = address;
|
element->kinds.mem_si_write.address = address;
|
||||||
element->kinds.mem_si_write.value = value;
|
element->kinds.mem_si_write.value = value;
|
||||||
}
|
}
|
||||||
@ -160,6 +186,7 @@ void sim_queue_mem_di_write (SIM_CPU *cpu, SI address, DI value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_MEM_DI_WRITE;
|
element->kind = CGEN_MEM_DI_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.mem_di_write.address = address;
|
element->kinds.mem_di_write.address = address;
|
||||||
element->kinds.mem_di_write.value = value;
|
element->kinds.mem_di_write.value = value;
|
||||||
}
|
}
|
||||||
@ -169,6 +196,7 @@ void sim_queue_mem_df_write (SIM_CPU *cpu, SI address, DF value)
|
|||||||
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
CGEN_WRITE_QUEUE *q = CPU_WRITE_QUEUE (cpu);
|
||||||
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
CGEN_WRITE_QUEUE_ELEMENT *element = CGEN_WRITE_QUEUE_NEXT (q);
|
||||||
element->kind = CGEN_MEM_DF_WRITE;
|
element->kind = CGEN_MEM_DF_WRITE;
|
||||||
|
element->insn_address = CPU_PC_GET (cpu);
|
||||||
element->kinds.mem_df_write.address = address;
|
element->kinds.mem_df_write.address = address;
|
||||||
element->kinds.mem_df_write.value = value;
|
element->kinds.mem_df_write.value = value;
|
||||||
}
|
}
|
||||||
@ -215,28 +243,31 @@ cgen_write_queue_element_execute (SIM_CPU *cpu, CGEN_WRITE_QUEUE_ELEMENT *item)
|
|||||||
item->kinds.fn_df_write.regno,
|
item->kinds.fn_df_write.regno,
|
||||||
item->kinds.fn_df_write.value);
|
item->kinds.fn_df_write.value);
|
||||||
break;
|
break;
|
||||||
|
case CGEN_FN_PC_WRITE:
|
||||||
|
item->kinds.fn_pc_write.function (cpu, item->kinds.fn_pc_write.value);
|
||||||
|
break;
|
||||||
case CGEN_MEM_QI_WRITE:
|
case CGEN_MEM_QI_WRITE:
|
||||||
pc = CPU_PC_GET (cpu);
|
pc = item->insn_address;
|
||||||
SETMEMQI (cpu, pc, item->kinds.mem_qi_write.address,
|
SETMEMQI (cpu, pc, item->kinds.mem_qi_write.address,
|
||||||
item->kinds.mem_qi_write.value);
|
item->kinds.mem_qi_write.value);
|
||||||
break;
|
break;
|
||||||
case CGEN_MEM_HI_WRITE:
|
case CGEN_MEM_HI_WRITE:
|
||||||
pc = CPU_PC_GET (cpu);
|
pc = item->insn_address;
|
||||||
SETMEMHI (cpu, pc, item->kinds.mem_hi_write.address,
|
SETMEMHI (cpu, pc, item->kinds.mem_hi_write.address,
|
||||||
item->kinds.mem_hi_write.value);
|
item->kinds.mem_hi_write.value);
|
||||||
break;
|
break;
|
||||||
case CGEN_MEM_SI_WRITE:
|
case CGEN_MEM_SI_WRITE:
|
||||||
pc = CPU_PC_GET (cpu);
|
pc = item->insn_address;
|
||||||
SETMEMSI (cpu, pc, item->kinds.mem_si_write.address,
|
SETMEMSI (cpu, pc, item->kinds.mem_si_write.address,
|
||||||
item->kinds.mem_si_write.value);
|
item->kinds.mem_si_write.value);
|
||||||
break;
|
break;
|
||||||
case CGEN_MEM_DI_WRITE:
|
case CGEN_MEM_DI_WRITE:
|
||||||
pc = CPU_PC_GET (cpu);
|
pc = item->insn_address;
|
||||||
SETMEMDI (cpu, pc, item->kinds.mem_di_write.address,
|
SETMEMDI (cpu, pc, item->kinds.mem_di_write.address,
|
||||||
item->kinds.mem_di_write.value);
|
item->kinds.mem_di_write.value);
|
||||||
break;
|
break;
|
||||||
case CGEN_MEM_DF_WRITE:
|
case CGEN_MEM_DF_WRITE:
|
||||||
pc = CPU_PC_GET (cpu);
|
pc = item->insn_address;
|
||||||
SETMEMDF (cpu, pc, item->kinds.mem_df_write.address,
|
SETMEMDF (cpu, pc, item->kinds.mem_df_write.address,
|
||||||
item->kinds.mem_df_write.value);
|
item->kinds.mem_df_write.value);
|
||||||
break;
|
break;
|
||||||
|
@ -26,6 +26,7 @@ enum cgen_write_queue_kind {
|
|||||||
CGEN_BI_WRITE, CGEN_QI_WRITE, CGEN_SI_WRITE, CGEN_SF_WRITE,
|
CGEN_BI_WRITE, CGEN_QI_WRITE, CGEN_SI_WRITE, CGEN_SF_WRITE,
|
||||||
CGEN_PC_WRITE,
|
CGEN_PC_WRITE,
|
||||||
CGEN_FN_HI_WRITE, CGEN_FN_SI_WRITE, CGEN_FN_DI_WRITE, CGEN_FN_DF_WRITE,
|
CGEN_FN_HI_WRITE, CGEN_FN_SI_WRITE, CGEN_FN_DI_WRITE, CGEN_FN_DF_WRITE,
|
||||||
|
CGEN_FN_PC_WRITE,
|
||||||
CGEN_MEM_QI_WRITE, CGEN_MEM_HI_WRITE, CGEN_MEM_SI_WRITE, CGEN_MEM_DI_WRITE,
|
CGEN_MEM_QI_WRITE, CGEN_MEM_HI_WRITE, CGEN_MEM_SI_WRITE, CGEN_MEM_DI_WRITE,
|
||||||
CGEN_MEM_DF_WRITE,
|
CGEN_MEM_DF_WRITE,
|
||||||
CGEN_NUM_WRITE_KINDS
|
CGEN_NUM_WRITE_KINDS
|
||||||
@ -34,6 +35,7 @@ enum cgen_write_queue_kind {
|
|||||||
/* Element of the write queue. */
|
/* Element of the write queue. */
|
||||||
typedef struct {
|
typedef struct {
|
||||||
enum cgen_write_queue_kind kind; /* Used to select union member below. */
|
enum cgen_write_queue_kind kind; /* Used to select union member below. */
|
||||||
|
IADDR insn_address; /* Address of the insn performing the write. */
|
||||||
union {
|
union {
|
||||||
struct {
|
struct {
|
||||||
BI *target;
|
BI *target;
|
||||||
@ -74,6 +76,10 @@ typedef struct {
|
|||||||
DI value;
|
DI value;
|
||||||
void (*function)(SIM_CPU *, UINT, DI);
|
void (*function)(SIM_CPU *, UINT, DI);
|
||||||
} fn_df_write;
|
} fn_df_write;
|
||||||
|
struct {
|
||||||
|
USI value;
|
||||||
|
void (*function)(SIM_CPU *, USI);
|
||||||
|
} fn_pc_write;
|
||||||
struct {
|
struct {
|
||||||
SI address;
|
SI address;
|
||||||
QI value;
|
QI value;
|
||||||
@ -98,6 +104,7 @@ typedef struct {
|
|||||||
} CGEN_WRITE_QUEUE_ELEMENT;
|
} CGEN_WRITE_QUEUE_ELEMENT;
|
||||||
|
|
||||||
#define CGEN_WRITE_QUEUE_ELEMENT_KIND(element) ((element)->kind)
|
#define CGEN_WRITE_QUEUE_ELEMENT_KIND(element) ((element)->kind)
|
||||||
|
#define CGEN_WRITE_QUEUE_ELEMENT_IADDR(element) ((element)->insn_address)
|
||||||
|
|
||||||
extern void cgen_write_queue_element_execute (
|
extern void cgen_write_queue_element_execute (
|
||||||
SIM_CPU *, CGEN_WRITE_QUEUE_ELEMENT *
|
SIM_CPU *, CGEN_WRITE_QUEUE_ELEMENT *
|
||||||
@ -136,6 +143,7 @@ extern void sim_queue_fn_hi_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, UHI), UI
|
|||||||
extern void sim_queue_fn_si_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, USI), UINT, SI);
|
extern void sim_queue_fn_si_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, USI), UINT, SI);
|
||||||
extern void sim_queue_fn_di_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, DI), UINT, DI);
|
extern void sim_queue_fn_di_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, DI), UINT, DI);
|
||||||
extern void sim_queue_fn_df_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, DI), UINT, DF);
|
extern void sim_queue_fn_df_write (SIM_CPU *, void (*)(SIM_CPU *, UINT, DI), UINT, DF);
|
||||||
|
extern void sim_queue_fn_pc_write (SIM_CPU *, void (*)(SIM_CPU *, USI), USI);
|
||||||
|
|
||||||
extern void sim_queue_mem_qi_write (SIM_CPU *, SI, QI);
|
extern void sim_queue_mem_qi_write (SIM_CPU *, SI, QI);
|
||||||
extern void sim_queue_mem_hi_write (SIM_CPU *, SI, HI);
|
extern void sim_queue_mem_hi_write (SIM_CPU *, SI, HI);
|
||||||
|
339
sim/mips/configure
vendored
339
sim/mips/configure
vendored
File diff suppressed because it is too large
Load Diff
@ -702,9 +702,6 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
000000,5.RS,5.RT,5.RD,00000,101100:SPECIAL:64::DADD
|
000000,5.RS,5.RT,5.RD,00000,101100:SPECIAL:64::DADD
|
||||||
"dadd r<RD>, r<RS>, r<RT>"
|
"dadd r<RD>, r<RS>, r<RT>"
|
||||||
*mipsIII:
|
*mipsIII:
|
||||||
@ -3108,6 +3105,7 @@
|
|||||||
|
|
||||||
110101,5.BASE,5.FT,16.OFFSET:COP1:64::LDC1
|
110101,5.BASE,5.FT,16.OFFSET:COP1:64::LDC1
|
||||||
"ldc1 f<FT>, <OFFSET>(r<BASE>)"
|
"ldc1 f<FT>, <OFFSET>(r<BASE>)"
|
||||||
|
*mipsI:
|
||||||
*mipsII:
|
*mipsII:
|
||||||
*mipsIII:
|
*mipsIII:
|
||||||
*mipsIV:
|
*mipsIV:
|
||||||
@ -3465,8 +3463,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
010001,10,3.FMT,00000,5.FS,5.FD,010101:COP1:32::RECIP.fmt
|
010001,10,3.FMT,00000,5.FS,5.FD,010101:COP1:32::RECIP.fmt
|
||||||
*mipsIV:
|
|
||||||
"recip.%s<FMT> f<FD>, f<FS>"
|
"recip.%s<FMT> f<FD>, f<FS>"
|
||||||
|
*mipsIV:
|
||||||
*vr5000:
|
*vr5000:
|
||||||
{
|
{
|
||||||
unsigned32 instruction = instruction_0;
|
unsigned32 instruction = instruction_0;
|
||||||
@ -3545,6 +3543,7 @@
|
|||||||
|
|
||||||
111101,5.BASE,5.FT,16.OFFSET:COP1:64::SDC1
|
111101,5.BASE,5.FT,16.OFFSET:COP1:64::SDC1
|
||||||
"sdc1 f<FT>, <OFFSET>(r<BASE>)"
|
"sdc1 f<FT>, <OFFSET>(r<BASE>)"
|
||||||
|
*mipsI:
|
||||||
*mipsII:
|
*mipsII:
|
||||||
*mipsIII:
|
*mipsIII:
|
||||||
*mipsIV:
|
*mipsIV:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user