This is the mail archive of the gcc-help@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: Generate Function without Prologue and Epilogue


On Wed, Sep 5, 2012 at 9:46 AM, Jeff Kenton <jkenton@tilera.com> wrote:
> On 09/05/2012 12:36 PM, David Brown wrote:
>>
>> On 05/09/12 07:37, Ian Lance Taylor wrote:
>>>
>>> On Tue, Sep 4, 2012 at 10:35 PM, Xin Tong<xerox.time.tech@gmail.com>
>>> wrote:
>>>>
>>>> any reason why naked functions are not support for x86 ?
>>>
>>>
>>> No special reason, no.
>>>
>>> Ian
>>>
>>
>> Is this something that could easily be moved from target-specific
>> attributes into more general gcc support?  I'm sure the maintainers of ports
>> like the avr that have a "naked" attribute would be happier if it were a
>> general feature rather than specific to their port, and I'm sure that other
>> embedded targets would appreciate it.
>>
>> However, I have no clue as to whether this is a simple matter of moving
>> code from a target-specific file to a generic file, or if it needs a lot
>> more work.
>>
>> David
>
>
> It's not clear (to me) what the original poster was looking for.  If he just
> wants to eliminate (or minimize) the prologue and epilogue code he can
> sometimes get that effect for simple leaf functions by increasing the
> optimization to -O3.  But I don't know for sure if that is what he was
> asking.

I was looking for a way by which functions generated do not have
prologue and epilogue. the functions may not be leaf functions.

Xin

>
> --jeff
>


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