aboutsummaryrefslogtreecommitdiff
path: root/gcc/rtl.h
diff options
context:
space:
mode:
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>2000-05-31 18:37:31 +0000
committerRichard Kenner <kenner@gcc.gnu.org>2000-05-31 14:37:31 -0400
commit3bdf5ad13852aaa871ab41a6e8f509809c8c104d (patch)
treeb0b7fe92ad1922c85f0e4c70693ee5b33b128261 /gcc/rtl.h
parent99923eedd0700c7055810224f548f70bcd009267 (diff)
downloadgcc-3bdf5ad13852aaa871ab41a6e8f509809c8c104d.zip
gcc-3bdf5ad13852aaa871ab41a6e8f509809c8c104d.tar.gz
gcc-3bdf5ad13852aaa871ab41a6e8f509809c8c104d.tar.bz2
Makefile.in (c-decl.o): Depend on rtl.h and expr.h.
* Makefile.in (c-decl.o): Depend on rtl.h and expr.h. * alias.c (struct alias_entry): alias_set is HOST_WIDE_INT. (REG_BASE_VALUE): Remove unneeded cast to unsigned. (get_alias_set_entry): ALIAS_SET arg is HOST_WIDE_INT. (find_base_decl): New function, from c_find_base_decl in c-common.c. (new_alias_set): Moved from tree.c; return is HOST_WIDE_INT. (get_alias_set): Likewise. Major rework to do more things and allow language-specific code to just handle special-cases. (record_alias_subset): Args are HOST_WIDE_INT. (record_component_alias): Local vars are HOST_WIDE_INT. Don't handle COMPLEX_EXPR. (get_varargs_alias_set): Moved from builtins.c. (get_frame_alias_set): New function. * builtins.c (expand_builtin_return_address): Use frame alias set. (expand_builtin_setjmp, expand_builtin_longjmp): Use alias set for setjmp buffer. (get_memory_rtx): Rework to use set_mem_attributes. (get_varargs_alias_set): Deleted from here. * c-common.c (c_apply_type_quals_to_decl): Alias sets now HOST_WIDE_INT. (c_find_base_decl): Deleted from here. (c_get_alias_set): Remove many cases and rework to just handle C-specific cases. * c-common.h (c_get_alias_set): Returns HOST_WIDE_INT. * c-decl.c (rtl.h, expr.h): Now included. (init_decl_processing): Call record_component_aliases on array types. (grokdeclarator): Likewise. Set TREE_ADDRESSABLE for all fields that are not bitfields. * c-typeck.c (common_type): Call record_component_aliases for array. * caller-save.c (setup_save_areas): Rework register loop for unsigned. Set all save areas to the frame alias set. * calls.c (initialie_argument_information): Call set_mem_attributes. (compute_argument_addresses, expand_call): Likewise. * explow.c (set_mem_attributes): New function. (stabilize): Use MEM_COPY_ATTRIBUTES and force_reg. * expr.c (struct move_by_pieces): Remove {to,from}_{struct,readonly}. LEN and OFFSET now HOST_WIDE_INT. (clear_by_pieces): Similar changes. (move_by_pieces): LEN now HOST_WIDE_INT; don't set deleted fields. (move_by_pieces_ninsns): Now returns unsigned HOST_WIDE_INT. (move_by_pieces_1): Don't use deleted fields, use MEM_COPY_ATTRIBUTES. (clear_by_pieces_1): Likewise. (emit_push_insn): Call set_mem_attributes. (expand_expr, case INDIRECT_REF): Likewise. (expand_expr, case VAR_DECL): Call change_address. * expr.h (ADD_PARM_SIZE, SUB_PARM_SIZE): Use host_integerp and tree_low_cst. (get_varargs_alias_set, get_frame_alias_set): New decls. (record_base_value, record_alias_subset, lang_get_alias_set): Likewise. (new_alias_set, set_mem_attributes): Likewse. * function.c (struct temp_slot): ALIAS_SET is HOST_WIDE_INT. (assign_stack_temp_for_type): Likewise. Can split slot even if alias set since can copy. Set MEM_ALIAS_SET and MEM_SET_IN_STRUCT_P. (assign_temp): Use host_integerp and tree_low_cst. (put_var_into_stack): Properly handle SAVE_EXPR. (put_addressof_into_stack): Likewise. (assign_parms): Call set_mem_attributes. Delete #if 0 code. (fix_lexical_address): Put reference to chain into frame alias set. (expand_function_start): Call set_mem_attributes. * integrate.c (expand_inline_function): Likewise. * recog.c (adj_offsettable_operand): Use MEM_COPY_ATTRIBUTES. * regmove.c (try_apply_stack_adjustment): Likewise. * reload.c (push_reload, make_memloc): Likewise. * reload1.c (alter_reg): Make alias sets for spilled pseudos. * rtl.def (MEM): Update comment. * rtl.h (MEM_ALIAS_SET): Now uses XCWINT. (move_by_pieces): Change length to HOST_WIDE_INT. (record_base_value, record_alias_subset): Delete from here. * stmt.c (expand_decl): Call set_mem_attributes. * stor-layout.c (finish_record_layout): Call record_component_aliases.i * toplev.c (compile_file): Call init_alias_once earlier. * tree.c (lang_get_alias_set, get_alias_set, new_alias_set): Deleted from here: now in alias.c. * tree.h (struct tree_type): alias_set is HOST_WIDE_INT. (struct tree_decl): Likewise. (get_alias_set, new_alias_set, lang_get_alias_set): Deleted from here. * varasm.c (make_function_rtl, make_decl_rtl): Call set_mem_attributes. (output_constant_def, force_const_mem): Likewise. * cp/Makefile.in (decl.o): Include ../expr.h. * cp/decl.c (expr.h): Include. (init_decl_processing): Call record_component_aliases for arrays. (grokdeclarator): Likewise. Set TREE_ADDRESSABLE for fields that aren't bitfields. * cp/tree.c (build_cplus_array_type_1): Call record_component_aliases. From-SVN: r34305
Diffstat (limited to 'gcc/rtl.h')
-rw-r--r--gcc/rtl.h36
1 files changed, 19 insertions, 17 deletions
diff --git a/gcc/rtl.h b/gcc/rtl.h
index de0c37d..cca5d52 100644
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -746,8 +746,10 @@ extern const char * const note_insn_name[NOTE_INSN_MAX - NOTE_INSN_BIAS];
#define ASM_OPERANDS_INPUT_CONSTRAINT_VEC(RTX) XCVEC ((RTX), 4, ASM_OPERANDS)
#define ASM_OPERANDS_INPUT(RTX, N) XCVECEXP ((RTX), 3, (N), ASM_OPERANDS)
#define ASM_OPERANDS_INPUT_LENGTH(RTX) XCVECLEN ((RTX), 3, ASM_OPERANDS)
-#define ASM_OPERANDS_INPUT_CONSTRAINT(RTX, N) XSTR (XCVECEXP ((RTX), 4, (N), ASM_OPERANDS), 0)
-#define ASM_OPERANDS_INPUT_MODE(RTX, N) GET_MODE (XCVECEXP ((RTX), 4, (N), ASM_OPERANDS))
+#define ASM_OPERANDS_INPUT_CONSTRAINT(RTX, N) \
+ XSTR (XCVECEXP ((RTX), 4, (N), ASM_OPERANDS), 0)
+#define ASM_OPERANDS_INPUT_MODE(RTX, N) \
+ GET_MODE (XCVECEXP ((RTX), 4, (N), ASM_OPERANDS))
#define ASM_OPERANDS_SOURCE_FILE(RTX) XCSTR ((RTX), 5, ASM_OPERANDS)
#define ASM_OPERANDS_SOURCE_LINE(RTX) XCINT ((RTX), 6, ASM_OPERANDS)
@@ -755,22 +757,15 @@ extern const char * const note_insn_name[NOTE_INSN_MAX - NOTE_INSN_BIAS];
Also in an ASM_OPERANDS rtx. */
#define MEM_VOLATILE_P(RTX) ((RTX)->volatil)
-/* For a MEM rtx, 1 if it refers to a field of an aggregate. If zero,
- RTX may or may not refer to a field of an aggregate. */
+/* For a MEM rtx, 1 if it refers to an aggregate, either to the
+ aggregate itself of to a field of the aggregate. If zero, RTX may
+ or may not be such a refrence. */
#define MEM_IN_STRUCT_P(RTX) ((RTX)->in_struct)
/* For a MEM rtx, 1 if it refers to a scalar. If zero, RTX may or may
not refer to a scalar.*/
#define MEM_SCALAR_P(RTX) ((RTX)->frame_related)
-/* Copy the attributes that apply to memory locations from RHS to LHS. */
-#define MEM_COPY_ATTRIBUTES(LHS, RHS) \
- (MEM_VOLATILE_P (LHS) = MEM_VOLATILE_P (RHS), \
- MEM_IN_STRUCT_P (LHS) = MEM_IN_STRUCT_P (RHS), \
- MEM_SCALAR_P (LHS) = MEM_SCALAR_P (RHS), \
- MEM_ALIAS_SET (LHS) = MEM_ALIAS_SET (RHS), \
- RTX_UNCHANGING_P (LHS) = RTX_UNCHANGING_P (RHS))
-
/* If VAL is non-zero, set MEM_IN_STRUCT_P and clear MEM_SCALAR_P in
RTX. Otherwise, vice versa. Use this macro only when you are
*sure* that you know that the MEM is in a structure, or is a
@@ -797,7 +792,15 @@ extern const char * const note_insn_name[NOTE_INSN_MAX - NOTE_INSN_BIAS];
some front-ends, these numbers may correspond in some way to types,
or other language-level entities, but they need not, and the
back-end makes no such assumptions. */
-#define MEM_ALIAS_SET(RTX) XCINT(RTX, 1, MEM)
+#define MEM_ALIAS_SET(RTX) XCWINT(RTX, 1, MEM)
+
+/* Copy the attributes that apply to memory locations from RHS to LHS. */
+#define MEM_COPY_ATTRIBUTES(LHS, RHS) \
+ (MEM_VOLATILE_P (LHS) = MEM_VOLATILE_P (RHS), \
+ MEM_IN_STRUCT_P (LHS) = MEM_IN_STRUCT_P (RHS), \
+ MEM_SCALAR_P (LHS) = MEM_SCALAR_P (RHS), \
+ MEM_ALIAS_SET (LHS) = MEM_ALIAS_SET (RHS), \
+ RTX_UNCHANGING_P (LHS) = RTX_UNCHANGING_P (RHS))
/* For a LABEL_REF, 1 means that this reference is to a label outside the
loop containing the reference. */
@@ -1645,7 +1648,9 @@ extern int preserve_subexpressions_p PARAMS ((void));
/* In expr.c */
extern void init_expr_once PARAMS ((void));
-extern void move_by_pieces PARAMS ((rtx, rtx, int, unsigned int));
+extern void move_by_pieces PARAMS ((rtx, rtx,
+ unsigned HOST_WIDE_INT,
+ unsigned int));
/* In flow.c */
extern void allocate_bb_life_data PARAMS ((void));
@@ -1821,9 +1826,6 @@ extern void mark_constant_function PARAMS ((void));
extern void init_alias_once PARAMS ((void));
extern void init_alias_analysis PARAMS ((void));
extern void end_alias_analysis PARAMS ((void));
-
-extern void record_base_value PARAMS ((unsigned int, rtx, int));
-extern void record_alias_subset PARAMS ((int, int));
extern rtx addr_side_effect_eval PARAMS ((rtx, int, int));
/* In sibcall.c */