Subject: Re: powerpc gcc alignment problem
To: Guenther Grau <>
From: David Edelsohn <>
List: tech-toolchain
Date: 01/14/2000 11:27:54
	You are proposing mis-using the STRICT_ALIGNMENT macro.  The
description of the macro in the GCC documentation states:

     Define this macro to be the value 1 if instructions will fail to
     work if given data not on the nominal alignment.  If instructions
     will merely go slower in that case, define this macro as 0.

For the case of PowerPC big-endian, instructions WILL NOT FAIL TO WORK.
The description specifically says not to define this macro if instruction
simply perform more slowly.

	If you want to improve the flexibility and granularity of the
SLOW_UNALIGNED_ACCESS macro so that GCC chooses better instruction
sequences for access to values that it recognizes as unaligned, be my

	This discussion started because of instructions generated for a
library written relatively recently whose data layout is atrocious.  No
one is mentioning the inherent problem in this library.

	The discussion has continued with a number of incorrect premises
about both PowerPC architecture and the GNU C Compiler leading to
incorrect conclusions.  So far I have not heard any NetBSD-specific
subtlty which justifies the proposed conclusion despite all of the
incorrect premises.