delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-0.5 required=5.0 tests=AWL,BARRACUDA_BRBL,BAYES_20,SPF_SOFTFAIL |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <49591AA6.4080702@bmts.com> |
Date: | Mon, 29 Dec 2008 13:44:54 -0500 |
From: | Ralph Hempel <rhempel AT bmts DOT com> |
User-Agent: | Thunderbird 2.0.0.6 (X11/20071022) |
MIME-Version: | 1.0 |
To: | cygwin AT cygwin DOT com |
Subject: | Re: Cygwin struct alignment |
References: | <006b01c965c1$6a7c6300$4001a8c0 AT mycomputer> <003a01c965fe$539063c0$4001a8c0 AT mycomputer> <495291CD DOT 1000207 AT bmts DOT com> <004701c96993$ea2fa5f0$4001a8c0 AT mycomputer> <4959125A DOT 6020708 AT x-ray DOT at> <00cc01c969e3$57127590$4001a8c0 AT mycomputer> |
In-Reply-To: | <00cc01c969e3$57127590$4001a8c0@mycomputer> |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
John Emmas wrote: > Christopher / Reini - thanks for your tips. John, here's a quote from your original email: > As things stand, both client and server use System V shared memory and > everything works well if I compile under Cygwin or Linux. Ultimately > however, there'll be no Linux clients. The clients will either be > Cygwin clients or Windows clients. Therefore I'm currently > experimenting to see if I can change the server to use Windows shared > memory (only under Cygwin of course - not for Linux use). I'll repeat my original statement, which is that you will run screaming from your workstation before you will make two separate compilers understand each other's structure packing and struct alignment consistently. You might end up packing individual structs OK, but nested structs may end up aligned on full 32 or 64 bit boundaries again. I've been through this with HC16 and Blackfin processors, and I'm running into it with ARM devices too. However close you get to the Rosetta Stone of compiler settings, there will be corner cases that will not work, and you'll have a hell of a time tracking down the errors. Have a close look at the RFC I pointed you to, and see if it can help. Even if you just play with it for fun, there will be another tool in your belt when you're done. Ralph -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |