* [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer
@ 2009-06-16 20:16 Anton Vorontsov
2009-07-14 13:37 ` Anton Vorontsov
0 siblings, 1 reply; 5+ messages in thread
From: Anton Vorontsov @ 2009-06-16 20:16 UTC (permalink / raw)
To: Ingo Molnar; +Cc: linux-kernel, linuxppc-dev, Steven Rostedt, Sam Ravnborg
According to Segher Boessenkool and GCC manual, -fomit-frame-pointer
is only the default when optimising on archs/ABIs where it doesn't
hinder debugging and -pg. So, we do not get it by default on x86,
not at any optimisation level.
On the other hand, *using* -fno-omit-frame-pointer causes gcc to
produce buggy code on PowerPC targets.
If Segher and GCC manual are right, this patch should be a no-op
for all arches except PowerPC, where the patch fixes gcc issues.
Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
---
See this thread for more discussion:
http://osdir.com/ml/linux-kernel/2009-05/msg01754.html
p.s.
Obviously, I didn't test this patch on anything else but PPC32. ;-)
Segher, do you know if all GCC versions that we support for
building Linux are behaving the way that GCC manual describe?
Thanks,
Makefile | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Makefile b/Makefile
index ea63667..70ad1ff 100644
--- a/Makefile
+++ b/Makefile
@@ -535,7 +535,7 @@ KBUILD_CFLAGS += $(call cc-option, -fno-stack-protector)
endif
ifdef CONFIG_FRAME_POINTER
-KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
+KBUILD_CFLAGS += -fno-optimize-sibling-calls
else
KBUILD_CFLAGS += -fomit-frame-pointer
endif
--
1.6.3.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer
2009-06-16 20:16 [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer Anton Vorontsov
@ 2009-07-14 13:37 ` Anton Vorontsov
2009-07-14 13:46 ` Segher Boessenkool
2009-07-18 12:01 ` Ingo Molnar
0 siblings, 2 replies; 5+ messages in thread
From: Anton Vorontsov @ 2009-07-14 13:37 UTC (permalink / raw)
To: Ingo Molnar; +Cc: linuxppc-dev, Steven Rostedt, Sam Ravnborg, linux-kernel
On Wed, Jun 17, 2009 at 12:16:30AM +0400, Anton Vorontsov wrote:
> According to Segher Boessenkool and GCC manual, -fomit-frame-pointer
> is only the default when optimising on archs/ABIs where it doesn't
> hinder debugging and -pg. So, we do not get it by default on x86,
> not at any optimisation level.
>
> On the other hand, *using* -fno-omit-frame-pointer causes gcc to
> produce buggy code on PowerPC targets.
>
> If Segher and GCC manual are right, this patch should be a no-op
> for all arches except PowerPC, where the patch fixes gcc issues.
>
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---
>
> See this thread for more discussion:
> http://osdir.com/ml/linux-kernel/2009-05/msg01754.html
>
> p.s.
> Obviously, I didn't test this patch on anything else but PPC32. ;-)
>
> Segher, do you know if all GCC versions that we support for
> building Linux are behaving the way that GCC manual describe?
No news is good news... Ingo, can we merge this into -tip for testing?
Thanks,
> Makefile | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index ea63667..70ad1ff 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -535,7 +535,7 @@ KBUILD_CFLAGS += $(call cc-option, -fno-stack-protector)
> endif
>
> ifdef CONFIG_FRAME_POINTER
> -KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls
> +KBUILD_CFLAGS += -fno-optimize-sibling-calls
> else
> KBUILD_CFLAGS += -fomit-frame-pointer
> endif
> --
> 1.6.3.1
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer
2009-07-14 13:37 ` Anton Vorontsov
@ 2009-07-14 13:46 ` Segher Boessenkool
2009-07-18 12:01 ` Ingo Molnar
1 sibling, 0 replies; 5+ messages in thread
From: Segher Boessenkool @ 2009-07-14 13:46 UTC (permalink / raw)
To: avorontsov
Cc: linuxppc-dev, Ingo Molnar, Sam Ravnborg, Steven Rostedt,
linux-kernel
[Sorry for not replying earlier, somehow I missed this mail]
>> On the other hand, *using* -fno-omit-frame-pointer causes gcc to
>> produce buggy code on PowerPC targets.
It doesn't cause the problem, it only exposes it. And, of course,
only on certain GCC versions.
>> Segher, do you know if all GCC versions that we support for
>> building Linux are behaving the way that GCC manual describe?
I believe so, yes.
Segher
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer
2009-07-14 13:37 ` Anton Vorontsov
2009-07-14 13:46 ` Segher Boessenkool
@ 2009-07-18 12:01 ` Ingo Molnar
2009-09-04 16:53 ` Anton Vorontsov
1 sibling, 1 reply; 5+ messages in thread
From: Ingo Molnar @ 2009-07-18 12:01 UTC (permalink / raw)
To: Anton Vorontsov, Sam Ravnborg
Cc: linuxppc-dev, Steven Rostedt, Sam Ravnborg, linux-kernel
* Anton Vorontsov <avorontsov@ru.mvista.com> wrote:
> On Wed, Jun 17, 2009 at 12:16:30AM +0400, Anton Vorontsov wrote:
> > According to Segher Boessenkool and GCC manual, -fomit-frame-pointer
> > is only the default when optimising on archs/ABIs where it doesn't
> > hinder debugging and -pg. So, we do not get it by default on x86,
> > not at any optimisation level.
> >
> > On the other hand, *using* -fno-omit-frame-pointer causes gcc to
> > produce buggy code on PowerPC targets.
> >
> > If Segher and GCC manual are right, this patch should be a no-op
> > for all arches except PowerPC, where the patch fixes gcc issues.
> >
> > Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> > ---
> >
> > See this thread for more discussion:
> > http://osdir.com/ml/linux-kernel/2009-05/msg01754.html
> >
> > p.s.
> > Obviously, I didn't test this patch on anything else but PPC32. ;-)
> >
> > Segher, do you know if all GCC versions that we support for
> > building Linux are behaving the way that GCC manual describe?
>
> No news is good news... Ingo, can we merge this into -tip for
> testing?
Changes to the top level Makefile should really go via Sam's kbuild
tree.
Ingo
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer
2009-07-18 12:01 ` Ingo Molnar
@ 2009-09-04 16:53 ` Anton Vorontsov
0 siblings, 0 replies; 5+ messages in thread
From: Anton Vorontsov @ 2009-09-04 16:53 UTC (permalink / raw)
To: Ingo Molnar; +Cc: linuxppc-dev, Steven Rostedt, Sam Ravnborg, linux-kernel
On Sat, Jul 18, 2009 at 02:01:45PM +0200, Ingo Molnar wrote:
>
> * Anton Vorontsov <avorontsov@ru.mvista.com> wrote:
>
> > On Wed, Jun 17, 2009 at 12:16:30AM +0400, Anton Vorontsov wrote:
> > > According to Segher Boessenkool and GCC manual, -fomit-frame-pointer
> > > is only the default when optimising on archs/ABIs where it doesn't
> > > hinder debugging and -pg. So, we do not get it by default on x86,
> > > not at any optimisation level.
> > >
> > > On the other hand, *using* -fno-omit-frame-pointer causes gcc to
> > > produce buggy code on PowerPC targets.
> > >
> > > If Segher and GCC manual are right, this patch should be a no-op
> > > for all arches except PowerPC, where the patch fixes gcc issues.
> > >
> > > Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> > > ---
> > >
> > > See this thread for more discussion:
> > > http://osdir.com/ml/linux-kernel/2009-05/msg01754.html
> > >
> > > p.s.
> > > Obviously, I didn't test this patch on anything else but PPC32. ;-)
> > >
> > > Segher, do you know if all GCC versions that we support for
> > > building Linux are behaving the way that GCC manual describe?
> >
> > No news is good news... Ingo, can we merge this into -tip for
> > testing?
>
> Changes to the top level Makefile should really go via Sam's kbuild
> tree.
Sam, any thoughts about these patches?
Thanks!
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2009-09-04 16:53 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-16 20:16 [PATCH RFC 1/2] Makefile: Never use -fno-omit-frame-pointer Anton Vorontsov
2009-07-14 13:37 ` Anton Vorontsov
2009-07-14 13:46 ` Segher Boessenkool
2009-07-18 12:01 ` Ingo Molnar
2009-09-04 16:53 ` Anton Vorontsov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).