[Freeciv-Dev] Warmap optimization (was Re: Exploring triremes getting lo
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
--- Raimar Falke <hawk@xxxxxxxxxxxxxxxxxxxxxxx> wrote:
> > diff -ur -Xfreeciv/diff_ignore freeciv/server/gotohand.c
> freeciv_mod/server/gotohand.c
> > --- freeciv/server/gotohand.c Sun Sep 16 20:20:04 2001
> > +++ freeciv_mod/server/gotohand.c Sun Sep 16 21:09:23 2001
> > @@ -182,6 +182,7 @@
> > freelog(LOG_DEBUG, "returned before. getting next");
> > return get_from_mapqueue(x, y);
> > } else {
> > + warmap.returned[*x][*y] = 1;
>
> Why this change?
Right now warmap has a special field "returned" which is never changed
from it's initial zero value. If my guess is correct, it's intended use
was to indicate that the node was already processed and, the way warmap
works, there is no possibility that processing it again will improve
anything. So it should be used to avoid processing the same thing twice.
However when I added the above line and run some auto games, the
performance didn't change visibly. The savegames were identical, which
is good. Maybe I didn't have enough statistics...
I will do some more experiments with it.
G.
____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), (continued)
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Gregory Berkolaiko, 2001/09/17
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Raimar Falke, 2001/09/18
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Gregory Berkolaiko, 2001/09/18
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Raimar Falke, 2001/09/18
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Gregory Berkolaiko, 2001/09/18
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Ross W. Wetmore, 2001/09/17
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Gregory Berkolaiko, 2001/09/18
- [Freeciv-Dev] Re: [Patch] Exploring triremes getting lost (PR#961), Tony Stuckey, 2001/09/18
[Freeciv-Dev] Warmap optimization (was Re: Exploring triremes getting lost),
Gregory Berkolaiko <=
|
|