Add two pointers (saved_regs, extra_info) to struct frame_info.
Introduce new macro FRAME_INIT_SAVED_REGS which replaces
FRAME_FIND_SAVED_REGS.
Document.
Use in mn10300 and rs6000 targets. Fix side effects on ALPHA, MIPS,
Z8K and SPARC targets.
* m88k-tdep.c (examine_prologue): Modified to handle prologues for
pic code in addition to prologues where an instruction from the
prologue gets moved into the delay slot of a branch instruction
immediately following the prologue. A table of potential prologue
instructions (prologue_insn_tbl) is now used for picking apart a
function prologue.
(frame_find_saved_regs): Changed the way in which limit gets set
so that the delay slot of branch instructions immediately
following the prologue gets examined.
(pushed_size, store_parm_word, store_parm, push_parameters,
collect_returned_value): Deleted.
Change all references to stdout/stderr to gdb_stdout/gdb_stderr.
Replace all calls to stdio output functions with calls to
corresponding _unfiltered functions (`fprintf_unfiltered')
Replaced calls to fopen for output to gdb_fopen.
Added sufficient goo to utils.c and defs.h to make the above work.
The net effect is that stdio output functions are only directly used
in utils.c. Elsewhere, the _unfiltered and _filtered functions and
GDB_FILE type are used.
In the near future, GDB_FILE will stop being equivalant to FILE.
The semantics of some commands has changed in a very subtle way:
called in the right context, they may cause new occurences of
prompt_for_continue() behavior. The testsuite doesn't notice anything
like this, though.
Please respect this change by not reintroducing stdio output
dependencies in the main body of gdb code. All output from commands
should go to a GDB_FILE.
Target-specific code can still use stdio directly to communicate with
targets.
infcmd.c (step_1),
infrun.c (wait_for_inferior): collapse SHIFT_INST_REGS ifdef and insert macro.
* m88k-tdep.c: include ieee-float.h. new global target_is_m88110.
new const struct ext_format_m88110 for float format.
(pic_prologue_code): add braces.
(next_insn): remove unused variable buf.
(frame_find_saved_regs): remove unused variables next_addr,
saved_regs, regnum.
(frame_locals_address): remove unused variables frame, ap.
(frame_args_address): remove unused variables frame, ap.
(push_parameters): add some breaks and a default case.
* remote-bug.c: remove redundant includes of value.h, target.h,
serial.h.
(bug_open): corrected typo, sr_multi_scan -> gr_multi_scan.
(bug_fetch_register): special case sfip register for m88110.
remove flag bit masking of pc registers. This should be handled
by the ADDR_BITS_* macros.
(bug_store_register): special case sfip register for m88110.
Corrected sprint format for extended registers.
Include sys/types.h regardless of USG.
* configure.in: Fix typo (delta88r4 -> delta88v4).
* config/m88k/xm-delta88.h: Don't include sys/siginfo.h. It was
to make this work on SVR4 before SVR4 had its own configuration,
and it breaks SVR3.
(FP_REGNUM): define in terms of SP_REGNUM
rather than by absolute number. Also clearly comment that this
is a convenient lie in order to decrease future confusion.
(ACTUAL_FP_REGNUM): new macro for FP.
(FRAME_CHAIN_VALID): removed. Standard default works fine.
* m88k-tdep.c (frame_chain_valid): redundant, so removed.
(NEXT_PROLOGUE_INSN): removed unused fourth arg, fixed all
callers.
(read_next_frame_reg): declare static.
(examine_prologue): removed unused variabel insn2, rename insn1
to insn, rewrote comment about finding fp, sp, etc. set frame_fp
based on ACTUAL_FP_REGNUM rather than FP_REGNUM which is
actually a scammed alias for SP_REGNUM on m88k.
constants with an explicit null byte terminator. OP_STRING is
now used for real string types.
* c-lang.c (builtin_type_*): Move declarations to lang.c since
they are used by all languages.
* c-lang.c (_initialize_c_language): Move initializations of
builtin_type_* to lang.c.
* c-typeprint.c (c_type_print_varspec_prefix,
c_type_print_varspec_suffix): TYPE_CODE_PASCAL_ARRAY renamed
to TYPE_CODE_STRING.
* c-valprint.c (c_val_print): Change the way character arrays
are printed as strings to be consistent with the way strings
are printed when pointer-to-char types are dereferenced.
Remove test of print_max before calling val_print_string, which
now does it's own test.
* eval.c (evaluate_subexp): Add case for OP_ARRAY.
* expprint.c (print_subexp, dump_expression): Add case for OP_ARRAY.
* expression.h (enum exp_opcode): Add OP_ARRAY and document.
* gdbtypes.c (builtin_type_*): Add declarations moved from
c-lang.c.
* gdbtypes.c (create_string_type): New function to create real
string types.
* gdbtypes.c (recursive_dump_type): TYPE_CODE_PASCAL_ARRAY
renamed to TYPE_CODE_STRING.
* gdbtypes.c (_initialize_gdbtypes): Add initializations of
builtin_type_* types moved from c-lang.c.
* gdbtypes.h (enum type_code): TYPE_CODE_PASCAL_ARRAY renamed
to TYPE_CODE_STRING.
* gdbtypes.h (builtin_type_string): Add extern declaration.
* gdbtypes.h (create_string_type): Add prototype.
* m2-lang.c (m2_create_fundamental_type): TYPE_CODE_PASCAL_ARRAY
renamed to TYPE_CODE_STRING.
* m88k-tdep.c (pushed_size): TYPE_CODE_PASCAL_ARRAY renamed to
TYPE_CODE_STRING.
* mipsread.c (_initialize_mipsread): TYPE_CODE_PASCAL_ARRAY
renamed to TYPE_CODE_STRING.
* parse.c (length_of_subexp, prefixify_subexp): Add case for
OP_ARRAY.
* printcmd.c (print_formatted): Recognize TYPE_CODE_STRING.
* typeprint.c (print_type_scalar): TYPE_CODE_PASCAL_ARRAY renamed
to TYPE_CODE_STRING.
* valops.c (allocate_space_in_inferior): New function and
prototype, using code ripped out of value_string.
* valops.c (value_string): Rewritten to use new function
allocate_space_in_inferior, but temporarily disabled until some
other support is in place.
* valops.c (value_array): New function to create array constants.
* valprint.c (val_print_string): Add comment to document use,
complete rewrite to fix several small buglets.
* value.h (value_array): Add prototype.
* value.h (val_print_string): Change prototype to match rewrite.
**** start-sanitize-chill ****
* ch-valprint.c (chill_val_print): Add case for TYPE_CODE_STRING.
* ch-exp.y (match_character_literal): Disable recognition of
control sequence form of character literals and document why.
**** end-sanitize-chill ****
a optional type to decorate as an array type, the type of the
index, and the bounds of the array. Records this additional info
in the array type for use with languages with nonzero array
bounds.
* gdbtypes.h (enum type_code): Update comment for TYPE_CODE_ARRAY
to note that arrays may have bounds.
* gdbtypes.h (create_array_type): Update prototype.
* c-exp.y (ptype production): Adjust for new create_array_type
calling conventions.
* coffread.c (decode_type): Call create_array_type rather than
handcrafting array types.
* convex-tdep.c (value_type): Remove, now use create_array_type.
* convex-tdep.c (value_of_trapped_internalvar): Convert calls to
vector_type into calls to create_array_type.
* dwarfread.c (decode_subscr_data): Name changed to
decode_subscript_data_item throughout.
* dwarfread.c (decode_subscript_data_item): Rewrite to use
create_array_type. Now records index type and range as well.
* dwarfread.c (dwarf_read_array_type): Rewrite as part of
change to use create_array_type.
* dwarfread.c (read_subroutine_type): Test existing user defined
types before decorating them, to ensure they are blank, and
complain about it if they are not.
* dwarfread.c (decode_fund_type): For unrecognized types, always
return some valid type (type integer). If the unrecognized type
cannot be an implementation defined type, complain as well.
* m88k-tdep.c (pushed_size): Update comment for TYPE_CODE_ARRAY.
* m88k-tdep.c (store_param): Update comment for TYPE_CODE_ARRAY.
* mipsread.c (upgrade_type): Add FIXME comment that code to
handcraft arrays should be replaced with call to create_array_type.
* stabsread.c (read_array_type): Replace code to handcraft
array types with call to create_array_type.
* valprint.c (type_print_varspec_prefix): Minor formatting
change, join lines that don't need to be split.
basis. See comments in objfiles.h and details in ChangeLog. Also remove
redundant definitions of FRAME_CHAIN_VALID from most of the tm-* files and
use a default definition in frame.h.
* All GDB files that #include defs.h: Removed stdio.h.
(defs.h): #include stdio.h.
This has been tested by building GDBs for all targets hosted on Sun4.
None of the build problems were related to stdio.h inclusion. (n.b.
many configurations don't build for other reasons.)