Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: oops

Author: Severi Salminen

Date: 08:32:27 11/26/00

Go up one level in this thread


On November 26, 2000 at 11:22:17, Dan Andersson wrote:

>In a 32 bit processor how long is an integer?

Hmm...54 bits? No? In x86 family the size of an integer can be 8,16 or 32 bits.
It is not allways 32 bits. It is the matter of compiler/OS what size it chooses.
Nowadays 32 bit is the most common when using INT or LONG (in C or C++)

The point is that the programmer doesn't have to consider that. When I use 64
bit integers the compiler takes care of the two halves and I don't have to.
Usually compilers produce faster code than manually writeing assembler. So when
one uses 64 bit bitboards in chess program and divides them to two 32 bit
integers it makes me ask why. Probably he has some other reason than the size of
E?? registers? I don't know - that's why I asked. If he is using a compiler
which can't use 64 bit integers (LONG LOGN or __int64) then it is clear.

Severi



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.