(root)/
gcc-13.2.0/
gcc/
ipa-prop.h
       1  /* Interprocedural analyses.
       2     Copyright (C) 2005-2023 Free Software Foundation, Inc.
       3  
       4  This file is part of GCC.
       5  
       6  GCC is free software; you can redistribute it and/or modify it under
       7  the terms of the GNU General Public License as published by the Free
       8  Software Foundation; either version 3, or (at your option) any later
       9  version.
      10  
      11  GCC is distributed in the hope that it will be useful, but WITHOUT ANY
      12  WARRANTY; without even the implied warranty of MERCHANTABILITY or
      13  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
      14  for more details.
      15  
      16  You should have received a copy of the GNU General Public License
      17  along with GCC; see the file COPYING3.  If not see
      18  <http://www.gnu.org/licenses/>.  */
      19  
      20  #ifndef IPA_PROP_H
      21  #define IPA_PROP_H
      22  
      23  /* The following definitions and interfaces are used by
      24     interprocedural analyses or parameters.  */
      25  
      26  #define IPA_UNDESCRIBED_USE -1
      27  
      28  /* Index identifying an actualargument or a formal parameter may have only this
      29     many bits.  */
      30  
      31  #define IPA_PROP_ARG_INDEX_LIMIT_BITS 16
      32  
      33  /* ipa-prop.cc stuff (ipa-cp, indirect inlining):  */
      34  
      35  /* A jump function for a callsite represents the values passed as actual
      36     arguments of the callsite.  They were originally proposed in a paper called
      37     "Interprocedural Constant Propagation", by David Callahan, Keith D Cooper,
      38     Ken Kennedy, Linda Torczon in Comp86, pg 152-161.  There are three main
      39     types of values :
      40  
      41     Pass-through - the caller's formal parameter is passed as an actual
      42                    argument, possibly one simple operation performed on it.
      43     Constant     - a constant (is_gimple_ip_invariant)is passed as an actual
      44                    argument.
      45     Unknown      - neither of the above.
      46  
      47     IPA_JF_LOAD_AGG is a compound pass-through jump function, in which primary
      48     operation on formal parameter is memory dereference that loads a value from
      49     a part of an aggregate, which is represented or pointed to by the formal
      50     parameter.  Moreover, an additional unary/binary operation can be applied on
      51     the loaded value, and final result is passed as actual argument of callee
      52     (e.g. *(param_1(D) + 4) op 24 ).  It is meant to describe usage of aggregate
      53     parameter or by-reference parameter referenced in argument passing, commonly
      54     found in C++ and Fortran.
      55  
      56     IPA_JF_ANCESTOR is a special pass-through jump function, which means that
      57     the result is an address of a part of the object pointed to by the formal
      58     parameter to which the function refers.  It is mainly intended to represent
      59     getting addresses of ancestor fields in C++
      60     (e.g. &this_1(D)->D.1766.D.1756).  Note that if the original pointer is
      61     NULL, ancestor jump function must behave like a simple pass-through.
      62  
      63     Other pass-through functions can either simply pass on an unchanged formal
      64     parameter or can apply one simple binary operation to it (such jump
      65     functions are called polynomial).
      66  
      67     Jump functions are computed in ipa-prop.cc by function
      68     update_call_notes_after_inlining.  Some information can be lost and jump
      69     functions degraded accordingly when inlining, see
      70     update_call_notes_after_inlining in the same file.  */
      71  
      72  enum jump_func_type
      73  {
      74    IPA_JF_UNKNOWN = 0,  /* newly allocated and zeroed jump functions default */
      75    IPA_JF_CONST,             /* represented by field costant */
      76    IPA_JF_PASS_THROUGH,	    /* represented by field pass_through */
      77    IPA_JF_LOAD_AGG,	    /* represented by field load_agg */
      78    IPA_JF_ANCESTOR	    /* represented by field ancestor */
      79  };
      80  
      81  struct ipa_cst_ref_desc;
      82  
      83  /* Structure holding data required to describe a constant jump function.  */
      84  struct GTY(()) ipa_constant_data
      85  {
      86    /* The value of the constant.  */
      87    tree value;
      88    /* Pointer to the structure that describes the reference.  */
      89    struct ipa_cst_ref_desc GTY((skip)) *rdesc;
      90  };
      91  
      92  /* Structure holding data required to describe a pass-through jump function.  */
      93  
      94  struct GTY(()) ipa_pass_through_data
      95  {
      96    /* If an operation is to be performed on the original parameter, this is the
      97       second (constant) operand.  */
      98    tree operand;
      99    /* Number of the caller's formal parameter being passed.  */
     100    int formal_id;
     101    /* Operation that is performed on the argument before it is passed on.
     102       Special values which have other meaning than in normal contexts:
     103         - NOP_EXPR means no operation, not even type conversion.
     104         - ASSERT_EXPR means that only the value in operand is allowed to pass
     105           through (without any change), for all other values the result is
     106           unknown.
     107       Otherwise operation must be a simple binary or unary arithmetic operation
     108       where the caller's parameter is the first operand and (for binary
     109       operations) the operand field from this structure is the second one.  */
     110    enum tree_code operation;
     111    /* When the passed value is a pointer, it is set to true only when we are
     112       certain that no write to the object it points to has occurred since the
     113       caller functions started execution, except for changes noted in the
     114       aggregate part of the jump function (see description of
     115       ipa_agg_jump_function).  The flag is used only when the operation is
     116       NOP_EXPR.  */
     117    unsigned agg_preserved : 1;
     118    /* Set when the edge has already been used to decrement an appropriate
     119       reference description counter and should not be decremented again.  */
     120    unsigned refdesc_decremented : 1;
     121  };
     122  
     123  /* Structure holding data required to describe a load-value-from-aggregate
     124     jump function.  */
     125  
     126  struct GTY(()) ipa_load_agg_data
     127  {
     128    /* Inherit from pass through jump function, describing unary/binary
     129       operation on the value loaded from aggregate that is represented or
     130       pointed to by the formal parameter, specified by formal_id in this
     131       pass_through jump function data structure.  */
     132    struct ipa_pass_through_data pass_through;
     133    /* Type of the value loaded from the aggregate.  */
     134    tree type;
     135    /* Offset at which the value is located within the aggregate.  */
     136    HOST_WIDE_INT offset;
     137    /* True if loaded by reference (the aggregate is pointed to by the formal
     138       parameter) or false if loaded by value (the aggregate is represented
     139       by the formal parameter).  */
     140    bool by_ref;
     141  };
     142  
     143  /* Structure holding data required to describe an ancestor pass-through
     144     jump function.  */
     145  
     146  struct GTY(()) ipa_ancestor_jf_data
     147  {
     148    /* Offset of the field representing the ancestor.  */
     149    HOST_WIDE_INT offset;
     150    /* Number of the caller's formal parameter being passed.  */
     151    int formal_id;
     152    /* Flag with the same meaning like agg_preserve in ipa_pass_through_data.  */
     153    unsigned agg_preserved : 1;
     154    /* When set, the operation should not have any effect on NULL pointers.  */
     155    unsigned keep_null : 1;
     156  };
     157  
     158  /* A jump function for an aggregate part at a given offset, which describes how
     159     it content value is generated.  All unlisted positions are assumed to have a
     160     value defined in an unknown way.  */
     161  
     162  struct GTY(()) ipa_agg_jf_item
     163  {
     164    /* The offset for the aggregate part.  */
     165    HOST_WIDE_INT offset;
     166  
     167    /* Data type of the aggregate part.  */
     168    tree type;
     169  
     170    /* Jump function type.  */
     171    enum jump_func_type jftype;
     172  
     173    /* Represents a value of jump function. constant represents the actual constant
     174       in constant jump function content.  pass_through is used only in simple pass
     175       through jump function context.  load_agg is for load-value-from-aggregate
     176       jump function context.  */
     177    union jump_func_agg_value
     178    {
     179      tree GTY ((tag ("IPA_JF_CONST"))) constant;
     180      struct ipa_pass_through_data GTY ((tag ("IPA_JF_PASS_THROUGH"))) pass_through;
     181      struct ipa_load_agg_data GTY ((tag ("IPA_JF_LOAD_AGG"))) load_agg;
     182    } GTY ((desc ("%1.jftype"))) value;
     183  };
     184  
     185  /* Jump functions describing a set of aggregate contents.  */
     186  
     187  struct GTY(()) ipa_agg_jump_function
     188  {
     189    /* Description of the individual jump function item.  */
     190    vec<ipa_agg_jf_item, va_gc> *items;
     191    /* True if the data was passed by reference (as opposed to by value).  */
     192    bool by_ref;
     193  };
     194  
     195  class ipcp_transformation;
     196  class ipa_auto_call_arg_values;
     197  class ipa_call_arg_values;
     198  
     199  /* Element of a vector describing aggregate values for a number of arguments in
     200     a particular context, be it a call or the aggregate constants that a node is
     201     specialized for.  */
     202  
     203  struct GTY(()) ipa_argagg_value
     204  {
     205    /* The constant value.  In the contexts where the list of known values is
     206       being pruned, NULL means a variable value.  */
     207    tree value;
     208    /* Unit offset within the aggregate.  */
     209    unsigned unit_offset;
     210    /* Index of the parameter, as it was in the original function (i.e. needs
     211       remapping after parameter modification is carried out as part of clone
     212       materialization).  */
     213    unsigned index : IPA_PROP_ARG_INDEX_LIMIT_BITS;
     214    /* Whether the value was passed by reference.  */
     215    unsigned by_ref : 1;
     216  };
     217  
     218  /* A view into a sorted list of aggregate values in a particular context, be it
     219     a call or the aggregate constants that a node is specialized for.  The
     220     actual data is stored in the vector this has been constructed from.  */
     221  
     222  class ipa_argagg_value_list
     223  {
     224  public:
     225    ipa_argagg_value_list () = delete;
     226    ipa_argagg_value_list (const vec<ipa_argagg_value, va_gc> *values)
     227      : m_elts (values)
     228    {}
     229    ipa_argagg_value_list (const vec<ipa_argagg_value> *values)
     230      : m_elts (*values)
     231    {}
     232    ipa_argagg_value_list (const ipa_auto_call_arg_values *aavals);
     233    ipa_argagg_value_list (const ipa_call_arg_values *gavals);
     234    ipa_argagg_value_list (const ipcp_transformation *tinfo);
     235  
     236    /* Return the aggregate constant stored for INDEX at UNIT_OFFSET, if it is
     237       passed by reference or not according to BY_REF, or NULL_TREE
     238       otherwise.  */
     239  
     240    tree get_value (int index, unsigned unit_offset, bool by_ref) const;
     241  
     242    /* Return the aggregate constant stored for INDEX at UNIT_OFFSET, not
     243       performing any check of whether value is passed by reference.  Return
     244       NULL_TREE if there is no such constant.  */
     245  
     246    tree get_value (int index, unsigned unit_offset) const;
     247  
     248    /* Return the item describing a constant stored for INDEX at UNIT_OFFSET or
     249       NULL if there is no such constant.  */
     250  
     251    const ipa_argagg_value *get_elt (int index, unsigned unit_offset) const;
     252  
     253  
     254    /* Return the first item describing a constant stored for parameter with
     255       INDEX, regardless of offset or reference, or NULL if there is no such
     256       constant.  */
     257  
     258    const ipa_argagg_value *get_elt_for_index (int index) const;
     259  
     260    /* Return true if there is an aggregate constant referring to a value passed
     261       in or by parameter with INDEX (at any offset, whether by reference or
     262       not).  */
     263  
     264    bool value_for_index_p (int index) const
     265    {
     266      return !!get_elt_for_index (index);
     267    }
     268  
     269    /* Return true if all elements present in OTHER are also present in this
     270       list.  */
     271  
     272    bool superset_of_p (const ipa_argagg_value_list &other) const;
     273  
     274    /* Push all items in this list that describe parameter SRC_INDEX into RES as
     275       ones describing DST_INDEX while subtracting UNIT_DELTA from their unit
     276       offsets but skip those which would end up with a negative offset.  */
     277  
     278    void push_adjusted_values (unsigned src_index, unsigned dest_index,
     279  			     unsigned unit_delta,
     280  			     vec<ipa_argagg_value> *res) const;
     281  
     282    /* Dump aggregate constants to FILE.  */
     283  
     284    void dump (FILE *f);
     285  
     286    /* Dump aggregate constants to stderr.  */
     287  
     288    void DEBUG_FUNCTION debug ();
     289  
     290    /* Array slice pointing to the actual storage.  */
     291  
     292    array_slice<const ipa_argagg_value> m_elts;
     293  };
     294  
     295  /* Information about zero/non-zero bits.  */
     296  class GTY(()) ipa_bits
     297  {
     298  public:
     299    /* The propagated value.  */
     300    widest_int value;
     301    /* Mask corresponding to the value.
     302       Similar to ccp_lattice_t, if xth bit of mask is 0,
     303       implies xth bit of value is constant.  */
     304    widest_int mask;
     305  };
     306  
     307  /* Info about value ranges.  */
     308  
     309  class GTY(()) ipa_vr
     310  {
     311  public:
     312    /* The data fields below are valid only if known is true.  */
     313    bool known;
     314    enum value_range_kind type;
     315    wide_int min;
     316    wide_int max;
     317    bool nonzero_p (tree) const;
     318  };
     319  
     320  /* A jump function for a callsite represents the values passed as actual
     321     arguments of the callsite. See enum jump_func_type for the various
     322     types of jump functions supported.  */
     323  struct GTY (()) ipa_jump_func
     324  {
     325    /* Aggregate jump function description.  See struct ipa_agg_jump_function
     326       and its description.  */
     327    struct ipa_agg_jump_function agg;
     328  
     329    /* Information about zero/non-zero bits.  The pointed to structure is shared
     330       betweed different jump functions.  Use ipa_set_jfunc_bits to set this
     331       field.  */
     332    class ipa_bits *bits;
     333  
     334    /* Information about value range, containing valid data only when vr_known is
     335       true.  The pointed to structure is shared betweed different jump
     336       functions.  Use ipa_set_jfunc_vr to set this field.  */
     337    value_range *m_vr;
     338  
     339    enum jump_func_type type;
     340    /* Represents a value of a jump function.  pass_through is used only in jump
     341       function context.  constant represents the actual constant in constant jump
     342       functions and member_cst holds constant c++ member functions.  */
     343    union jump_func_value
     344    {
     345      struct ipa_constant_data GTY ((tag ("IPA_JF_CONST"))) constant;
     346      struct ipa_pass_through_data GTY ((tag ("IPA_JF_PASS_THROUGH"))) pass_through;
     347      struct ipa_ancestor_jf_data GTY ((tag ("IPA_JF_ANCESTOR"))) ancestor;
     348    } GTY ((desc ("%1.type"))) value;
     349  };
     350  
     351  
     352  /* Return the constant stored in a constant jump functin JFUNC.  */
     353  
     354  inline tree
     355  ipa_get_jf_constant (struct ipa_jump_func *jfunc)
     356  {
     357    gcc_checking_assert (jfunc->type == IPA_JF_CONST);
     358    return jfunc->value.constant.value;
     359  }
     360  
     361  inline struct ipa_cst_ref_desc *
     362  ipa_get_jf_constant_rdesc (struct ipa_jump_func *jfunc)
     363  {
     364    gcc_checking_assert (jfunc->type == IPA_JF_CONST);
     365    return jfunc->value.constant.rdesc;
     366  }
     367  
     368  /* Make JFUNC not participate in any further reference counting.  */
     369  
     370  inline void
     371  ipa_zap_jf_refdesc (ipa_jump_func *jfunc)
     372  {
     373    gcc_checking_assert (jfunc->type == IPA_JF_CONST);
     374    jfunc->value.constant.rdesc = NULL;
     375  }
     376  
     377  /* Return the operand of a pass through jmp function JFUNC.  */
     378  
     379  inline tree
     380  ipa_get_jf_pass_through_operand (struct ipa_jump_func *jfunc)
     381  {
     382    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     383    return jfunc->value.pass_through.operand;
     384  }
     385  
     386  /* Return the number of the caller's formal parameter that a pass through jump
     387     function JFUNC refers to.  */
     388  
     389  inline int
     390  ipa_get_jf_pass_through_formal_id (struct ipa_jump_func *jfunc)
     391  {
     392    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     393    return jfunc->value.pass_through.formal_id;
     394  }
     395  
     396  /* Return operation of a pass through jump function JFUNC.  */
     397  
     398  inline enum tree_code
     399  ipa_get_jf_pass_through_operation (struct ipa_jump_func *jfunc)
     400  {
     401    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     402    return jfunc->value.pass_through.operation;
     403  }
     404  
     405  /* Return the agg_preserved flag of a pass through jump function JFUNC.  */
     406  
     407  inline bool
     408  ipa_get_jf_pass_through_agg_preserved (struct ipa_jump_func *jfunc)
     409  {
     410    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     411    return jfunc->value.pass_through.agg_preserved;
     412  }
     413  
     414  /* Return the refdesc_decremented flag of a pass through jump function
     415     JFUNC.  */
     416  
     417  inline bool
     418  ipa_get_jf_pass_through_refdesc_decremented (struct ipa_jump_func *jfunc)
     419  {
     420    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     421    return jfunc->value.pass_through.refdesc_decremented;
     422  }
     423  
     424  /* Set the refdesc_decremented flag of a pass through jump function JFUNC to
     425     VALUE.  */
     426  
     427  inline void
     428  ipa_set_jf_pass_through_refdesc_decremented (ipa_jump_func *jfunc, bool value)
     429  {
     430    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     431    jfunc->value.pass_through.refdesc_decremented = value;
     432  }
     433  
     434  /* Return true if pass through jump function JFUNC preserves type
     435     information.  */
     436  
     437  inline bool
     438  ipa_get_jf_pass_through_type_preserved (struct ipa_jump_func *jfunc)
     439  {
     440    gcc_checking_assert (jfunc->type == IPA_JF_PASS_THROUGH);
     441    return jfunc->value.pass_through.agg_preserved;
     442  }
     443  
     444  /* Return the offset of an ancestor jump function JFUNC.  */
     445  
     446  inline HOST_WIDE_INT
     447  ipa_get_jf_ancestor_offset (struct ipa_jump_func *jfunc)
     448  {
     449    gcc_checking_assert (jfunc->type == IPA_JF_ANCESTOR);
     450    return jfunc->value.ancestor.offset;
     451  }
     452  
     453  /* Return the number of the caller's formal parameter that an ancestor jump
     454     function JFUNC refers to.  */
     455  
     456  inline int
     457  ipa_get_jf_ancestor_formal_id (struct ipa_jump_func *jfunc)
     458  {
     459    gcc_checking_assert (jfunc->type == IPA_JF_ANCESTOR);
     460    return jfunc->value.ancestor.formal_id;
     461  }
     462  
     463  /* Return the agg_preserved flag of an ancestor jump function JFUNC.  */
     464  
     465  inline bool
     466  ipa_get_jf_ancestor_agg_preserved (struct ipa_jump_func *jfunc)
     467  {
     468    gcc_checking_assert (jfunc->type == IPA_JF_ANCESTOR);
     469    return jfunc->value.ancestor.agg_preserved;
     470  }
     471  
     472  /* Return true if ancestor jump function JFUNC presrves type information.  */
     473  
     474  inline bool
     475  ipa_get_jf_ancestor_type_preserved (struct ipa_jump_func *jfunc)
     476  {
     477    gcc_checking_assert (jfunc->type == IPA_JF_ANCESTOR);
     478    return jfunc->value.ancestor.agg_preserved;
     479  }
     480  
     481  /* Return if jfunc represents an operation whether we first check the formal
     482     parameter for non-NULLness unless it does not matter because the offset is
     483     zero anyway.  */
     484  
     485  inline bool
     486  ipa_get_jf_ancestor_keep_null (struct ipa_jump_func *jfunc)
     487  {
     488    gcc_checking_assert (jfunc->type == IPA_JF_ANCESTOR);
     489    return jfunc->value.ancestor.keep_null;
     490  }
     491  
     492  /* Class for allocating a bundle of various potentially known properties about
     493     actual arguments of a particular call on stack for the usual case and on
     494     heap only if there are unusually many arguments.  The data is deallocated
     495     when the instance of this class goes out of scope or is otherwise
     496     destructed.  */
     497  
     498  class ipa_auto_call_arg_values
     499  {
     500  public:
     501    /* If m_known_vals (vector of known "scalar" values) is sufficiantly long,
     502       return its element at INDEX, otherwise return NULL.  */
     503    tree safe_sval_at (int index)
     504    {
     505      if ((unsigned) index < m_known_vals.length ())
     506        return m_known_vals[index];
     507      return NULL;
     508    }
     509  
     510    /* Vector describing known values of parameters.  */
     511    auto_vec<tree, 32> m_known_vals;
     512  
     513    /* Vector describing known polymorphic call contexts.  */
     514    auto_vec<ipa_polymorphic_call_context, 32> m_known_contexts;
     515  
     516    /* Vector describing known aggregate values.  */
     517    auto_vec<ipa_argagg_value, 32> m_known_aggs;
     518  
     519    /* Vector describing known value ranges of arguments.  */
     520    auto_vec<value_range, 32> m_known_value_ranges;
     521  };
     522  
     523  inline
     524  ipa_argagg_value_list
     525  ::ipa_argagg_value_list (const ipa_auto_call_arg_values *aavals)
     526    : m_elts (aavals->m_known_aggs)
     527  {}
     528  
     529  /* Class bundling the various potentially known properties about actual
     530     arguments of a particular call.  This variant does not deallocate the
     531     bundled data in any way as the vectors can either be pointing to vectors in
     532     ipa_auto_call_arg_values or be allocated independently.  */
     533  
     534  class ipa_call_arg_values
     535  {
     536  public:
     537    /* Default constructor, setting the vectors to empty ones.  */
     538    ipa_call_arg_values ()
     539    {}
     540  
     541    /* Construct this general variant of the bundle from the variant which uses
     542       auto_vecs to hold the vectors.  This means that vectors of objects
     543       constructed with this constructor should not be changed because if they
     544       get reallocated, the member vectors and the underlying auto_vecs would get
     545       out of sync.  */
     546    ipa_call_arg_values (ipa_auto_call_arg_values *aavals)
     547      : m_known_vals (aavals->m_known_vals.to_vec_legacy ()),
     548        m_known_contexts (aavals->m_known_contexts.to_vec_legacy ()),
     549        m_known_aggs (aavals->m_known_aggs.to_vec_legacy ()),
     550        m_known_value_ranges (aavals->m_known_value_ranges.to_vec_legacy ())
     551    {}
     552  
     553    /* If m_known_vals (vector of known "scalar" values) is sufficiantly long,
     554       return its element at INDEX, otherwise return NULL.  */
     555    tree safe_sval_at (int index)
     556    {
     557      if ((unsigned) index < m_known_vals.length ())
     558        return m_known_vals[index];
     559      return NULL;
     560    }
     561  
     562    /* Vector describing known values of parameters.  */
     563    vec<tree> m_known_vals = vNULL;
     564  
     565    /* Vector describing known polymorphic call contexts.  */
     566    vec<ipa_polymorphic_call_context> m_known_contexts = vNULL;
     567  
     568    /* Vector describing known aggregate values.  */
     569    vec<ipa_argagg_value> m_known_aggs = vNULL;
     570  
     571    /* Vector describing known value ranges of arguments.  */
     572    vec<value_range> m_known_value_ranges = vNULL;
     573  };
     574  
     575  inline
     576  ipa_argagg_value_list
     577  ::ipa_argagg_value_list (const ipa_call_arg_values *gavals)
     578    : m_elts (gavals->m_known_aggs)
     579  {}
     580  
     581  /* Summary describing a single formal parameter.  */
     582  
     583  struct GTY(()) ipa_param_descriptor
     584  {
     585    /* In analysis and modification phase, this is the PARAM_DECL of this
     586       parameter, in IPA LTO phase, this is the type of the described
     587       parameter or NULL if not known.  Do not read this field directly but
     588       through ipa_get_param and ipa_get_type as appropriate.  */
     589    tree decl_or_type;
     590    /* If all uses of the parameter are described by ipa-prop structures, this
     591       says how many there are.  If any use could not be described by means of
     592       ipa-prop structures (which include flag dereferenced below), this is
     593       IPA_UNDESCRIBED_USE.  */
     594    int controlled_uses;
     595    unsigned int move_cost : 27;
     596    /* The parameter is used.  */
     597    unsigned used : 1;
     598    unsigned used_by_ipa_predicates : 1;
     599    unsigned used_by_indirect_call : 1;
     600    unsigned used_by_polymorphic_call : 1;
     601    /* Set to true when in addition to being used in call statements, the
     602       parameter has also been used for loads (but not for writes, does not
     603       escape, etc.).  This allows us to identify parameters p which are only
     604       used as *p, and so when we propagate a constant to them, we can generate a
     605       LOAD and not ADDR reference to them.  */
     606    unsigned load_dereferenced : 1;
     607  };
     608  
     609  /* ipa_node_params stores information related to formal parameters of functions
     610     and some other information for interprocedural passes that operate on
     611     parameters (such as ipa-cp).  */
     612  
     613  class GTY((for_user)) ipa_node_params
     614  {
     615  public:
     616    /* Default constructor.  */
     617    ipa_node_params ();
     618  
     619    /* Default destructor.  */
     620    ~ipa_node_params ();
     621  
     622    /* Information about individual formal parameters that are gathered when
     623       summaries are generated. */
     624    vec<ipa_param_descriptor, va_gc> *descriptors;
     625    /* Pointer to an array of structures describing individual formal
     626       parameters.  */
     627    class ipcp_param_lattices * GTY((skip)) lattices;
     628    /* Only for versioned nodes this field would not be NULL,
     629       it points to the node that IPA cp cloned from.  */
     630    struct cgraph_node * GTY((skip)) ipcp_orig_node;
     631    /* If this node is an ipa-cp clone, these are the known constants that
     632       describe what it has been specialized for.  */
     633    vec<tree> GTY((skip)) known_csts;
     634    /* If this node is an ipa-cp clone, these are the known polymorphic contexts
     635       that describe what it has been specialized for.  */
     636    vec<ipa_polymorphic_call_context> GTY((skip)) known_contexts;
     637    /* Whether the param uses analysis and jump function computation has already
     638       been performed.  */
     639    unsigned analysis_done : 1;
     640    /* Whether the function is enqueued in ipa-cp propagation stack.  */
     641    unsigned node_enqueued : 1;
     642    /* Whether we should create a specialized version based on values that are
     643       known to be constant in all contexts.  */
     644    unsigned do_clone_for_all_contexts : 1;
     645    /* Set if this is an IPA-CP clone for all contexts.  */
     646    unsigned is_all_contexts_clone : 1;
     647    /* Node has been completely replaced by clones and will be removed after
     648       ipa-cp is finished.  */
     649    unsigned node_dead : 1;
     650    /* Node is involved in a recursion, potentionally indirect.  */
     651    unsigned node_within_scc : 1;
     652    /* Node contains only direct recursion.  */
     653    unsigned node_is_self_scc : 1;
     654    /* Node is calling a private function called only once.  */
     655    unsigned node_calling_single_call : 1;
     656    /* False when there is something makes versioning impossible.  */
     657    unsigned versionable : 1;
     658  };
     659  
     660  inline
     661  ipa_node_params::ipa_node_params ()
     662  : descriptors (NULL), lattices (NULL), ipcp_orig_node (NULL),
     663    known_csts (vNULL), known_contexts (vNULL), analysis_done (0),
     664    node_enqueued (0), do_clone_for_all_contexts (0), is_all_contexts_clone (0),
     665    node_dead (0), node_within_scc (0), node_is_self_scc (0),
     666    node_calling_single_call (0), versionable (0)
     667  {
     668  }
     669  
     670  inline
     671  ipa_node_params::~ipa_node_params ()
     672  {
     673    free (lattices);
     674    vec_free (descriptors);
     675    known_csts.release ();
     676    known_contexts.release ();
     677  }
     678  
     679  /* Intermediate information that we get from alias analysis about a particular
     680     parameter in a particular basic_block.  When a parameter or the memory it
     681     references is marked modified, we use that information in all dominated
     682     blocks without consulting alias analysis oracle.  */
     683  
     684  struct ipa_param_aa_status
     685  {
     686    /* Set when this structure contains meaningful information.  If not, the
     687       structure describing a dominating BB should be used instead.  */
     688    bool valid;
     689  
     690    /* Whether we have seen something which might have modified the data in
     691       question.  PARM is for the parameter itself, REF is for data it points to
     692       but using the alias type of individual accesses and PT is the same thing
     693       but for computing aggregate pass-through functions using a very inclusive
     694       ao_ref.  */
     695    bool parm_modified, ref_modified, pt_modified;
     696  };
     697  
     698  /* Information related to a given BB that used only when looking at function
     699     body.  */
     700  
     701  struct ipa_bb_info
     702  {
     703    /* Call graph edges going out of this BB.  */
     704    vec<cgraph_edge *> cg_edges;
     705    /* Alias analysis statuses of each formal parameter at this bb.  */
     706    vec<ipa_param_aa_status> param_aa_statuses;
     707  };
     708  
     709  /* Structure with global information that is only used when looking at function
     710     body. */
     711  
     712  struct ipa_func_body_info
     713  {
     714    /* The node that is being analyzed.  */
     715    cgraph_node *node;
     716  
     717    /* Its info.  */
     718    class ipa_node_params *info;
     719  
     720    /* Information about individual BBs. */
     721    vec<ipa_bb_info> bb_infos;
     722  
     723    /* Number of parameters.  */
     724    int param_count;
     725  
     726    /* Number of statements we are still allowed to walked by when analyzing this
     727       function.  */
     728    unsigned int aa_walk_budget;
     729  };
     730  
     731  /* ipa_node_params access functions.  Please use these to access fields that
     732     are or will be shared among various passes.  */
     733  
     734  /* Return the number of formal parameters. */
     735  
     736  inline int
     737  ipa_get_param_count (class ipa_node_params *info)
     738  {
     739    return vec_safe_length (info->descriptors);
     740  }
     741  
     742  /* Return the parameter declaration in DESCRIPTORS at index I and assert it is
     743     indeed a PARM_DECL.  */
     744  
     745  inline tree
     746  ipa_get_param (const vec<ipa_param_descriptor, va_gc> &descriptors, int i)
     747  {
     748    tree t = descriptors[i].decl_or_type;
     749    gcc_checking_assert (TREE_CODE (t) == PARM_DECL);
     750    return t;
     751  }
     752  
     753  /* Return the declaration of Ith formal parameter of the function corresponding
     754     to INFO.  Note there is no setter function as this array is built just once
     755     using ipa_initialize_node_params.  This function should not be called in
     756     WPA.  */
     757  
     758  inline tree
     759  ipa_get_param (class ipa_node_params *info, int i)
     760  {
     761    gcc_checking_assert (info->descriptors);
     762    return ipa_get_param (*info->descriptors, i);
     763  }
     764  
     765  /* Return the type of Ith formal parameter of the function corresponding
     766     to INFO if it is known or NULL if not.  */
     767  
     768  inline tree
     769  ipa_get_type (class ipa_node_params *info, int i)
     770  {
     771    if (vec_safe_length (info->descriptors) <= (unsigned) i)
     772      return NULL;
     773    tree t = (*info->descriptors)[i].decl_or_type;
     774    if (!t)
     775      return NULL;
     776    if (TYPE_P (t))
     777      return t;
     778    gcc_checking_assert (TREE_CODE (t) == PARM_DECL);
     779    return TREE_TYPE (t);
     780  }
     781  
     782  /* Return the move cost of Ith formal parameter of the function corresponding
     783     to INFO.  */
     784  
     785  inline int
     786  ipa_get_param_move_cost (class ipa_node_params *info, int i)
     787  {
     788    gcc_checking_assert (info->descriptors);
     789    return (*info->descriptors)[i].move_cost;
     790  }
     791  
     792  /* Set the used flag corresponding to the Ith formal parameter of the function
     793     associated with INFO to VAL.  */
     794  
     795  inline void
     796  ipa_set_param_used (class ipa_node_params *info, int i, bool val)
     797  {
     798    gcc_checking_assert (info->descriptors);
     799    (*info->descriptors)[i].used = val;
     800  }
     801  
     802  /* Set the used_by_ipa_predicates flag corresponding to the Ith formal
     803     parameter of the function associated with INFO to VAL.  */
     804  
     805  inline void
     806  ipa_set_param_used_by_ipa_predicates (class ipa_node_params *info, int i, bool val)
     807  {
     808    gcc_checking_assert (info->descriptors);
     809    (*info->descriptors)[i].used_by_ipa_predicates = val;
     810  }
     811  
     812  /* Set the used_by_indirect_call flag corresponding to the Ith formal
     813     parameter of the function associated with INFO to VAL.  */
     814  
     815  inline void
     816  ipa_set_param_used_by_indirect_call (class ipa_node_params *info, int i, bool val)
     817  {
     818    gcc_checking_assert (info->descriptors);
     819    (*info->descriptors)[i].used_by_indirect_call = val;
     820  }
     821  
     822  /* Set the .used_by_polymorphic_call flag corresponding to the Ith formal
     823     parameter of the function associated with INFO to VAL.  */
     824  
     825  inline void
     826  ipa_set_param_used_by_polymorphic_call (class ipa_node_params *info, int i, bool val)
     827  {
     828    gcc_checking_assert (info->descriptors);
     829    (*info->descriptors)[i].used_by_polymorphic_call = val;
     830  }
     831  
     832  /* Return how many uses described by ipa-prop a parameter has or
     833     IPA_UNDESCRIBED_USE if there is a use that is not described by these
     834     structures.  */
     835  inline int
     836  ipa_get_controlled_uses (class ipa_node_params *info, int i)
     837  {
     838    /* FIXME: introducing speculation causes out of bounds access here.  */
     839    if (vec_safe_length (info->descriptors) > (unsigned)i)
     840      return (*info->descriptors)[i].controlled_uses;
     841    return IPA_UNDESCRIBED_USE;
     842  }
     843  
     844  /* Set the controlled counter of a given parameter.  */
     845  
     846  inline void
     847  ipa_set_controlled_uses (class ipa_node_params *info, int i, int val)
     848  {
     849    gcc_checking_assert (info->descriptors);
     850    (*info->descriptors)[i].controlled_uses = val;
     851  }
     852  
     853  /* Assuming a parameter does not have IPA_UNDESCRIBED_USE controlled uses,
     854     return flag which indicates it has been dereferenced but only in a load.  */
     855  inline int
     856  ipa_get_param_load_dereferenced (class ipa_node_params *info, int i)
     857  {
     858    gcc_assert (ipa_get_controlled_uses (info, i) != IPA_UNDESCRIBED_USE);
     859    return (*info->descriptors)[i].load_dereferenced;
     860  }
     861  
     862  /* Set the load_dereferenced flag of a given parameter.  */
     863  
     864  inline void
     865  ipa_set_param_load_dereferenced (class ipa_node_params *info, int i, bool val)
     866  {
     867    gcc_checking_assert (info->descriptors);
     868    (*info->descriptors)[i].load_dereferenced = val;
     869  }
     870  
     871  /* Return the used flag corresponding to the Ith formal parameter of the
     872     function associated with INFO.  */
     873  
     874  inline bool
     875  ipa_is_param_used (class ipa_node_params *info, int i)
     876  {
     877    gcc_checking_assert (info->descriptors);
     878    return (*info->descriptors)[i].used;
     879  }
     880  
     881  /* Return the used_by_ipa_predicates flag corresponding to the Ith formal
     882     parameter of the function associated with INFO.  */
     883  
     884  inline bool
     885  ipa_is_param_used_by_ipa_predicates (class ipa_node_params *info, int i)
     886  {
     887    gcc_checking_assert (info->descriptors);
     888    return (*info->descriptors)[i].used_by_ipa_predicates;
     889  }
     890  
     891  /* Return the used_by_indirect_call flag corresponding to the Ith formal
     892     parameter of the function associated with INFO.  */
     893  
     894  inline bool
     895  ipa_is_param_used_by_indirect_call (class ipa_node_params *info, int i)
     896  {
     897    gcc_checking_assert (info->descriptors);
     898    return (*info->descriptors)[i].used_by_indirect_call;
     899  }
     900  
     901  /* Return the used_by_polymorphic_call flag corresponding to the Ith formal
     902     parameter of the function associated with INFO.  */
     903  
     904  inline bool
     905  ipa_is_param_used_by_polymorphic_call (class ipa_node_params *info, int i)
     906  {
     907    gcc_checking_assert (info->descriptors);
     908    return (*info->descriptors)[i].used_by_polymorphic_call;
     909  }
     910  
     911  /* Structure holding information for the transformation phase of IPA-CP.  */
     912  
     913  struct GTY(()) ipcp_transformation
     914  {
     915    /* Known aggregate values.  */
     916    vec<ipa_argagg_value, va_gc>  *m_agg_values;
     917    /* Known bits information.  */
     918    vec<ipa_bits *, va_gc> *bits;
     919    /* Value range information.  */
     920    vec<ipa_vr, va_gc> *m_vr;
     921  
     922    /* Default constructor.  */
     923    ipcp_transformation ()
     924    : m_agg_values (NULL), bits (NULL), m_vr (NULL)
     925    { }
     926  
     927    /* Default destructor.  */
     928    ~ipcp_transformation ()
     929    {
     930      vec_free (m_agg_values);
     931      vec_free (bits);
     932      vec_free (m_vr);
     933    }
     934  };
     935  
     936  inline
     937  ipa_argagg_value_list::ipa_argagg_value_list (const ipcp_transformation *tinfo)
     938    : m_elts (tinfo->m_agg_values)
     939  {}
     940  
     941  void ipa_set_node_agg_value_chain (struct cgraph_node *node,
     942  				   vec<ipa_argagg_value, va_gc> *aggs);
     943  void ipcp_transformation_initialize (void);
     944  void ipcp_free_transformation_sum (void);
     945  
     946  /* ipa_edge_args stores information related to a callsite and particularly its
     947     arguments.  It can be accessed by the IPA_EDGE_REF macro.  */
     948  
     949  class GTY((for_user)) ipa_edge_args
     950  {
     951   public:
     952  
     953    /* Default constructor.  */
     954    ipa_edge_args () : jump_functions (NULL), polymorphic_call_contexts (NULL)
     955      {}
     956  
     957    /* Destructor.  */
     958    ~ipa_edge_args ()
     959      {
     960        unsigned int i;
     961        ipa_jump_func *jf;
     962        FOR_EACH_VEC_SAFE_ELT (jump_functions, i, jf)
     963  	vec_free (jf->agg.items);
     964        vec_free (jump_functions);
     965        vec_free (polymorphic_call_contexts);
     966      }
     967  
     968    /* Vectors of the callsite's jump function and polymorphic context
     969       information of each parameter.  */
     970    vec<ipa_jump_func, va_gc> *jump_functions;
     971    vec<ipa_polymorphic_call_context, va_gc> *polymorphic_call_contexts;
     972  };
     973  
     974  /* ipa_edge_args access functions.  Please use these to access fields that
     975     are or will be shared among various passes.  */
     976  
     977  /* Return the number of actual arguments. */
     978  
     979  inline int
     980  ipa_get_cs_argument_count (class ipa_edge_args *args)
     981  {
     982    return vec_safe_length (args->jump_functions);
     983  }
     984  
     985  /* Returns a pointer to the jump function for the ith argument.  Please note
     986     there is no setter function as jump functions are all set up in
     987     ipa_compute_jump_functions. */
     988  
     989  inline struct ipa_jump_func *
     990  ipa_get_ith_jump_func (class ipa_edge_args *args, int i)
     991  {
     992    return &(*args->jump_functions)[i];
     993  }
     994  
     995  /* Returns a pointer to the polymorphic call context for the ith argument.
     996     NULL if contexts are not computed.  */
     997  inline class ipa_polymorphic_call_context *
     998  ipa_get_ith_polymorhic_call_context (class ipa_edge_args *args, int i)
     999  {
    1000    if (!args->polymorphic_call_contexts)
    1001      return NULL;
    1002    return &(*args->polymorphic_call_contexts)[i];
    1003  }
    1004  
    1005  /* Function summary for ipa_node_params.  */
    1006  class GTY((user)) ipa_node_params_t: public function_summary <ipa_node_params *>
    1007  {
    1008  public:
    1009    ipa_node_params_t (symbol_table *table, bool ggc):
    1010      function_summary<ipa_node_params *> (table, ggc)
    1011    {
    1012      disable_insertion_hook ();
    1013    }
    1014  
    1015    /* Hook that is called by summary when a node is duplicated.  */
    1016    void duplicate (cgraph_node *node,
    1017  		  cgraph_node *node2,
    1018  		  ipa_node_params *data,
    1019  		  ipa_node_params *data2) final override;
    1020  };
    1021  
    1022  /* Summary to manange ipa_edge_args structures.  */
    1023  
    1024  class GTY((user)) ipa_edge_args_sum_t : public call_summary <ipa_edge_args *>
    1025  {
    1026   public:
    1027    ipa_edge_args_sum_t (symbol_table *table, bool ggc)
    1028      : call_summary<ipa_edge_args *> (table, ggc) { }
    1029  
    1030    void remove (cgraph_edge *edge)
    1031    {
    1032      call_summary <ipa_edge_args *>::remove (edge);
    1033    }
    1034  
    1035    /* Hook that is called by summary when an edge is removed.  */
    1036    void remove (cgraph_edge *cs, ipa_edge_args *args) final override;
    1037    /* Hook that is called by summary when an edge is duplicated.  */
    1038    void duplicate (cgraph_edge *src,
    1039  		  cgraph_edge *dst,
    1040  		  ipa_edge_args *old_args,
    1041  		  ipa_edge_args *new_args) final override;
    1042  };
    1043  
    1044  /* Function summary where the parameter infos are actually stored. */
    1045  extern GTY(()) ipa_node_params_t * ipa_node_params_sum;
    1046  /* Call summary to store information about edges such as jump functions.  */
    1047  extern GTY(()) ipa_edge_args_sum_t *ipa_edge_args_sum;
    1048  
    1049  /* Function summary for IPA-CP transformation.  */
    1050  class ipcp_transformation_t
    1051  : public function_summary<ipcp_transformation *>
    1052  {
    1053  public:
    1054    ipcp_transformation_t (symbol_table *table, bool ggc):
    1055      function_summary<ipcp_transformation *> (table, ggc) {}
    1056  
    1057    ~ipcp_transformation_t () {}
    1058  
    1059    static ipcp_transformation_t *create_ggc (symbol_table *symtab)
    1060    {
    1061      ipcp_transformation_t *summary
    1062        = new (ggc_alloc_no_dtor <ipcp_transformation_t> ())
    1063        ipcp_transformation_t (symtab, true);
    1064      return summary;
    1065    }
    1066    /* Hook that is called by summary when a node is duplicated.  */
    1067    void duplicate (cgraph_node *node,
    1068  		  cgraph_node *node2,
    1069  		  ipcp_transformation *data,
    1070  		  ipcp_transformation *data2) final override;
    1071  };
    1072  
    1073  /* Function summary where the IPA CP transformations are actually stored.  */
    1074  extern GTY(()) function_summary <ipcp_transformation *> *ipcp_transformation_sum;
    1075  
    1076  /* Creating and freeing ipa_node_params and ipa_edge_args.  */
    1077  void ipa_create_all_node_params (void);
    1078  void ipa_create_all_edge_args (void);
    1079  void ipa_check_create_edge_args (void);
    1080  void ipa_free_all_node_params (void);
    1081  void ipa_free_all_edge_args (void);
    1082  void ipa_free_all_structures_after_ipa_cp (void);
    1083  void ipa_free_all_structures_after_iinln (void);
    1084  
    1085  void ipa_register_cgraph_hooks (void);
    1086  int count_formal_params (tree fndecl);
    1087  
    1088  /* This function ensures the array of node param infos is big enough to
    1089     accommodate a structure for all nodes and reallocates it if not.  */
    1090  
    1091  inline void
    1092  ipa_check_create_node_params (void)
    1093  {
    1094    if (!ipa_node_params_sum)
    1095      ipa_node_params_sum
    1096        = (new (ggc_alloc_no_dtor <ipa_node_params_t> ())
    1097  	 ipa_node_params_t (symtab, true));
    1098  }
    1099  
    1100  /* Returns true if edge summary contains a record for EDGE.  The main purpose
    1101     of this function is that debug dumping function can check info availability
    1102     without causing allocations.  */
    1103  
    1104  inline bool
    1105  ipa_edge_args_info_available_for_edge_p (struct cgraph_edge *edge)
    1106  {
    1107    return ipa_edge_args_sum->exists (edge);
    1108  }
    1109  
    1110  inline ipcp_transformation *
    1111  ipcp_get_transformation_summary (cgraph_node *node)
    1112  {
    1113    if (ipcp_transformation_sum == NULL)
    1114      return NULL;
    1115  
    1116    return ipcp_transformation_sum->get (node);
    1117  }
    1118  
    1119  /* Function formal parameters related computations.  */
    1120  void ipa_initialize_node_params (struct cgraph_node *node);
    1121  bool ipa_propagate_indirect_call_infos (struct cgraph_edge *cs,
    1122  					vec<cgraph_edge *> *new_edges);
    1123  
    1124  /* Indirect edge processing and target discovery.  */
    1125  tree ipa_get_indirect_edge_target (struct cgraph_edge *ie,
    1126  				   ipa_call_arg_values *avals,
    1127  				   bool *speculative);
    1128  struct cgraph_edge *ipa_make_edge_direct_to_target (struct cgraph_edge *, tree,
    1129  						    bool speculative = false);
    1130  tree ipa_impossible_devirt_target (struct cgraph_edge *, tree);
    1131  ipa_bits *ipa_get_ipa_bits_for_value (const widest_int &value,
    1132  				      const widest_int &mask);
    1133  
    1134  
    1135  /* Functions related to both.  */
    1136  void ipa_analyze_node (struct cgraph_node *);
    1137  
    1138  /* Aggregate jump function related functions.  */
    1139  tree ipa_find_agg_cst_from_init (tree scalar, HOST_WIDE_INT offset,
    1140  				 bool by_ref);
    1141  bool ipa_load_from_parm_agg (struct ipa_func_body_info *fbi,
    1142  			     vec<ipa_param_descriptor, va_gc> *descriptors,
    1143  			     gimple *stmt, tree op, int *index_p,
    1144  			     HOST_WIDE_INT *offset_p, poly_int64 *size_p,
    1145  			     bool *by_ref, bool *guaranteed_unmodified = NULL);
    1146  
    1147  /* Debugging interface.  */
    1148  void ipa_print_node_params (FILE *, struct cgraph_node *node);
    1149  void ipa_print_all_params (FILE *);
    1150  void ipa_print_node_jump_functions (FILE *f, struct cgraph_node *node);
    1151  void ipa_print_all_jump_functions (FILE * f);
    1152  void ipcp_verify_propagated_values (void);
    1153  
    1154  template <typename value>
    1155  class ipcp_value;
    1156  
    1157  extern object_allocator<ipcp_value<tree> > ipcp_cst_values_pool;
    1158  extern object_allocator<ipcp_value<ipa_polymorphic_call_context> >
    1159    ipcp_poly_ctx_values_pool;
    1160  
    1161  template <typename valtype>
    1162  struct ipcp_value_source;
    1163  
    1164  extern object_allocator<ipcp_value_source<tree> > ipcp_sources_pool;
    1165  
    1166  struct ipcp_agg_lattice;
    1167  
    1168  extern object_allocator<ipcp_agg_lattice> ipcp_agg_lattice_pool;
    1169  
    1170  void ipa_prop_write_jump_functions (void);
    1171  void ipa_prop_read_jump_functions (void);
    1172  void ipcp_write_transformation_summaries (void);
    1173  void ipcp_read_transformation_summaries (void);
    1174  int ipa_get_param_decl_index (class ipa_node_params *, tree);
    1175  tree ipa_value_from_jfunc (class ipa_node_params *info,
    1176  			   struct ipa_jump_func *jfunc, tree type);
    1177  tree ipa_agg_value_from_jfunc (ipa_node_params *info, cgraph_node *node,
    1178  			       const ipa_agg_jf_item *item);
    1179  unsigned int ipcp_transform_function (struct cgraph_node *node);
    1180  ipa_polymorphic_call_context ipa_context_from_jfunc (ipa_node_params *,
    1181  						     cgraph_edge *,
    1182  						     int,
    1183  						     ipa_jump_func *);
    1184  value_range ipa_value_range_from_jfunc (ipa_node_params *, cgraph_edge *,
    1185  					ipa_jump_func *, tree);
    1186  void ipa_push_agg_values_from_jfunc (ipa_node_params *info, cgraph_node *node,
    1187  				     ipa_agg_jump_function *agg_jfunc,
    1188  				     unsigned dst_index,
    1189  				     vec<ipa_argagg_value> *res);
    1190  void ipa_dump_param (FILE *, class ipa_node_params *info, int i);
    1191  void ipa_release_body_info (struct ipa_func_body_info *);
    1192  tree ipa_get_callee_param_type (struct cgraph_edge *e, int i);
    1193  bool ipcp_get_parm_bits (tree, tree *, widest_int *);
    1194  bool unadjusted_ptr_and_unit_offset (tree op, tree *ret,
    1195  				     poly_int64 *offset_ret);
    1196  
    1197  /* From tree-sra.cc:  */
    1198  tree build_ref_for_offset (location_t, tree, poly_int64, bool, tree,
    1199  			   gimple_stmt_iterator *, bool);
    1200  
    1201  /* In ipa-cp.cc  */
    1202  void ipa_cp_cc_finalize (void);
    1203  
    1204  #endif /* IPA_PROP_H */