diff options
author | Aldy Hernandez <aldyh@redhat.com> | 2011-11-08 11:13:41 +0000 |
---|---|---|
committer | Aldy Hernandez <aldyh@redhat.com> | 2011-11-08 11:13:41 +0000 |
commit | 788649fc885d6a911f262662c9fcefdccde4f39a (patch) | |
tree | e07de8d0b6265f8d72388d335bd471022e753d57 /gcc/cgraph.h | |
parent | acb58beffd6d2343c00619d10336614762c70c2f (diff) |
Merge from transactional-memory branch.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@181154 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cgraph.h')
-rw-r--r-- | gcc/cgraph.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/cgraph.h b/gcc/cgraph.h index 294fb772a5b..9e98ce9e2ef 100644 --- a/gcc/cgraph.h +++ b/gcc/cgraph.h @@ -98,6 +98,9 @@ struct GTY(()) cgraph_local_info { /* True when the function has been originally extern inline, but it is redefined now. */ unsigned redefined_extern_inline : 1; + + /* True if the function may enter serial irrevocable mode. */ + unsigned tm_may_enter_irr : 1; }; /* Information about the function that needs to be computed globally @@ -245,6 +248,11 @@ struct GTY((chain_next ("%h.next"), chain_prev ("%h.previous"))) cgraph_node { unsigned only_called_at_startup : 1; /* True when function can only be called at startup (from static dtor). */ unsigned only_called_at_exit : 1; + /* True when function is the transactional clone of a function which + is called only from inside transactions. */ + /* ?? We should be able to remove this. We have enough bits in + cgraph to calculate it. */ + unsigned tm_clone : 1; }; typedef struct cgraph_node *cgraph_node_ptr; @@ -565,6 +573,8 @@ void verify_cgraph_node (struct cgraph_node *); void cgraph_build_static_cdtor (char which, tree body, int priority); void cgraph_reset_static_var_maps (void); void init_cgraph (void); +struct cgraph_node * cgraph_copy_node_for_versioning (struct cgraph_node *, + tree, VEC(cgraph_edge_p,heap)*, bitmap); struct cgraph_node *cgraph_function_versioning (struct cgraph_node *, VEC(cgraph_edge_p,heap)*, VEC(ipa_replace_map_p,gc)*, @@ -1082,4 +1092,14 @@ cgraph_edge_recursive_p (struct cgraph_edge *e) else return e->caller->decl == callee->decl; } + +/* Return true if the TM_CLONE bit is set for a given FNDECL. */ +static inline bool +decl_is_tm_clone (const_tree fndecl) +{ + struct cgraph_node *n = cgraph_get_node (fndecl); + if (n) + return n->tm_clone; + return false; +} #endif /* GCC_CGRAPH_H */ |