mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 00:24:12 +08:00
b6254ced4d
There is no point in copying floating point regs when there is no FPU and MATH_EMULATION is not selected. Create a new CONFIG_PPC_FPU_REGS bool that is selected by CONFIG_MATH_EMULATION and CONFIG_PPC_FPU, and use it to opt out everything related to fp_state in thread_struct. The asm const used only by fpu.S are opted out with CONFIG_PPC_FPU as fpu.S build is conditionnal to CONFIG_PPC_FPU. The following app spends approx 8.1 seconds system time on an 8xx without the patch, and 7.0 seconds with the patch (13.5% reduction). On an 832x, it spends approx 2.6 seconds system time without the patch and 2.1 seconds with the patch (19% reduction). void sigusr1(int sig) { } int main(int argc, char **argv) { int i = 100000; signal(SIGUSR1, sigusr1); for (;i--;) raise(SIGUSR1); exit(0); } Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/7569070083e6cd5b279bb5023da601aba3c06f3c.1597770847.git.christophe.leroy@csgroup.eu
22 lines
606 B
Makefile
22 lines
606 B
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
#
|
|
# Makefile for the linux kernel.
|
|
#
|
|
|
|
CFLAGS_ptrace-view.o += -DUTS_MACHINE='"$(UTS_MACHINE)"'
|
|
|
|
obj-y += ptrace.o ptrace-view.o
|
|
obj-$(CONFIG_PPC_FPU_REGS) += ptrace-fpu.o
|
|
obj-$(CONFIG_COMPAT) += ptrace32.o
|
|
obj-$(CONFIG_VSX) += ptrace-vsx.o
|
|
ifneq ($(CONFIG_VSX),y)
|
|
obj-$(CONFIG_PPC_FPU_REGS) += ptrace-novsx.o
|
|
endif
|
|
obj-$(CONFIG_ALTIVEC) += ptrace-altivec.o
|
|
obj-$(CONFIG_SPE) += ptrace-spe.o
|
|
obj-$(CONFIG_PPC_TRANSACTIONAL_MEM) += ptrace-tm.o
|
|
obj-$(CONFIG_PPC_ADV_DEBUG_REGS) += ptrace-adv.o
|
|
ifneq ($(CONFIG_PPC_ADV_DEBUG_REGS),y)
|
|
obj-y += ptrace-noadv.o
|
|
endif
|