This is the mail archive of the
mailing list for the GCC project.
RE: Frame pointer optimization issues
- From: "Thomas Preud'homme" <thomas dot preudhomme at arm dot com>
- To: "'Wilco Dijkstra'" <wdijkstr at arm dot com>, <gcc at gcc dot gnu dot org>
- Date: Thu, 21 Aug 2014 18:00:13 +0800
- Subject: RE: Frame pointer optimization issues
- Authentication-results: sourceware.org; auth=none
- References: <000801cfbc8a$8ce28d40$a6a7a7c0$ at com>
> From: email@example.com [mailto:firstname.lastname@example.org] On Behalf Of
> Wilco Dijkstra
> One could hack this a bit further and set flag_omit_frame_pointer = 2 to
> differentiate between a
> user setting and the override hack, but that's just making things even worse.
> So I see 3 possible
> 1. Add a copy of flag_omit_frame_pointer, and only modify that in the
> override. This is the generic
> correct solution that allows any kind of modifications on the copies. This
> could be done by making
> all flags separate variables and automating the copy in the options parsing
> code. Any code that
> writes the x_flag_ variables should eventually be fixed to stop doing this to
> avoid these bugs (i386
> does this 22 times and c6x 2x).
I just sent a patch  following a similar approach for a problem on ARM target
when compiling for thumb1 and optimizing for size. In this case call_used_regs
will be modified to not save some registers in the prologue, ignoring any
value the user might have set.
So I think a general solution would be useful.