[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-gnubg] Simple multi-threading...

From: Jonathan Kinsey
Subject: Re: [Bug-gnubg] Simple multi-threading...
Date: Fri, 05 Jan 2007 22:04:39 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv: Gecko/20061207 Thunderbird/ Mnenhy/

Jonathan Kinsey wrote:
> I'll try and check the initial code in tonight - I'll add a

I've checked in the first go at multi-threading the analysegame
function.  It works fine from MSVC but I seem to have broken something
with mingw (it worked earlier), I've add some GLib threading code so it
should (in theory) work with linux as well.  I'll debug the mingw crash
when I get some time, but that might not be until after the weekend so I
thought I'd check it in now.  Here's some notes:

If you compile the current code without USE_MULTITHREAD defined, it
should be the same as before I checked it in.

If you define USE_MULTITHREAD you must add the multithread.c file.
In multithread.c the MULTITHREADED define at the top controls whether
multiple threads are actually used.  The TRY_COUTING_PROCEESING_UNITS
define will call GetLogicalProcssingUnitCount(), which is in another new
file corecount.c.  This is an Intel sample - and there may be a license
issue in using this code.  You can manually set the number of threads
used from the options dialog.

The main thing outstanding is the double/decision link that I've avoided
(so take/drop decisions aren't included).  Also the progress indicator
is not that responsive (maybe as the cpu is too busy).


Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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