Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2006-07

mutexes and semaphores.

3 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Andreas Berger

In order to implement threading in DOS I will need to use some type of mutex, but would like to implement it the FPC way.

Does FPC implement platform independent mutexes and/or semaphores? Or must each platform use it's own OS specific versions?

Regards,
Andreas

���� ����������� � mail.ru
to Andreas Berger

AB> In order to implement threading in DOS I will need to use some type of AB> mutex, but would like to implement it the FPC way.

AB> Does FPC implement platform independent mutexes and/or semaphores? Or AB> must each platform use it's own OS specific versions?

Michael Van Canneyt can answer this question, there are some parts in FCL approaching OS independence.

Michael Van Canneyt
to Andreas Berger: In order to implement threading in DOS I will need to use some type of mutex, but would…
Andreas Berger wrote
In order to implement threading in DOS I will need to use some type of mutex, but would like to implement it the FPC way.

There is no "FPC way" :-)

Does FPC implement platform independent mutexes and/or semaphores? Or must each platform use it's own OS specific versions?

Each platform currently uses it's own OS specific version.

For FPC, it should be enough to implement RTLCiticalSection support, using the thread manager. The Syncobjs unit in the FCL uses that to implement classes which can be used as a mutex.

Michael.