On Wed, Oct 09, 2013 at 04:33:59PM +0200, Peter Zijlstra wrote: > On Wed, Oct 09, 2013 at 04:07:34PM +0200, Peter Zijlstra wrote: > > Once I force a x86_64 build using the 'same' config it goes away and > > generates 'sensible' code again (although I don't see why L9 isn't > > merged with L2): > > i386-SMP also generates correct code afaict; a tad stupid but not wrong. > > If I remove ftrace from the .config its still broken.. > If I also remove the likely/unlikely tracer its still broken and lots > smaller: OK, its -march=winchip2 that's buggered. Find attached task_work.i and try: gcc -nostdinc -I /usr/src/linux-2.6/arch/x86/include -I arch/x86/include/generated -I /usr/src/linux-2.6/include -I include -I /usr/src/linux-2.6/arch/x86/include/uapi -I arch/x86/include/generated/uapi -I /usr/src/linux-2.6/include/uapi -I include/generated/uapi -I /usr/src/linux-2.6/kernel -I kernel -D __KERNEL__ -D CONFIG_AS_CFI=1 -D CONFIG_AS_CFI_SIGNAL_FRAME=1 -D CONFIG_AS_CFI_SECTIONS=1 -D CONFIG_AS_AVX=1 -D CONFIG_AS_AVX2=1 -D CC_HAVE_ASM_GOTO -D "KBUILD_STR(s)=#s" -D "KBUILD_BASENAME=KBUILD_STR(task_work)" -D KBUILD_MODNAME="KBUILD_STR(task_work)" -isystem /usr/lib/gcc/x86_64-linux-gnu/4.8/include -include /usr/src/linux-2.6/include/linux/kconfig.h -m32 -msoft-float -mregparm=3 -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -O2 -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -Werror=implicit-function-declaration -Wno-format-security -Wno-sign-compare -Wframe-larger-than=2048 -Wno-unused-but-set-variable -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-aliasing -fno-common -fno-delete-null-pointer-checks -freg-struct-return -fno-pic -ffreestanding -fno-asynchronous-unwind-tables -fno-stack-protector -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-strict-overflow -fconserve-stack -fverbose-asm -S -o - task_work.i and gcc -nostdinc -I /usr/src/linux-2.6/arch/x86/include -I arch/x86/include/generated -I /usr/src/linux-2.6/include -I include -I /usr/src/linux-2.6/arch/x86/include/uapi -I arch/x86/include/generated/uapi -I /usr/src/linux-2.6/include/uapi -I include/generated/uapi -I /usr/src/linux-2.6/kernel -I kernel -D __KERNEL__ -D CONFIG_AS_CFI=1 -D CONFIG_AS_CFI_SIGNAL_FRAME=1 -D CONFIG_AS_CFI_SECTIONS=1 -D CONFIG_AS_AVX=1 -D CONFIG_AS_AVX2=1 -D CC_HAVE_ASM_GOTO -D "KBUILD_STR(s)=#s" -D "KBUILD_BASENAME=KBUILD_STR(task_work)" -D KBUILD_MODNAME="KBUILD_STR(task_work)" -isystem /usr/lib/gcc/x86_64-linux-gnu/4.8/include -include /usr/src/linux-2.6/include/linux/kconfig.h -m32 -msoft-float -mregparm=3 -mpreferred-stack-boundary=2 -march=winchip2 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -O2 -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -Werror=implicit-function-declaration -Wno-format-security -Wno-sign-compare -Wframe-larger-than=2048 -Wno-unused-but-set-variable -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-aliasing -fno-common -fno-delete-null-pointer-checks -freg-struct-return -fno-pic -ffreestanding -fno-asynchronous-unwind-tables -fno-stack-protector -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-strict-overflow -fconserve-stack -fverbose-asm -S -o - task_work.i | less