Commit f5576705 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] ppc64: Add -funit-at-a-time

From: Anton Blanchard <anton@samba.org>

Be like x86 and enable -funit-at-a-time.
Use the check_gcc hook when enabling -mcpu=power4/-mtune=power4.
parent dd6af5b8
...@@ -27,15 +27,16 @@ LDFLAGS_vmlinux := -Bstatic -e $(KERNELLOAD) -Ttext $(KERNELLOAD) ...@@ -27,15 +27,16 @@ LDFLAGS_vmlinux := -Bstatic -e $(KERNELLOAD) -Ttext $(KERNELLOAD)
CFLAGS += -msoft-float -pipe -Wno-uninitialized -mminimal-toc \ CFLAGS += -msoft-float -pipe -Wno-uninitialized -mminimal-toc \
-mtraceback=none -mtraceback=none
HAS_POWER4 := $(shell if $(CC) -mcpu=power4 -S -o /dev/null -xc /dev/null > /dev/null 2>&1; then echo y; else echo n; fi;)
ifeq ($(HAS_POWER4),y)
ifeq ($(CONFIG_POWER4_ONLY),y) ifeq ($(CONFIG_POWER4_ONLY),y)
CFLAGS += -mcpu=power4 CFLAGS += $(call check_gcc,-mcpu=power4,)
else else
CFLAGS += -mtune=power4 CFLAGS += $(call check_gcc,-mtune=power4,)
endif
endif endif
# Enable unit-at-a-time mode when possible. It shrinks the
# kernel considerably.
CFLAGS += $(call check_gcc,-funit-at-a-time,)
head-y := arch/ppc64/kernel/head.o head-y := arch/ppc64/kernel/head.o
libs-y += arch/ppc64/lib/ libs-y += arch/ppc64/lib/
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment