This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Copy-on-write fork


On Sat, Apr 20, 2002 at 03:06:55AM +0100, Chris January wrote:
>This is mainly a question aimed at Christopher Faylor, but maybe someone
>else knows the answer.
>My question is, with regard to Chris's post "Re: copy-on-write (oh well)"
>[http://www.cygwin.com/ml/cygwin-developers/2000-07/msg00026.html], does
>anyone know why a copy-on-write implementation of fork takes longer than the
>current Cygwin version??
>BTW, I've not had any problems forking beyond the first level using the
>example code from 'Window NT/2000 Native API reference'. What problems did
>you encounter Chris? My test case is probably not rigorous enough.

I don't know.  I've remarked on this in the past.  My benchmarks showed
the same thing.  I was excited about doing this when I was first hired
by Cygnus since I wanted to contribute to making cygwin faster.

I implemented a fork using Windows API copy-on-write (for NT) and I
believe I also tried to use the low-level NT technique.  Neither showed
any noticeable performance gain and, of course, both suffered from
being NT-only.

I assume that one possible reason is that the copy-on-write fork may be
somehow bypassing normal in-memory sharing of text segments but I never
knew for sure.

The problems with forking beyond the first level are for the Windows
API method, not with the low-level NT calls.

cgf

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]