X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:reply-to :references:mime-version:content-type:in-reply-to; q=dns; s= default; b=WIqaAooXQIhIA4eYgijnTQmQaUzVjMxW9yEpmHOOANJ+/wufIJkEC HdiGKQC1JTxoO81+mulOcY1AXqm/PbEzOQtheQ352TjAQLp/if+DvlM69NX/JArk UrvSwrKKPCn6R6GvHoaPv4TLj1T8jzrmxCM5T5awSi0hquKVV1tNGE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:reply-to :references:mime-version:content-type:in-reply-to; s=default; bh=2BTaw/6vzUGS1mYD0/Sjmth8HAg=; b=VStjgNQPyDwUwhJUH7om96x7WCam myl5qcod5/Xhic65DkroAEcn2zkAMd+zQLiihwBsGBFaPHEYDjrQaUUM30sIHbi9 c7urEu0TVpKas09dWLAOcAVt861Lu86SC1BC6KnogKz/ADWZO27MSlkjsqK2vsgW 8qX0hlWkRJzFRiE= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-100.9 required=5.0 tests=BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=yselkowiredhatcom, yselkowi AT redhat DOT com, medical, Medical X-HELO: mout.kundenserver.de Date: Thu, 29 Nov 2018 09:58:16 +0100 From: Corinna Vinschen To: Sam Habiel , cygwin AT cygwin DOT com Subject: Re: 32 bit vs 64 bit Cygwin, followup Message-ID: <20181129085816.GV30649@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: Sam Habiel , cygwin AT cygwin DOT com References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="/0P/MvzTfyTu5j9Q" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) --/0P/MvzTfyTu5j9Q Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Please, no top-posting. On Nov 28 11:06, Sam Habiel wrote: > Yaakov, >=20 > On Wed, Nov 28, 2018 at 11:01 AM Yaakov Selkowitz w= rote: > > > > On Mon, 2018-11-26 at 14:07 -0500, Sam Habiel wrote: > > > Hello everybody, > > > > > > In this message > > > (https://www.sourceware.org/ml/cygwin/2018-11/msg00190.html), Corinna > > > (Hi Corinna!) says: > > > > > > "Don't do that. Use 64 bit Cygwin whenever possible. 32 bit is a lo= st cause." > > > > > > I would like to mention why I am still using 32 bit Cygwin. > > > > > > I maintain a port of a database called GT.M > > > (https://en.wikipedia.org/wiki/GT.M) on Cygwin. I work with Electronic > > > Medical Records that run on this database. GT.M contains a large > > > amount of assembly code, written to run on the x32 Linux ABI and the > > > AMD x64 ABI. It's was very easy to get the x32 Linux ABI to run on > > > Cygwin x32; Cygwin x64 on the other hand uses the Windows x64 ABI, > > > which is very different than the AMD ABI (more detail here: > > > https://eli.thegreenplace.net/2011/09/06/stack-frame-layout-on-x86-64= /). > > > I don't have the expertise nor the time to rewrite a lot of assembly > > > code to use the Windows x64 ABI. There are about 100 source code files > > > that are in assembly. > > > > -mabi=3Dsysv ? > > > Are you telling me that gcc has a flag to support AMD ABI on Cygwin > x64? The assembly code is not standalone; it gets called from C code > and calls C code. That's what he's telling you. However, you have to interact with the MS ABI(*) as well as soon as you call external library functions so it makes sense to keep your C code in MS ABI. For the assembler functions, you can just tell the compiler they are in SYSV ABI by adding a function attribute to the declaration: int asm_func (args) __attribute__ ((sysv_abi)) Good luck, Corinna (*) Just keep in mind that Cygwin is LP64, not LLP64: https://cygwin.com/faq/faq.html#faq.programming.64bitporting --=20 Corinna Vinschen Cygwin Maintainer --/0P/MvzTfyTu5j9Q Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEoVYPmneWZnwT6kwF9TYGna5ET6AFAlv/qigACgkQ9TYGna5E T6APzQ//cAOBdFAV1Dn4b49lG/9FSnWjurIkzEZejvzKyXQBeL2b/etHkfFB+Vmc /Ej2vAQRfotVrYwNxjIA76OOgDRZ/r6Isx5Ms1El/XSM9fBiQ371QMiSsGwQ7vvP MkNEh1P5eMY0Wrt+d85InBy0t1Eu6DaM9TYRIX+wt71ULOILTSziEiRyg6DIvzqn 3oaN3wIRz8a90y2odOObXWOvmoJgz0DVsLyduC585UBMm9sr5Jfl4w2jbnWBY4RS nD2zWjFJz/vO1CYErWRZO1jOBIHGuB68HXl4Jp/4upuS53ALAuJbVYLqBTQ2ZdXh CsYajH0Q1u9/bCeQ/g7Gzwrf0YmjxOV+GZ9+M9gQ0/CaFM3B+h+wvsMZTlXUE1bz WKvZckDcltAlvss0kWojmm4u4+A3HiiUlTn7ctZewSEXnfmPslevLG9EM+lE8X3/ 2MfBxmV32QUqnwusEN0Bh9bA+P4y/mRYzlOaJUGUb0PoXNMJsOuy2OKzDAHNOCKy XT195A4E594aWiiaq+9YBgRBJjOoZcBHpPBycnXC1gc6ICO4T5kiNiVbRxrzU36v MdvVPGotPFkBDc5j1VtXNVwgEQIiu8IbA50wmZRCV6N+3g1JxJVkn11NWExINSvu HKnrDLfuSzUGyE+scpJ1CoFOGJhU4O9OtPZ1AhKeNUDQMJFbnuI= =7zoy -----END PGP SIGNATURE----- --/0P/MvzTfyTu5j9Q--