提交 0030cbf0 编写于 作者: M Matthias Urlichs 提交者: Linus Torvalds

[PATCH] Turn off sibling call optimization w/ frame pointers

Frame pointers are supposed to enable debuggers to reliably tell where a
call comes from.  That is defeated by GCC's sibling call optimization (aka
tail recursion elimination).

This patch turns this optimization off when compiling with frame pointers.
Signed-Off-By: NMatthias Urlichs <smurf@smurf.noris.de>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 71a2224d
......@@ -518,7 +518,7 @@ CFLAGS += $(call add-align,CONFIG_CC_ALIGN_LOOPS,-loops)
CFLAGS += $(call add-align,CONFIG_CC_ALIGN_JUMPS,-jumps)
ifdef CONFIG_FRAME_POINTER
CFLAGS += -fno-omit-frame-pointer
CFLAGS += -fno-omit-frame-pointer $(call cc-option,-fno-optimize-sibling-calls,)
else
CFLAGS += -fomit-frame-pointer
endif
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册