This is the mail archive of the gcc-bugs@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]

[Bug c/8335] problems with __builtin_frame_address when -fomit-frame-pointer used


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=8335



------- Additional Comments From davmac@ozonline.com.au  2003-06-16 02:06 -------
Subject: Re:  problems with __builtin_frame_address when -fomit-frame-pointer used

I don't believe this is correct. In the manual it describes __builtin_frame_address() as returning "the
address of the function frame". Ie. the manual documents a specific behaviour, and that specific behaviour doesn't occur when -fomit-frame-pointer is used. Therefore this is a "bug" and not an "enhancement". Either the behaviour is incorrect or the documentation is incorrect.

The only indication given in the manual that it won't work is where it says "If the processor has a dedicated frame pointer register, and the function has a frame, then __builtin_frame_address will return the value of the pointer register".

Your comment that it "never was described to work" is not correct, because the manual describes how __builtin_frame_address is supposed to work and does not mention that it won't work if -fomit-frame-pointer is used.

regards,
Davin


On 26 May 2003 18:56:35 -0000, "pinskia@physics.uc.edu" <gcc-bugzilla@gcc.gnu.org> wrote:
> ------- Additional Comments From pinskia@physics.uc.edu  2003-05-26 18:56 -------
> This is know defect of gcc when using -fomi-frame-pointer and __builtin_frame_address, it still is 
> an enhancement though because it never worked and never was described to worked.
>


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