DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 4ALIjRHU4175820 Authentication-Results: delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com Authentication-Results: delorie.com; spf=pass smtp.mailfrom=cygwin.com DKIM-Filter: OpenDKIM Filter v2.11.0 delorie.com 4ALIjRHU4175820 Authentication-Results: delorie.com; dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=lS6O8120 X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 785943857820 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1732214726; bh=430dV0PYhYvRH9UhxfQsDcRZKosOhb1eYr+/3F9IQcI=; h=Date:To:Subject:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=lS6O81201CMV8r0dylLapOusCWADLSwfgxa6Cw1eCPAyTvZ2QoQPawULTPzxOxtAH nPrCn6yXtKBifNixcujIbikfK7UBTIhYfi/mjxHZ6Ebh+mYKZLg9lVAnKo9w1q9gQ7 gjC70XYABJUYSED/XUdLzLAkLRCILkT0V2meaYAU= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C7CF33857C7A Date: Thu, 21 Nov 2024 19:44:55 +0100 To: cygwin AT cygwin DOT com Subject: Re: include tag in uname -s for ARM64 hosts Message-ID: Mail-Followup-To: cygwin AT cygwin DOT com References: <833327a2-3a62-ed26-e4ba-5302bcdb8000 AT jdrake DOT com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Corinna Vinschen via Cygwin Reply-To: cygwin AT cygwin DOT com Cc: Corinna Vinschen Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" On Nov 21 10:15, Jeremy Drake via Cygwin wrote: > On Thu, 21 Nov 2024, Corinna Vinschen via Cygwin wrote: > > > > i686 x86_64 -WOW64-x64 (or omit arch to match existing?) > > > > Just -WOW64 > > > > For backward compat and it's a sole representative of an intel-intel > > emulation anyway. I think we may safely ignore "WOW" > > > > > i686 ARM64 -WOW64-ARM64 > > > > Just -ARM64 > > > > The suffix already indicates an emulator, the target CPU is in the > > machine field. > > > > > ARM ARM64 -WOW64-ARM64 > > > > Apart from not supporting 32 bit targets anymore (the tiny address space > > is simply not feasible anymore) just -ARM64. Again, the target CPU is > > in the machine field. > > > Interesting. So basically disregard the wincap.is_wow64 (which is gone > anyway in supported versions), and only look at the host arch, appending a > tag only when it's different from Cygwin's own arch, with the special case > that x64 is called "WOW64"? (Maybe the special case should be if the host > is x64 AND Cygwin is i686, otherwise use x64, just in case MS does > something useful like adding ARM64 emulation to x86_64) I bet, they won't. There's no reason to. These emulators are meant to enable old, paid applications to run on a new system. Now consider that 99.9% of Windows apps are x86{_64} and 0.01% of apps are ARM64. Of these 0.01%, 100% are available as x86{_64} app anyway. IMHO: if (IsWow64Process2 (GetCurrentProcess (), &emulated, &hosted)) && emulated != IMAGE_FILE_MACHINE_UNKNOWN) if (hosted == IMAGE_FILE_MACHINE_AMD64) strcat (sysname, "-WOW64"); else if (hosted == IMAGE_FILE_MACHINE_ARM64) strcat (sysname, "-ARM64"); else stract (sysname, "-WTF"); } And the target machine is in the machine field, so the info should be sufficient to identify the emulation environment. Corinna -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple