basic thread question

sturlamolden sturlamolden at yahoo.no
Tue Aug 25 14:25:19 EDT 2009


On 25 Aug, 13:33, Piet van Oostrum <p... at cs.uu.nl> wrote:

> I have heard about that also, but is there a Python implementation that
> uses this? (Just curious, I am not using Windows.)

On Windows we have three different versions of Python 2.6:

* Python 2.6 for Win32/64 (from python.org) does not have os.fork.

* Python 2.6 for Cygwin has os.fork, but it is non-COW and sluggish.

* Python 2.6 for SUA has a fast os.fork with copy-on-write.

You get Python 2.6.2 for SUA prebuilt by Microsoft from http://www.interopsystems.com.

Using Python 2.6 for SUA is not without surprices: For example, the
process is not executed from the Win32 subsystem, hence the Windows
API is inaccessible. That means we cannot use native Windows GUI.
Instead we must run an X11 server on the Windows subsystem (e.g. X-
Win32), and use the Xlib SUA has installed. You can compare SUA to a
stripped down Linux distro, on which you have to build and install
most of the software you want to use. I do not recommend using Python
for SUA instead of Python for Windows unless you absolutely need a
fast os.fork or have a program that otherwise requires Unix. But for
running Unix apps on Windows, SUA is clearly superior to Cygwin.
Licencing is also better: Programs compiled against Cygwin libraries
are GPL (unless you buy a commercial license). Program compiled
against SUA libraries are not.



Sturla Molden



More information about the Python-list mailing list