What happen if fthread IO is on the async wait list and
fthread P tries to do a transfer on an fchannel?

Normally an active fthread does fchannel transfers by placing
the peer fthread onto the active fthread list (or, actually
making it the active thread).

But if the peer is on the async wait list, all hell will break
loose because it will resume executing from its blocking
point, but also remain on the async wait list.

[I don't think I've seen this happening, but it could ..]

The right way is to notice that the fthread is blocked
on async and don't put it on the active list, since
the demux wakeup will do that anyhow.

A more coherent way to do this might be to actually
use the fchannel interface for the wakeup. What happens
is not quite as simple as described above. If the fthread
is waiting on a different channel, it won't be scheduled.
[It is actually the channel I/O transfers that do the scheduling!]

--
john skaller
[email protected]





------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Felix-language mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/felix-language

Reply via email to