Computer Chess Club Archives


Search

Terms

Messages

Subject: Programming question.

Author: Inmann Werner

Date: 13:06:10 03/19/99


Hello.

Today I changed my hashtables from fixed one ta allocated one.

Example
Old

long hindex[65536]
signed char hcolor[65536]
signed short int value[65536]
.....

New

long *hindex
signed char *hcolor
signed short int *value
....

hindex=malloc(4*65536)
hcolor=malloc(65536)
value=malloc(2*65536)
....

Works fine but:

On my P90, the NPS decreases about 30%  !!!!!
On my Cyrix 233 everything is fine (same speed)

Do I anything extremly wrong or what happens here. Has this something to do
with Prozessor cache or what?

Any suggestions??

Werner

P.S.: Excuse my C, I come from Cobol....
I use Watcom C Version 11 Compiler.



This page took 0.01 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.