diff mbox

build_function_call and TREE_ADDRESSABLE

Message ID 20110304045856.GY13094@bubble.grove.modra.org
State New
Headers show

Commit Message

Alan Modra March 4, 2011, 4:58 a.m. UTC
Warn off anyone trying to do as I did, and the bit about inlines is
no longer relevant.  OK to apply?

	* tree.h (TREE_ADDRESSABLE): Note that direct calls set the
	flag on FUNCTION_DECLs.

Comments

Richard Biener March 4, 2011, 10:16 a.m. UTC | #1
On Fri, Mar 4, 2011 at 5:58 AM, Alan Modra <amodra@gmail.com> wrote:
> Warn off anyone trying to do as I did, and the bit about inlines is
> no longer relevant.  OK to apply?
>
>        * tree.h (TREE_ADDRESSABLE): Note that direct calls set the
>        flag on FUNCTION_DECLs.
>
> Index: gcc/tree.h
> ===================================================================
> --- gcc/tree.h  (revision 170665)
> +++ gcc/tree.h  (working copy)
> @@ -1106,8 +1106,8 @@ extern void omp_clause_range_check_faile
>
>  /* In VAR_DECL, PARM_DECL and RESULT_DECL nodes, nonzero means address
>    of this is needed.  So it cannot be in a register.
> -   In a FUNCTION_DECL, nonzero means its address is needed.
> -   So it must be compiled even if it is an inline function.
> +   In a FUNCTION_DECL, nonzero means its address is needed.  This even
> +   happens on a direct call, making the flag fairly useless.
>    In CONSTRUCTOR nodes, it means object constructed must be in memory.
>    In LABEL_DECL nodes, it means a goto for this label has been seen
>    from a place outside all binding contours that restore stack levels.

Rather 'In a FUNCTION_DECL, it has no meaning.'

Ok with that change.
Richard.

> --
> Alan Modra
> Australia Development Lab, IBM
>
diff mbox

Patch

Index: gcc/tree.h
===================================================================
--- gcc/tree.h	(revision 170665)
+++ gcc/tree.h	(working copy)
@@ -1106,8 +1106,8 @@  extern void omp_clause_range_check_faile
 
 /* In VAR_DECL, PARM_DECL and RESULT_DECL nodes, nonzero means address
    of this is needed.  So it cannot be in a register.
-   In a FUNCTION_DECL, nonzero means its address is needed.
-   So it must be compiled even if it is an inline function.
+   In a FUNCTION_DECL, nonzero means its address is needed.  This even
+   happens on a direct call, making the flag fairly useless.
    In CONSTRUCTOR nodes, it means object constructed must be in memory.
    In LABEL_DECL nodes, it means a goto for this label has been seen
    from a place outside all binding contours that restore stack levels.