diff options
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-7.3.inc | 1 | ||||
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-7.3/no-sse-fix-test-case-failures.patch | 259 |
2 files changed, 260 insertions, 0 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-7.3.inc b/meta/recipes-devtools/gcc/gcc-7.3.inc index 724f9c32a0..da236e50c0 100644 --- a/meta/recipes-devtools/gcc/gcc-7.3.inc +++ b/meta/recipes-devtools/gcc/gcc-7.3.inc | |||
@@ -74,6 +74,7 @@ SRC_URI = "\ | |||
74 | file://0048-gcc-Enable-static-PIE.patch \ | 74 | file://0048-gcc-Enable-static-PIE.patch \ |
75 | file://fix-segmentation-fault-precompiled-hdr.patch \ | 75 | file://fix-segmentation-fault-precompiled-hdr.patch \ |
76 | file://0050-RISC-V-Handle-non-legitimate-address-in-riscv_legiti.patch \ | 76 | file://0050-RISC-V-Handle-non-legitimate-address-in-riscv_legiti.patch \ |
77 | file://no-sse-fix-test-case-failures.patch \ | ||
77 | ${BACKPORTS} \ | 78 | ${BACKPORTS} \ |
78 | " | 79 | " |
79 | BACKPORTS = "\ | 80 | BACKPORTS = "\ |
diff --git a/meta/recipes-devtools/gcc/gcc-7.3/no-sse-fix-test-case-failures.patch b/meta/recipes-devtools/gcc/gcc-7.3/no-sse-fix-test-case-failures.patch new file mode 100644 index 0000000000..cb87c5ab7e --- /dev/null +++ b/meta/recipes-devtools/gcc/gcc-7.3/no-sse-fix-test-case-failures.patch | |||
@@ -0,0 +1,259 @@ | |||
1 | From f22830da2ba64577deb6f717d05d86c03dd2e50d Mon Sep 17 00:00:00 2001 | ||
2 | From: RAGHUNATH LOLUR <raghunath.lolur@kpit.com> | ||
3 | Date: Wed, 6 Dec 2017 22:52:26 -0800 | ||
4 | Subject: [PATCH] Fix for testsuite failure | ||
5 | |||
6 | 2017-11-16 Raghunath Lolur <raghunath.lolur@kpit.com> | ||
7 | |||
8 | * gcc.dg/pr56275.c: If SSE is disabled, ensure that | ||
9 | "-mfpmath" is not set to use SSE. Set "-mfpmath=387". | ||
10 | * gcc.dg/pr68306.c: Likewise | ||
11 | * gcc.dg/pr68306-2.c: Likewise | ||
12 | * gcc.dg/pr68306-3.c: Likewise | ||
13 | * gcc.dg/pr69634.c: Likewise | ||
14 | * gcc.target/i386/amd64-abi-1.c: Likewise | ||
15 | * gcc.target/i386/funcspec-6.c: Likewise | ||
16 | * gcc.target/i386/interrupt-387-err-1.c: Likewise | ||
17 | * gcc.target/i386/isa-14.c: Likewise | ||
18 | * gcc.target/i386/pr44948-2b.c: Likewise | ||
19 | * gcc.target/i386/pr53425-1.c: Likewise | ||
20 | * gcc.target/i386/pr53425-2.c: Likewise | ||
21 | * gcc.target/i386/pr55247.c: Likewise | ||
22 | * gcc.target/i386/pr59644.c: Likewise | ||
23 | * gcc.target/i386/pr62120.c: Likewise | ||
24 | * gcc.target/i386/pr70467-1.c: Likewise | ||
25 | * gcc.target/i386/warn-vect-op-1.c: Likewise | ||
26 | |||
27 | If -Wall, -Werror are used during compilation various test cases fail | ||
28 | to compile. | ||
29 | |||
30 | If SSE is disabled, be sure to -mfpmath=387 to resolve this. | ||
31 | |||
32 | This patch removes the changes to Changelog from the original patch. | ||
33 | This will help us avoid conflicts. | ||
34 | |||
35 | Upstream-Status: Pending | ||
36 | |||
37 | Signed-off-by: Mark Hatle <mark.hatle@windriver.com> | ||
38 | --- | ||
39 | gcc/testsuite/ChangeLog | 21 +++++++++++++++++++++ | ||
40 | gcc/testsuite/gcc.dg/pr56275.c | 2 +- | ||
41 | gcc/testsuite/gcc.dg/pr68306-2.c | 2 +- | ||
42 | gcc/testsuite/gcc.dg/pr68306-3.c | 2 +- | ||
43 | gcc/testsuite/gcc.dg/pr68306.c | 2 +- | ||
44 | gcc/testsuite/gcc.dg/pr69634.c | 2 +- | ||
45 | .../gcc/testsuite/gcc.target/i386/amd64-abi-1.c | 2 +- | ||
46 | .../gcc/testsuite/gcc.target/i386/funcspec-6.c | 1 + | ||
47 | .../testsuite/gcc.target/i386/interrupt-387-err-1.c | 2 +- | ||
48 | gcc/testsuite/gcc.target/i386/isa-14.c | 2 +- | ||
49 | .../gcc/testsuite/gcc.target/i386/pr44948-2b.c | 2 +- | ||
50 | gcc/testsuite/gcc.target/i386/pr53425-1.c | 2 +- | ||
51 | gcc/testsuite/gcc.target/i386/pr53425-2.c | 2 +- | ||
52 | gcc/testsuite/gcc.target/i386/pr55247.c | 2 +- | ||
53 | gcc/testsuite/gcc.target/i386/pr59644.c | 2 +- | ||
54 | gcc/testsuite/gcc.target/i386/pr62120.c | 2 +- | ||
55 | gcc/testsuite/gcc.target/i386/pr70467-1.c | 2 +- | ||
56 | .../gcc/testsuite/gcc.target/i386/warn-vect-op-1.c | 2 +- | ||
57 | 18 files changed, 38 insertions(+), 16 deletions(-) | ||
58 | |||
59 | diff --git a/gcc/testsuite/gcc.dg/pr56275.c b/gcc/testsuite/gcc.dg/pr56275.c | ||
60 | index b901bb2..a4f6c95 100644 | ||
61 | --- a/gcc/testsuite/gcc.dg/pr56275.c | ||
62 | +++ b/gcc/testsuite/gcc.dg/pr56275.c | ||
63 | @@ -1,6 +1,6 @@ | ||
64 | /* { dg-do compile } */ | ||
65 | /* { dg-options "-O2" } */ | ||
66 | -/* { dg-additional-options "-mno-sse" { target { i?86-*-* x86_64-*-* } } } */ | ||
67 | +/* { dg-additional-options "-mno-sse -mfpmath=387" { target { i?86-*-* x86_64-*-* } } } */ | ||
68 | |||
69 | typedef long long v2tw __attribute__ ((vector_size (2 * sizeof (long long)))); | ||
70 | |||
71 | diff --git a/gcc/testsuite/gcc.dg/pr68306-2.c b/gcc/testsuite/gcc.dg/pr68306-2.c | ||
72 | index 4672ebe..2a368c4 100644 | ||
73 | --- a/gcc/testsuite/gcc.dg/pr68306-2.c | ||
74 | +++ b/gcc/testsuite/gcc.dg/pr68306-2.c | ||
75 | @@ -1,6 +1,6 @@ | ||
76 | /* { dg-do compile } */ | ||
77 | /* { dg-options "-O3" } */ | ||
78 | -/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */ | ||
79 | +/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */ | ||
80 | |||
81 | struct { | ||
82 | int tz_minuteswest; | ||
83 | diff --git a/gcc/testsuite/gcc.dg/pr68306-3.c b/gcc/testsuite/gcc.dg/pr68306-3.c | ||
84 | index f5a8c10..df3390c 100644 | ||
85 | --- a/gcc/testsuite/gcc.dg/pr68306-3.c | ||
86 | +++ b/gcc/testsuite/gcc.dg/pr68306-3.c | ||
87 | @@ -1,6 +1,6 @@ | ||
88 | /* { dg-do compile } */ | ||
89 | /* { dg-options "-O3" } */ | ||
90 | -/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */ | ||
91 | +/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */ | ||
92 | /* { dg-additional-options "-mno-altivec -mno-vsx" { target powerpc*-*-* } } */ | ||
93 | |||
94 | extern void fn2(); | ||
95 | diff --git a/gcc/testsuite/gcc.dg/pr68306.c b/gcc/testsuite/gcc.dg/pr68306.c | ||
96 | index 54e5b40..0813389 100644 | ||
97 | --- a/gcc/testsuite/gcc.dg/pr68306.c | ||
98 | +++ b/gcc/testsuite/gcc.dg/pr68306.c | ||
99 | @@ -1,6 +1,6 @@ | ||
100 | /* { dg-do compile } */ | ||
101 | /* { dg-options "-O3" } */ | ||
102 | -/* { dg-additional-options "-mno-sse -mno-mmx" { target i?86-*-* x86_64-*-* } } */ | ||
103 | +/* { dg-additional-options "-mno-sse -mno-mmx -mfpmath=387" { target i?86-*-* x86_64-*-* } } */ | ||
104 | |||
105 | enum powerpc_pmc_type { PPC_PMC_IBM }; | ||
106 | struct { | ||
107 | diff --git a/gcc/testsuite/gcc.dg/pr69634.c b/gcc/testsuite/gcc.dg/pr69634.c | ||
108 | index 60a5614..bcc23f9 100644 | ||
109 | --- a/gcc/testsuite/gcc.dg/pr69634.c | ||
110 | +++ b/gcc/testsuite/gcc.dg/pr69634.c | ||
111 | @@ -1,6 +1,6 @@ | ||
112 | /* { dg-do compile } */ | ||
113 | /* { dg-options "-O2 -fno-dce -fschedule-insns -fno-tree-vrp -fcompare-debug -Wno-psabi" } */ | ||
114 | -/* { dg-additional-options "-mno-sse" { target i?86-*-* x86_64-*-* } } */ | ||
115 | +/* { dg-additional-options "-mno-sse -mfpmath=387" { target i?86-*-* x86_64-*-* } } */ | ||
116 | /* { dg-require-effective-target scheduling } */ | ||
117 | |||
118 | typedef unsigned short u16; | ||
119 | diff --git a/gcc/testsuite/gcc.target/i386/amd64-abi-1.c b/gcc/testsuite/gcc.target/i386/amd64-abi-1.c | ||
120 | index 69fde57..7f1f1c0 100644 | ||
121 | --- a/gcc/testsuite/gcc.target/i386/amd64-abi-1.c | ||
122 | +++ b/gcc/testsuite/gcc.target/i386/amd64-abi-1.c | ||
123 | @@ -1,5 +1,5 @@ | ||
124 | /* { dg-do compile { target { ! ia32 } } } */ | ||
125 | -/* { dg-options "-mno-sse" } */ | ||
126 | +/* { dg-options "-mno-sse -mfpmath=387" } */ | ||
127 | /* { dg-additional-options "-mabi=sysv" { target *-*-mingw* } } */ | ||
128 | |||
129 | double foo(void) { return 0; } /* { dg-error "SSE disabled" } */ | ||
130 | diff --git a/gcc/testsuite/gcc.target/i386/funcspec-6.c b/gcc/testsuite/gcc.target/i386/funcspec-6.c | ||
131 | index ea896b7..bf15569 100644 | ||
132 | --- a/gcc/testsuite/gcc.target/i386/funcspec-6.c | ||
133 | +++ b/gcc/testsuite/gcc.target/i386/funcspec-6.c | ||
134 | @@ -1,6 +1,7 @@ | ||
135 | /* Test whether all of the 64-bit function specific options are accepted | ||
136 | without error. */ | ||
137 | /* { dg-do compile { target { ! ia32 } } } */ | ||
138 | +/* { dg-additional-options "-mfpmath=387" } */ | ||
139 | |||
140 | #include "funcspec-56.inc" | ||
141 | |||
142 | diff --git a/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c b/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c | ||
143 | index 3fbdc88..6b4d9d1 100644 | ||
144 | --- a/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c | ||
145 | +++ b/gcc/testsuite/gcc.target/i386/interrupt-387-err-1.c | ||
146 | @@ -1,5 +1,5 @@ | ||
147 | /* { dg-do compile } */ | ||
148 | -/* { dg-options "-O2 -mgeneral-regs-only -mno-cld -mno-iamcu -m80387" } */ | ||
149 | +/* { dg-options "-O2 -mgeneral-regs-only -mno-cld -mno-iamcu -m80387 -mfpmath=387" } */ | ||
150 | |||
151 | typedef unsigned int uword_t __attribute__ ((mode (__word__))); | ||
152 | |||
153 | diff --git a/gcc/testsuite/gcc.target/i386/isa-14.c b/gcc/testsuite/gcc.target/i386/isa-14.c | ||
154 | index 5d49e6e..1de2db9 100644 | ||
155 | --- a/gcc/testsuite/gcc.target/i386/isa-14.c | ||
156 | +++ b/gcc/testsuite/gcc.target/i386/isa-14.c | ||
157 | @@ -1,5 +1,5 @@ | ||
158 | /* { dg-do run } */ | ||
159 | -/* { dg-options "-march=x86-64 -msse4a -mfma4 -mno-sse" } */ | ||
160 | +/* { dg-options "-march=x86-64 -msse4a -mfma4 -mno-sse -mfpmath=387" } */ | ||
161 | |||
162 | extern void abort (void); | ||
163 | |||
164 | diff --git a/gcc/testsuite/gcc.target/i386/pr44948-2b.c b/gcc/testsuite/gcc.target/i386/pr44948-2b.c | ||
165 | index fa1769b..f79fb12 100644 | ||
166 | --- a/gcc/testsuite/gcc.target/i386/pr44948-2b.c | ||
167 | +++ b/gcc/testsuite/gcc.target/i386/pr44948-2b.c | ||
168 | @@ -1,5 +1,5 @@ | ||
169 | /* { dg-do compile } */ | ||
170 | -/* { dg-options "-O -mno-sse -Wno-psabi -mtune=generic" } */ | ||
171 | +/* { dg-options "-O -mno-sse -Wno-psabi -mtune=generic -mfpmath=387" } */ | ||
172 | |||
173 | struct A | ||
174 | { | ||
175 | diff --git a/gcc/testsuite/gcc.target/i386/pr53425-1.c b/gcc/testsuite/gcc.target/i386/pr53425-1.c | ||
176 | index 2e89ff7..6339bf6 100644 | ||
177 | --- a/gcc/testsuite/gcc.target/i386/pr53425-1.c | ||
178 | +++ b/gcc/testsuite/gcc.target/i386/pr53425-1.c | ||
179 | @@ -1,6 +1,6 @@ | ||
180 | /* PR target/53425 */ | ||
181 | /* { dg-do compile { target { ! ia32 } } } */ | ||
182 | -/* { dg-options "-O2 -mno-sse" } */ | ||
183 | +/* { dg-options "-O2 -mno-sse -mfpmath=387" } */ | ||
184 | /* { dg-skip-if "no SSE vector" { x86_64-*-mingw* } } */ | ||
185 | |||
186 | typedef double __v2df __attribute__ ((__vector_size__ (16))); | ||
187 | diff --git a/gcc/testsuite/gcc.target/i386/pr53425-2.c b/gcc/testsuite/gcc.target/i386/pr53425-2.c | ||
188 | index 61f6283..2c5a55f 100644 | ||
189 | --- a/gcc/testsuite/gcc.target/i386/pr53425-2.c | ||
190 | +++ b/gcc/testsuite/gcc.target/i386/pr53425-2.c | ||
191 | @@ -1,6 +1,6 @@ | ||
192 | /* PR target/53425 */ | ||
193 | /* { dg-do compile { target { ! ia32 } } } */ | ||
194 | -/* { dg-options "-O2 -mno-sse" } */ | ||
195 | +/* { dg-options "-O2 -mno-sse -mfpmath=387" } */ | ||
196 | /* { dg-skip-if "no SSE vector" { x86_64-*-mingw* } } */ | ||
197 | |||
198 | typedef float __v2sf __attribute__ ((__vector_size__ (8))); | ||
199 | diff --git a/gcc/testsuite/gcc.target/i386/pr55247.c b/gcc/testsuite/gcc.target/i386/pr55247.c | ||
200 | index 23366d0..9810e3a 100644 | ||
201 | --- a/gcc/testsuite/gcc.target/i386/pr55247.c | ||
202 | +++ b/gcc/testsuite/gcc.target/i386/pr55247.c | ||
203 | @@ -1,6 +1,6 @@ | ||
204 | /* { dg-do compile { target { ! ia32 } } } */ | ||
205 | /* { dg-require-effective-target maybe_x32 } */ | ||
206 | -/* { dg-options "-O2 -mno-sse -mno-mmx -mx32 -maddress-mode=long" } */ | ||
207 | +/* { dg-options "-O2 -mno-sse -mno-mmx -mx32 -maddress-mode=long -mfpmath=387" } */ | ||
208 | |||
209 | typedef unsigned int uint32_t; | ||
210 | typedef uint32_t Elf32_Word; | ||
211 | diff --git a/gcc/testsuite/gcc.target/i386/pr59644.c b/gcc/testsuite/gcc.target/i386/pr59644.c | ||
212 | index 96006b3..4287e45 100644 | ||
213 | --- a/gcc/testsuite/gcc.target/i386/pr59644.c | ||
214 | +++ b/gcc/testsuite/gcc.target/i386/pr59644.c | ||
215 | @@ -1,6 +1,6 @@ | ||
216 | /* PR target/59644 */ | ||
217 | /* { dg-do run { target lp64 } } */ | ||
218 | -/* { dg-options "-O2 -ffreestanding -mno-sse -mpreferred-stack-boundary=3 -maccumulate-outgoing-args -mno-red-zone" } */ | ||
219 | +/* { dg-options "-O2 -ffreestanding -mno-sse -mpreferred-stack-boundary=3 -maccumulate-outgoing-args -mno-red-zone -mfpmath=387" } */ | ||
220 | |||
221 | /* This test uses __builtin_trap () instead of e.g. abort, | ||
222 | because due to -mpreferred-stack-boundary=3 it should not call | ||
223 | diff --git a/gcc/testsuite/gcc.target/i386/pr62120.c b/gcc/testsuite/gcc.target/i386/pr62120.c | ||
224 | index bfb8c47..ed04cf1 100644 | ||
225 | --- a/gcc/testsuite/gcc.target/i386/pr62120.c | ||
226 | +++ b/gcc/testsuite/gcc.target/i386/pr62120.c | ||
227 | @@ -1,5 +1,5 @@ | ||
228 | /* { dg-do compile } */ | ||
229 | -/* { dg-options "-mno-sse" } */ | ||
230 | +/* { dg-options "-mno-sse -mfpmath=387" } */ | ||
231 | |||
232 | void foo () | ||
233 | { | ||
234 | diff --git a/gcc/testsuite/gcc.target/i386/pr70467-1.c b/gcc/testsuite/gcc.target/i386/pr70467-1.c | ||
235 | index 4e112c8..bcfb396 100644 | ||
236 | --- a/gcc/testsuite/gcc.target/i386/pr70467-1.c | ||
237 | +++ b/gcc/testsuite/gcc.target/i386/pr70467-1.c | ||
238 | @@ -1,6 +1,6 @@ | ||
239 | /* PR rtl-optimization/70467 */ | ||
240 | /* { dg-do compile } */ | ||
241 | -/* { dg-options "-O2 -mno-sse" } */ | ||
242 | +/* { dg-options "-O2 -mno-sse -mfpmath=387" } */ | ||
243 | |||
244 | void foo (unsigned long long *); | ||
245 | |||
246 | diff --git a/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c b/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c | ||
247 | index 6cda153..26e37f5 100644 | ||
248 | --- a/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c | ||
249 | +++ b/gcc/testsuite/gcc.target/i386/warn-vect-op-1.c | ||
250 | @@ -1,5 +1,5 @@ | ||
251 | /* { dg-do compile { target { ! ia32 } } } */ | ||
252 | -/* { dg-options "-mno-sse -Wvector-operation-performance" } */ | ||
253 | +/* { dg-options "-mno-sse -Wvector-operation-performance -mfpmath=387" } */ | ||
254 | #define vector(elcount, type) \ | ||
255 | __attribute__((vector_size((elcount)*sizeof(type)))) type | ||
256 | |||
257 | -- | ||
258 | 1.8.5.6 | ||
259 | |||