state-threads
[Top] [All Lists]

Re: Porting from POSIX threads to State Threads

To: state-threads@xxxxxxxxxxx
Subject: Re: Porting from POSIX threads to State Threads
From: Dan Melomedman <dmelomed@xxxxxxxx>
Date: Mon, 30 Jul 2001 19:19:19 -0400
In-reply-to: <Pine.GSO.4.05.10107301353300.3714-100000@xxxxxxxxxxxxxxxx>
Mail-followup-to: state-threads@xxxxxxxxxxx
References: <Pine.GSO.4.05.10107301353300.3714-100000@xxxxxxxxxxxxxxxx>
Sender: owner-state-threads@xxxxxxxxxxx
User-agent: Mutt/1.3.18i
On Mon, Jul 30, 2001 at 02:14:31PM -0700, Claude Johnson wrote the following:
> Alright, my basic question is what are the gotchas in 
> making this move? 
> 
> I couldn't find anything in the archives about experiences
> or "good to knows" in making the move from POSIX threads 
> to ST. I'm guessing the list would be fairly extensive.
> So if someone can run down the major gotchas, that would
> be helpful, in the sense of what are major differences 
> between Pthreads and State Threads.

If your thread blocks in ST, then your process blocks. Because of this,
all network and disk I/O calls that are not implemented with ST library
should either be converted to use ST, or should be used in an external
process. Usually you do not need mutexes or thread safety like in most
Pthread libraries in ST.

<Prev in Thread] Current Thread [Next in Thread>