Newsgroups: comp.arch Path: utzoo!henry From: henry@utzoo.uucp (Henry Spencer) Subject: Re: Unaligned Accesses (was Re: How to use silicon) Message-ID: <1989Mar29.232103.6835@utzoo.uucp> Organization: U of Toronto Zoology References: <37196@bbn.COM> <1989Mar16.190043.23227@utzoo.uucp> <24889@amdcad.AMD.COM> <355@bnr-fos.UUCP> <13@microsoft.UUCP> <362@bnr-fos.UUCP> <59@microsoft.UUCP> <343@unicads.UUCP> <25000@amdcad.AMD.COM> Date: Wed, 29 Mar 89 23:21:03 GMT In article bruce@tigger.wv.tek.com (Bruce Robertson;685-2912;;;tigger) writes: >... nothing says you can't write a utility to reorder your >structure members at the C source level, optimizing for a particular >architecture. Obviously, you would have to avoid using this utility >if the order of structure elements matters (you wouldn't want to do it >to the Unix kernel!) If you look at the kernel sources, especially the older parts, you'll find that there is a remarkable tendency for (e.g.) "char" members of structs to be grouped together so they will pack densely. -- Welcome to Mars! Your | Henry Spencer at U of Toronto Zoology passport and visa, comrade? | uunet!attcan!utzoo!henry henry@zoo.toronto.edu