Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Separate Thread or plain Loop??

Author: David Rasmussen

Date: 10:53:57 12/18/01

Go up one level in this thread


On December 18, 2001 at 12:32:43, Miguel A. Ballicora wrote:

>
>Well, there is not portable way to poll in C either. So, if portability is an
>issue, the question is which approach will give "better chances" to port it.
>I do not think that doing it with threads is necessarily more difficult to port.
>It depends very much on how it was implemented, I guess. The way I did it
>I used only two functions that I should be able to find in any multithreaded
>environment. One that launches the thread and another that waits to finish (so
>one thread can wait to the other after sending a message (a global variable)
>that a move has been entered etc.)
>I am NOT an expert on this, but I guess that I should be able to port this
>without much of a headache. I have't tried yet.
>
>Regards,
>Miguel
>

You are absolutely right, my mistake. Both ways are non-portable. And since
pthread libraries exists for almost everything, the portability is at least as
good for threading than for non-threading in this case.

/David



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.