Boost logo

Boost :

Subject: Re: [boost] [PREDEF] Review for the Boost.Predef library by Rene Riviera
From: Mathias Gaunard (mathias.gaunard_at_[hidden])
Date: 2012-02-19 06:38:24


On 02/18/2012 10:18 PM, Lars Viklund wrote:
> On Sat, Feb 18, 2012 at 03:01:49PM -0600, Rene Rivera wrote:
>> On 2/18/2012 8:36 AM, Klaim - Joël Lamotte wrote:
>>> I guess it is ok to ask about details even if the library isn't in review
>>> yet, right?
>>
>> Sure.. As it certainly won't prevent me from answering them ;-)
>>
>>> I'm not an expert in architecture so I hope I'm not asking
>>> something obvious.
>>>
>>> My understanding is that for example if you're targeting classic PC
>>> hardware, you'll get
>>> BOOST_ARCHITECTURE_X86 for 32Bit OS
>>> BOOST_ARCHITECTURE_AMD64 for 64Bit OS (running on 64bit processor).
>>
>> If you are targeting 64Bit you are more likely to get both
>> BOOST_ARCHITECTURE_AMD64 and BOOST_ARCHITECTURE_IA64.
>
> The set of 64-bit architectures is a bit error-prone to enumerate
> explicitly in user code, as the set will inevitably be either incomplete
> or stale.
>
> Just consider SPARC, IBM's POWER, MIPS, and not to mention the most
> glorious DEC Alpha.

Couldn't you just use static_if(sizeof(void*) == 8) for this? ;)


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk