[fpc-devel] semaphores and mutes

Boian Mitov mitov at mitov.com
Sat Jun 21 00:37:58 CEST 2008


   Hi Peter,

Thank you!
I am already working to implement the Semaphores, and Mutexes.
I need timeout. Can you please post the patch? This is actually very 
important issue, as the libraries use threads extensively, and share huge 
number of resources. The timeouts are needed to resolve deadlocks.

  With best regards,
    Boian Mitov

--------------------------------------------------------------------
Mitov Software
http://www.mitov.com
--------------------------------------------------------------------


----- Original Message ----- 
From: "Peter Popov" <ppopov at tamu.edu>
To: "FPC developers' list" <fpc-devel at lists.freepascal.org>
Sent: Friday, June 20, 2008 3:32 PM
Subject: Re: [fpc-devel] semaphores and mutes


> Anyways, some time ago I debuged the issue and patched kylix's SynObjs 
> unit to cure that. Basically, the problem is, as expected, glibc. Older 
> version did not have sem_timedwait() implemented. Later glibc included it, 
> along with several new variants of the remaining semaphore routines. So, 
> based on what thread model is used (LinuxThreads or NTPL) each semaphore 
> routine is implemented several times. The thing is a total mess. Anyways, 
> if one explicitly instructs the kylix linker which version of semaphore 
> functions to use (they have to be consistent) TEvent.WaitFor can be 
> implemnted for any timeout. If there is interest I can post the patch.
>




More information about the fpc-devel mailing list