Hi Vijay,

> About the lack of shared libraries on Plan9: Plan9 don't need shared
> libraries because components on Plan9 can interact using just four
> system calls - open, read, write and close. As an example consider a
> graphics library that could be shared by various applications:
> /* Pseudo C */
> handle =3D  LoadLibrary ("graphics.so");
> CallFn (handle, "drawRect", 0, 0, 200, 200);
> Close (handle);
> The equivalent plan9 code will be something like this:
> handle =3D open ("/sys/graphics/cntl");
> cmd =3D "drawRect 0 0 200 200";
> write (handle, cmd, strlen (cmd));
> close (handle);
> The interesting thing is that /sys/graphics/cntl/ could be on a remote
> file system. This makes distributed computing easy and shared
> libraries redundant.

that's very nice, no need for all that ffi as usual on linux or windows
and all works from text based scripts.  However, I wonder how bad is the
performance penalty for marshalling and unmarshalling all those calls as
opposed to pasing args directly in C.  I suppose the advantage of
transparent distribution is more valued in Plan 9 than the raw speed.


UNSUBSCRIBE: mailto:picol...@software-lab.de?subject=unsubscribe

Reply via email to