David,
First off I agree with Aaron that using consproc is much better, as it is
supported at the pop-11 level.
If you fork a process, you will create a new process with its own memory.
Any OS would get very confused otherwise; for example how would you control
file access etc.?
I believe that under Linux you can use create(2), [extended by NPTL, I
think] and share VM via a flag. The implications of which I have no idea.
This begs the question what are you really trying to do? Why do you want
multiple threads? Yes, there can be good reasons, but on a single CPU this
is not always the case.
I did write (a few years ago) a pop-11 section to enable communications
between forked processes via pipes, pipe-manager.p. You can have a copy, but
you will a few other files to understand how to use it. It was useful
because I wanted to supply input to a exe file for which I had no source,
and read back the replies.
Joe
<ug57dsm@cs.bham.ac.uk> wrote in message
c3umo3$oo9$1@soapbox.cs.bham.ac.uk">news:c3umo3$oo9$1@soapbox.cs.bham.ac.uk...
> Aaron Sloman wrote:
> > If you really want to share memory the simplest thing is to use
> > 'lightweight' processes, created using consproc, etc.
> >
> > You'll then need to write your own scheduler, as explained previously.
> >
>
> OK, thanks, I'll find my way around this... :)
>
|