Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Problem with Nalimov Tablebases

Author: Todd Segal

Date: 13:00:56 05/01/02

Go up one level in this thread


 I have posted the code below, taking out some cout's and function sig's. I am
sure everything is kosher up to the probe call...

I am using g++ under a dual Pentium III 1.1Ghz Intel based PC running Solaris 8
x86 (an instructional machine at my university).

Thanks again for any help!

  IInitializeTb(HOMEDIR);
  int PieceDesc[10];
  //PieceDesc will be used to describe number of pieces etc.
  Fill Piece Desc correctly <-- I have checked this!

  int TB = IDescFindFromCounters(PieceDesc);
  int side;
  int invert;
  square *white_loc, *black_loc;
  int enPassant = XX;

  if (TB > 0)
    {
      side = turn;
      invert = false;
      white_loc = b->white_squares;     //b is the board
      black_loc = b->black_squares;
    }
  else
    {
      side = (turn == WHITE) ? BLACK : WHITE;
      invert = true;
      white_loc = b->black_squares;
      black_loc = b->white_squares;
      TB = -TB;
    }
  INDEX index = PfnIndCalc(TB, side) (white_loc, black_loc, XX, invert);
  int results = L_TbtProbeTable(TB, 0, index);







On May 01, 2002 at 10:04:31, Tom Likens wrote:

>
>Todd,
>
>Could you possibly post the code that is giving you the trouble.  Also
>any additional information such as the compiler you are using, operating
>system, PC etc. would also be helpful.
>
>Also if you are programming under Windows and are worried about pointer
>errors it might be worthwhile to run your code under Bounds Checker.
>If you don't have acccess to Bounds Checker then stepping through your
>program with a good debugger might point out the problem.
>
>As a word of encouragement- Nalimov's tablebase code *does* work :)
>
>regards,
>--tom
>
>On May 01, 2002 at 04:47:56, Todd Segal wrote:
>
>>Hi,
>>
>>I am programming a project using Nalimov tablebases and whenever I probe a
>>tablebase (no matter which one) I seem to be getting the same result from the
>>probe function (from Nalimov's tbindex.cpp).
>>
>>More specifically when calling  "L_TbtProbeTable(iTb, 0, index); " I always get
>>32767 (not bev_broken).
>>
>>I think I am setting everything up right, but I fear this is a problem due to
>>bad initialization or bad pointers (I never get a segfault though).
>>
>>Any help would be HUGELY HELPFUL!
>>
>>Thanks so much!
>>
>>- Todd Segal



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.