Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2003:
[Freeciv-Dev] Re: (PR#3391) SDL client polls the network
Home

[Freeciv-Dev] Re: (PR#3391) SDL client polls the network

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: jdorje@xxxxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#3391) SDL client polls the network
From: "Raimar Falke via RT" <rt@xxxxxxxxxxxxxx>
Date: Wed, 12 Feb 2003 03:47:58 -0800
Reply-to: rt.freeciv.org@xxxxxxxxxxxxxx

On Wed, Feb 12, 2003 at 03:27:04AM -0800, Jason Short via RT wrote:
> Raimar Falke wrote:
> > On Wed, Feb 12, 2003 at 11:22:24AM +0100, Rafa? Bursig wrote:
> 
> >>Some time before Bob Pendelton fight with this problem and he
> >>creatae thread based event code (see:
> >>http://gameprogrammer.com/game.html )
> > 
> > 
> > Bob is a lot wiser than the SDL people by using a condition
> > variable. If you have condition variables and can use threads (and
> > both are AFAIK part of SDL) these are superior to polling. His FE
> > (fast events) looks a lot like classical select. Select here takes the
> > role of SDL_CondWait.
> 
> If SDL implements the condition variable, then it's possible it uses 
> polling too.  In that case there wouldn't be any advantage.

I hope this is only the case for very exotic platforms. Looking at
http://www.libsdl.org/cgi/cvsweb.cgi/SDL12/src/thread/ suggests that
it uses native OS implmentations most of the time.

> At some point, though, you have to put trust in the library authors. 

My trust in the SDL library authors isn't very high.

> Either that, or rewrite/fix the library...

Or don't use it. We have also other clients ;)

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx
 "Microsoft DNS service terminates abnormally when it recieves a response
  to a DNS query that was never made.
  Fix Information: Run your DNS service on a different platform."
    -- MS service information on bugtraq




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