Sujet : Re: best approach for multithreading (?)
De : 643-408-1753 (at) *nospam* kylheku.com (Kaz Kylheku)
Groupes : comp.lang.cDate : 06. Dec 2024, 04:14:13
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <20241205191339.256@kylheku.com>
References : 1 2 3 4 5 6 7
User-Agent : slrn/pre1.0.4-9 (Linux)
On 2024-12-06, James Kuyper <
jameskuyper@alumni.caltech.edu> wrote:
On 12/3/24 12:48, Kaz Kylheku wrote:
...
Think about it. The POSIX standard includes ISO C by reference.
So that means POSIX has to have two thread libraries.
It's a waste of flash in embedded systems.
>
C <threads.h> can be implemented as a thin wrapper over POSIX threads.
The waste is relatively negligible. The differences, were intended to
allow <threads.h> to also be implemented on non-POSIX systems as
wrappers for whatever the native threading system was.
Generally speaking, you can have a function called pthread_create on
non-POSIX systems, and a header <pthread.h>.
-- TXR Programming Language: http://nongnu.org/txrCygnal: Cygwin Native Application Library: http://kylheku.com/cygnalMastodon: @Kazinator@mstdn.ca