1*4882a593SmuzhiyunFrom 96d9aa55d29b24e2490d5647a9efc66940fc400f Mon Sep 17 00:00:00 2001
2*4882a593SmuzhiyunFrom: Khem Raj <raj.khem@gmail.com>
3*4882a593SmuzhiyunDate: Wed, 13 Jan 2016 19:17:31 +0000
4*4882a593SmuzhiyunSubject: [PATCH] Disable -mfpmath=sse as well when SSE is disabled
5*4882a593Smuzhiyun
6*4882a593SmuzhiyunFixes
7*4882a593Smuzhiyun
8*4882a593Smuzhiyunconfigure:20574: i586-poky-linux-gcc  -m32    -march=core2 -msse3
9*4882a593Smuzhiyun-mtune=generic -mfpmath=sse
10*4882a593Smuzhiyun--sysroot=/usr/local/dev/yocto/grubtest2/build/tmp/sysroots/emenlow -o
11*4882a593Smuzhiyunconftest -O2 -pipe -g -feliminate-unused-debug-types -Wall -W -Wshadow
12*4882a593Smuzhiyun-Wpointer-arith -Wmissing-prototypes -Wundef -Wstrict-prototypes -g
13*4882a593Smuzhiyun-falign-jumps=1 -falign-loops=1 -falign-functions=1 -mno-mmx -mno-sse
14*4882a593Smuzhiyun-mno-sse2 -mno-3dnow -fno-dwarf2-cfi-asm -m32 -fno-stack-protector
15*4882a593Smuzhiyun-mno-stack-arg-probe -Werror -nostdlib -Wl,--defsym,___main=0x8100
16*4882a593Smuzhiyun-Wall -W -I$(top_srcdir)/include -I$(top_builddir)/include
17*4882a593Smuzhiyun-DGRUB_MACHINE_PCBIOS=1 -DGRUB_MACHINE=I386_PC -Wl,-O1
18*4882a593Smuzhiyun-Wl,--hash-style=gnu -Wl,--as-needed conftest.c  >&5
19*4882a593Smuzhiyunconftest.c:1:0: error: SSE instruction set disabled, using 387
20*4882a593Smuzhiyunarithmetics [-Werror]
21*4882a593Smuzhiyuncc1: all warnings being treated as errors
22*4882a593Smuzhiyun
23*4882a593SmuzhiyunSigned-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
24*4882a593SmuzhiyunSigned-off-by: Khem Raj <raj.khem@gmail.com>
25*4882a593Smuzhiyun
26*4882a593SmuzhiyunUpstream-Status: Pending
27*4882a593Smuzhiyun---
28*4882a593Smuzhiyun configure.ac | 2 +-
29*4882a593Smuzhiyun 1 file changed, 1 insertion(+), 1 deletion(-)
30*4882a593Smuzhiyun
31*4882a593Smuzhiyundiff --git a/configure.ac b/configure.ac
32*4882a593Smuzhiyunindex 7656f24..0868ea9 100644
33*4882a593Smuzhiyun--- a/configure.ac
34*4882a593Smuzhiyun+++ b/configure.ac
35*4882a593Smuzhiyun@@ -824,7 +824,7 @@ fi
36*4882a593Smuzhiyun if ( test "x$target_cpu" = xi386 || test "x$target_cpu" = xx86_64 ) && test "x$platform" != xemu; then
37*4882a593Smuzhiyun   # Some toolchains enable these features by default, but they need
38*4882a593Smuzhiyun   # registers that aren't set up properly in GRUB.
39*4882a593Smuzhiyun-  TARGET_CFLAGS="$TARGET_CFLAGS -mno-mmx -mno-sse -mno-sse2 -mno-sse3 -mno-3dnow"
40*4882a593Smuzhiyun+  TARGET_CFLAGS="$TARGET_CFLAGS -mno-mmx -mno-sse -mno-sse2 -mno-sse3 -mno-3dnow -mfpmath=387"
41*4882a593Smuzhiyun fi
42*4882a593Smuzhiyun
43*4882a593Smuzhiyun # GRUB doesn't use float or doubles at all. Yet some toolchains may decide
44