===================================================================
@@ -1,3 +1,9 @@
+2013-09-20 Bruce Korb <bkorb@gnu.org>
+
+ * inclhack.def: many of the headers found under "bits/" are
+ often stashed under architecture directories. Apply fixes
+ to those, too. Also, re-ordered a couple of misordered fixes.
+
2013-09-20 Alan Modra <amodra@gmail.com>
* configure: Regenerate.
===================================================================
[[generated]]
===================================================================
@@ -1140,6 +1140,20 @@
};
/*
+ * Old Linux kernel's <compiler.h> header breaks Traditional CPP
+ */
+fix = {
+ hackname = complier_h_tradcpp;
+ files = linux/compiler.h;
+
+ select = "#define __builtin_warning\\(x, y\\.\\.\\.\\) \\(1\\)";
+ c_fix = format;
+ c_fix_arg = "/* __builtin_warning(x, y...) is obsolete */";
+
+ test_text = "#define __builtin_warning(x, y...) (1)";
+};
+
+/*
* Fix various macros used to define ioctl numbers.
* The traditional syntax was:
*
@@ -1509,6 +1523,60 @@
};
/*
+ * Incorrect feraiseexcept extern inline in bits/fenv.h on x86_64
+ * that fails when compiling for SSE-less 32-bit x86.
+ */
+fix = {
+ hackname = feraiseexcept_nosse_invalid;
+ mach = 'i[34567]86-*-linux*', 'x86*-linux*', 'amd64-*-linux*';
+ files = bits/fenv.h, '*/bits/fenv.h';
+ select = "^([\t ]*)__asm__ __volatile__ \\(\"divss %0, %0 *\" : "
+ ": \"x\" \\(__f\\)\\);$";
+ bypass = "\"fdiv .*; fwait\"";
+
+ c_fix = format;
+ c_fix_arg = <<- _EOText_
+ # ifdef __SSE_MATH__
+ %0
+ # else
+ %1__asm__ __volatile__ ("fdiv %%%%st, %%%%st(0); fwait"
+ %1 : "=t" (__f) : "0" (__f));
+ # endif
+ _EOText_;
+
+ test_text = <<- _EOText_
+ __asm__ __volatile__ ("divss %0, %0" : : "x" (__f));
+ _EOText_;
+};
+
+/*
+ * Incorrect feraiseexcept extern inline in bits/fenv.h on x86_64
+ * that fails when compiling for SSE-less 32-bit x86.
+ */
+fix = {
+ hackname = feraiseexcept_nosse_divbyzero;
+ mach = 'i[34567]86-*-linux*', 'x86*-linux*', 'amd64-*-linux*';
+ files = bits/fenv.h, '*/bits/fenv.h';
+ select = "^([\t ]*)__asm__ __volatile__ \\(\"divss %1, %0 *\" : "
+ ": \"x\" \\(__f\\), \"x\" \\(__g\\)\\);$";
+ bypass = "\"fdivp .*; fwait\"";
+
+ c_fix = format;
+ c_fix_arg = <<- _EOText_
+ # ifdef __SSE_MATH__
+ %0
+ # else
+ %1__asm__ __volatile__ ("fdivp %%%%st, %%%%st(1); fwait"
+ %1 : "=t" (__f) : "0" (__f), "u" (__g) : "st(1)");
+ # endif
+ _EOText_;
+
+ test_text = <<- _EOText_
+ __asm__ __volatile__ ("divss %1, %0" : : "x" (__f), "x" (__g));
+ _EOText_;
+};
+
+/*
* Between 8/24/1998 and 2/17/2001, FreeBSD system headers presume
* neither the existence of GCC 3 nor its exact feature set yet break
* (by design?) when __GNUC__ is set beyond 2.
@@ -1738,7 +1806,7 @@
versions. */
fix = {
hackname = glibc_strncpy;
- files = bits/string2.h;
+ files = bits/string2.h, '*/bits/string2.h';
bypass = "__builtin_strncpy";
c_fix = format;
c_fix_arg = "# define strncpy(dest, src, n) __builtin_strncpy (dest, src, n)";
@@ -2411,7 +2479,7 @@
*/
fix = {
hackname = huge_val_hex;
- files = bits/huge_val.h;
+ files = bits/huge_val.h, '*/bits/huge_val.h';
select = "^#[ \t]*define[ \t]*HUGE_VAL[ \t].*0x1\\.0p.*";
bypass = "__builtin_huge_val";
@@ -2426,7 +2494,7 @@
*/
fix = {
hackname = huge_valf_hex;
- files = bits/huge_val.h;
+ files = bits/huge_val.h, '*/bits/huge_val.h';
select = "^#[ \t]*define[ \t]*HUGE_VALF[ \t].*0x1\\.0p.*";
bypass = "__builtin_huge_valf";
@@ -2441,7 +2509,7 @@
*/
fix = {
hackname = huge_vall_hex;
- files = bits/huge_val.h;
+ files = bits/huge_val.h, '*/bits/huge_val.h';
select = "^#[ \t]*define[ \t]*HUGE_VALL[ \t].*0x1\\.0p.*";
bypass = "__builtin_huge_vall";
@@ -4226,7 +4294,7 @@
fix = {
hackname = thread_keyword;
files = "pthread.h";
- files = "bits/sigthread.h";
+ files = bits/sigthread.h, '*/bits/sigthread.h';
select = "([* ])__thread([,)])";
c_fix = format;
c_fix_arg = "%1__thr%2";
@@ -4760,72 +4828,4 @@
test_text = "extern char *\tsprintf();";
};
-/*
- * Incorrect feraiseexcept extern inline in bits/fenv.h on x86_64
- * that fails when compiling for SSE-less 32-bit x86.
- */
-fix = {
- hackname = feraiseexcept_nosse_invalid;
- mach = 'i[34567]86-*-linux*', 'x86*-linux*', 'amd64-*-linux*';
- files = bits/fenv.h;
- select = "^([\t ]*)__asm__ __volatile__ \\(\"divss %0, %0 *\" : "
- ": \"x\" \\(__f\\)\\);$";
- bypass = "\"fdiv .*; fwait\"";
-
- c_fix = format;
- c_fix_arg = <<- _EOText_
- # ifdef __SSE_MATH__
- %0
- # else
- %1__asm__ __volatile__ ("fdiv %%%%st, %%%%st(0); fwait"
- %1 : "=t" (__f) : "0" (__f));
- # endif
- _EOText_;
-
- test_text = <<- _EOText_
- __asm__ __volatile__ ("divss %0, %0" : : "x" (__f));
- _EOText_;
-};
-
-/*
- * Incorrect feraiseexcept extern inline in bits/fenv.h on x86_64
- * that fails when compiling for SSE-less 32-bit x86.
- */
-fix = {
- hackname = feraiseexcept_nosse_divbyzero;
- mach = 'i[34567]86-*-linux*', 'x86*-linux*', 'amd64-*-linux*';
- files = bits/fenv.h;
- select = "^([\t ]*)__asm__ __volatile__ \\(\"divss %1, %0 *\" : "
- ": \"x\" \\(__f\\), \"x\" \\(__g\\)\\);$";
- bypass = "\"fdivp .*; fwait\"";
-
- c_fix = format;
- c_fix_arg = <<- _EOText_
- # ifdef __SSE_MATH__
- %0
- # else
- %1__asm__ __volatile__ ("fdivp %%%%st, %%%%st(1); fwait"
- %1 : "=t" (__f) : "0" (__f), "u" (__g) : "st(1)");
- # endif
- _EOText_;
-
- test_text = <<- _EOText_
- __asm__ __volatile__ ("divss %1, %0" : : "x" (__f), "x" (__g));
- _EOText_;
-};
-
-/*
- * Old Linux kernel's <compiler.h> header breaks Traditional CPP
- */
-fix = {
- hackname = complier_h_tradcpp;
- files = linux/compiler.h;
-
- select = "#define __builtin_warning\\(x, y\\.\\.\\.\\) \\(1\\)";
- c_fix = format;
- c_fix_arg = "/* __builtin_warning(x, y...) is obsolete */";
-
- test_text = "#define __builtin_warning(x, y...) (1)";
-};
-
/*EOF*/