diff options
Diffstat (limited to 'gcc/function.h')
-rw-r--r-- | gcc/function.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/gcc/function.h b/gcc/function.h index 617034872cc..fec0168a5d2 100644 --- a/gcc/function.h +++ b/gcc/function.h @@ -503,8 +503,8 @@ struct GTY(()) function { pointer. */ tree nonlocal_goto_save_area; - /* List of function local variables, functions, types and constants. */ - tree local_decls; + /* Vector of function local variables, functions, types and constants. */ + VEC(tree,gc) *local_decls; /* For md files. */ @@ -609,6 +609,17 @@ struct GTY(()) function { unsigned int is_thunk : 1; }; +/* Add the decl D to the local_decls list of FUN. */ + +static inline void +add_local_decl (struct function *fun, tree d) +{ + VEC_safe_push (tree, gc, fun->local_decls, d); +} + +#define FOR_EACH_LOCAL_DECL(FUN, I, D) \ + FOR_EACH_VEC_ELT_REVERSE (tree, (FUN)->local_decls, I, D) + /* If va_list_[gf]pr_size is set to this, it means we don't know how many units need to be saved. */ #define VA_LIST_MAX_GPR_SIZE 255 |