From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2155) id CCD59395B062; Fri, 13 May 2022 12:39:02 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CCD59395B062 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Corinna Vinschen To: cygwin-cvs@sourceware.org Subject: [newlib-cygwin] Cygwin: wincap: drop has_broken_prefetchvm flag and related code X-Act-Checkin: newlib-cygwin X-Git-Author: Corinna Vinschen X-Git-Refname: refs/heads/master X-Git-Oldrev: 24363cffefd2aa21050497398f4b8c874286bcba X-Git-Newrev: bf6940a4133d920a75bed91b231cf2527173287c Message-Id: <20220513123902.CCD59395B062@sourceware.org> Date: Fri, 13 May 2022 12:39:02 +0000 (GMT) X-BeenThere: cygwin-cvs@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Cygwin core component git logs List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 May 2022 12:39:02 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3Dbf6940a4133= d920a75bed91b231cf2527173287c commit bf6940a4133d920a75bed91b231cf2527173287c Author: Corinna Vinschen Date: Mon Mar 7 12:30:32 2022 +0100 Cygwin: wincap: drop has_broken_prefetchvm flag and related code =20 Signed-off-by: Corinna Vinschen Diff: --- winsup/cygwin/mmap.cc | 10 +--------- winsup/cygwin/wincap.cc | 13 ------------- winsup/cygwin/wincap.h | 2 -- 3 files changed, 1 insertion(+), 24 deletions(-) diff --git a/winsup/cygwin/mmap.cc b/winsup/cygwin/mmap.cc index 7982fd18e..b38ffc39e 100644 --- a/winsup/cygwin/mmap.cc +++ b/winsup/cygwin/mmap.cc @@ -1487,15 +1487,7 @@ posix_madvise (void *addr, size_t len, int advice) WIN32_MEMORY_RANGE_ENTRY me =3D { base, size }; if (!PrefetchVirtualMemory (GetCurrentProcess (), 1, &me, 0) && GetLastError () !=3D ERROR_PROC_NOT_FOUND) - { - /* FIXME 2015-08-27: On W10 build 10240 under WOW64, - PrefetchVirtualMemory always returns ERROR_INVALID_PARAMETER - for some reason. If we're running on W10 WOW64, ignore this - error. This has been fixed in W10 1511. */ - if (!wincap.has_broken_prefetchvm () - || GetLastError () !=3D ERROR_INVALID_PARAMETER) - ret =3D EINVAL; - } + ret =3D EINVAL; } break; case POSIX_MADV_DONTNEED: diff --git a/winsup/cygwin/wincap.cc b/winsup/cygwin/wincap.cc index a1c0a452e..e67778c2c 100644 --- a/winsup/cygwin/wincap.cc +++ b/winsup/cygwin/wincap.cc @@ -27,7 +27,6 @@ wincaps wincap_7 __attribute__((section (".cygwin_dll_com= mon"), shared)) =3D { has_gaa_largeaddress_bug:true, has_precise_system_time:false, has_microsoft_accounts:false, - has_broken_prefetchvm:false, has_new_pebteb_region:false, has_broken_whoami:true, has_unprivileged_createsymlink:false, @@ -58,7 +57,6 @@ wincaps wincap_8 __attribute__((section (".cygwin_dll_com= mon"), shared)) =3D { has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:false, has_broken_whoami:false, has_unprivileged_createsymlink:false, @@ -89,7 +87,6 @@ wincaps wincap_8_1 __attribute__((section (".cygwin_dll_c= ommon"), shared)) =3D { has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:false, has_broken_whoami:false, has_unprivileged_createsymlink:false, @@ -120,7 +117,6 @@ wincaps wincap_10_1507 __attribute__((section (".cygwi= n_dll_common"), shared)) has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:true, has_new_pebteb_region:false, has_broken_whoami:false, has_unprivileged_createsymlink:false, @@ -151,7 +147,6 @@ wincaps wincap_10_1607 __attribute__((section (".cygwi= n_dll_common"), shared)) has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:true, has_new_pebteb_region:false, has_broken_whoami:false, has_unprivileged_createsymlink:false, @@ -182,7 +177,6 @@ wincaps wincap_10_1703 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -213,7 +207,6 @@ wincaps wincap_10_1709 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -244,7 +237,6 @@ wincaps wincap_10_1803 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -275,7 +267,6 @@ wincaps wincap_10_1809 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -306,7 +297,6 @@ wincaps wincap_10_1903 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -337,7 +327,6 @@ wincaps wincap_10_2004 __attribute__((section (".cygwin= _dll_common"), shared)) =3D has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -368,7 +357,6 @@ wincaps wincap_11 __attribute__((section (".cygwin_dll_= common"), shared)) =3D { has_gaa_largeaddress_bug:false, has_precise_system_time:true, has_microsoft_accounts:true, - has_broken_prefetchvm:false, has_new_pebteb_region:true, has_broken_whoami:false, has_unprivileged_createsymlink:true, @@ -450,7 +438,6 @@ wincapc::init () ((wincaps *)caps)->is_server =3D (version.wProductType !=3D VER_NT_WORKS= TATION); { ((wincaps *)caps)->has_gaa_largeaddress_bug =3D false; - ((wincaps *)caps)->has_broken_prefetchvm =3D false; } =20 __small_sprintf (osnam, "NT-%d.%d", version.dwMajorVersion, diff --git a/winsup/cygwin/wincap.h b/winsup/cygwin/wincap.h index 3114771e5..6b5723aa5 100644 --- a/winsup/cygwin/wincap.h +++ b/winsup/cygwin/wincap.h @@ -21,7 +21,6 @@ struct wincaps unsigned has_gaa_largeaddress_bug : 1; unsigned has_precise_system_time : 1; unsigned has_microsoft_accounts : 1; - unsigned has_broken_prefetchvm : 1; unsigned has_new_pebteb_region : 1; unsigned has_broken_whoami : 1; unsigned has_unprivileged_createsymlink : 1; @@ -82,7 +81,6 @@ public: bool IMPLEMENT (has_gaa_largeaddress_bug) bool IMPLEMENT (has_precise_system_time) bool IMPLEMENT (has_microsoft_accounts) - bool IMPLEMENT (has_broken_prefetchvm) bool IMPLEMENT (has_new_pebteb_region) bool IMPLEMENT (has_broken_whoami) bool IMPLEMENT (has_unprivileged_createsymlink)