[PATCH] Use cygwin spawn functions

Richard Henderson rth@redhat.com
Tue Oct 12 16:21:00 GMT 2010


On 10/11/2010 05:41 PM, Richard Henderson wrote:
> Emulating fork(2) on cygwin is a bit of a challenge; the hoop jumping is
> a regular circus act.  Worse, fork has a habit of failing on Windows 7 64-bit,
> as seen in the many "Bad address" and "Resource temporarily unavailable"
> errors during testing
> (e.g. http://gcc.gnu.org/ml/gcc-testresults/2010-10/msg00624.html).
> 
> Cygwin's own faq (sec 5.5) says that it's better to avoid using fork+exec
> when possible and use the spawn family of calls instead.
> 
> With this, I managed an entire check-gcc run without a single spurious
> fork failure for --host=i686-cygwin --target=x86_64-w64-mingw64.
> 
> Like so.  Ok to commit?

Hum.  Actually, something is Not Quite Right with it.

On both WinXP-32 and Win7-64 hosts, a full test run eventually got to a
point where every test would time out.  In both cases, collect2 appears
to have gotten stuck.  More investigation is required.


r~



More information about the Gcc-patches mailing list