GCC Middle and Back End API Reference
ipa-ref.c File Reference

Functions

struct ipa_refipa_record_reference (symtab_node referring_node, symtab_node referred_node, enum ipa_ref_use use_type, gimple stmt)
struct ipa_refipa_maybe_record_reference (symtab_node referring_node, tree val, enum ipa_ref_use use_type, gimple stmt)
void ipa_remove_reference ()
void ipa_remove_all_references ()
void ipa_remove_all_referring ()
void ipa_dump_references ()
void ipa_dump_referring ()
struct ipa_refipa_clone_ref (struct ipa_ref *ref, symtab_node dest_node, gimple stmt)
void ipa_clone_references (symtab_node dest_node, struct ipa_ref_list *src)
void ipa_clone_referring (symtab_node dest_node, struct ipa_ref_list *src)
bool ipa_ref_cannot_lead_to_return ()
bool ipa_ref_has_aliases_p ()
struct ipa_refipa_find_reference (symtab_node referring_node, symtab_node referred_node, gimple stmt, unsigned int lto_stmt_uid)
void ipa_remove_stmt_references ()
void ipa_clear_stmts_in_references ()

Variables

static const char * ipa_ref_use_name [] = {"read","write","addr","alias"}

Function Documentation

void ipa_clear_stmts_in_references ( )
Remove all stmt references in non-speculative references.
   Those are not maintained during inlining & clonning. 
   The exception are speculative references that are updated along
   with callgraph edges associated with them.   

References ipa_ref::lto_stmt_uid, ipa_ref::speculative, and ipa_ref::stmt.

Referenced by cgraph_materialize_all_clones().

struct ipa_ref* ipa_clone_ref ( struct ipa_ref ref,
symtab_node  dest_node,
gimple  stmt 
)
read
Clone reference REF to DEST_NODE and set its stmt to STMT.   

References ipa_record_reference(), ipa_ref::lto_stmt_uid, ipa_ref::referred, and ipa_ref::speculative.

Referenced by copy_bb().

void ipa_clone_references ( symtab_node  dest_node,
struct ipa_ref_list src 
)
Clone all references from SRC to DEST_NODE or DEST_VARPOOL_NODE.   

References ipa_record_reference(), ipa_ref::lto_stmt_uid, ipa_ref::referred, ipa_ref::speculative, and ipa_ref::stmt.

Referenced by cgraph_clone_node().

void ipa_clone_referring ( symtab_node  dest_node,
struct ipa_ref_list src 
)
Clone all referring from SRC to DEST_NODE or DEST_VARPOOL_NODE.   

References ipa_record_reference(), ipa_ref::lto_stmt_uid, ipa_ref::referring, ipa_ref::speculative, and ipa_ref::stmt.

Referenced by lto_cgraph_replace_node(), and lto_varpool_replace_node().

void ipa_dump_references ( )
Dump references in LIST to FILE.   

References ipa_ref_use_name, ipa_ref::referred, ipa_ref::speculative, and symtab_node_asm_name().

Referenced by dump_symtab_base().

void ipa_dump_referring ( )
Dump referring in LIST to FILE.   

References ipa_ref_use_name, ipa_ref::referring, ipa_ref::speculative, and symtab_node_asm_name().

Referenced by dump_symtab_base().

struct ipa_ref* ipa_find_reference ( symtab_node  referring_node,
symtab_node  referred_node,
gimple  stmt,
unsigned int  lto_stmt_uid 
)
read
Find the structure describing a reference in REFERRING_NODE to REFERRED_NODE
   and associated with statement STMT.   

References ipa_ref::lto_stmt_uid, ipa_ref::referred, ipa_ref::speculative, and ipa_ref::stmt.

Referenced by ipcp_discover_new_direct_edges(), propagate_controlled_uses(), and remove_described_reference().

struct ipa_ref* ipa_maybe_record_reference ( symtab_node  referring_node,
tree  val,
enum ipa_ref_use  use_type,
gimple  stmt 
)
read
If VAL is a reference to a function or a variable, add a reference from
   REFERRING_NODE to the corresponding symbol table node.  USE_TYPE specify
   type of the use and STMT the statement (if it exists).  Return the new
   reference or NULL if none was created.   

References get_base_var(), ipa_record_reference(), ipa_ref::referred, and symtab_get_node().

Referenced by cgraph_create_virtual_clone(), and create_specialized_node().

bool ipa_ref_cannot_lead_to_return ( )
Return true when execution of REF can lead to return from
   function.  

References cgraph_node_cannot_return(), and ipa_ref_referring_node().

Referenced by analyze_function(), and propagate_pure_const().

bool ipa_ref_has_aliases_p ( )
Return true if list contains an alias.   

References IPA_REF_ALIAS.

Referenced by can_remove_node_now_p_1(), and cgraph_non_local_node_p_1().

void ipa_remove_all_referring ( )
Remove all references in ref list LIST.   

References ipa_remove_reference(), and ipa_ref_list::referring.

Referenced by symtab_unregister_node().

void ipa_remove_stmt_references ( )
Remove all references from REFERRING_NODE that are associated with statement
   STMT.   

References ipa_remove_reference(), and ipa_ref::stmt.

Referenced by delete_unreachable_blocks_update_callgraph(), and ipa_modify_call_arguments().


Variable Documentation

const char* ipa_ref_use_name[] = {"read","write","addr","alias"}
static
@verbatim Interprocedural reference lists.

Copyright (C) 2010-2013 Free Software Foundation, Inc. Contributed by Jan Hubicka

This file is part of GCC.

GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.

GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see http://www.gnu.org/licenses/.

Referenced by ipa_dump_references(), and ipa_dump_referring().