Author: Uri Blass
Date: 03:28:44 07/17/03
Go up one level in this thread
On July 17, 2003 at 06:14:04, Richard Pijl wrote: >On July 17, 2003 at 05:58:39, Gerd Isenberg wrote: > >>On July 17, 2003 at 05:06:16, Uri Blass wrote: >> >>>Note that the name of the arrays that I have is different but I replaced the >>>names to make it easy to understand the problem. >>> >>>I have an array A[64][8] >>> >>>I want to replace it by 8 arrays A0[64],A1[64],...A7[64] when A[i][j]=Aj[i] >> >>Hi Uri, >> >>I would suggest A[8][64] for your purpose. >> >>Then you still may index the arrays with A[j][sq] and you get your suggested >>single 64 element arrays: A0[sq], A1[sq] with A[0][sq], A[1][sq] ... >> >>Gerd > >Of course! Let the compiler do the optimizing. I guess most compilers will >recognize this? >Richard. Your suggestion seems to be better. The point is that I have significant names instead of A0,A1,.... and I do not want to lose the significant names. I only wrote here A0, A1 to explain the point because otherwise I cannot use a simple formula based on the name of the array. I already finished the replace of the array and I now only need to add your definitions and save calculations that are done twice for both arrays. The arrays practically are not the same but every time that I call A[i][j] it is the same as Ai[j], so it is a waste of time to calculate A[i][j] and I can have A[8][64] only in the definitions and never use it in the program and continue to use the original names that I have instead of A0...A7 thanks to your post. 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.