This is the mail archive of the
mailing list for the GCC project.
Re: Is there any reason to use vfork() ?
- From: "Michael N. Moran" <mnmoran at bellsouth dot net>
- To: niXman <i dot nixman at autistici dot org>
- Cc: pinskia at gmail dot com, gcc at gcc dot gnu dot org
- Date: Tue, 13 May 2014 11:47:18 -0400
- Subject: Re: Is there any reason to use vfork() ?
- Authentication-results: sourceware.org; auth=none
- References: <db279b78b31710a4d4a38e37817520e9 at autistici dot org> <D5C7AF9D-88B7-4683-A45B-5D7506D4B97F at gmail dot com> <438b671e26e4e2e3d10e0e0b81a57108 at autistici dot org>
On 05/13/2014 10:59 AM, niXman wrote:
pinskia 2014-05-13 18:47:
Can you share more information about this env.
This is specially built distributive used for micro-pc.
It might be a bug not in gcc.
I'm sure that the bug not in the GCC. After I wrote to this
ML I made sure that freezes any program using 'vfork()'.
I'll deal with it ...
I just wanted to understand the reasons to use 'vfork()'
instead of 'fork()'.
I cannot speak for GCC, but I work with embedded Linux
systems and we use vfork() to reduce the memory footprint
of child processes. When a process is created with
fork() it's memory footprint is the same as the parent
process (copied page tables). The same is not true with
This is particularly important in the embedded systems
space with limited RAM.
Consider the system RAM requirements for a parent process
with a large RAM footprint that needs to spawn a child
process with an otherwise much smaller RAM footprint.
Michael N. Moran (h) 770 516 7918
5009 Old Field Ct. (c) 678 521 5460
Kennesaw, GA, USA 30144 http://mnmoran.org
The Beatles were wrong: 1 & 1 & 1 is 1