Skip to content

Commit

Permalink
kbuild: move -fno-dwarf2-cfi-asm to powerpc only
Browse files Browse the repository at this point in the history
Better dwarf2 unwind information is a good thing, it allows better
debugging with kgdb and crash and helps systemtap.

Commit 0030864 ("Build with
-fno-dwarf2-cfi-asm") disabled some CFI information globally to work
around a module loader bug on powerpc.

But this disables the better unwind tables for all architectures, not just
powerpc.  Move the workaround to powerpc and also add a suitable comment
that's it really a workaround.

This improves dwarf2 unwind tables on x86 at least.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Michal Marek <mmarek@suse.cz>
  • Loading branch information
Andi Kleen authored and Michal Marek committed Feb 5, 2010
1 parent 59dde38 commit d0679c7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -579,9 +579,6 @@ KBUILD_CFLAGS += $(call cc-option,-Wno-pointer-sign,)
# disable invalid "can't wrap" optimizations for signed / pointers
KBUILD_CFLAGS += $(call cc-option,-fno-strict-overflow)

# revert to pre-gcc-4.4 behaviour of .eh_frame
KBUILD_CFLAGS += $(call cc-option,-fno-dwarf2-cfi-asm)

# conserve stack if available
KBUILD_CFLAGS += $(call cc-option,-fconserve-stack)

Expand Down
5 changes: 5 additions & 0 deletions arch/powerpc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,11 @@ KBUILD_CFLAGS += $(call cc-option,-mspe=no)
# kernel considerably.
KBUILD_CFLAGS += $(call cc-option,-funit-at-a-time)

# FIXME: the module load should be taught about the additional relocs
# generated by this.
# revert to pre-gcc-4.4 behaviour of .eh_frame
KBUILD_CFLAGS += $(call cc-option,-fno-dwarf2-cfi-asm)

# Never use string load/store instructions as they are
# often slow when they are implemented at all
KBUILD_CFLAGS += -mno-string
Expand Down

0 comments on commit d0679c7

Please sign in to comment.