diff options
author | Mark Mitchell <mark@markmitchell.com> | 1998-06-25 15:14:41 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 1998-06-25 15:14:41 +0000 |
commit | 41472af8777035219decfe1cb4742ce2b3ed8e38 (patch) | |
tree | af8828e1df0f3e051eb29c58c7d958cd177e474d /gcc/tree.h | |
parent | 9c606f693ddca43b89097388cfdeeffaead030df (diff) | |
download | gcc-41472af8777035219decfe1cb4742ce2b3ed8e38.zip gcc-41472af8777035219decfe1cb4742ce2b3ed8e38.tar.gz gcc-41472af8777035219decfe1cb4742ce2b3ed8e38.tar.bz2 |
invoke.texi (-fstrict-aliasing): Document.
* invoke.texi (-fstrict-aliasing): Document.
* rtl.texi (MEM_ALIAS_SET): Document.
* flags.h (flag_strict_aliasing): Declare.
* toplev.c (flag_strict_aliasing): Define.
(f_options): Add -strict-aliasing.
(main): Set flag_strict_aliasing if -O2 or higher.
* tree.h (tree_type): Add alias_set field.
(TYPE_ALIAS_SET): New macro.
(TYPE_ALIAS_SET_KNOWN_P): Likewise.
(get_alias_set): Declare.
* tree.c (lang_get_alias_set): Define.
(make_node): Initialize TYPE_ALIAS_SET.
(get_alias_set): New function.
* print-tree.c (print_node): Dump the alias set for a type.
* c-tree.h (c_get_alias_set): Declare.
* c-common.c (c_get_alias_set): New function.
* c-decl.c (init_decl_processing): Set lang_get_alias_set.
* expr.c (protect_from_queue): Propogage alias sets.
(expand_assignment): Calculate alias set for new MEMs.
(expand_expr): Likewise.
* function.c (put_var_into_stack): Likewise.
(put_reg_into_stack): Likewise.
(gen_mem_addressof): Likewise.
(assign_parms): Likewise.
* stmt.c (expand_decl): Likewise.
* varasm.c (make_decl_rtl): Eliminate redundant clearing of
DECL_RTL. Calculate alias set for new MEMs.
* rtl.def (REG): Add dummy operand.
(MEM): Add extra operand to store the MEM_ALIAS_SET.
* rtl.h (MEM_ALIAS_SET): New macro.
(gen_rtx_MEM): Declare.
* emit-rtl.c (gen_rtx_MEM): New function.
* gengenrtl.c (sepcial_rtx): Make MEMs special.
* alias.c (CHECK_ALIAS_SETS_FOR_CONSISTENCY): New macro.
(DIFFERENT_ALIAS_SETS_P): Likewise.
(canon_rtx): Propogate the alias set to the new MEM.
(true_dependence): Check the alias sets.
(anti_dependence): Likewise.
(output_dependence): Likewise.
* explow.c (stabilize): Progoate alias sets.
* integrate.c (copy_rtx_and_substitute): Likewise.
* final.c (alter_subreg): Make sure not to leave MEM_IN_STRUCT_P
in an unpredictable state. Propogate alias sets.
* reload1.c (reload): Clear MEM_ALIAS_SET for new MEMs about which
we have no alias information.
From-SVN: r20719
Diffstat (limited to 'gcc/tree.h')
-rw-r--r-- | gcc/tree.h | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -776,6 +776,18 @@ struct tree_block #define TYPE_OBSTACK(NODE) (TYPE_CHECK (NODE)->type.obstack) #define TYPE_LANG_SPECIFIC(NODE) (TYPE_CHECK (NODE)->type.lang_specific) +/* The (language-specific) typed-based alias set for this type. + Objects whose TYPE_ALIAS_SETs are different cannot alias each + other. If the TYPE_ALIAS_SET is -1, no alias set has yet been + assigned to this type. If the TYPE_ALIAS_SET is 0, objects of this + type can alias objects of any type. */ +#define TYPE_ALIAS_SET(NODE) (TYPE_CHECK (NODE)->type.alias_set) + +/* Nonzero iff the typed-based alias set for this type has been + calculated. */ +#define TYPE_ALIAS_SET_KNOWN_P(NODE) \ + (TYPE_CHECK (NODE)->type.alias_set != -1) + /* A TREE_LIST of IDENTIFIER nodes of the attributes that apply to this type. */ #define TYPE_ATTRIBUTES(NODE) (TYPE_CHECK (NODE)->type.attributes) @@ -870,6 +882,7 @@ struct tree_type union tree_node *noncopied_parts; union tree_node *context; struct obstack *obstack; + int alias_set; /* Points to a structure whose details depend on the language in use. */ struct lang_type *lang_specific; }; @@ -1811,6 +1824,8 @@ extern tree get_file_function_name PROTO((int)); extern tree get_set_constructor_bits PROTO((tree, char *, int)); extern tree get_set_constructor_bytes PROTO((tree, unsigned char *, int)); +extern int get_alias_set PROTO((tree)); +extern int (*lang_get_alias_set) PROTO((tree)); /* In stmt.c */ |