Squeak Socket Primitives

Raab, Andreas Andreas.Raab at disney.com
Wed Nov 10 21:00:50 UTC 1999


Lex,

> When people say "poll" from the image, are they talking about things
> like "self dataAvailable" and "self isConnected"?  Well, how slow can
> such checks possibly be, especially if the VM can answer such requests
> without doing a system call?  I'd wager they could be tuned up to be
> pretty darned fast if you try.  And it seems like you can't avoid some
> of them no matter what you do--for instance, it's critical to keep
> verifying that the socket is still connected before you try anything
> else.

You are partly right. The efficiency problem that we currently have (in
particular for servers) is mainly due to the fact that the support code
doesn't know what state changes are of interest and must therefore monitor
socket state continuously. This constant monitoring at the VM level is what
Craig refers to as polling and this is where his set of prims differ. I have
just sent out my comparison of the Squeak and Correspondants prims to a
number of people (if there is interest I can post it to the list as well).
So, it is in fact the case that Craig's implementation will prove to be more
responsive in particular for server applications.

  Andreas





More information about the Squeak-dev mailing list