[Prev] Thread [Next]  |  [Prev] Date [Next]

Re: from 32 to 64 Paul Fri Jul 31 13:30:49 2009

stan wrote:
On Fri, 31 Jul 2009 20:12:05 +0100 (BST)
Patrick Dupre <[EMAIL PROTECTED]> wrote:


I do observe abnormal results with my applications

Moving from a 32 to 64 bits architecture, using, c, C++, perl, is
they something that I should be aware of ? like size of the
float, integer ?

Yes, in C and C++, shouldn't matter in perl.  If you search on 64 bit
compatibility you will find articles.  There was a post on this list a
long time ago about it also.

Basically, there are special names that adjust depending on arch size.

Some of the type sizes are different between 32-bit and 64-bit architectures, even between different 32-bit architectures. Other types are fixed, no matter what architecture you use.

A char, for instance, is always 8 bits or one byte. A Unicode char, if implemented, is 16 bits or two bytes.

An int is a "natural" integer, a.k.a. "word", for the CPU architecture, so 8, 16, 32 or 64 bits depending on the CPU.

More detail can be found here: http://en.wikipedia.org/wiki/C_variable_types_and_declarations, among other places.




fedora-list mailing list
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines