Commit Graph

10 Commits

Author SHA1 Message Date
Qian Hong ff3c4a7d2f Check for correct funtion entry address in munge_threadfunc
* init.cc (munge_threadfunc): Check that we're actually replacing
	the correct original function address on the stack.
	* ntdll.h (enum _THREADINFOCLASS): Add ThreadQuerySetWin32StartAddress.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-29 09:17:57 +01:00
Brian Inglis 6090952296 strftime: Add support for %s (seconds since epoch)
* libc/time/strftime.c (__strftime): add support for %s (seconds from
	Unix epoch).  Fix whitespaces.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-27 09:41:40 +01:00
Corinna Vinschen 6b457615e6 Export aligned_alloc, at_quick_exit, quick_exit.
* common.din (aligned_alloc): Export.
	(at_quick_exit): Export.
	(quick_exit): Export.

	* posix.xml (std-iso): New section.
	(std-deprec): Rearrange title text.
	* new-features.xml (ov-new2.3): Document aligned_alloc, at_quick_exit,

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-22 16:21:17 +02:00
Corinna Vinschen e01381afde Avoid SEGV when handling SIDs with 0 subauthorities
* sec_helper.cc (cygsid::get_sid): Don't reject SIDs with missing
	subauthorities.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-22 15:38:42 +02:00
Corinna Vinschen 6599fad55d Add release message for previous Cygwin patch 2015-10-22 15:35:46 +02:00
Corinna Vinschen c0345822e5 Fix memory leak in pthread_getattr_np
* thread.cc (pthread_getattr_np): Fix memory leak, remove usage of
	malloc for small local buffer.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-21 12:46:32 +02:00
Corinna Vinschen 713161b28b Fix EIO error accessing certain (OS X SMB?) drives
* path.cc (symlink_info::check_reparse_point): Don't generate an EIO
	error if NtFsControlFile returns STATUS_NOT_A_REPARSE_POINT.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-10-21 12:01:11 +02:00
Corinna Vinschen 36da3f961c Cygwin 2.3.0: Add missing release message
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-09-08 22:53:54 +02:00
Corinna Vinschen 38fd7ddb79 Allow sysconf to return CPU cache information
* include/sys/unistd.h (_SC_LEVEL*): Add cache-related variables as
        on Linux.

        * fhandler_proc.cc (format_proc_cpuinfo): Fetch cache information
        from new cache functions in sysconf.cc, get_cpu_cache_intel and
        get_cpu_cache_amd.
        * sysconf.cc (__nt_query_system): New local helper.
        (get_nproc_values): Utilize __nt_query_system on pre-Windows 7 systems.
        Use GetLogicalProcessorInformationEx otherwise to handle more than
        64 CPUs.  Only handle _SC_NPROCESSORS_CONF and _SC_NPROCESSORS_ONLN.
        (get_phys_pages): New helper to handle _SC_PHYS_PAGES.
        (cpuid2_cache_descriptor): New array to map Intel CPUID 2 descriptor
        values to cache type, cache size, associativity and linesize.
        (cpuid2_cache_desc_compar): Comparision function for bsearch over
        cpuid2_cache_descriptor.
        (get_cpu_cache_intel_cpuid2): New function to fetch cache info from
        Intel CPUID 2.
        (get_cpu_cache_intel_cpuid4): Ditto from Intel CPUID 4.
        (get_cpu_cache_intel): New function as CPU-specific entry point.
        (assoc): New array to map associativity values from AMD CPUID
        0x80000006.
        (get_cpu_cache_amd): New function to fetch cache info from AMD CPUIDs
        0x80000005 and 0x80000006.
        (get_cpu_cache): New function to fetch cache info.
        (sca): Call get_phys_pages if _SC_PHYS_PAGES is requested.  Call
        get_cpu_cache for new _SC_* cache requests.
        (SC_MAX): Set to _SC_LEVEL4_CACHE_LINESIZE.
        (get_phys_pages(void)): Call get_phys_pages(int).
        * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.

        * new-features.xml (ov-new2.3): Document sysconf cache addition.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-08-29 09:16:47 +02:00
Corinna Vinschen 35d5d87540 Implement POSIX_MADV_WILLNEED/POSIX_MADV_DONTNEED for newer OSes
* autoload.cc (DiscardVirtualMemory): Import.
        (PrefetchVirtualMemory): Import.
        * mmap.cc (posix_madvise): Actually implement POSIX_MADV_WILLNEED
        utilizing PrefetchVirtualMemory and POSIX_MADV_DONTNEED utilizing
        DiscardVirtualMemory on systems supporting them.
        * wincap.h (wincaps::has_broken_prefetchvm): New element.
        * wincap.cc: Implement above element throughout.
        (wincapc::init): Make sure has_broken_prefetchvm is only true on
        W10 under WOW64.
        * include/cygwin/version.h (CYGWIN_VERSION_DLL_MAJOR): Bump to 2003.
        (CYGWIN_VERSION_API_MINOR): Reset to 0.

        * new-features.xml (ov-new2.3): New section, document posix_madvise
        POSIX_MADV_WILLNEED/POSIX_MADV_DONTNEED change.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2015-08-27 13:34:25 +02:00
Renamed from winsup/cygwin/release/2.2.2 (Browse further)