This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Ada] Do not generate special PARM_DECL in LTO mode


On Mon, Oct 22, 2012 at 10:04 AM, Eric Botcazou <ebotcazou@adacore.com> wrote:
> We generate a special PARM_DECL for Out parameters passed by copy at -O0, but
> it doesn't play nice with LTO so this patch removes it when LTO is enabled.
>
> Tested on x86_64-suse-linux, applied on the mainline and 4.7 branch.

Shouldn't it be simply the abstract origin for the VAR_DECL?  Or be
not 'lowered'
here but be a 'proper' PARM_DECL with DECL_VALUE_EXPR?  That said,
how is debug info emitted in the optimize case?

No objection to the patch as-is, but guarding sth with flag_generate_lto always
makes me suspicious ;)

Richard.

> 2012-10-22  Eric Botcazou  <ebotcazou@adacore.com>
>
>         * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Out_Parameter>: Do not
>         generate the special PARM_DECL for an Out parameter in LTO mode.
>
>
> --
> Eric Botcazou


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]