[Freeciv-Dev] Re: [RFC] Path finding implementation.
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
At 09:09 PM 02/06/29 +0200, Raimar Falke wrote:
>On Sat, Jun 29, 2002 at 07:31:04PM +0100, Gregory Berkolaiko wrote:
>> Mmm...
[...]
>> Thus if we had an iterator working directy with xy,
>> adjc_xy_iterate(xy, xy1) {
>> /* ... */
>> }
>> this would make indexed approach both the most convinient and the fastest.
>
>I don't think that you can improve the access much beyond two memory
>accesses and one lea (which you get with 2D array).
Not with your precomputed reference flavour, you are correct in this.
But in most cases, you will drop your index array access and end up with
a single memory access when accessing the value if you don't try to out
think the compiler and just let it handle the index computations :-).
> Raimar
>--
Cheers,
RossW
=====
- [Freeciv-Dev] Re: [RFC] Path finding implementation., (continued)
[Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/28
- [Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation., G. Dyke, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation., Ross W. Wetmore, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/29
- [Freeciv-Dev] Re: [RFC] Path finding implementation.,
Ross W. Wetmore <=
[Freeciv-Dev] Re: [RFC] Path finding implementation., Ross W. Wetmore, 2002/06/30
[Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/30
[Freeciv-Dev] Re: [RFC] Path finding implementation., Ross W. Wetmore, 2002/06/30
[Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/29
[Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/29
[Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/29
[Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/29
[Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/29
[Freeciv-Dev] Re: [RFC] Path finding implementation., Raimar Falke, 2002/06/30
[Freeciv-Dev] Re: [RFC] Path finding implementation., Gregory Berkolaiko, 2002/06/30
|
|