URL: <http://gna.org/patch/?3715>
Summary: Threaded AI cities generating Worker task requests Project: Freeciv Submitted by: cazfi Submitted on: Mon 18 Feb 2013 04:32:04 AM EET Category: ai Priority: 5 - Normal Status: In Progress Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any Planned Release: 2.5.0 _______________________________________________________ Details: This proof-of-concept patch adds first real work to threaded AI's subthread. In the beginning of the player phase, cities evaluate potential worker tasks in their area, and send best one to the main thread to set for the city. When workers then have time, they take these tasks. This still needs a lot of work before it gives as good results as current model of settlers always looking for job themselves. - Supports only a few worker tasks, no road or base building - Assumes that any task it evaluates is possible, i.e., may request impossible tasks - Virtually no mutex protection so threads may handle the city simultaneously leading them to get inconsistent values - Does not give out values of the tasks. Worker may end working on almost-zero-value task of one city when nearby city has urgent task. - Does not care about lenght of the work, only about value of sfinished work _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Mon 18 Feb 2013 04:32:04 AM EET Name: ThreadedCityRequests.patch Size: 7kB By: cazfi <http://gna.org/patch/download.php?file_id=17243> _______________________________________________________ Reply to this item at: <http://gna.org/patch/?3715> _______________________________________________ Message sent via/by Gna! http://gna.org/ _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev