• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [Fwd: Re: execv bug???]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Fwd: Re: execv bug???]


  • Subject: Re: [Fwd: Re: execv bug???]
  • From: Jonas Maebe <email@hidden>
  • Date: Sun, 27 Jan 2008 23:46:55 +0100


On 27 Jan 2008, at 20:56, Peter Seebach wrote:

In message <email@hidden>, Steve writes:
So, are you suggesting then it could well be a bug with Leopard (it
works fine on Tiger and, it works fine as coded by simply removing the
v from vfork)? Obviously, the simple solution on Leopard for now is to
use fork. I shall proceed to make a small test program and submit to
Apple then.

I wouldn't consider it a significant bug; vfork is deprecated, having been
a performance hack to improve performance on the VAX. The existence of
modern systems with copy-on-write semantics makes it a waste of time to try
to make things work with vfork

That's more or less true for Linux, but not for Mac OS X at least up till 10.4.x (I haven't benchmarked on 10.5 yet). Compiling our compiler with itself, which involves about 173 (v)fork+execs from a single compiler run to assemble&link all the files, is 20% to 25% slower with fork instead of vfork on a G4, and 35% to 40% on a G5 (32 bit processes in both cases) on 10.4.x. And for clarity: this is relative to the entire time needed for compiling+assembling+linking everything (on the G5: 24 vs 15 seconds), not some academic mbench- like speed difference between the fork and vforks.


Copying the memory maps is extremely expensive on Darwin (at least in the versions I tested on), and gets progressively more expensive the more memory the program has allocated.

The modern alternative is obviously posix_spawn, but we cannot use that since we still support 10.3.x (it even probably even still works on 10.1 and 10.2 as well, but I don't test those anymore).


Jonas _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: [Fwd: Re: execv bug???]
      • From: "Jordan K. Hubbard" <email@hidden>
    • Re: [Fwd: Re: execv bug???]
      • From: email@hidden (Peter Seebach)
References: 
 >Re: [Fwd: Re: execv bug???] (From: email@hidden (Peter Seebach))

  • Prev by Date: Re: Running a time consuming background process
  • Next by Date: Re: [Fwd: Re: execv bug???]
  • Previous by thread: Re: [Fwd: Re: execv bug???]
  • Next by thread: Re: [Fwd: Re: execv bug???]
  • Index(es):
    • Date
    • Thread