Complete.Org: Mailing Lists: Archives: freeciv-ai: July 2004:
[freeciv-ai] Re: (PR#6912) Optimize/reimplement CM: per-city caches
Home

[freeciv-ai] Re: (PR#6912) Optimize/reimplement CM: per-city caches

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [freeciv-ai] Re: (PR#6912) Optimize/reimplement CM: per-city caches
From: "Benoit Hudson" <bh@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 20 Jul 2004 11:14:12 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=6912 >

On Tue, Jul 20, 2004 at 09:54:17AM -0700, Jason Short wrote:
> > [bhudson - Mon Mar 01 03:17:03 2004]:
> > 
> > I can't think of any problem of copying the parameter, but please
> > inform me if it's just a lack of imagination on my part.
> 
> 1.  It's slow.

It's 64 bytes.  We'd be copying it at most once per call to a function
that solves an NP-hard problem.  Not a problem.

> 2.  Some values in the struct may themselves be pointers.  So that data
> wouldn't actually be copied.

We'd be using the cm_copy_parameter function, so all data would be
correctly taken care of.

        -- Benoît




[Prev in Thread] Current Thread [Next in Thread]