PythonThreading

George mydevgroup at gmail.com
Thu Sep 1 23:41:13 CEST 2011


Hi,
Why doesn't python threads show an associated PID?  On spawning python
threads using the threading module I can only see the main thread's pid on
using top or ps unix command, no  subprocesses are displayed. In otherwords
top or ps in not aware of any subprocesses created using threading module in
python.

Whereas in Java , creating threads will result in separate pid , these
subprocesses can be listed using top or ps. Java threads get mapped to the
cores in the system.

Does it mean that python threads are not mapped to the core in the system.
On using multiprocessing module, separate processes are created with unique
PID.


Any input would be great
George





More information about the Python-list mailing list