[Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Mon, Aug 20, 2001 at 10:19:06PM +0300, Markus Linnala wrote:
> Raimar Falke <hawk@xxxxxxxxxxxxxxxxxxxxxxx> writes:
>
> > find_genlist_position() does the right thing for -1. So there is only
> > the overhead of one (find_genlist_position) function call.
>
> That overhead of one function call is not negligible. More than
> 3%.
The 3% doesn't convince me but this one:
-----------------------------------------------
0.00 0.00 632/8136906 genlist_get [566]
0.34 0.00 8136274/8136906 genlist_iterator_init [42]
[77] 1.6 0.34 0.00 8136906 find_genlist_position [77]
-----------------------------------------------
And a lot if not all calls to genlist_iterator_init have a position of
0 or -1. So I would vote for a genlist_iterator_init_from_head and a
genlist_iterator_init_from_tail.
Raimar
--
email: rf13@xxxxxxxxxxxxxxxxx
reality.sys corrupt. Reboot Universe? (y,n,q)
- [Freeciv-Dev] [PATCH] Small improvement at genlist and maphand, Markus Linnala, 2001/08/20
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Raimar Falke, 2001/08/20
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Markus Linnala, 2001/08/20
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand,
Raimar Falke <=
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Justin Moore, 2001/08/20
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Raimar Falke, 2001/08/21
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Justin Moore, 2001/08/21
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Justin Moore, 2001/08/21
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Raimar Falke, 2001/08/21
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Justin Moore, 2001/08/21
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Raimar Falke, 2001/08/22
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Justin Moore, 2001/08/22
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Raimar Falke, 2001/08/22
- [Freeciv-Dev] Re: [PATCH] Small improvement at genlist and maphand, Trent Piepho, 2001/08/22
|
|