Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Yet another GCC question

Author: Robert Hyatt

Date: 19:05:47 12/05/03

Go up one level in this thread


On December 05, 2003 at 21:44:41, Russell Reagan wrote:

>On December 05, 2003 at 21:24:19, Robert Hyatt wrote:
>
>>I have a structure that looks like this:
>>
>>struct BOOK_POSITION {
>>  long long signature;
>>  unsigned int status;
>>  float learn;
>>  int CAP;
>>}
>>
>>sizeof(above) gives 20 on my dual xeon, 24 on the
>>opteron.  I'd like to make it 20 so that my binary book
>>can be shared between the opteron and the rest of the
>>intel world.
>>
>>Is there a reasonably portable way to fix this???
>>
>>(note the long long becomes a long on the opteron, the rest
>>are not changed.)
>
>The -fpack-struct option seems to do the trick, but I think it will probably
>remove any padding for all structs, which might not be a good thing overall.


Certainly fixed that, but it slowed things down overall.  Guess I give up on
a portable binary book file, which is not that important anyway.  Fixing to
build an enormous book.bin to see what this opteron is capable of doing with
that process...




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.