This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
frame_pointer_needed always true ?
- From: AurÃlien Buhrig <aurelien dot buhrig dot gcc at gmail dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Mon, 13 Jun 2016 12:24:06 +0200
- Subject: frame_pointer_needed always true ?
- Authentication-results: sourceware.org; auth=none
Hi,
I'm porting a private backend from an old 4.6 gcc to the 6.1.0 release,
and would appreciate an little help figuring out what may be wrong.
In my backend prologue (6.1.0 release), I test frame_pointer_needed to
figure out if the frame pointer is needed or not. But
frame_pointer_needed is always true (even the function void f(void) {}
which does not use any register), unless setting -fomit_frame_pointer.
The TARGET_FRAME_POINTER_REQUIRED is defined to hook_bool_void_false,
and the INITIAL_ELIMINATION_OFFSET, ELIMINABLE_REGS and
TARGET_CAN_ELIMINATE seem to be correctly defined and elimination works
correctly with -fomit-frame-pointer.
I noticed that both my frame pointer and the stack pointer are marked
live in; lr in and lr use for this empty function (post reload). I
wonder if it is normal.
Thanks in advance!
AurÃlien