Author: Uri Blass
Date: 10:56:26 01/08/03
Go up one level in this thread
On January 08, 2003 at 13:49:56, Uri Blass wrote: >Here is the descreption of the error. > >Subscript Overrun: Array index value 44 exceeds array index limit of 8. > >Current Call Stack >evalchange c:\unzipped\movei257source\evaluate.c 213 >evalmovewithoutpawns c:\unzipped\movei257source\evaluate.c 312 >evalmove c:\unzipped\movei257source\evaluate.c 316 >makemove c:\unzipped\movei257source\boardi.c 4834 >makeandprintpvmove c:\unzipped\movei257source\main.c 677 >xboard c:\unzipped\movei257source\main.c 1237 >main c:\unzipped\movei257source\main.c 414 >mainCRTStartup crt0.c 206 > C:\WINNT\system32\KERNEL32.dll!0x00017d03 > > >I do not understand what is the error because I do not see an array with limit >of 8. > >The command that movei was supposed to do is > >if (color(from)==LIGHT) > change=pcsq[piece(from)][63-to]-pcsq[piece(from)][63-from]; > >I have the following defintion in def.h > > >#define piece(target) ((info[target])&7) >#define color(target) (((info[target])>>3)&3) > >I also have >int PADDED_info[80]; >int * const info = PADDED_info+8; > >in data.c > >and >extern int * const info; >in data.h >It means that practically I can call info[i] for every -8<=i<=71 > >I thought maybe a problem in pcsq but I have in data.c > >int pcsq[6][64]= > >I also have in data.h >extern int pcsq[6][64]; > >Uri Note also that I tried checkingbounds few days ago and thought that there is no problem but I did not use start debug but execute. I thought that if the program run significantly slower in run mode then it means that it check for bound errors but today I decided to test it by doing an error on purpose and only after checking bounds did not find the error I understood that I was wrong. I do not see what is the purpose of execute in debug mode. I see only 2 cases(case 1 is that I want to debug the program and case 2 when I want to run it as fast as possible). Can somebody explain me what is the purpose of the option execute when the program is not in release mode? Uri
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.