Boost logo

Boost :

Subject: Re: [boost] Need some 64-bit testing help.
From: John Maddock (boost.regex_at_[hidden])
Date: 2012-01-17 15:20:07


>> No I mean it's only been tested on a machine with a 32-bit registers.
>> It's
>> the integer manipulations I want to double check - there are some
>> expressions which could conceivably be optimized in a way that would fail
>> if
>> 64-bit registers are used - I believe they shouldn't do so if the
>> standard
>> is strictly followed - but sometimes compilers can play a bit
>> fast-and-loose
>> when optimizations are turned on. If necessary I have a fallback, but
>> let's
>> see if there's an issue first.
>>
>> John.
>>
>
> I'm confused. As I'm sure we all know, 64 bit amd x86_64 uses 64 bit
> pointers,
> but int is still 32 bit.

It uses a mix of 32 and 64 bit integer operations, for example "complement a
32 bit int, then promote to 64 bits and add". Reverse the order of
operations and the complement will do the wrong thing. Any clearer? ;-)

John.


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