[fpc-devel] fpfork
Michael Schnell
mschnell at lumino.de
Mon Feb 11 12:16:22 CET 2008
Jonas Maebe wrote:
>
> In some cases memory is still allocated between the fork and the exec.
> You cannot use vfork in such a case. That code still has to be
> rewritten so it does not allocate any memory.
Do you suggest that some improvement should be done there ? Of course I
will try to do this for the other architectures once I'll get started
with that task and fully understand the implications. I feel that a
better solution would be e.g. to drop the fpVFork function altogether
and do the difference (if necessary at all) in the fpFork function.
>
>> - vfork seems to be used in BSD and SUNOS. Why just in these systems ?
>
> Correction: it is only used on those systems if the RTL is libc-based.
> And the reason is that our thread variable implementation and its use
> in the syscall implementations conflicts with using vfork.
Don't you use the pthread library for the implementation of pascal
threads ? (Threads and inter thread communications is another issue that
I'll need to investigate - and maybe improve - when I'll start to do the
"embedded pascal" project.)
>
>> - when doing a non-MMU (µCLinux) architecture fork is not available.
>> What is the best way of handling that situation ? (Should we
>> introduce a UCLINUX OS flavor ?)
>
> Does it already have posix_spawn?
I don't know. The expert are just trying to get a 2.6. µCLinux version
out of the door and I don't even have any hardware to test yet.
Thanks for your answers !
-Michael
More information about the fpc-devel
mailing list