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: patch: always_inline attribute


>>>>> "Aldy" == Aldy Hernandez <aldyh@redhat.com> writes:

> On Sat, Feb 23, 2002 at 04:47:42PM +0000, Jason Merrill wrote:
> finally...

>> > +   if (optimize == 0
>> > +       && lookup_attribute ("always_inline", DECL_ATTRIBUTES (fn)) == NULL)
>> > +     return 1;
>> 
>> Woops, looks like my earlier mail came too late.  Please conditionalize
>> this stuff on a flag other than optimize, so that -O1 -fno-inline still
>> works.  You'll probably have to add Yet Another inlining flag.  While

> i don't understand why we clobber flag_no_inline to 1 inside
> c_common_post_options:

>   if (! flag_instrument_function_entry_exit)
>     {
>       if (!flag_no_inline)
>         flag_no_inline = 1;

Because if we're doing tree inlining, we don't need to do RTL inlining.

>> While you're at it, you might as well make -O0 -finline work.

> what were the issues?

Just history.  The RTL inliner doesn't work at -O0.  The tree inliner works
fine.  Or would, if it were possible to enable it.

> perhaps in another patch i can remove the code disabling inlining at -O0,
> and change the documentation accordingly?

That's what I was suggesting.  Or rather, not remove it, but set
flag_really_no_inline from flag_no_inline befor we get to that code.

Thanks,
Jason


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