diff options
Diffstat (limited to 'winsup/mingw')
-rw-r--r-- | winsup/mingw/ChangeLog | 65 | ||||
-rwxr-xr-x | winsup/mingw/configure | 2 | ||||
-rw-r--r-- | winsup/mingw/configure.in | 2 | ||||
-rw-r--r-- | winsup/mingw/include/_mingw.h | 25 | ||||
-rw-r--r-- | winsup/mingw/include/excpt.h | 23 | ||||
-rw-r--r-- | winsup/mingw/include/inttypes.h | 39 | ||||
-rw-r--r-- | winsup/mingw/include/limits.h | 4 | ||||
-rw-r--r-- | winsup/mingw/include/process.h | 22 | ||||
-rw-r--r-- | winsup/mingw/include/stdint.h | 1 | ||||
-rw-r--r-- | winsup/mingw/include/stdio.h | 8 | ||||
-rw-r--r-- | winsup/mingw/include/stdlib.h | 9 | ||||
-rw-r--r-- | winsup/mingw/include/sys/param.h | 4 | ||||
-rw-r--r-- | winsup/mingw/include/wchar.h | 4 | ||||
-rw-r--r-- | winsup/mingw/mingwex/Makefile.in | 6 | ||||
-rw-r--r-- | winsup/mingw/mingwex/gdtoa/gd_qnan.h | 8 | ||||
-rw-r--r-- | winsup/mingw/mingwex/membarrier.c | 19 | ||||
-rwxr-xr-x | winsup/mingw/mingwex/tsearch.c | 26 | ||||
-rw-r--r-- | winsup/mingw/profile/Makefile.in | 4 |
18 files changed, 45 insertions, 226 deletions
diff --git a/winsup/mingw/ChangeLog b/winsup/mingw/ChangeLog index 3eb8975c1..1dd80cc56 100644 --- a/winsup/mingw/ChangeLog +++ b/winsup/mingw/ChangeLog @@ -1,68 +1,3 @@ -2012-08-08 Kai Tietz <ktietz@redhat.com> - - * mingwex/gdtoa/gd_qnan.h: Make Nan constants positive valued. - -2012-08-06 Earnie Boyd <earnie@users.sourceforge.net> - - * mingwex/membarrier.c: New file. - * mingwex/Makefile.in (DISTFILES): Add membarrier.c. - (REPLACE_OBJS): Add membarrier.o. - -2012-08-02 Ivan Maidanski <ivmai@users.sourceforge.net> - - * include/process.h (_wexec*, _wspawn*): Declare. - -2012-08-02 Earnie Boyd <earnie@users.sourceforge.net> - - * include/stdlib.h (_strtoi64): Declare. - (_strtoi64_l): Ditto. - (_strtoui64): Ditto. - (_strtoui64_l): Ditto. - (_wcstrtoi64): Ditto. - (_wcstrtoi64_l): Ditto. - (_wcstrtoui64): Ditto. - (_wcstrtoui64_l): Ditto. - * include/wchar.h (_wcstrtoi64): Ditto. - (_wcstrtoi64_l): Ditto. - (_wcstrtoui64): Ditto. - (_wcstrtoui64_l): Ditto. - * include/stdio.h (_getws, _putws): Guard with #ifndef __STRICT_ANSI__. - (_wfdopen, _wfopen, _wfreopen, _wfsopen, _wtmpnam, _wtempnam): Ditto. - (_wrename, _wremove, _wperror, _wpopen): Ditto. - (_lock_file, _unlock_file): Declare. - * include/limits.h (PATH_MAX): Guard with #ifndef __STRICT_ANSI__. - * include/sys/param.h (MAXPATHLEN): Make sure PATH_MAX is defined. - * include/_mingw.h (threadlocalinfostruct, threadmbinfostruct, - *pthreadlocinfo, *pthreadmbcinfo, _locale_tstruct, *_locale_t): Declare. - * mingwex/tsearch.c: Correct coding to produce the proper results. - -2012-08-01 Earnie Boyd <earnie@users.sourceforge.net> - - * include/excpt.h (__try1): Define based on _WIN64 definition. - (__except1): Ditto. - -2012-07-30 Earnie Boyd <earnie@users.sourceforge.net> - - * include/stdint.h: Include _mingw.h for the definition of __int64 when - _WIN64 is defined. - * include/inttypes.h: A few items like PRNdPTR and SCNdPTR need 64 - bitness specified when _WIN64 is defined. - * include/_mingw.h: Add __MINGW_VERSION, __MINGW_MAJOR_VERSION, - __MINGW_MINOR_VERSION and __MINGW_PATCHLEVEL deprecating the __MINGW32_* - versions of the macros. - * configure.in: Use __MINGW_VERSION instead of __MINGW32_VERSION. - * configure: Ditto. - -2012-05-08 Keith Marshall <keithmarshall@users.sourceforge.net> - - Remove references to nonexistent files. - - * mingwex/Makefile.in (DISTFILES): Delete references to aclocal.m4, - configure.in, and configure; these are no longer required, and are no - longer available for distribution. - - * profile/Makefile.in (DISTFILES): Likewise. - 2012-02-01 Keith Marshall <keithmarshall@users.sourceforge.net> More performance enhancements and POSIX compliance corrections. diff --git a/winsup/mingw/configure b/winsup/mingw/configure index 598ed6d9d..1ca8b5336 100755 --- a/winsup/mingw/configure +++ b/winsup/mingw/configure @@ -1788,7 +1788,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:$LINENO: checking package version" >&5 $as_echo_n "checking package version... " >&6; } - PACKAGE_VERSION=`awk '$2 == "'"__MINGW_VERSION"'" { print $3 }' ${srcdir}/include/_mingw.h` + PACKAGE_VERSION=`awk '$2 == "'"__MINGW32_VERSION"'" { print $3 }' ${srcdir}/include/_mingw.h` { $as_echo "$as_me:$LINENO: result: $PACKAGE_VERSION" >&5 $as_echo "$PACKAGE_VERSION" >&6; } diff --git a/winsup/mingw/configure.in b/winsup/mingw/configure.in index eccf84074..92dbd3d1d 100644 --- a/winsup/mingw/configure.in +++ b/winsup/mingw/configure.in @@ -18,7 +18,7 @@ dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. AC_PREREQ([2.59]) AC_INIT([MinGW Runtime], [v3.x], [http://mingw.org/reporting_bugs], [mingwrt]) -MINGW_AC_CONFIG_SRCDIR([__MINGW_VERSION], [include/_mingw.h]) +MINGW_AC_CONFIG_SRCDIR([__MINGW32_VERSION], [include/_mingw.h]) AC_CANONICAL_SYSTEM GCC_NO_EXECUTABLES diff --git a/winsup/mingw/include/_mingw.h b/winsup/mingw/include/_mingw.h index cbfd54ced..cb0ff53a7 100644 --- a/winsup/mingw/include/_mingw.h +++ b/winsup/mingw/include/_mingw.h @@ -22,13 +22,6 @@ */ #define __MINGW_H -#define __MINGW_VERSION 4 -#define __MINGW_MAJOR_VERSION 0 -#define __MINGW_MINOR_VERSION 0 -#define __MINGW_PATCHLEVEL 0 - -// These four macros are deprecated and will be removed in the next major -// version release. #define __MINGW32_VERSION 3.20 #define __MINGW32_MAJOR_VERSION 3 #define __MINGW32_MINOR_VERSION 20 @@ -47,10 +40,10 @@ __MINGW_IMPORT The attribute definition to specify imported variables/functions. _CRTIMP As above. For MS compatibility. - __MINGW_VERSION Runtime version. - __MINGW_MAJOR_VERSION Runtime major version. - __MINGW_MINOR_VERSION Runtime minor version. - __MINGW_BUILD_DATE Runtime build date. + __MINGW32_VERSION Runtime version. + __MINGW32_MAJOR_VERSION Runtime major version. + __MINGW32_MINOR_VERSION Runtime minor version. + __MINGW32_BUILD_DATE Runtime build date. Macros to enable MinGW features which deviate from standard MSVC compatible behaviour; these may be specified directly in user code, @@ -290,14 +283,4 @@ allow GCC to optimize away some EH unwind code, at least in DW2 case. */ # endif #endif -struct threadlocalinfostruct; -struct threadmbinfostruct; -typedef struct threadlocalinfostruct *pthreadlocinfo; -typedef struct threadmbcinfostruct *pthreadmbcinfo; - -typedef struct localeinfo_struct { - pthreadlocinfo locinfo; - pthreadmbcinfo mbcinfo; -} _locale_tstruct, *_locale_t; - #endif /* __MINGW_H */ diff --git a/winsup/mingw/include/excpt.h b/winsup/mingw/include/excpt.h index 3919cb791..e75ceb78f 100644 --- a/winsup/mingw/include/excpt.h +++ b/winsup/mingw/include/excpt.h @@ -75,15 +75,8 @@ typedef PEXCEPTION_REGISTRATION PEXCEPTION_REGISTRATION_RECORD; * onto the stack, then put a pointer to the new registration * structure (i.e. the current stack pointer) at fs:0. */ -#ifdef _WIN64 -# define __try1(pHandler) \ - __asm__ __volatile__ ("pushq %0;pushq %%gs:0;movq %%rsp,%%gs:0;" : : \ - "g" (pHandler)); -#else -# define __try1(pHandler) \ - __asm__ __volatile__ ("pushl %0;pushl %%fs:0;movl %%esp,%%fs:0;" : : \ - "g" (pHandler)); -#endif +#define __try1(pHandler) \ + __asm__ ("pushl %0;pushl %%fs:0;movl %%esp,%%fs:0;" : : "g" (pHandler)); /* * A macro which (despite its name) *removes* an installed @@ -96,15 +89,9 @@ typedef PEXCEPTION_REGISTRATION PEXCEPTION_REGISTRATION_RECORD; * the stack must be in the exact state at this point that it was * after we did __try1 or this will smash things. */ -#ifdef _WIN64 -# define __except1 \ - __asm__ __volatile__ ("movq (%%rsp),%%rax;movq %%rax,%%gs:0;addq \ - $16,%%rsp;" : : : "%rax"); -#else -# define __except1 \ - __asm__ __volatile__ ("movl (%%esp),%%eax;movl %%eax,%%fs:0;addl \ - $8,%%esp;" : : : "%eax"); -#endif +#define __except1 \ + __asm__ ("movl (%%esp),%%eax;movl %%eax,%%fs:0;addl $8,%%esp;" \ + : : : "%eax"); #ifdef __cplusplus } diff --git a/winsup/mingw/include/inttypes.h b/winsup/mingw/include/inttypes.h index e13040634..2d2bb8d80 100644 --- a/winsup/mingw/include/inttypes.h +++ b/winsup/mingw/include/inttypes.h @@ -44,6 +44,7 @@ typedef struct { #define PRIdFAST64 "I64d" #define PRIdMAX "I64d" +#define PRIdPTR "d" #define PRIi8 "i" #define PRIi16 "i" @@ -61,6 +62,7 @@ typedef struct { #define PRIiFAST64 "I64i" #define PRIiMAX "I64i" +#define PRIiPTR "i" #define PRIo8 "o" #define PRIo16 "o" @@ -79,6 +81,8 @@ typedef struct { #define PRIoMAX "I64o" +#define PRIoPTR "o" + /* fprintf macros for unsigned types */ #define PRIu8 "u" #define PRIu16 "u" @@ -97,6 +101,7 @@ typedef struct { #define PRIuFAST64 "I64u" #define PRIuMAX "I64u" +#define PRIuPTR "u" #define PRIx8 "x" #define PRIx16 "x" @@ -114,6 +119,7 @@ typedef struct { #define PRIxFAST64 "I64x" #define PRIxMAX "I64x" +#define PRIxPTR "x" #define PRIX8 "X" #define PRIX16 "X" @@ -131,22 +137,7 @@ typedef struct { #define PRIXFAST64 "I64X" #define PRIXMAX "I64X" - -#ifdef _WIN64 -#define PRIdPTR "I64d" -#define PRIiPTR "I64i" -#define PRIoPTR "I64o" -#define PRIuPTR "I64u" -#define PRIxPTR "I64x" -#define PRIXPTR "I64X" -#else -#define PRIdPTR "d" -#define PRIiPTR "i" -#define PRIoPTR "o" -#define PRIuPTR "u" -#define PRIxPTR "x" #define PRIXPTR "X" -#endif /* * fscanf macros for signed int types @@ -168,6 +159,7 @@ typedef struct { #define SCNdFAST64 "I64d" #define SCNdMAX "I64d" +#define SCNdPTR "d" #define SCNi16 "hi" #define SCNi32 "i" @@ -182,6 +174,7 @@ typedef struct { #define SCNiFAST64 "I64i" #define SCNiMAX "I64i" +#define SCNiPTR "i" #define SCNo16 "ho" #define SCNo32 "o" @@ -196,6 +189,7 @@ typedef struct { #define SCNoFAST64 "I64o" #define SCNoMAX "I64o" +#define SCNoPTR "o" #define SCNx16 "hx" #define SCNx32 "x" @@ -210,6 +204,8 @@ typedef struct { #define SCNxFAST64 "I64x" #define SCNxMAX "I64x" +#define SCNxPTR "x" + /* fscanf macros for unsigned int types */ @@ -226,20 +222,7 @@ typedef struct { #define SCNuFAST64 "I64u" #define SCNuMAX "I64u" - -#ifdef _WIN64 -#define SCNdPTR "I64d" -#define SCNiPTR "I64i" -#define SCNoPTR "I64o" -#define SCNxPTR "I64x" -#define SCNuPTR "I64u" -#else -#define SCNdPTR "d" -#define SCNiPTR "i" -#define SCNoPTR "o" -#define SCNxPTR "x" #define SCNuPTR "u" -#endif #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L /* diff --git a/winsup/mingw/include/limits.h b/winsup/mingw/include/limits.h index ca4900610..96ad26cec 100644 --- a/winsup/mingw/include/limits.h +++ b/winsup/mingw/include/limits.h @@ -29,9 +29,7 @@ * are semantically identical, with a limit of 259 characters for the * path name, plus one for a terminating NUL, for a total of 260. */ -#ifndef __STRICT_ANSI__ -# define PATH_MAX 260 -#endif +#define PATH_MAX 260 /* * Characteristics of the char data type. diff --git a/winsup/mingw/include/process.h b/winsup/mingw/include/process.h index 0a3511f4d..c0c380fbd 100644 --- a/winsup/mingw/include/process.h +++ b/winsup/mingw/include/process.h @@ -79,28 +79,6 @@ _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnve (int, const char*, const char* _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnvp (int, const char*, const char* const*); _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnvpe (int, const char*, const char* const*, const char* const*); -#ifndef _WPROCESS_DEFINED -/* Also in wchar.h - keep in sync */ -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecl (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecle (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexeclp (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexeclpe (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecv (const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecve (const wchar_t*, const wchar_t* const*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecvp (const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecvpe (const wchar_t*, const wchar_t* const*, const wchar_t* const*); - -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnl (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnle (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnlp (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnlpe (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnv (int, const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnve (int, const wchar_t*, const wchar_t* const*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnvp (int, const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnvpe (int, const wchar_t*, const wchar_t* const*, const wchar_t* const*); - -#define _WPROCESS_DEFINED -#endif /* * The functions _beginthreadex and _endthreadex are not provided by CRTDLL. diff --git a/winsup/mingw/include/stdint.h b/winsup/mingw/include/stdint.h index 942a1a8fc..c6ab3bcef 100644 --- a/winsup/mingw/include/stdint.h +++ b/winsup/mingw/include/stdint.h @@ -19,7 +19,6 @@ #ifndef _STDINT_H #define _STDINT_H -#include <_mingw.h> #define __need_wint_t #define __need_wchar_t #include <stddef.h> diff --git a/winsup/mingw/include/stdio.h b/winsup/mingw/include/stdio.h index 60f540114..fe9f2b735 100644 --- a/winsup/mingw/include/stdio.h +++ b/winsup/mingw/include/stdio.h @@ -591,13 +591,10 @@ _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW fgetws (wchar_t*, int, FILE*); _CRTIMP int __cdecl __MINGW_NOTHROW fputws (const wchar_t*, FILE*); _CRTIMP wint_t __cdecl __MINGW_NOTHROW getwc (FILE*); _CRTIMP wint_t __cdecl __MINGW_NOTHROW getwchar (void); -_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwc (wint_t, FILE*); -_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwchar (wint_t); -#ifndef __STRICT_ANSI__ -_CRTIMP void __cdecl __MINGW_NOTHROW _lock_file(FILE*); -_CRTIMP void __cdecl __MINGW_NOTHROW _unlock_file(FILE*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _getws (wchar_t*); +_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwc (wint_t, FILE*); _CRTIMP int __cdecl __MINGW_NOTHROW _putws (const wchar_t*); +_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwchar (wint_t); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfdopen(int, const wchar_t *); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfopen (const wchar_t*, const wchar_t*); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfreopen (const wchar_t*, const wchar_t*, FILE*); @@ -608,7 +605,6 @@ _CRTIMP int __cdecl __MINGW_NOTHROW _wrename (const wchar_t*, const wchar_t*); _CRTIMP int __cdecl __MINGW_NOTHROW _wremove (const wchar_t*); _CRTIMP void __cdecl __MINGW_NOTHROW _wperror (const wchar_t*); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wpopen (const wchar_t*, const wchar_t*); -#endif /* __STRICT_ANSI__ */ #endif /* __MSVCRT__ */ #ifndef __NO_ISOCEXT /* externs in libmingwex.a */ diff --git a/winsup/mingw/include/stdlib.h b/winsup/mingw/include/stdlib.h index ece21cb44..4df18aab3 100644 --- a/winsup/mingw/include/stdlib.h +++ b/winsup/mingw/include/stdlib.h @@ -300,11 +300,6 @@ __MINGW_IMPORT int _fmode_dll; #endif /* Not __STRICT_ANSI__ */ -_CRTIMP __int64 __cdecl _strtoi64(const char*, char **, int); -_CRTIMP __int64 __cdecl _strtoi64_l(const char *, char **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _strtoui64(const char*, char **, int); -_CRTIMP unsigned __int64 __cdecl _strtoui64_l(const char *, char **, int, _locale_t); - _CRTIMP double __cdecl __MINGW_NOTHROW atof (const char*); _CRTIMP int __cdecl __MINGW_NOTHROW atoi (const char*); _CRTIMP long __cdecl __MINGW_NOTHROW atol (const char*); @@ -328,10 +323,6 @@ _CRTIMP unsigned long __cdecl __MINGW_NOTHROW strtoul (const char*, char**, int) #ifndef _WSTDLIB_DEFINED /* also declared in wchar.h */ -_CRTIMP __int64 __cdecl _wcstoi64(const wchar_t *, wchar_t **, int); -_CRTIMP __int64 __cdecl _wcstoi64_l(const wchar_t *, wchar_t **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _wcstoui64(const wchar_t *, wchar_t **, int); -_CRTIMP unsigned __int64 __cdecl _wcstoui64_l(const wchar_t *, wchar_t **, int, _locale_t); _CRTIMP long __cdecl __MINGW_NOTHROW wcstol (const wchar_t*, wchar_t**, int); _CRTIMP unsigned long __cdecl __MINGW_NOTHROW wcstoul (const wchar_t*, wchar_t**, int); _CRTIMP double __cdecl __MINGW_NOTHROW wcstod (const wchar_t*, wchar_t**); diff --git a/winsup/mingw/include/sys/param.h b/winsup/mingw/include/sys/param.h index d38b46a5c..74966bd78 100644 --- a/winsup/mingw/include/sys/param.h +++ b/winsup/mingw/include/sys/param.h @@ -17,10 +17,6 @@ #define LITTLE_ENDIAN 1234 #define BYTE_ORDER LITTLE_ENDIAN -#ifdef PATH_MAX #define MAXPATHLEN PATH_MAX -#else -#define MAXPATHLEN 260 -#endif #endif diff --git a/winsup/mingw/include/wchar.h b/winsup/mingw/include/wchar.h index dadeda6d3..60e8d9c2b 100644 --- a/winsup/mingw/include/wchar.h +++ b/winsup/mingw/include/wchar.h @@ -177,10 +177,6 @@ _CRTIMP void __cdecl __MINGW_NOTHROW _wmakepath(wchar_t*, const wchar_t*, const _CRTIMP void __cdecl __MINGW_NOTHROW _wsplitpath (const wchar_t*, wchar_t*, wchar_t*, wchar_t*, wchar_t*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wfullpath (wchar_t*, const wchar_t*, size_t); #endif -_CRTIMP __int64 __cdecl _wcstoi64(const wchar_t *, wchar_t **, int); -_CRTIMP __int64 __cdecl _wcstoi64_l(const wchar_t *, wchar_t **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _wcstoui64(const wchar_t *, wchar_t **, int); -_CRTIMP unsigned __int64 __cdecl _wcstoui64_l(const wchar_t *, wchar_t **, int, _locale_t); #define _WSTDLIB_DEFINED #endif /* _WSTDLIB_DEFINED */ diff --git a/winsup/mingw/mingwex/Makefile.in b/winsup/mingw/mingwex/Makefile.in index afe32e5be..a495d5269 100644 --- a/winsup/mingw/mingwex/Makefile.in +++ b/winsup/mingw/mingwex/Makefile.in @@ -35,12 +35,12 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs DISTFILES = \ - Makefile.in \ + Makefile.in configure configure.in aclocal.m4 \ _Exit.c atoll.c dirent.c feclearexcept.c fegetenv.c \ fegetexceptflag.c fegetround.c feholdexcept.c feraiseexcept.c \ fesetenv.c fesetexceptflag.c fesetround.c fetestexcept.c \ feupdateenv.c ftruncate.c fwide.c getopt.c imaxabs.c imaxdiv.c \ - lltoa.c lltow.c mbsinit.c membarrier.c mingw-aligned-malloc.c \ + lltoa.c lltow.c mbsinit.c mingw-aligned-malloc.c \ mingw-fseek.c sitest.c strtoimax.c strtoumax.c \ testwmem.c tst-aligned-malloc.c ulltoa.c ulltow.c wcstof.c \ wcstoimax.c wcstold.c wcstoumax.c wctrans.c wctype.c \ @@ -201,7 +201,7 @@ POSIX_OBJS = \ dirent.o wdirent.o getopt.o ftruncate.o gettimeofday.o usleep.o \ basename.o dirname.o tsearch.o twalk.o tdelete.o tfind.o REPLACE_OBJS = \ - membarrier.o mingw-aligned-malloc.o mingw-fseek.o + mingw-aligned-malloc.o mingw-fseek.o COMPLEX_OBJS = \ cabs.o cabsf.o cabsl.o cacos.o cacosf.o cacosl.o cacosh.o \ cacoshf.o cacoshl.o carg.o cargf.o cargl.o casin.o casinf.o \ diff --git a/winsup/mingw/mingwex/gdtoa/gd_qnan.h b/winsup/mingw/mingwex/gdtoa/gd_qnan.h index 0b468c492..87eba8fb3 100644 --- a/winsup/mingw/mingwex/gdtoa/gd_qnan.h +++ b/winsup/mingw/mingwex/gdtoa/gd_qnan.h @@ -1,12 +1,12 @@ -#define f_QNAN 0x7fc00000 +#define f_QNAN 0xffc00000 #define d_QNAN0 0x0 -#define d_QNAN1 0x7ff80000 +#define d_QNAN1 0xfff80000 #define ld_QNAN0 0x0 #define ld_QNAN1 0xc0000000 -#define ld_QNAN2 0x7fff +#define ld_QNAN2 0xffff #define ld_QNAN3 0x0 #define ldus_QNAN0 0x0 #define ldus_QNAN1 0x0 #define ldus_QNAN2 0x0 #define ldus_QNAN3 0xc000 -#define ldus_QNAN4 0x7fff +#define ldus_QNAN4 0xffff diff --git a/winsup/mingw/mingwex/membarrier.c b/winsup/mingw/mingwex/membarrier.c deleted file mode 100644 index b8da9f7de..000000000 --- a/winsup/mingw/mingwex/membarrier.c +++ /dev/null @@ -1,19 +0,0 @@ -/** - * THIS SOFTWARE IS NOT COPYRIGHTED - * - * This source code is offered for use in the public domain. You may - * use, modify or distribute it freely. - * - * This code is distributed in the hope that it will be useful but - * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY - * DISCLAIMED. This includes but is not limited to warranties of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - */ -void __mingworg_MemoryBarrier(void); -void __mingworg_MemoryBarrier(void) -{ - long Barrier = 0; - __asm__ __volatile__("xchgl %%eax,%0 " - :"=r" (Barrier)); -} - diff --git a/winsup/mingw/mingwex/tsearch.c b/winsup/mingw/mingwex/tsearch.c index 55f192214..a0aa0eb36 100755 --- a/winsup/mingw/mingwex/tsearch.c +++ b/winsup/mingw/mingwex/tsearch.c @@ -23,33 +23,29 @@ tsearch(const void * __restrict__ vkey, /* key to be located */ void ** __restrict__ vrootp, /* address of tree root */ int (*compar) (const void *, const void *)) { - node_t *q, **n; + node_t *q; node_t **rootp = (node_t **)vrootp; if (rootp == NULL) return NULL; - n = rootp; - while (*n != NULL) { /* Knuth's T1: */ + while (*rootp != NULL) { /* Knuth's T1: */ int r; - if ((r = (*compar)(vkey, ((*n)->key))) == 0) /* T2: */ - return *n; /* we found it! */ + if ((r = (*compar)(vkey, (*rootp)->key)) == 0) /* T2: */ + return *rootp; /* we found it! */ - n = (r < 0) ? + rootp = (r < 0) ? &(*rootp)->llink : /* T3: follow left branch */ &(*rootp)->rlink; /* T4: follow right branch */ - if (*n == NULL) - break; - rootp = n; } q = malloc(sizeof(node_t)); /* T5: key not found */ - if (!q) - return q; - *n = q; /* make new node */ - /* LINTED const castaway ok */ - q->key = (void *)vkey; /* initialize new node */ - q->llink = q->rlink = NULL; + if (q != 0) { /* make new node */ + *rootp = q; /* link new node to old */ + /* LINTED const castaway ok */ + q->key = (void *)vkey; /* initialize new node */ + q->llink = q->rlink = NULL; + } return q; } diff --git a/winsup/mingw/profile/Makefile.in b/winsup/mingw/profile/Makefile.in index afd480960..83a288033 100644 --- a/winsup/mingw/profile/Makefile.in +++ b/winsup/mingw/profile/Makefile.in @@ -33,8 +33,8 @@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs -DISTFILES = Makefile.in gcrt0.c gmon.c gmon.h \ - mcount.c profil.c profil.h profile.h CYGWIN_LICENSE COPYING +DISTFILES = Makefile.in configure configure.in aclocal.m4 gcrt0.c gmon.c gmon.h \ +mcount.c profil.c profil.h profile.h CYGWIN_LICENSE COPYING CC = @CC@ # FIXME: Which is it, CC or CC_FOR_TARGET? |