autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: alignment boundary


From: Bob Friesenhahn
Subject: Re: alignment boundary
Date: Sat, 12 May 2007 10:02:57 -0500 (CDT)

On Sat, 12 May 2007, Ralf Wildenhues wrote:

One approach is to use malloc() to allocate some memory and see what
the alignment of the returned address is:

Its alignment could be much larger than needed, no?

Yes, possibly.  But no less.

If you have only a finite set of data types to check, then you can use
AC_CHECK_ALIGNOF on (a union of) the types.

In that case be sure to test for the 128 bit integer and double types supported by some common CPUs. Given the lack of standardization for how to specify these extended types ('long long int'? 'long double'?) developing a configure test could be interesting.

Bob
======================================
Bob Friesenhahn
address@hidden, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]