[Top][All Lists]

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

Re: FW: AC_CHECK_ALIGNOF maximum ??

From: Eric Blake
Subject: Re: FW: AC_CHECK_ALIGNOF maximum ??
Date: Wed, 04 Dec 2013 10:43:06 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0

On 06/20/2013 08:37 AM, 'Chris Hall' wrote:
> I hope I am in the right place, if not please direct me !

Just now noticing this mail, and that no one ever seemed to reply.

> I have found:
>   AC_CHECK_ALIGNOF (type, [includes = ‘AC_INCLUDES_DEFAULT’])
> which is quite lovely, as far as it goes... but it does not appear to
> tell me the maximum possible alignment.

What are you expecting to do with the biggest alignment, anyways?  The
most you can portably do is determine the alignment of the types you
plan on using ('long long', 'long double', or if you probe for extension
types such as __int128_t and then check the alignment of that).

> Of course gcc gives __BIGGEST_ALIGNMENT__ for this.  And I guess other
> compilers do something similar...
> ...but I cannot help feeling that autoconf should cover this, but if
> it does, I have failed to find where :-(

Without a good use case for what you expect to do with it that you
cannot already determine by checking the alignments of the biggest types
your code uses, I'm not sure that autoconf needs an extra macro.

Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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