powerpc/Makefile: set -mcpu=860 flag for the 8xx
authorChristophe Leroy <christophe.leroy@c-s.fr>
Mon, 28 May 2018 06:08:34 +0000 (06:08 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Sun, 3 Jun 2018 14:39:20 +0000 (00:39 +1000)
commit1c38976334c0efce1b285369a6037f205e196299
tree6c976da4bc1f36d222062e82fbf97fc14af0b2f1
parente9c4943a107b56696e4872cdffdba6b0c7277c77
powerpc/Makefile: set -mcpu=860 flag for the 8xx

When compiled with GCC 8.1, vmlinux is significantly bigger than
with GCC 4.8.

When looking at the generated code with objdump, we notice that
all functions and loops when a 16 bytes alignment. This significantly
increases the size of the kernel. It is pointless and even
counterproductive as on the 8xx 'nop' also consumes one clock cycle.

Size of vmlinux with GCC 4.8:
   text    data     bss     dec     hex filename
5801948 1626076  457796 7885820  7853fc vmlinux

Size of vmlinux with GCC 8.1:
   text    data     bss     dec     hex filename
6764592 1630652  456476 8851720  871108 vmlinux

Size of vmlinux with GCC 8.1 and this patch:
   text    data     bss     dec     hex filename
6331544 1631756  456476 8419776  8079c0 vmlinux

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/Makefile